AtiQah-FC / lavfilters

Automatically exported from code.google.com/p/lavfilters
GNU General Public License v2.0
0 stars 0 forks source link

Mpeg2 DXVA2 Crash #199

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Using my custom EVR presenter, I get a crash upon releasing 

IDirect3DDeviceManager9 *m_pDeviceManager;

only when using LAV in mpeg2 mode. Playing h264 files with h/w acceleration 
causes no problems. I've not had any other filters causing this particular 
issue. I am not doing anything else with the service. I can see in my logs LAV 
calls a reference for

MR_VIDEO_RENDER_SERVICE

for which I return

*ppv = m_pDeviceManager;
m_pDeviceManager->AddRef();

http://imgur.com/MqdrY

Original issue reported on code.google.com by I.Cur...@gmail.com on 22 Feb 2012 at 10:59

GoogleCodeExporter commented 9 years ago
Just to add to this, the debugger says the error is
Unhandled exception at 0x00000001 : 0xC0000005: Access violation.

It's the -> release method which causes this. Is it possible lav is somehow 
breaking the reference count ? Or destroying the object before I get a chance 
to release it ?

Original comment by I.Cur...@gmail.com on 22 Feb 2012 at 4:50

GoogleCodeExporter commented 9 years ago
The only reference LAV asks for is MR_VIDEO_ACCELERATION_SERVICE, once for the 
IDirect3DDeviceManager9 and once for the IDirectXVideoMemoryConfiguration

It also wouldn't make sense to have different behaviour depending on codec, 
really.

Is you hardware MPEG-2 HW Decoding capable, or is it maybe erroring out and 
doesn't properly release stuff then?

Original comment by h.lepp...@gmail.com on 22 Feb 2012 at 6:16

GoogleCodeExporter commented 9 years ago
Can you maybe try with this?

http://files.1f0.de/lavf/LAVVideo-0.47-dxva2cleanup.zip

Original comment by h.lepp...@gmail.com on 22 Feb 2012 at 6:28

GoogleCodeExporter commented 9 years ago
The attached zip fixes the problem. It doesn't crash anymore. I am not sure it 
was actually using dxva for mpeg2 video because the cpu usage was actually 
coming out higher than decoding h264.

Original comment by I.Cur...@gmail.com on 22 Feb 2012 at 9:13

GoogleCodeExporter commented 9 years ago

Original comment by h.lepp...@gmail.com on 23 Feb 2012 at 5:18