Mailing List Archive

New Video Decode and Presentation API
I'm pleased to announce a new video API for Unix and Unix-like platforms,
and a technology preview implementation of this API from NVIDIA.

The API is called VDPAU (Video Decode and Presentation API for Unix).

The current API documentation is here:

ftp://download.nvidia.com/XFree86/vdpau/doxygen/html/index.html

Some highlights of VDPAU:

* Defines an API for GPU-accelerated decode of MPEG-1, MPEG-2, H.264, and
VC-1 bitstreams.
* Defines an API for post-processing of decoded video, including
temporal and spatial deinterlacing, inverse telecine, and noise
reduction.
* Defines an API for timestamp-based presentation of final video
frames.
* Defines an API for compositing sub-picture, on-screen display,
and other UI elements.

Note that VDPAU does not address content protection.

Some highlights/limitations of NVIDIA's current implementation:

* Supported on NVIDIA GPUs with the NVIDIA second generation video
processors (see the end of this announcement for a complete GPU list).
* Currently, only one video stream can be decoded at a time; we hope
to lift this restriction eventually.
* Available in the 180.06 NVIDIA public beta release:
http://www.nvidia.com/object/linux_display_ia32_180.06.html
http://www.nvidia.com/object/linux_display_amd64_180.06.html
http://www.nvidia.com/object/freebsd_180.06.html
http://www.nvidia.com/object/solaris_display_180.06.html

The VDPAU support in the NVIDIA 180.06 beta release is still very
preliminary. We are aware of cases of visual corruption and in some
cases GPU hangs. We will be working on these issues over the next
several NVIDIA driver releases.

While NVIDIA's VDPAU implementation is not ready for end user use yet,
it should be far enough along that interested application developers
can begin working with it.

Additionally, NVIDIA has developed patches to ffmpeg and MPlayer to
demonstrate a video player using VDPAU:

ftp://download.nvidia.com/XFree86/vdpau/mplayer-vdpau-3076399.tar.bz2

These patches include changes against libavcodec, libavutil, ffmpeg,
and MPlayer itself; they may serve as an example of how to use VDPAU.

Once we do some further testing, bugfixing, and cleanup, we will
contribute the MPlayer patches to the MPlayer developers.


If other hardware vendors are interested, they are welcome to also
provide implementations of VDPAU. The VDPAU API was designed to allow
a vendor backend to be selected at run time.


Thanks,
Andy Ritger
Manager, NVIDIA Linux Graphics Driver


VDPAU is currently supported on the following NVIDIA GPUs:

Desktop GPUs:
GeForce 200 Series
GeForce 9 Series
GeForce 86xx Series
GeForce 85xx Series
GeForce 84xx Series
GeForce 8800 GTS 512
GeForce 8800 GT
GeForce 8800 GS

Mobile GPUs:
GeForce 98xxM
GeForce 9700M
GeForce 96xxM
GeForce 9500M
GeForce 9300M
GeForce 9200M
GeForce 8800M
GeForce 8800M GTS
GeForce 8800M GTX
GeForce 8600M

Motherboard GPUs:
GeForce 9400
GeForce 9300
GeForce 9100
GeForce 8300
GeForce 8200

VC-1 support in NVIDIA's VDPAU implementation currently requires GeForce
9300 GS, GeForce 9200M GS, GeForce 9300M GS, or GeForce 9300M GS.

_______________________________________________
mythtv-dev mailing list
mythtv-dev@mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
Re: New Video Decode and Presentation API [ In reply to ]
On Fri, 14 Nov 2008 10:42:12 -0800 (PST), Andy Ritger wrote:
>
>These patches include changes against libavcodec, libavutil, ffmpeg,
>and MPlayer itself; they may serve as an example of how to use VDPAU.
>
>Once we do some further testing, bugfixing, and cleanup, we will
>contribute the MPlayer patches to the MPlayer developers.

this is nice, but to save you (and mplayer/ffmpeg developers time) it
would be good if you would submit what you have first. below are
comments from the mplayer developers on the subject.

>The larger the patch you submit is the longer it will take to get
>it committed
>Not to mention how _very_ much more painful it would be if the review
>found any design flaws (probably unlikely but still).

>We want to see it early in case you are running into the wrong
>direction. Then we can prevent you from doing work in vain.

>This is just long standing experience, especially from experience with
>FFmpeg Google Summer of Code.
>The longer something is in "hidden" (i.e. only one person sees the code)
>development the longer it will usually take to be integrated.

