project-navigation
Personal tools

Poll

Does the audio stutter or have issues when playing video cinematic clips?

Yes, there are problems
3 (100%)
No, it plays fine
0 (0%)

Total Members Voted: 3

Author Topic: Who has audio/sound issues with intro video clip?  (Read 8505 times)

Offline Destructavator

  • Combination Multiple Specialty Developer
  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 1908
  • Creater of Scorchcrafter, knows the zarakites...
    • View Profile
Who has audio/sound issues with intro video clip?
« on: January 30, 2010, 05:07:23 pm »
I've noticed on my computer that when playing the intro video clip, or any OGM or RoQ video for that matter (although right now the working copy just has one video, the intro video), I still get stuttering audio and other issues with the soundtrack even though the graphic content displays fine.  I thought it was my system only, because I use special music/audio engineering studio soundcards that most people don't have on their computers (they cost a lot of money, and are nothing like Sigmatel or SoundBlaster).

I've now seen on the IRC channel and other places that some other people also have this issue, while some people have no problems at all - I wanted to post this to see how many have bad audio playback.

If you do vote, please also post your system hardware specs along with what operating system you are running and what version/revision of the game you experienced this with.

Please also post whether or not you are working with a virtual environment (such as running Windows/WINE within Linux in a shell, for example).

Edit:  You can manually play a video at any time in the game by pulling up the console and typing "cinematic" followed by the video filename.

Offline joe davis

  • Rookie
  • ***
  • Posts: 55
    • View Profile
Re: Who has audio/sound issues with intro video clip?
« Reply #1 on: January 31, 2010, 03:22:44 am »
How does one pull up the console?  Though it might be posted somewhere on the forum, thought I might not be the only one who doesn't know so maybe it would be nice to have instructions here.  Also what is the easiest method of acquiring what revision I am in?

Offline Xune

  • Rookie
  • ***
  • Posts: 18
    • View Profile
Re: Who has audio/sound issues with intro video clip?
« Reply #2 on: January 31, 2010, 04:24:08 am »
Yes, I had problems with the video playback when I first started my installation of Mutton's ufoai_28213 windows build. The sound playback was stuttering and distorted, crackling. I also believe the video playback stuttered too. I didn't wait around long, just hit the escape key and continued on with the game. Only saw this the once as the video appears to be suppressed on subsequent startups. Is there a flag to run it on startup so I can check the exact symptoms again?

My specs just in case:
Windows XP
AMD 2800+ XP
Asus A&N8X Deluxe using onboard nforce sound
nvidia 7600gs

I'm using the latest graphics drivers and the most recent (but very) old sound drivers.

Offline Destructavator

  • Combination Multiple Specialty Developer
  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 1908
  • Creater of Scorchcrafter, knows the zarakites...
    • View Profile
Re: Who has audio/sound issues with intro video clip?
« Reply #3 on: January 31, 2010, 05:06:46 am »
There isn't a flag to run it again, unless you delete the APPDATA config files as if you had just made a fresh install of the game, but the console command will play it.

To pull up the console, press the "~" key (On most common keyboards this is in the top-left corner next to the number "1" and above TAB).

Also, if you type just "cinematic" and hit ENTER without any parameters, the game will list filenames of available video clips to play.


Offline Xune

  • Rookie
  • ***
  • Posts: 18
    • View Profile
Re: Who has audio/sound issues with intro video clip?
« Reply #4 on: January 31, 2010, 05:25:37 am »
Ok, there is no apparent break in video's frame rate but I do get stuttering accompanied by static in the audio.

Offline Mattn

  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 4831
  • https://github.com/mgerhardy/vengi
    • View Profile
    • Vengi Voxel Tools
Re: Who has audio/sound issues with intro video clip?
« Reply #5 on: January 31, 2010, 09:24:32 am »
There isn't a flag to run it again, unless you delete the APPDATA config files as if you had just made a fresh install of the game, but the console command will play it.

the cvar is cl_introshown

Offline Muton

  • Sergeant
  • *****
  • Posts: 496
    • View Profile
Re: Who has audio/sound issues with intro video clip?
« Reply #6 on: January 31, 2010, 11:56:27 am »
I think scaling seems to be the problem

Store this @ your ufoai install under base next to 0vids.pk3
1vids.pk3

run the game open console and type
cinematic small.ogm (play "smothy" [except sometimes scraping noise {like an old platter}])
cinematic big.ogm (slideshow [45% cpu time on a dual core])
cinematic xxl.ogm (no way)

activate options->video->show fps:

I've converted an older avi file using VLC
the small one was scaled down to 0.25
xxl scaled up to 2

vlc play the movie (intro.ogm) smoothy
and btw it looks a lot better and consume much less cpu time
But vlc is using directX
using opengl as output vlc consumes 3 times more cpu time
But still much less than ufo.exe
« Last Edit: January 31, 2010, 12:01:14 pm by Muton »

Offline joe davis

  • Rookie
  • ***
  • Posts: 55
    • View Profile
Re: Who has audio/sound issues with intro video clip?
« Reply #7 on: January 31, 2010, 05:06:16 pm »
used '~' with 'cinematic intro' and replays with choppy audio, not sure which revision, version 2.3 dev 01232010

specs
Windows XP
AMD Athlon 64 3500+
built in AC97 Sound Card
Radeon X1650 series graphics card 512MB

Offline Mattn

  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 4831
  • https://github.com/mgerhardy/vengi
    • View Profile
    • Vengi Voxel Tools
Re: Who has audio/sound issues with intro video clip?
« Reply #8 on: January 31, 2010, 06:01:39 pm »
as i've said in the other intro topic, videos must be power of two in their resolution.

Offline Muton

  • Sergeant
  • *****
  • Posts: 496
    • View Profile
Re: Who has audio/sound issues with intro video clip?
« Reply #9 on: January 31, 2010, 07:08:02 pm »
Mattn --verbose intro

Offline Muton

  • Sergeant
  • *****
  • Posts: 496
    • View Profile
Re: Who has audio/sound issues with intro video clip?
« Reply #10 on: February 02, 2010, 04:00:02 pm »
for information wikis
http://ufoai.ninex.info/wiki/index.php/Artwork#Videos_.28Cutscenes.29
http://ufoai.ninex.info/wiki/index.php/SBTut

It doesnt work anyway
After a look into the code i've found this function
CIN_THEORA_FrameYUVtoRGB24
and i start to think that this software conversion cost so much cpu time
normaly you use hardware overlay for that work
and SDL support that

http://www.bluishcoder.co.nz/2009/06/decoding-theora-files-using-libtheora.html
http://www.gamedev.net/community/forums/topic.asp?topic_id=370896
http://www.bluishcoder.co.nz/2009/01/liboggplay-playback-performance.html
Quote
http://209.85.135.132/search?q=cache:QrvLUW9uY78J:old.nabble.com/Limitations-of-video-overlay--td18980116.html+sdl+yuv+rgb+24&cd=3&hl=en&ct=clnk
SDL uses Xv to implement YUV support under X. If Xv creation fails
(because of an unsupported video format, because the size is too
big...) you get a software overlay: the YUV data is converted to RGB
in software by SDL and the sent to a "normal" window.

Offline Destructavator

  • Combination Multiple Specialty Developer
  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 1908
  • Creater of Scorchcrafter, knows the zarakites...
    • View Profile
Re: Who has audio/sound issues with intro video clip?
« Reply #11 on: February 02, 2010, 04:34:30 pm »
I'm not sure how related this is, but I do know from past experience that it is indeed more resource-costly to have the main CPU software-render or convert something that should really be left up to the video card.

That would certainly explain quite a bit with these issues.

Now if someone could code a fix - I would do it myself but I'm not that good a C coder yet.


Offline Mattn

  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 4831
  • https://github.com/mgerhardy/vengi
    • View Profile
    • Vengi Voxel Tools
Re: Who has audio/sound issues with intro video clip?
« Reply #12 on: February 02, 2010, 08:08:08 pm »
patches are welcome ;)

Offline Muton

  • Sergeant
  • *****
  • Posts: 496
    • View Profile
Re: Who has audio/sound issues with intro video clip?
« Reply #13 on: February 03, 2010, 09:59:17 pm »
liboggplay seems to be a good way to play ogm files
but compiling this inside mingw is pure dependency hell
I've finaly got it done after a 12h fight

Offline Mattn

  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 4831
  • https://github.com/mgerhardy/vengi
    • View Profile
    • Vengi Voxel Tools
Re: Who has audio/sound issues with intro video clip?
« Reply #14 on: February 03, 2010, 10:14:54 pm »
liboggplay is not available on most linuxes (repos) and macos (macports)