[vlc-devel] Windows 0-copy DXVA

Steve Lhomme robux4 at videolabs.io
Wed Apr 15 14:42:44 CEST 2015


Hi,

I managed to get a "0-copy" version of DXVA working with the D3D9
vout. For now it's still a bit hackish here and there but it closes
currently and can be reused across file opening. I don't get any out
of order frames anymore and recovering from high CPU load is fine.

The DXVA always outputs an opaque pixel format that only it (and D3D9)
knows about. I added a filter to convert the opaque surface to I420
pixels in case filters or other vout are used.

Now I'm hitting a (big) issue. The picture_t decoder pool is not tied
to the decoder. It's created in the vout wrapper here:
http://git.videolan.org/?p=vlc.git;a=blob;f=src/video_output/vout_wrapper.c;h=d172bcca0bfdacc9ebc5c7979a1f10850e7092c9;hb=HEAD#l133

With D3D9 I made sure the conditions are met so that decoder_pool =
display_pool. But when another vout is used that's not the case. And
the picture_pool_t is created with picture_pool_NewFromFormat()
allocating empty planes (fine) and no D3D9 surfaces (not good). And
when vlc_va_Extract() is called with a picture coming from the
"decoder pool" it doesn't have any D3D9 surface I can use.

Shouldn't there be a way to tie the decoder pool to the actual decoder
? At least tell the decoder this pool is being used and also when it's
not used anymore.



More information about the vlc-devel mailing list