-compn
_______________________________________________
mythtv-dev mailing list
mythtv-dev@mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
Re: New Video Decode and Presentation API [ In reply to ]
Thanks for the feedback, compn.

We will try to propose patches to the mplayer developers, soon. We will
also break the patches up into logical pieces, so that it isn't just
one large unwieldy patch to review.

At the very least, we have some code cleanup to do in our patches,
before proposing them to the mplayer development community.

Thanks,
- Andy


On Sat, 15 Nov 2008, compn wrote:

> On Fri, 14 Nov 2008 10:42:12 -0800 (PST), Andy Ritger wrote:
>>
>> These patches include changes against libavcodec, libavutil, ffmpeg,
>> and MPlayer itself; they may serve as an example of how to use VDPAU.
>>
>> Once we do some further testing, bugfixing, and cleanup, we will
>> contribute the MPlayer patches to the MPlayer developers.
>
> this is nice, but to save you (and mplayer/ffmpeg developers time) it
> would be good if you would submit what you have first. below are
> comments from the mplayer developers on the subject.
>
>> The larger the patch you submit is the longer it will take to get
>> it committed
>> Not to mention how _very_ much more painful it would be if the review
>> found any design flaws (probably unlikely but still).
>
>> We want to see it early in case you are running into the wrong
>> direction. Then we can prevent you from doing work in vain.
>
>> This is just long standing experience, especially from experience with
>> FFmpeg Google Summer of Code.
>> The longer something is in "hidden" (i.e. only one person sees the code)
>> development the longer it will usually take to be integrated.
>
> -compn
> _______________________________________________
> mythtv-dev mailing list
> mythtv-dev@mythtv.org
> http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
>
_______________________________________________
mythtv-dev mailing list
mythtv-dev@mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
Re: New Video Decode and Presentation API [ In reply to ]
On Friday 14 November 2008 1:42:12 pm Andy Ritger wrote:
> I'm pleased to announce a new video API for Unix and Unix-like platforms,
> and a technology preview implementation of this API from NVIDIA.
>
> The API is called VDPAU (Video Decode and Presentation API for Unix).

Here's a _very_ preliminary patch that enables very basic use of VDPAU in
myth. You'll need at least a distclean after applying.

