Announcement

Collapse
No announcement yet.

AMD's UVD2-based XvBA Finally Does Something On Linux

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Originally posted by tball View Post
    Bird_42_MBit_ABR runs fine on my computer (HD4650) with thiese versions:
    - libva-0.31.0
    - mplayer-vaapi-20091228
    - xvba-video-0.6.0

    I would love to test the latest bits if I had time. But I just wandered to say that it had actually worked.

    @xipu
    Try run it sith -fs parameter. It makes the movie start in fullscreen, and made the bird movie run smooth on my computer.
    Thanks for the suggestion, but running in fullscreen mode didn't change the performance I saw.

    As a recap, I figured out that my lack of acceleration was caused by having the "-ass" flag in my mplayer config - without this flag (for better subtitle support), vaapi appears to fully accelerate.

    mplayer-vaapi-20091228 (and earlier snapshots) simply don't render ASS subtitles in vaapi mode; I suppose January's builds are better in that respect.

    I found a good sample clip to demonstrate ASS subtitles here: http://matroska.free.fr/samples/mewmew/
    The "mewmew-vorbis-ssa.mkv" clip has 15 different tracks of ASS-format subtitles. Using mplayer-vaapi-20100105 or mplayer-vaapi-20100114 with "-va vaapi -vo vaapi:gl -ass" options, you can see the colorspace/-vf scale warnings in MPlayer:
    Code:
    $ ~/mplayer-vaapi-20100105/mplayer-vaapi/mplayer  -va vaapi -vo vaapi:gl ~/Desktop/mewmew-vorbis-ssa.mkv -ass
    MPlayer SVN-r30226-4.4.1 (C) 2000-2009 MPlayer Team
    
    Playing /home/user/Desktop/mewmew-vorbis-ssa.mkv.
    [mkv] Track ID 1: video (V_MS/VFW/FOURCC), -vid 0
    [mkv] Track ID 2: audio (A_VORBIS), -aid 0, -alang jpn
    [mkv] Track ID 3: subtitles (S_SSA), -sid 0, -slang eng
    [mkv] Track ID 4: subtitles (S_SSA), -sid 1, -slang dut
    [mkv] Track ID 5: subtitles (S_SSA), -sid 2, -slang eng
    [mkv] Track ID 6: subtitles (S_SSA), -sid 3, -slang fin
    [mkv] Track ID 7: subtitles (S_SSA), -sid 4, -slang fre
    [mkv] Track ID 8: subtitles (S_SSA), -sid 5, -slang ger
    [mkv] Track ID 9: subtitles (S_SSA), -sid 6, -slang heb
    [mkv] Track ID 10: subtitles (S_SSA), -sid 7, -slang hun
    [mkv] Track ID 11: subtitles (S_SSA), -sid 8, -slang ita
    [mkv] Track ID 12: subtitles (S_SSA), -sid 9, -slang jpn
    [mkv] Track ID 13: subtitles (S_SSA), -sid 10, -slang nor
    [mkv] Track ID 14: subtitles (S_SSA), -sid 11, -slang pol
    [mkv] Track ID 15: subtitles (S_SSA), -sid 12, -slang por
    [mkv] Track ID 16: subtitles (S_SSA), -sid 13, -slang rus
    [mkv] Track ID 17: subtitles (S_ASS), -sid 14, -slang spa
    [mkv] Track ID 18: subtitles (S_ASS), -sid 15, -slang swe
    [mkv] Will play video track 1.
    Matroska file format detected.
    VIDEO:  [XVID]  640x480  16bpp  23.976 fps    0.0 kbps ( 0.0 kbyte/s)
    [vo_vaapi] Using OpenGL rendering
    libva: libva version 0.31.0-sds4
    libva: va_getDriverName() returns 0
    libva: Trying to open /usr/lib/va/drivers/fglrx_drv_video.so
    libva: va_openDriver() returns 0
    [ass] auto-open
    [ass] Init
    [ass] Updating font cache.
    ==========================================================================
    Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
    [VD_FFMPEG] VA API accelerated codec.
    [VD_FFMPEG] Trying pixfmt=0.
    Unsupported PixelFormat -1
    Could not find matching colorspace - retrying with -vf scale...
    Opening video filter: [scale]
    The selected video_out device is incompatible with this codec.
    Try appending the scale filter to your filter list,
    e.g. -vf spp,scale instead of -vf spp.
    [VD_FFMPEG] Trying pixfmt=1.
    Unsupported PixelFormat -1
    Could not find matching colorspace - retrying with -vf scale...
    Opening video filter: [scale]
    The selected video_out device is incompatible with this codec.
    Try appending the scale filter to your filter list,
    e.g. -vf spp,scale instead of -vf spp.
    [VD_FFMPEG] Trying pixfmt=2.
    Unsupported PixelFormat -1
    Movie-Aspect is undefined - no prescaling applied.
    VO: [vaapi] 640x480 => 640x480 Planar YV12 
    Selected video codec: [ffodivx] vfm: ffmpeg (FFmpeg MPEG-4)
    ==========================================================================
    ==========================================================================
    Opening audio decoder: [ffmpeg] FFmpeg/libavcodec audio decoders
    AUDIO: 48000 Hz, 2 ch, s16le, 0.0 kbit/0.00% (ratio: 0->192000)
    Selected audio codec: [ffvorbis] afm: ffmpeg (FFmpeg Vorbis)
    ==========================================================================
    AO: [alsa] 48000Hz 2ch s16le (2 bytes per sample)
    Starting playback...
    Movie-Aspect is 1.33:1 - prescaling to correct movie aspect.
    VO: [vaapi] 640x480 => 640x480 Planar YV12 
    A:   2.1 V:   2.1 A-V:  0.003 ct:  0.019   0/  0  1%  6%  0.3% 0 0 
    Exiting... (Quit)
    Without the "-ass" option, the subtitles don't render properly, but vaapi is happy. The video bitrate with this clip doesn't require much CPU power, but we can combine the ASS subtitles with the high bitrate Bird_42 video with mkvtoolnix:
    Code:
    mkvmerge -o birds_subbed.mkv Bird_42_MBit_ABR_\(+-1.5\ MBit\).mkv -D -A --default-track 5 mewmew-vorbis-ssa.mkv
    This command muxes the video track of Bird_42 with the subtitles of the mewmew clip, and sets the "language selection menu" subtitles on by default. birds_subbed.mkv represents a high-bitrate video with ASS-formatted subtitles (which generally look better than plaintext subtitles). Currently, I am left with 2 options for playing a video like the resulting Bird_42_subbed.mkv:
    • I include the -ass option, which causes mplayer to render the subs properly (as in the matroska site's screenshot), but without hardware acceleration
    • I omit the -ass option, which enables hardware acceleration but causes the subtitles to render improperly (all white lettering and misaligned text)


    I now see that I forgot to answer some of gbeauche's ques4tions
    Originally posted by gbeauche View Post
    - Does this happen with the precompiled binary too?
    - If not, what is the log output from mplayer -vo vaapi:gl -va vaapi -msglevel decvideo=9:vo=9 /your/file ?
    - What is the last MPlayer version that worked for you with xvba-video 0.6.2?
    1. Sorry, I only see the i686 binary on your site, which can't find certain 32bit libs and crashes; is there an amd64 precompiled binary elsewhere?
    2. The output of running "~/mplayer-vaapi-20100114/mplayer-vaapi/mplayer -vo vaapi:gl -va vaapi -msglevel decvideo=9:vo=9 -ass birds_subbed.mkv" can be found at http://pastebin.com/f1c47c28 (132KB of logs..). birds_subbed.mkv is the high bitrate subtitled version of Birds_42, created using mkvmerge as described earlier in my post.
    3. mplayer-vaapi-122809 with xvba-video-0.6.2 is able to accelerate all of my videos when using the -ass option, but unfortunately it skips subtitle rendering in this case. So far, no version of mplayer-vaapi has played a video with ASS subtitles correctly for me.
    Last edited by xipu; 15 January 2010, 02:35 AM.

    Comment


    • Originally posted by Kitof View Post
      Ok, great news.

      My config is :
      - Radeon HD 2600 XT AGP (rv630/UVD)
      - xorg-x11-drv-catalyst-9.12-1.fc11.i586 (9.12 hotfix i presume)
      - libva_0.31.0-1+sds9
      - xvba-video-0.6.2.i686
      - mplayer-vaapi-20100114

      The VERY good news is this :

      Code:
      [email protected]>vainfo                                        
      libva: libva version 0.31.0-sds4
      libva: va_getDriverName() returns 0
      libva: Trying to open /usr/lib/va/drivers/fglrx_drv_video.so
      libva: va_openDriver() returns 0
      vainfo: VA API version: 0.31
      vainfo: Driver version: Splitted-Desktop Systems XvBA backend for VA API - 0.6.2
      vainfo: Supported profile and entrypoints
            VAProfileMPEG2Simple            :	VAEntrypointIDCT
            VAProfileMPEG2Main              :	VAEntrypointIDCT
            VAProfileH264High               :	VAEntrypointVLD
            VAProfileVC1Advanced            :	VAEntrypointVLD
      But tests with mplayer aren't so good

      Code:
      [email protected]>./mplayer -va vaapi -vo vaapi:gl /home/Kitof/T?l?chargement/Bird_42_MBit_ABR_\(+-1.5\ MBit\).mkv
      MPlayer SVN-r30302-4.4.1 (C) 2000-2009 MPlayer Team
      
      Playing /home/Kitof/Bird_42_MBit_ABR_(+-1.5 MBit).mkv.
      [mkv] Track ID 1: video (V_MPEG4/ISO/AVC), -vid 0
      [mkv] Will play video track 1.
      [mkv] No audio track found/wanted.
      Matroska file format detected.
      VIDEO:  [avc1]  1920x1072  24bpp  23.976 fps    0.0 kbps ( 0.0 kbyte/s)
      [vo_vaapi] Using OpenGL rendering
      libva: libva version 0.31.0-sds4
      libva: va_getDriverName() returns 0
      libva: Trying to open /usr/lib/va/drivers/fglrx_drv_video.so
      libva: va_openDriver() returns 0
      ==========================================================================
      Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
      [VD_FFMPEG] VA API accelerated codec.
      Selected video codec: [ffh264] vfm: ffmpeg (FFmpeg H.264)
      ==========================================================================
      Audio: no sound
      Starting playback...
      [VD_FFMPEG] Trying pixfmt=0.
      Movie-Aspect is 1.79:1 - prescaling to correct movie aspect.
      VO: [vaapi] 1920x1072 => 1920x1072 H.264 VA API Acceleration 
      [vo_vaapi] Using 1:1 VA surface mapping
      [VD_FFMPEG] XVMC-accelerated MPEG-2.
      
      
      MPlayer interrupted by signal 11 in module: flip_page
      - MPlayer crashed by bad usage of CPU/FPU/RAM.
        Recompile MPlayer with --enable-debug and make a 'gdb' backtrace and
        disassembly. Details in DOCS/HTML/en/bugreports_what.html#bugreports_crash.
      - MPlayer crashed. This shouldn't happen.
        It can be a bug in the MPlayer code _or_ in your drivers _or_ in your
        gcc version. If you think it's MPlayer's fault, please read
        DOCS/HTML/en/bugreports.html and follow the instructions there. We can't and
        won't help unless you provide this information when reporting a possible bug.
      Code:
      [email protected]>./mplayer -va vaapi -vo vaapi:gl /home/Kitof/BBCHD-P-40.ts                       
      MPlayer SVN-r30302-4.4.1 (C) 2000-2009 MPlayer Team
      
      Playing /home/Kitof/T?l?chargement/BBCHD-P-40.ts.
      TS file format detected.
      VIDEO H264(pid=2318) AUDIO A52(pid=2319) NO SUBS (yet)!  PROGRAM N. 6940
      FPS seems to be: 25.000000
      [vo_vaapi] Using OpenGL rendering
      libva: libva version 0.31.0-sds4
      libva: va_getDriverName() returns 0
      libva: Trying to open /usr/lib/va/drivers/fglrx_drv_video.so
      libva: va_openDriver() returns 0
      ==========================================================================
      Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
      [VD_FFMPEG] VA API accelerated codec.
      Selected video codec: [ffh264] vfm: ffmpeg (FFmpeg H.264)
      ==========================================================================
      ==========================================================================
      Opening audio decoder: [ffmpeg] FFmpeg/libavcodec audio decoders
      AUDIO: 48000 Hz, 2 ch, s16le, 384.0 kbit/25.00% (ratio: 48000->192000)
      Selected audio codec: [ffac3] afm: ffmpeg (FFmpeg AC-3)
      ==========================================================================
      [AO OSS] audio_setup: Can't open audio device /dev/dsp: No such file or directory
      AO: [alsa] 48000Hz 2ch s16le (2 bytes per sample)
      Starting playback...
      [VD_FFMPEG] Trying pixfmt=0.
      Movie-Aspect is 1.82:1 - prescaling to correct movie aspect.
      VO: [vaapi] 1440x1080 => 1964x1080 H.264 VA API Acceleration 
      [vo_vaapi] Using 1:1 VA surface mapping
      [VD_FFMPEG] XVMC-accelerated MPEG-2.
      [h264 @ 0x89ef680]number of reference frames exceeds max (probably corrupt input), discarding one
      The last tests left me with a black windowed screen, and hangs my system after I ctrl-c mplayer.

      I hope it helps.
      I have the same problem. I got a black windowed screen, and will freeze my system when mplayer is killed/interrupted. Do you have any luck solving this issue?

      [EDIT]This is no longer a problem using the hotfix release at http://support.amd.com/us/kbarticles...912Hotfix.aspx. But the colour played through vaapi isn't accurate, it has red and green tints every now and then [/EDIT]
      Last edited by Saphy; 16 January 2010, 08:10 PM.

      Comment


      • The only working solution is to use software mode (maybe multithreaded), when system is too slow for this replace card.

        Comment


        • Originally posted by Kano View Post
          The only working solution is to use software mode (maybe multithreaded), when system is too slow for this replace card.
          I found that the hotfix fixed this problem:

          http://support.amd.com/us/kbarticles...912Hotfix.aspx

          mplayer-vaapi plays fine now.

          Comment


          • Originally posted by Kano View Post
            Why couldnt you get this into ffmpeg mainline?
            Because it did not pass review for some reason for 3 weeks. Finally got it through after 3 pings...

            configure: error: libva is present but libavcodec/vaapi.h is missing
            This means you haven't installed FFmpeg correctly or you have not pointed to the right FFmpeg headers install directory.

            Comment


            • xvba-video 0.6.3

              A new version of xvba-video (0.6.3) is now available:
              http://www.splitted-desktop.com/~gbe...ne/xvba-video/

              Version 0.6.3 - 18.Jan.2010
              * Add background-color display attribute
              * Fix output surface allocation logic
              * Fix subwindow stacking order in vaPutSurface()
              * Fix vaGetImage() to wait for decoding to complete

              Comment


              • Thanks for the latest symlinks, it would have been more easy wit

                http://www.splitted-desktop.com/~gbe...est-1_i386.deb

                and

                http://www.splitted-desktop.com/~gbe...st-1_amd64.deb

                however, but could use the other name too if needed.

                Comment


                • I've checked XBMC Forums and they say they will give a try to integrate XBVA once this enters mainline ffmpeg.

                  Any date for that?

                  Comment


                  • Originally posted by cjr2k3 View Post
                    I've checked XBMC Forums and they say they will give a try to integrate XBVA once this enters mainline ffmpeg.

                    Any date for that?
                    IMHO, XvBA will never enter mainline FFmpeg as it is not even public. You are probably confusing with VAAPI, which is now fully integrated upstream.

                    Comment


                    • Does anyone know why when playing video with XvBA, the colour in video will get slightly distorted/pixelated? Or am I the only one experiencing this problem? Strange colour block tends to appears in frames where the motion is slow, sometimes to the point where it becomes obvious. When playing with only software acceleration, the colour is fine.

                      The video will not appear in the screenshot, so I have no idea how I can show this problem pictorially.
                      Last edited by Saphy; 19 January 2010, 09:16 AM.

                      Comment

                      Working...
                      X