Page 2 of 3

Posted: Mon Apr 03, 2006 9:35 am
by Zeratul
If i will not get image every frame, the animation will not be smooth.

Posted: Mon Apr 03, 2006 9:49 am
by Softanics
Zeratul wrote:If i will not get image every frame, the animation will not be smooth.


Yes, it just plays.

Posted: Mon Apr 03, 2006 9:54 am
by Zeratul
Ok. And what about callback function or function of getting direct access to image buffer for a simple bitmap(RGB) ? Will it be completed on this week ?

Posted: Mon Apr 03, 2006 10:00 am
by Softanics
Zeratul wrote:Ok. And what about callback function or function of getting direct access to image buffer for a simple bitmap(RGB) ? Will it be completed on this week ?


I hope, yes.

Posted: Tue Apr 04, 2006 7:56 pm
by Zeratul
Can you write a small part of code, how to get only RGB bitmap via the same technique as used for alpha bitmaps, while you have no ability to get direct access?

Posted: Wed Apr 05, 2006 7:23 am
by Softanics
Zeratul wrote:Can you write a small part of code, how to get only RGB bitmap via the same technique as used for alpha bitmaps, while you have no ability to get direct access?


Code: Select all

m_hwndFlashPlayerControl =
   CreateWindow(WC_FLASH,
                         NULL,
                         WS_CHILD | WS_VISIBLE,
                         rc.left,
                         rc.top,
                         rc.right - rc.left,
                         rc.bottom - rc.top,
                         m_hWnd,
                         NULL,
                         NULL,
                         NULL);

...

SFPCGetFrameBitmap FPCGetFrameBitmap = { 0 };

SendMessage(m_hwndFlashPlayerControl, FPCM_GET_FRAME_BITMAP, 0, (LPARAM)&FPCGetFrameBitmap);

HBITMAP hBitmap = FPCGetFrameBitmap.hBitmap;

DeleteObject(hBitmap);


But you can't get access to pixels using GetObject.

Posted: Wed Apr 05, 2006 12:53 pm
by Softanics
Please see example:
http://www.flashplayercontrol.com/TEMP/FPCNPaint.zip

Before building download last version of the DLL:
http://www.flashplayercontrol.com/downl ... rolDLL.zip

Posted: Thu Apr 06, 2006 7:48 am
by Zeratul
Thanks. I will check it.

Posted: Mon Apr 10, 2006 7:59 am
by Zeratul
Thanks! It is working very fast. But still there is a problem with using it. How can I create flash control without window(or hidden). When the game started, it will not be nice, to have a lot of additional windows on the screen, which are playing flash movies.

Posted: Mon Apr 10, 2006 8:08 am
by Zeratul
Can it work the same way as with transparent images? but callback will return RGB images of course. Because there are no real benefits if it is impossible.

Posted: Mon Apr 10, 2006 8:56 am
by Softanics
Zeratul wrote:Thanks! It is working very fast. But still there is a problem with using it. How can I create flash control without window(or hidden). When the game started, it will not be nice, to have a lot of additional windows on the screen, which are playing flash movies.


Yes, I understand the problem. When FPC is a hidden window, the notification FPCN_PAINT doesn't work. It will be fixed in the nearest time (tomorrow, I hope). I will post here about the update.
Thank you.

Posted: Mon Apr 10, 2006 9:02 am
by Softanics
Zeratul wrote:Can it work the same way as with transparent images? but callback will return RGB images of course. Because there are no real benefits if it is impossible.


For what you need the transparent image? May be you just want to draw flash with alpha channel to a HDC? I can add the method for that. It will be faster than getting a bitmap with alpha channel.

Posted: Mon Apr 10, 2006 9:51 am
by Zeratul
No. Well. I will describe what I need from this flash player control.

1. No other windows on the screen. They can be hidden or course. But they must not be visible.
2. Every frame get buffer with pixels(for smooth animations). It will be much better If it will be possible to get pixels buffer through some functions, but not through callbacks. Something like: GetLastFrameImage
Because if FPS in flash object will be more then in application, it will slow down the application, because the only thing the application will do in this case is updating frames, not internal processes. This problem appears when dealing with large flash movie playing(I mean full screen). I just tested this.
3. RGB buffer support.

If we will get all of this features, then we will obtain a site license.

1. You promise to do this tomorrow.
2. Will be very good, but I don't know, can you make this or not.
3. It is already supported.
So just 1 and 2 left.

Thats all.

Posted: Tue Apr 11, 2006 8:05 am
by Softanics
Please download updated example:
http://www.flashplayercontrol.com/TEMP/FPCNPaint1.zip
The updated dll is in the this zip (in the Debug folder).

Posted: Tue Apr 11, 2006 10:36 am
by Zeratul
Well. It is working good now. Thanks! But about new version of control ? I mean in download section it is still old. When new one will be added ?