What works:
- mpeg2 decode (haven't really tested anything else)

What's missing:
- Any sort of hardware capability detection
- Deinterlacing
- OSD
- Stability

Expect things to be very buggy/unstable/hardware catching on fire/etc - please
treat this as more of a proof of concept patch. I don't need to be inundated
with replies that things don't work at this stage. =)

Make sure you have the 180.x driver installed (and have supported hardware),
then patch myth, make distclean, re-run configure, and then all you need to do
is set the decoder/renderer to vdpau in the video playback profile settings.

Isaac
Re: New Video Decode and Presentation API [ In reply to ]
On Tue, Nov 18, 2008 at 1:50 PM, Isaac Richards <ijr@case.edu> wrote:

> On Friday 14 November 2008 1:42:12 pm Andy Ritger wrote:
> > I'm pleased to announce a new video API for Unix and Unix-like platforms,
> > and a technology preview implementation of this API from NVIDIA.
> >
> > The API is called VDPAU (Video Decode and Presentation API for Unix).
>
> Here's a _very_ preliminary patch that enables very basic use of VDPAU in
> myth. You'll need at least a distclean after applying.
>
> What works:
> - mpeg2 decode (haven't really tested anything else)
>
> What's missing:
> - Any sort of hardware capability detection
> - Deinterlacing
> - OSD
> - Stability
>
> Expect things to be very buggy/unstable/hardware catching on fire/etc -
> please
> treat this as more of a proof of concept patch. I don't need to be
> inundated
> with replies that things don't work at this stage. =)
>
> Make sure you have the 180.x driver installed (and have supported
> hardware),
> then patch myth, make distclean, re-run configure, and then all you need to
> do
> is set the decoder/renderer to vdpau in the video playback profile
> settings.
>
> Isaac
>
>
> _______________________________________________
>

Wow, Isaac thanks for the patch. Knowing that you have started the process
in trunk is a great sign of soon to be support in trunk with HD-PVR use.

From you knowledge does it look like VDPAU will have all the downsides of
XvMC or is it better?

Mitchell is very excited to get his 8400 in the mail and start testing
this.

Thanks!
Re: New Video Decode and Presentation API [ In reply to ]
On Tuesday 18 November 2008 3:02:03 pm Mitch Gore wrote:
> Wow, Isaac thanks for the patch. Knowing that you have started the
> process in trunk is a great sign of soon to be support in trunk with HD-PVR
> use.
>
> From you knowledge does it look like VDPAU will have all the downsides of
> XvMC or is it better?

Downsides meaning more liable to be stuttery due to less buffering, the
greyscale OSD (without colorkey tricks), etc? Naw, none of that applies.
When finished, this should be better than regular Xv playback.

Isaac

_______________________________________________
mythtv-dev mailing list
mythtv-dev@mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
Re: New Video Decode and Presentation API [ In reply to ]
On Tue, Nov 18, 2008 at 03:19:25PM -0500, Isaac Richards wrote:
> On Tuesday 18 November 2008 3:02:03 pm Mitch Gore wrote:
> > From you knowledge does it look like VDPAU will have all the downsides of
> > XvMC or is it better?
>
> Downsides meaning more liable to be stuttery due to less buffering, the
> greyscale OSD (without colorkey tricks), etc? Naw, none of that applies.
> When finished, this should be better than regular Xv playback.

Those downsides and doesn't XvMC also suffer from severly limited
deinterlacing options? Regarding deinterlacing, I believe the vdpau
docs only list bob and weave deinterlacers. Will there be anything
like the 2x deinterlacers we have now added to vdpau?

Given your druthers, would you rather have a new E8400/E8500 based
frontend for viewing HD-PVR recordings or save some cash and use vdpau
in an older frontend with a new video card? My current frontend can
only handle 480p HD-PVR recordings and I was about to build a new one
when the vdpau news broke.

David
--
David Engel
david@istwok.net
_______________________________________________
mythtv-dev mailing list
mythtv-dev@mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
Re: New Video Decode and Presentation API [ In reply to ]
On Tuesday 18 November 2008 4:42:35 pm David Engel wrote:
> On Tue, Nov 18, 2008 at 03:19:25PM -0500, Isaac Richards wrote:
> > On Tuesday 18 November 2008 3:02:03 pm Mitch Gore wrote:
> > > From you knowledge does it look like VDPAU will have all the downsides
> > > of XvMC or is it better?
> >
> > Downsides meaning more liable to be stuttery due to less buffering, the
> > greyscale OSD (without colorkey tricks), etc? Naw, none of that applies.
> > When finished, this should be better than regular Xv playback.
>
> Those downsides and doesn't XvMC also suffer from severly limited
> deinterlacing options? Regarding deinterlacing, I believe the vdpau
> docs only list bob and weave deinterlacers. Will there be anything
> like the 2x deinterlacers we have now added to vdpau?

There's more than just bob + weave. Going by the header, it has options for
"motion adaptive temporal de-interlacing" and a "more advanced version of
temporal de-interlacing that additionally uses edge-guided spatial
interpolation". It'll also do IVTC, apparently, too.

> Given your druthers, would you rather have a new E8400/E8500 based
> frontend for viewing HD-PVR recordings or save some cash and use vdpau
> in an older frontend with a new video card? My current frontend can
> only handle 480p HD-PVR recordings and I was about to build a new one
> when the vdpau news broke.

Preliminarily, this stuff looks _very_ promising.

Isaac

_______________________________________________
mythtv-dev mailing list
mythtv-dev@mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
Re: New Video Decode and Presentation API [ In reply to ]
Does this API only allow for video processing output to a display
device? If so, does that mean it will not be useful for commercial
detection or even just rendering to individual frames for use in
commercial detection?
_______________________________________________
mythtv-dev mailing list
mythtv-dev@mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
Re: New Video Decode and Presentation API [ In reply to ]
On Tue, 2008-11-18 at 19:42 -0500, Chase Douglas wrote:
> Does this API only allow for video processing output to a display
> device? If so, does that mean it will not be useful for commercial
> detection or even just rendering to individual frames for use in
> commercial detection?

It looks like you can read back bits:
ftp://download.nvidia.com/XFree86/vdpau/doxygen/html/group___vdp_video_surface.html#ge3550dc62e4e4c390c1874b37f96e7c0

This is a good question. If the nvidia provided deinterlacers
aren't as nice as one might hope, it may be possible to read back
the data and feed it through the conventional software or OpenGL
deinterlacers. My hope is that built-in deints are sufficient,
I just got a 8300 in the mail today so I may be able to test that
theory soon...

Caveats:
1/ This may be less efficient than doing the decoding in software,
reading from video memory is not generally an optimized path.
2/ I don't know if this call is actually supported by real hardware.
3/ The commercial detector, transcoder, etc do not have access to
the display hardware.
a) There is no OS support in Linux for parcelling out GPU
resources fairly so any implementation would be a hack.
b) AFAIK no one is planning to implement GPU acceleration
for any non-display connected utilities in MythTV.

