MPEG-2 DXVA Not Decoding

MPEG-2 DXVA Not Decoding

Hi

I am facing a problem in making my MPEG-2 Video Decoder filter to work using DXVA (essentially hardware decoding). My system supports MPEG-2 off-host bitstream processing. Here is my problem.

Following is the sequence of APIs I have called on XP, DXVA1.0 for MPEG2_A(probed and
locked for off-Host bitstream parsing):

- BeginFrame()
- GetBuffer( for PictureParameter buffer)
- Execute() (for PictureParameter buffer)
- ReleaseBuffer() (for PictureParameter buffer)
- Loop 3 times - (for InvQuantization, SliceControl and Bitstream data buffers sent together)
{ GetBuffer()
}
- Execute()
- Loop 3 times - (for InvQuantization, SliceControl and Bitstream data buffers sent together)
{ ReleaseBuffer()
}
- EndFrame()
- QueryRenderStatus()

All these APIs returned S_OK. but when I call DisplayFrame() with the same surfaceIndex, output is blank.

Experiments carried out :
1. - Called BeginFrame()
- Got the pointer to buffer through GetBuffer() with TypeIndex as 0xFFFFFFFF and
BufferIndex as surfaceIndex after BeginFrame and memset with a known value. (set with value 128)
- Called Execute() with necessary buffers
- Called EndFrame()
- Called QueryRenderStatus()
- Again got the pointer to buffer through GetBuffer() and checked the values, It was not modified
and the value was exactly equal to what i set previously. (it was still 128)

This means even if all the APIs return S_OK, the surfaceIndex is untouched. I am stuck at this point.

2. I also carried out one more experiment by sending InvQMatrix, SliceControl and bitstream data
buffers through separate Execute calls. We Initialized *lpPrivateOutput to 128.
Here lpPrivateOutput of Execute() returned '0' while sending InvQmatrix and slicecontrol buffers.
But when bitstream data buffer(bitstream starting from slice start code of 1st slice) was sent
lpPrivateOutput was not updated. Does this mean that there is some problem in sending the bitstream buffer?

Please help me if I am missing something. If any addition information is required please let me know.
Any Input or thoughts is greatly appreciated.

Thanks,

Cheers,
Gowtham

9 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

Quoting - gowthamhk
Hi

I am facing a problem in making my MPEG-2 Video Decoder filter to work using DXVA (essentially hardware decoding). My system supports MPEG-2 off-host bitstream processing. Here is my problem.

Following is the sequence of APIs I have called on XP, DXVA1.0 for MPEG2_A(probed and
locked for off-Host bitstream parsing):

- BeginFrame()
- GetBuffer( for PictureParameter buffer)
- Execute() (for PictureParameter buffer)
- ReleaseBuffer() (for PictureParameter buffer)
- Loop 3 times - (for InvQuantization, SliceControl and Bitstream data buffers sent together)
{ GetBuffer()
}
- Execute()
- Loop 3 times - (for InvQuantization, SliceControl and Bitstream data buffers sent together)
{ ReleaseBuffer()
}
- EndFrame()
- QueryRenderStatus()

All these APIs returned S_OK. but when I call DisplayFrame() with the same surfaceIndex, output is blank.

Experiments carried out :
1. - Called BeginFrame()
- Got the pointer to buffer through GetBuffer() with TypeIndex as 0xFFFFFFFF and
BufferIndex as surfaceIndex after BeginFrame and memset with a known value. (set with value 128)
- Called Execute() with necessary buffers
- Called EndFrame()
- Called QueryRenderStatus()
- Again got the pointer to buffer through GetBuffer() and checked the values, It was not modified
and the value was exactly equal to what i set previously. (it was still 128)

This means even if all the APIs return S_OK, the surfaceIndex is untouched. I am stuck at this point.

2. I also carried out one more experiment by sending InvQMatrix, SliceControl and bitstream data
buffers through separate Execute calls. We Initialized *lpPrivateOutput to 128.
Here lpPrivateOutput of Execute() returned '0' while sending InvQmatrix and slicecontrol buffers.
But when bitstream data buffer(bitstream starting from slice start code of 1st slice) was sent
lpPrivateOutput was not updated. Does this mean that there is some problem in sending the bitstream buffer?

Please help me if I am missing something. If any addition information is required please let me know.
Any Input or thoughts is greatly appreciated.

Thanks,

Cheers,
Gowtham

No response from Intel???

I got it, anyways.

Hello gowthamhk,

I'm facing a similar problem using DXVA2 in VLD MPEG2 decoding mode (the output surface is blank/green).

Could you please explain how did you manage to fix the blank output problem?

Thank you in advance!

Add 32 for MB bit offset in SliceInfo buffer. The doc doesn't mentions it properly. And let me know.

Thanks a lot!

Got it working. MS should correct the doc after so many years... It seems that adding 8 for the MB bit offset and removing the slice start code prefix also works.

Thanks again and best regards.

WC

Yeah. That doc is a little ambiguous at places.

hello Gowtham, have you solved the problem? I have got the similar problem.

thanks
jacky

a dreamer.

Hi all
i have the similiar problem too, anyone can help ?

shin

Leave a Comment

Please sign in to add a comment. Not a member? Join today