[vlc-devel] Intel DXVA2 green screen issue

Jeremiah Gilbert jagged at vtnetworks.net
Mon Jun 28 13:30:54 CEST 2010

 	j-b asked that I post the following information here. I hope it is 
of some help.

The Intel green screen issue seems to be shared by 2 projects (xbmc + vlc) 
who use ffmpeg code. I believe the issue actually lies in the ffmpeg dxva 

Reading the document from Intel at the bottom of this page:


describing the implementation work they did w/ Casimir666 on implementing 
DXVA in MPC-HC a couple things stand out:

"The application/codec needs to inform the hardware it is sending a 
full list of reference pictures by setting the 
DXVA_PicEntry_H264.Reserved16Bits to 0x34c."

I believe this is an error in the document and that it should read 
DXVA_PicParam_H264.Reserved16Bits, as there is no such variable in the 
PicEntry_H264 structure (which is a member of the PicParam_H264 
structure.) Also reviewing Casimir666's current MPC-HC code reveals this:

 	if(m_pFilter->GetPCIVendor() == PCIV_Intel)
 		m_DXVAPicParams.Reserved16Bits = 0x534c;
 		m_DXVAPicParams.Reserved16Bits = 0;

Interestingly this differs from the article (setting it to 0x534c instead 
of 0x34c). Both of these are quite different from what Microsoft's DXVA 
doc specifies (this parameter should be set to 0, 1, 2, or 3). In the 
current ffmpeg source it is set to 3. (see Microsoft DXVA specification 
doc: http://www.microsoft.com/downloads/d...6-714063a6d7a6)

The next interesting peice in the Intel article was this:

"One of the fundamental differences about the implementation on the Intel 
Graphics Media Accelerator X4500HD should be called out at this point. In 
other implementations, the RefPicList[][].Index7Bits contains a index into 
the DXVA_PicParams_H264.RefFrameList[]. The index is its position in the 
.master. reference list. On the Intel GMA X4500HD, the 
RefPicList[][].Index7Bits needs to contain the surface index . so 
essentially the reference picture structure for slices has the same 
information that the master list has in its Index7Bits field."

They also include some of the code demonstrating how it was done (though 
from what I can tell, it's since changed). I think this is likely the 
heart of the issue. Unfortunately, I know next to nothing about the ffmpeg 
code (Which is where I think the main change would need to be implemented) 
and even less about h264 decoding. Though, I'm happy to help test.


More information about the vlc-devel mailing list