FPCM_GET_TOTALFRAMES fails for FLV files

DLL Edition of the F-IN-BOX
Softanics
Site Admin
Posts: 1402
Joined: Sat Sep 18, 2004 3:03 am
Location: Russia, St. Petersburg
Contact:

Postby Softanics » Mon Oct 06, 2008 6:13 pm

key88sf wrote:Hi - ok one last question :)

After I call LoadFLV() as below, how would I call seekVideo() ??


Could you please try:

CallFunction("<invoke name="seekVideo" returntype="void"><arguments><number>10</number></arguments></invoke>");

?
Best regards, Artem A. Razin,
F-IN-BOX support
Ask your question here: http://www.f-in-box.com/support.html

key88sf
Posts: 17
Joined: Wed Apr 30, 2008 4:48 pm

Postby key88sf » Mon Oct 06, 2008 10:05 pm

I tried this -- I got back S_OK for the HRESULT, but the response string was null and response length was 0. The bitmap returned is still all black :(

Also - when trying to play a FLV with this new player, the messages coming from FPCSetEventListener() are new... for example, instead of getting FPCN_ONREADYSTATECHANGE, I am getting a message with ID = 5114. What is this message?

Finally - when I ignore the new event listener codes, the playback window has the embedded "Play" button on the flash control itself. This is not good, because my app already has a Play button in the main UI window.

I would like the new flash swf control to work with all the regular FPC functions ( Play, Stop, SetFrame, etc... ). Is this possible??

Softanics
Site Admin
Posts: 1402
Joined: Sat Sep 18, 2004 3:03 am
Location: Russia, St. Petersburg
Contact:

Postby Softanics » Tue Oct 07, 2008 6:18 am

key88sf wrote:I tried this -- I got back S_OK for the HRESULT, but the response string was null and response length was 0. The bitmap returned is still all black :(


Does seekVideo work well? Is your window visible?

key88sf wrote:Also - when trying to play a FLV with this new player, the messages coming from FPCSetEventListener() are new... for example, instead of getting FPCN_ONREADYSTATECHANGE, I am getting a message with ID = 5114. What is this message?


FPCN_FLASHCALLW

key88sf wrote:Finally - when I ignore the new event listener codes, the playback window has the embedded "Play" button on the flash control itself. This is not good, because my app already has a Play button in the main UI window.


Use: strFlashVars += _T("&hide_control=true");

key88sf wrote:I would like the new flash swf control to work with all the regular FPC functions ( Play, Stop, SetFrame, etc... ). Is this possible??


No.

The regular functions use regular flash activex interface. When you have single frame with a flv player inside it, FPC_Stop / FPC_Play don't stop / play the video. To work with FLV you use API provided by a FLV Player that you use.

Thank you.
Best regards, Artem A. Razin,

F-IN-BOX support

Ask your question here: http://www.f-in-box.com/support.html

key88sf
Posts: 17
Joined: Wed Apr 30, 2008 4:48 pm

Postby key88sf » Tue Oct 07, 2008 8:11 am

seekVideo doesn't seem to work. My window is not visible, but I call seekVideo like this:

DWORD respLength = 0;
wchar_t seekResp[256] = {0};
FPCCallFunction( m_hWnd, L"<invoke name=\"seekVideo\" returntype=\"void\"><arguments><number>10</number></arguments></invoke>", seekResp, &respLength );

Then I try to get a bitmap snapshot using FPCM_GET_FRAME_BITMAP.

Still all black.

Do I have to tell the FLVPlayer to *play* the video first, *before* calling seekVideo() ??

key88sf
Posts: 17
Joined: Wed Apr 30, 2008 4:48 pm

Postby key88sf » Tue Oct 07, 2008 8:34 am

Also - when playing a FLV using the new player (with a visible window), if I specify hide_control=true, there is a red border on the top and left side of the window. This was not present with the old FLV player control. Can this be fixed?

Softanics
Site Admin
Posts: 1402
Joined: Sat Sep 18, 2004 3:03 am
Location: Russia, St. Petersburg
Contact:

Postby Softanics » Tue Oct 07, 2008 8:48 am

key88sf wrote:seekVideo doesn't seem to work. My window is not visible


Could you please make the window visible to view what are happening?
Best regards, Artem A. Razin,

F-IN-BOX support

Ask your question here: http://www.f-in-box.com/support.html

Softanics
Site Admin
Posts: 1402
Joined: Sat Sep 18, 2004 3:03 am
Location: Russia, St. Petersburg
Contact:

Postby Softanics » Tue Oct 07, 2008 8:56 am

key88sf wrote:Also - when playing a FLV using the new player (with a visible window), if I specify hide_control=true, there is a red border on the top and left side of the window. This was not present with the old FLV player control. Can this be fixed?


In my tests no such effect... Could you please send me the code to support (at) f-in-box.com ?

Thank you.
Best regards, Artem A. Razin,

F-IN-BOX support

Ask your question here: http://www.f-in-box.com/support.html

key88sf
Posts: 17
Joined: Wed Apr 30, 2008 4:48 pm

Postby key88sf » Tue Oct 07, 2008 4:48 pm

Softanics wrote:Could you please make the window visible to view what are happening?


I will try :) Requires a bit of code changes here, but let me see if I can do this.

I will also try to reproduce the red border problem using your sample code. Maybe it is a problem in my code.

key88sf
Posts: 17
Joined: Wed Apr 30, 2008 4:48 pm

Postby key88sf » Tue Oct 07, 2008 7:44 pm

If I use the flvplayer window which is visible that we use for playback, the seekVideo() works.

If I use the flvplayer window which is not visible that we use for generating a bitmap, it does not work. I think maybe the problem is that this window is created in a separate thread which is not the UI thread, and does not have a message pump. Could this be preventing the Flash control from playback / bitmap generation?

Softanics
Site Admin
Posts: 1402
Joined: Sat Sep 18, 2004 3:03 am
Location: Russia, St. Petersburg
Contact:

Postby Softanics » Wed Oct 08, 2008 9:16 am

key88sf wrote:If I use the flvplayer window which is not visible that we use for generating a bitmap, it does not work. I think maybe the problem is that this window is created in a separate thread which is not the UI thread, and does not have a message pump. Could this be preventing the Flash control from playback / bitmap generation?


Yes, it can be a problem. It would be better if you insert a standard message cycle.

Thank you.
Best regards, Artem A. Razin,

F-IN-BOX support

Ask your question here: http://www.f-in-box.com/support.html


Return to “DLL Edition”

Who is online

Users browsing this forum: No registered users and 11 guests