PlayVideo problems....

Started by Cogliostro, Tue 10/06/2014 19:25:01

Previous topic - Next topic

Cogliostro

Okay, I created a video in an attempt to shave a 100MB off the download size.  I put the Earth.avi in the main folder with the Game.agf, run the game, and I get an error stating it cannot find the file.  Check the wiki, the AVI files are supposed to go into the COMPILED folder.  Put the AVI in the COMPILED folder, compile the game, run setup, launch the game, and get the same error.

Use VLC Media Player to convert the game from an AVI to an OGG, get the same error.  Regardless of the folder.
Rename the extension to OGV and it works in the main folder.   

    PlayVideo("Earth.ogv", eVideoSkipEscKey, 11); // works
    PlayVideo("Earth.ogg", eVideoSkipEscKey, 11); // failed
    PlayVideo("compiled/Earth.ogg", eVideoSkipEscKey, 11); // failed
    PlayVideo("Earth.avi", eVideoSkipEscKey, 11); // failed
    PlayVideo("compiled/Earth.avi", eVideoSkipEscKey, 11); // failed

I sort of have a solution, since the OGV works and is 99% smaller!!  However, there's serious loss in the video quality. 

Regardless of anything else, where should the AVI files go to get PlayVideo() to work?  Beyond that, is there a better app for converting video?

- Cogliostro
"First things first, but not necessarily in that order." - Dr. Who

Khris

Did you try this:
PlayVideo("Earth.avi", eVideoSkipEscKey, 11); // failed
while Earth.avi was in the Compiled folder? (you aren't supposed to add "compiled/" like that, afaik)

If you did, build the game (F7), then run it from the Compiled folder.

Grim

Loss in the quality? I've used ogv files for my new game (converted from avi using some first online converter I could find in 30 seconds searching for it) and noticed no quality drop whatsoever. And it works 100%. I mean, I'm no expert on this, but I've been experimenting with playing videos in AGS games lately and found it was fairly easy. Maybe you should try to convert them again using different software?...

Cogliostro


VLC is my video player of choice, but I suspected the conversion aspect was wonky, so thanks for confirming that Grim.


Now, the file Eaerth.avi is current located in the source folder, *AND* in the compiled folder.  The line reads:

  PlayVideo("Eagle.avi",eVideoSkipNotAllowed, 11);

Compile the game (F7), go into the compiled folder, click on Pillars.exe (my executable) and try to play the video and get an error - "Video playing error: File not found: []\Earth.avi"

Run AGS, launch game from there, and get the error: "Video playing error: File not found: []\Compiled\Earth.avi"

The code itself seems fine.  I'm currently suspicious that the AVI won't play unless Windows Media Player is associated with the AVI files.  Regardless I think I'll pickup a different converter and stick to the OGV files.

Thanks for the suggestions,
- Cogliostro
"First things first, but not necessarily in that order." - Dr. Who

Grim

My main argument against AVI is that (supposedly )they might not work for some players depending on their codecs.

SMF spam blocked by CleanTalk