Author Topic: NVIDA H264 Codec  (Read 8450 times)

pw44

  • Addicted
  • *
  • Posts: 653
    • View Profile
Re: NVIDA H264 Codec
« Reply #15 on: February 22, 2010, 06:19:32 pm »
Hia,
Could anyone help how to get sound going on H264 files played by mplayer?
TIA

phenigma

  • wants to work for LinuxMCE
  • **
  • Posts: 920
    • View Profile
Re: NVIDA H264 Codec
« Reply #16 on: February 22, 2010, 07:12:47 pm »
I'm not at home right now but I have AAC multi-channel audio over SPDIF working in mplayer from the command line, havn't figured out where/how to put the config to work from LMCE yet.  I'll post what I have done when I get home later today, maybe you can take it the next step.

J.

phenigma

  • wants to work for LinuxMCE
  • **
  • Posts: 920
    • View Profile
Re: NVIDA H264 Codec
« Reply #17 on: February 22, 2010, 10:28:05 pm »
I don't recall where I found this, it works well with mplayer from the command line for AVC/AAC encoded material on my Zotac ION 330 with vdpau.  I don't know what this does under lmce as I havn't tested that yet.  This should work properly with AVC/MPEG1&2/WMV/VC1 video encoded media and AAC/AC3/DTS encoded media.

If your on the core you would need to create ~/.mplayer/config and on an MD this would be /root/.mplayer/config instead.  The file I use looks like this:
Code: [Select]
#Set Video output to VDPAU and use appropriate codecs
vo=vdpau
vc=ffh264vdpau,ffmpeg12vdpau,ffwmv3vdpau,ffvc1vdpau
# Set AC3/DTS PASSTHROUGH and ON THE FLY AC3 RE-ENCODING FOR 6 CHANNEL AAC FILES
ao=alsa:device=hw=0.1
afm=hwac3
channels=6
af=scaletempo,lavcac3enc=1:640:3

This is the only way I have found to on-the-fly re-encode AAC multi-channel encoded files to AC3 so my optical SPDIF connection will pass the surround sound properly.  Without this you would require an HDMI audio connection to pass AAC multi-channel audio properly.

Anyways, I'm not entirely sure if this helps you or not but there it is.

J.
« Last Edit: February 22, 2010, 10:35:15 pm by phenigma »

maverick0815

  • Addicted
  • *
  • Posts: 520
    • View Profile
Re: NVIDA H264 Codec
« Reply #18 on: February 23, 2010, 07:56:05 pm »
hmm...I tried that config with mplayer...but so far the files don't play

phenigma

  • wants to work for LinuxMCE
  • **
  • Posts: 920
    • View Profile
Re: NVIDA H264 Codec
« Reply #19 on: February 23, 2010, 08:03:48 pm »
Try commenting out the final line.

Are you running mplayer from LMCE or the command line?

J.
« Last Edit: February 23, 2010, 08:55:06 pm by phenigma »

pw44

  • Addicted
  • *
  • Posts: 653
    • View Profile
Re: NVIDA H264 Codec
« Reply #20 on: February 23, 2010, 11:25:00 pm »
Hi Phenigma,
IT WORKS. And with mplayer, there is no need to rebuild the MD and regenerate the orbiter.
I did try on a mkv file (after renaming to m2ts), which did not output sound before and a mp4 file (after renaming to m2ts). Both did load subtitles, played sound.
I'm now running mplayer from linuxmce with sound and subtitles.
Thank you very much. I will continue to test and will give feedback.
BTW, is there a way to define the filetypes to be used by mplayer? For pluto-xine, i know is possible to add or remove filestypes (extensions) to/from the database.
Paulo
« Last Edit: February 24, 2010, 06:13:44 pm by pw44 »

maverick0815

  • Addicted
  • *
  • Posts: 520
    • View Profile
Re: NVIDA H264 Codec
« Reply #21 on: February 24, 2010, 12:56:42 pm »
hmmm...perhaps there are some files on my system which just won't play no matter what.
I have some where I got sound but no video too.

pw44

  • Addicted
  • *
  • Posts: 653
    • View Profile
Re: NVIDA H264 Codec
« Reply #22 on: February 24, 2010, 01:11:46 pm »
All my video files output video, some of them didn't output sound and with Phenigma' s hint, all i tested yesterday did output sound. The mp4 and some mvk i needed to rename to m2ts.
With me, pluto-xine crashed when trying to open mp4 files, and after renaming tmp4 to m2ts, mplayer under linuxmce played it., and with Phenigma's hint, with sound.

maverick0815

  • Addicted
  • *
  • Posts: 520
    • View Profile
Re: NVIDA H264 Codec
« Reply #23 on: February 24, 2010, 02:52:09 pm »
I'll try some more when I come home. So I have some mkv that play fine, others play only in mplayer- renamed to m2ts, but badly out of synch....my guess was that this might have something to do with vdpau not working correctly with mplayer...but thats just a shot in the dark on my part

Beeker

  • Guru
  • ****
  • Posts: 267
    • View Profile
Re: NVIDA H264 Codec
« Reply #24 on: February 24, 2010, 03:53:06 pm »
Stupid questions guys
I am assuming my MD is using xine as the default player for my m2ts files and that's why it is having trouble playing the HD 1920 x 1080 home movies with the video in slow motion but the sound is perfect.

So how would I make the default player as mplayer as this may fix my problem....what's everybody's thoughts on this as the actual hardware will play the content quite happily if I boot the MD back into XP

Any advice greatly appreciated
Cheers
Beeker

phenigma

  • wants to work for LinuxMCE
  • **
  • Posts: 920
    • View Profile
Re: NVIDA H264 Codec
« Reply #25 on: February 24, 2010, 04:31:17 pm »
I'll try some more when I come home. So I have some mkv that play fine, others play only in mplayer- renamed to m2ts, but badly out of synch....my guess was that this might have something to do with vdpau not working correctly with mplayer...but thats just a shot in the dark on my part

VDPAU works great in mplayer on my Zotac ION 330.  Playing through a network I have had to add a buffer '-cache 8192' I think does it at the command line, this can probably be added to the config file.

J.

phenigma

  • wants to work for LinuxMCE
  • **
  • Posts: 920
    • View Profile
Re: NVIDA H264 Codec
« Reply #26 on: February 24, 2010, 04:35:00 pm »
Stupid questions guys
I am assuming my MD is using xine as the default player for my m2ts files and that's why it is having trouble playing the HD 1920 x 1080 home movies with the video in slow motion but the sound is perfect.

Xine is the default player for almost all media in LMCE.  Xine can play 1080P content with VDPAU acceleration with no problem.  Your MD should be playing m2ts files should with mplayer by default.

So how would I make the default player as mplayer as this may fix my problem....

This I'm not sure of and it is certainly not recommended as LMCE doesn't have full control of mplayer.

J.

Beeker

  • Guru
  • ****
  • Posts: 267
    • View Profile
Re: NVIDA H264 Codec
« Reply #27 on: February 24, 2010, 04:55:21 pm »
Thanks J for the quick reply and I have tried with VDPAU and it just plays the H264 content in slow motion so it's got me buggered why. Can't understand how the same hardware under XP plays the content fine but not 810b2

Cheers
Beeker

phenigma

  • wants to work for LinuxMCE
  • **
  • Posts: 920
    • View Profile
Re: NVIDA H264 Codec
« Reply #28 on: February 24, 2010, 05:17:20 pm »
The 7600GS doesn't support VDPAU acceleration.  Just because hardware works in Windows doesn't mean that it will work in Linux, software drivers are very different and there are different levels of compatibility under Linux than Windows because of this.

Turn off the VDPAU, your system should be failing back to OpenGL anyways.  You will have to remove the 'vo=...' and 'vc=...' section of the mplayer config file as well.  The system will then rely on your CPU for the decoding and it will need to be hefty to do a good job with h264 media.  Do some searching on the forums there have been discussions about non-vdpau requirements for 1080P playback.

My immediate recommendation would be to ditch the 7600GS and get an 8xxx or 9xxx card with VDPAU acceleration.  Havn't looked myself but I remember posts where people have said a PCI-e 9xxx something or other could be had for around $30.  

Check out nvidia's vdpau hardware compatibility list: http://us.download.nvidia.com/XFree86/Linux-x86/190.53/README/appendix-a.html

J.
« Last Edit: February 24, 2010, 06:04:13 pm by phenigma »

maverick0815

  • Addicted
  • *
  • Posts: 520
    • View Profile
Re: NVIDA H264 Codec
« Reply #29 on: February 24, 2010, 06:35:12 pm »
hmm...the problem remains for me. I checked the files that won't play for corruption- they play fine on my windows-box...renamed them from mkv to m2ts...no game
mplayer crashes whenever I open one of them.