-- Daniel


_______________________________________________
mythtv-dev mailing list
mythtv-dev@mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
Re: New Video Decode and Presentation API [ In reply to ]
David Engel <david@istwok.net> says:
> Given your druthers, would you rather have a new E8400/E8500 based
> frontend for viewing HD-PVR recordings or save some cash and use
> vdpau in an older frontend with a new video card? My current
> frontend can only handle 480p HD-PVR recordings and I was about to
> build a new one when the vdpau news broke.

I'm in the same boat; my nearly three years-old frontend *can* play
6Mbps 720p HD-PVR recordings
(<URL:http://www.gossamer-threads.com/lists/mythtv/users/348381#348381>,
<URL:http://www.gossamer-threads.com/lists/mythtv/users/351830#351830>),
and surprisingly well, but had planned on eventually building a new
Core 2 Duo-powered frontend to handle 13.5Mbps HD-PVR recordings
(including 1080i when support improves). The Nvidia news and Isaac's
patch give me hope that my frontend may last for another three years.

--
Frontend: P4 3.0GHz, 1.5TB software RAID 5 array
Backend: Quad-core Xeon 1.6GHz, 6.6TB sw RAID 6
Video inputs: Four high-definition over FireWire/OTA
Accessories: 47" 1080p LCD, 5.1 digital, and MX-600
_______________________________________________
mythtv-dev mailing list
mythtv-dev@mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
Re: New Video Decode and Presentation API [ In reply to ]
Isaac Richards wrote:
> Preliminarily, this stuff looks _very_ promising.
>
> Isaac
>
I realise this is a 'how long is a piece of string' type question, but
is this the likely to make it into 0.22, or are we talking a fairly long
dev time?

Been thinking of taking the plunge to trunk, and this may be the thing
that does it

cheers

Dunc
_______________________________________________
mythtv-dev mailing list
mythtv-dev@mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
Re: New Video Decode and Presentation API [ In reply to ]
On Tue, Nov 18, 2008 at 5:15 PM, Isaac Richards <ijr@case.edu> wrote:
> Preliminarily, this stuff looks _very_ promising.
>
> Isaac
>

I would tend to agree, this could be a "game-changer" going from some
of the benchmarks out there:

http://www.phoronix.com/scan.php?page=article&item=nvidia_vdpau&num=2

Matt
_______________________________________________
mythtv-dev mailing list
mythtv-dev@mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
Re: New Video Decode and Presentation API [ In reply to ]
Yeechang Lee wrote:
> David Engel <david@istwok.net> says:
>> Given your druthers, would you rather have a new E8400/E8500 based
>> frontend for viewing HD-PVR recordings or save some cash and use
>> vdpau in an older frontend with a new video card? My current
>> frontend can only handle 480p HD-PVR recordings and I was about to
>> build a new one when the vdpau news broke.
>
> I'm in the same boat; my nearly three years-old frontend *can* play
> 6Mbps 720p HD-PVR recordings
> (<URL:http://www.gossamer-threads.com/lists/mythtv/users/348381#348381>,
> <URL:http://www.gossamer-threads.com/lists/mythtv/users/351830#351830>),
> and surprisingly well, but had planned on eventually building a new
> Core 2 Duo-powered frontend to handle 13.5Mbps HD-PVR recordings
> (including 1080i when support improves). The Nvidia news and Isaac's
> patch give me hope that my frontend may last for another three years.

I guess I could be in the same boat too. I have an aging EPIA m10k and
while it seems to cope surprisingly well it's got no hope of HD
playback. It's got a PCI slot on it and I'm wondering if more
knowledgable folks could say if slapping in an Nvidia card and using
this approach could prolong the life of that f/e? I'm not sure if any
suitible PCI card would even suffice to be honest tho', so it may be new
f/e regardless. If so then so be it!

Col

--

Colin Guthrie
myth(at)colin.guthr.ie
http://colin.guthr.ie/

Day Job:
Tribalogic Limited [http://www.tribalogic.net/]
Open Source:
Mandriva Linux Contributor [http://www.mandriva.com/]
PulseAudio Hacker [http://www.pulseaudio.org/]
Trac Hacker [http://trac.edgewall.org/]
_______________________________________________
mythtv-dev mailing list
mythtv-dev@mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev