Register
Site Login
Site Search
Forums
Advertisement
Welcome to PocketMatrix. PocketMatrix is dedicated to providing the best online community for mobile device developers and enthusiests. What's new?

Problem opening video files


Problem opening video files

Postby clintsinger » Jan 18, 2007 @ 1:59am

Hi,

After giving up on trying to get GledPlay to work on my Windows CE 5.0 board I thought I would try it out on my Dell x51v. The sample worked fine until I wanted to try out the video class. More specifically all my calls to the "open" method return ReturnCode::ERROR_OPENING_VIDEO regardless of what kind of video I have tried, including ogg/theora created using ffmpeg2theora using the default settings as well as those suggested in the gledplay video documenation. I have also tried mpeg 2 files but I get the same result.

Any suggestions?

Cheers,
Clint
clintsinger
pm Member
 
Posts: 15
Joined: Nov 18, 2004 @ 1:15am


Postby Sergio » Jan 18, 2007 @ 10:39pm

Hi,

Is it working on Windows?
Can you send us a (small) copy of the video?
Can you publish a piece of the source code?

Thank you,
Sergio.
Sergio Fierens

GledPlay
User avatar
Sergio
pm Member
 
Posts: 97
Joined: Mar 17, 2006 @ 2:43pm


Postby clintsinger » Jan 18, 2007 @ 11:49pm

Hi,

I tried opening the file using the desktop version and while it opens fine, all I get is a pink surface blitted to the screen. I will see what I can do about sending the file. The code is pretty simple in that it is just the multistate application with the following changes.

Code: Select all









10 
11 
12 
13 
14 
15 
16 
17 
18 
19 
20 
21 
22 
23 
24 
25 
26 
27 
28 
29 
30 
31 
32 
33 
34 
35 
HRESULT MainEventHandler::onInit(Surface* pBackBuffer, Panel* panel, Application* application)
{
    //Save the pointer to the application, to acces shared components.
    this->application = (InitialApplication *) application;

    frame = 0;

    int nRet = video.open(TEXT("macreddin_sample_wmv.ogg"));
    if (nRet != ReturnCode::OK)
    {
        return ReturnCode::ERROR_OPENING_VIDEO;
    }

    return ReturnCode::OK;
}

HRESULT MainEventHandler::onNextFrame(Surface* pBackBuffer, Panel* mainPanel)
{
    HRESULT hr = video.getNextFrame(&videosurface);
    switch(hr)
    {
    case ReturnCode::OK:
        // Blit the image to the screen
        pBackBuffer->bltFast(0, 0, &videosurface);
        frame++;
        break;
    case ReturnCode::END_OF_VIDEO:
        // Video is over
        break;
    default:
        break;
    }

    return ReturnCode::OK;
}
35 lines; 13 keywds; 3 nums; 84 ops; 1 strs; 3 coms    Syntactic Coloring v0.4 - Dan East  


On another note, the xp build of the application has an extremely annoying behaviour where it minimizes the screen when it loses focus.
clintsinger
pm Member
 
Posts: 15
Joined: Nov 18, 2004 @ 1:15am


Postby Sergio » Jan 21, 2007 @ 10:18pm

I'm sorry, but I'm really going to need an example video. Could you send it (up to 10Mb) to

sergio (at) gledplay.com

I'm really sorry for all this inconveniences.

Best regards,
Sergio.
Sergio Fierens

GledPlay
User avatar
Sergio
pm Member
 
Posts: 97
Joined: Mar 17, 2006 @ 2:43pm


Return to GledPlay


Sort


Forum Description

Game Engine for Embedded Devices. Simple, complete, and powerful. Focused on the game.

Moderators:

Matias, Sergio

Forum permissions

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

cron