View Full Version : Media Player Classic Home Cinema (MPC-HC) - DXVA!
Dreamhacker
15th August 2010, 07:38
I'm not able to fully explain why the on-exit crash occurs. But what a little debugging shows is that the dockbars which CSizingControlBar objects in CMainFrame are docked to, are destroyed without actually nullifying the m_pDockBar in CSizingControlBar objects (because apparently these dockbars contain 1 element, but when it requests the pointer for it, the pointer is null). The result of m_pDockBar pointing to freed memory is that when CDockContext is destructing itself, it will cause the access violation by reading this memory area.
So, the only real workaround until one finds why the CSizingControlBar doesn't get registered properly in the CDockBar, is to actually do this in the CSizingControlBar destructor:
m_pDockContext->m_pBar->m_pDockBar = NULL;
MPC-HTPC
15th August 2010, 07:52
Congratulations for finding a workaround to the Crash-on-exit-problem in MSVC2010! :)
I remeber that XhmikosR said, that he contacted the developer of CSizingControlBar, but it seems like he has not yet replied.
I am curious if your workaround also fixes the other two known issues when compiling MPC-HC with MSVC2010:
-shader editor window does not work
-playlist window does not work
(The information was taken from XhmikosR and can be found here: http://xhmikosr.1f0.de/mpc-hc_msvc2010/BIG_FAT_WARNING.txt)
Porsche_fan
15th August 2010, 08:39
I have a few dvd's that show aliasing when watching them. I was hoping to use the graphic card’s Direct3D anti-aliasing to correct it but can’t seem to get it to work.
Should the D3D Fullscreen GUI Support allow the utilization of a graphic card’s anti-aliasing or is it only to reduce tearing?
namaiki
15th August 2010, 08:50
I was hoping to use the graphic card’s Direct3D anti-aliasing to correct it but can’t seem to get it to work.
It doesn't work like that, AFAIK. The PC is just painting a picture onto a rectangle. Anti-aliasing can be applied onto the edges of shapes.
jeremy33
15th August 2010, 10:41
In the rev. 2246 if the settings are stored in an .ini file in read only these source filter Flac - MP4/MOV - MPEG audio - MPEG PS/TS/PVA are unchecked but there are checked in the .ini
2243 2246
http://img203.imageshack.us/img203/9287/2243.th.png (http://img203.imageshack.us/i/2243.png/) http://img121.imageshack.us/img121/5966/2246.th.png (http://img121.imageshack.us/i/2246.png/)
namaiki
15th August 2010, 10:58
In the rev. 2246 if the settings are stored in an .ini file in read only these source filter Flac - MP4/MOV - MPEG audio - MPEG PS/TS/PVA are unchecked but there are checked in the .ini
Have you tried creating a new ini file in read only and see if it will hold?
Search and replace the following value in your ini file:
[Internal Filters]
SrcFilters=-1202241
tetsuo55
15th August 2010, 11:07
I'm not able to fully explain why the on-exit crash occurs. But what a little debugging shows is that the dockbars which CSizingControlBar objects in CMainFrame are docked to, are destroyed without actually nullifying the m_pDockBar in CSizingControlBar objects (because apparently these dockbars contain 1 element, but when it requests the pointer for it, the pointer is null). The result of m_pDockBar pointing to freed memory is that when CDockContext is destructing itself, it will cause the access violation by reading this memory area.
So, the only real workaround until one finds why the CSizingControlBar doesn't get registered properly in the CDockBar, is to actually do this in the CSizingControlBar destructor:
m_pDockContext->m_pBar->m_pDockBar = NULL;can you make a patch?
Dreamhacker
15th August 2010, 11:08
Congratulations for finding a workaround to the Crash-on-exit-problem in MSVC2010! :)
I remeber that XhmikosR said, that he contacted the developer of CSizingControlBar, but it seems like he has not yet replied.
I am curious if your workaround also fixes the other two known issues when compiling MPC-HC with MSVC2010:
-shader editor window does not work
-playlist window does not work
(The information was taken from XhmikosR and can be found here: http://xhmikosr.1f0.de/mpc-hc_msvc2010/BIG_FAT_WARNING.txt)
I do believe all the errors could be caused by the same issue, so my workaround does not fix those two windows. But knowing that, maybe I could try find a real solution.
Dreamhacker
15th August 2010, 11:44
can you make a patch?
What do you mean by patch? Like, a patch file that applies changes to binary files? Or do you mean something else?
jeremy33
15th August 2010, 11:55
Have you tried creating a new ini file in read only and see if it will hold?
Search and replace the following value in your ini file:
That's what I mean is it is normal ?
Sebastiii
15th August 2010, 12:04
What do you mean by patch? Like, a patch file that applies changes to binary files? Or do you mean something else?
I think patch from source svn file :) it's more easy to look diff :)
Thanks :)
dbone1026
15th August 2010, 12:54
I am using MPC HC v1.3.2212.
I have a question about subtitles that are flagged as forced. I have an mkv where I have two subtitle tracks (IDX/SUB). The first subtitle track is the full English subtitles. This is marked as Default = No and Forced = No. The second subtitle track is the forced subtitles. This is marked as Default = Yes and Forced = Yes.
In MPC HC If I keep "Auto-load subtitles" unchecked no subtitles will show. If I check "Auto-load subtitles" MPC HC just loads the first subtitle track, when I think it should auto load the second subtitle track with is flagged as forced. I am not using any External Filters in MPC HC, just the internal ones. Is this noted behavior, does MPC HC not respect the forced track flag? Thanks
oddball
15th August 2010, 15:12
I've got a problem when using Haali as the Matroska splitter. If I uncheck the internal splitter I get a pin out error and the internal DXVA decoder does not load. It works fine with the internal splitter checked. Any ideas?
EDIT: Nevermind. Installed 2246 and all is well again.
EDIT2: I was wrong. It works on one particular source but all others give the pin error. The source that works has an old MS codec I think. Anything newer like x264 fails with the pin out error.
WTH!
namaiki
15th August 2010, 15:23
Only thing I could think of is make sure that 'Options-> Input-> Use custom media type for H.264' is set to 'No,' in Haali Media Splitter Properties.
Dreamhacker
15th August 2010, 15:48
Okay, so I got the Playlist window and Shader Editor window to work again, though the solution is a bit more hacky than I wanted to. What seems to be the problem is that MFC, when it's supposed to dock the bar, actually removes it from the list of docked bars again, so even if it exists and SHOULD be docked, the code would seem to think it's not and it crashes. What seems to work is to simply adding them back into the array after you've run the initial docking function, though there must be something wrong somewhere for this to be necessary (to me it looks like it's the MFC function that is broken. :S).
I'll try to get the updated files posted one of the next few days, so the changes can be added to the SVN. :)
renq
15th August 2010, 16:05
b2246 wont use madVR. Haali and evr work fine. b2206 was fine
Sebastiii
15th August 2010, 16:15
Okay, so I got the Playlist window and Shader Editor window to work again, though the solution is a bit more hacky than I wanted to. What seems to be the problem is that MFC, when it's supposed to dock the bar, actually removes it from the list of docked bars again, so even if it exists and SHOULD be docked, the code would seem to think it's not and it crashes. What seems to work is to simply adding them back into the array after you've run the initial docking function, though there must be something wrong somewhere for this to be necessary (to me it looks like it's the MFC function that is broken. :S).
I'll try to get the updated files posted one of the next few days, so the changes can be added to the SVN. :)
Great :) Thanks :)
oddball
15th August 2010, 16:16
Only thing I could think of is make sure that 'Options-> Input-> Use custom media type for H.264' is set to 'No,' in Haali Media Splitter Properties.
That was it. Thanks. :)
oddball
15th August 2010, 16:19
b2246 wont use madVR. Haali and evr work fine. b2206 was fine
Works for me but only if I use CoreAVC for decoding. If I blick CoreAVC it loads EVR instead.
renq
15th August 2010, 17:09
Works for me but only if I use CoreAVC for decoding. If I blick CoreAVC it loads EVR instead.
Using internal codecs.
2206 was msvc10, 2246 is vc08, (both x86), should it be of any use.
MPC-HTPC
15th August 2010, 19:42
Okay, so I got the Playlist window and Shader Editor window to work again, though the solution is a bit more hacky than I wanted to.
Thanks for finding a workaround for these two problems too, Dreamhacker! :)
iaTa
15th August 2010, 20:16
I am using MPC HC v1.3.2212.
I have a question about subtitles that are flagged as forced. I have an mkv where I have two subtitle tracks (IDX/SUB). The first subtitle track is the full English subtitles. This is marked as Default = No and Forced = No. The second subtitle track is the forced subtitles. This is marked as Default = Yes and Forced = Yes.
In MPC HC If I keep "Auto-load subtitles" unchecked no subtitles will show. If I check "Auto-load subtitles" MPC HC just loads the first subtitle track, when I think it should auto load the second subtitle track with is flagged as forced. I am not using any External Filters in MPC HC, just the internal ones. Is this noted behavior, does MPC HC not respect the forced track flag? Thanks
I was also going to ask a similar question regarding forced subtitles. Would it be possible for an option to be added so that only subtitles which are marked as forced within an mkv are displayed?
Dreamhacker
16th August 2010, 11:46
Here is the patch for playlist/shader editor/crash. :)
Link: http://home.nith.no/~lilgun/mpc-hc-fixes.patch
XhmikosR
16th August 2010, 13:18
Here is the patch for playlist/shader editor/crash. :)
Link: http://home.nith.no/~lilgun/mpc-hc-fixes.patch
Thanks for the patch. Currently the playlist and editor window do not open at all for me with the vs2010 builds. It might have something to do with the manifest failing to parse with vs2010 sdk.
Dreamhacker
16th August 2010, 13:40
Thanks for the patch. Currently the playlist and editor window do not open at all for me with the vs2010 builds. It might have something to do with the manifest failing to parse with vs2010 sdk.
What do you mean by failing to parse the manifest (sorry if it's a silly question :p)?
XhmikosR
16th August 2010, 14:36
H:\progs\Compiling\mpc-hc_dev\src\apps\mplayerc\res\mpc-hc.exe.manifest : manifest authoring warning 81010002: Unrecognized Element "compatibility" in namespace "urn:schemas-microsoft-com:compatibility.v1".
It happens with SDK v7.0A which is the one VS2010 ships with, but it doesn't happen with SDK v7.1. Maybe I should set Windows7.1SDK as the platform toolset for the mpc-hc project.
I tested your patch and it doesn't seem to work.
Try a debug msvc2010 build and you'll see the errors.
Dreamhacker
16th August 2010, 16:10
H:\progs\Compiling\mpc-hc_dev\src\apps\mplayerc\res\mpc-hc.exe.manifest : manifest authoring warning 81010002: Unrecognized Element "compatibility" in namespace "urn:schemas-microsoft-com:compatibility.v1".
It happens with SDK v7.0A which is the one VS2010 ships with, but it doesn't happen with SDK v7.1. Maybe I should set Windows7.1SDK as the platform toolset for the mpc-hc project.
I tested your patch and it doesn't seem to work.
Try a debug msvc2010 build and you'll see the errors.
Hmmm... I didn't actually test the changes with the latest build before I made the patch, gonna have a look at it again.
Also, the manifest error is indeed not there if you compile with 7.1. :)
For me the changes in that patch fixes it. :S
3ngel
16th August 2010, 17:25
I just tracked down the BOB bug.
It's introduced with the addition of the ELA deinterlacing,
in the r1922
The r1906 it's the last working without problem
(the ELA is not present).
I hope this information can help fix the issue.
omri09
16th August 2010, 18:00
Is there any difference between x64 version to x86?
I have WIN7 x64, should I be satisfied with x86 version?
XhmikosR
16th August 2010, 19:05
I just tracked down the BOB bug.
It's introduced with the addition of the ELA deinterlacing,
in the r1922
The r1906 it's the last working without problem
(the ELA is not present).
I hope this information can help fix the issue.
Use the trac (https://sourceforge.net/apps/trac/mpc-hc/newticket). Whatever you report here will be lost after a couple of days.
Dreamhacker
16th August 2010, 19:13
H:\progs\Compiling\mpc-hc_dev\src\apps\mplayerc\res\mpc-hc.exe.manifest : manifest authoring warning 81010002: Unrecognized Element "compatibility" in namespace "urn:schemas-microsoft-com:compatibility.v1".
It happens with SDK v7.0A which is the one VS2010 ships with, but it doesn't happen with SDK v7.1. Maybe I should set Windows7.1SDK as the platform toolset for the mpc-hc project.
I tested your patch and it doesn't seem to work.
Try a debug msvc2010 build and you'll see the errors.
Did you mean there was something wrong with the code changes, or the patch file? Because the changes do indeed fix the playlist/shader editor crashes.
tetsuo55
16th August 2010, 19:20
He means he was not able to reproduce the not-crashing behaviour you mentioned, in particular with debug builds.
the patch looks pretty slim, are you sure we only need those 3 lines of code?
Dreamhacker
16th August 2010, 19:50
I cannot guarantee it, but both my computers have working playlist and shader editor in build 2249 compiled with VC2010 after I did these changes. It's basically a hack to get around what MFC does.
PS: Not sure if there will be needed a define to avoid the extra lines to be run on VC2008, I don't have that installed to test it on. But some people said it was with VC2010 it became apparent.
PS2: Gonna take a look at another approach that could be less "hacky".
3ngel
16th August 2010, 19:57
Thank you very much XhmikosR
Done that.
Dreamhacker
16th August 2010, 20:54
The real problem is that pBar->m_hWnd points to itself, I think. For what reason that is the next question to answer. But at least the error is no longer in MFC anymore. :P
XhmikosR
16th August 2010, 20:56
I cannot guarantee it, but both my computers have working playlist and shader editor in build 2249 compiled with VC2010 after I did these changes. It's basically a hack to get around what MFC does.
PS: Not sure if there will be needed a define to avoid the extra lines to be run on VC2008, I don't have that installed to test it on. But some people said it was with VC2010 it became apparent.
PS2: Gonna take a look at another approach that could be less "hacky".
Here is the thing. The playlist and shader editor windows do not even open for me with vs2010 builds. With a debug VS2010 build here is what I get when I try to open playlist or shader editor window:
Debug Assertion Failed!
Program: C:\Program Files\MPC-HC\mpc-hc.exe
File: f:\dd\vctools\vc7libs\ship\atlmfc\src\mfc\winfrm.cpp
Line: 1395
Dreamhacker
16th August 2010, 21:30
Here is the thing. The playlist and shader editor windows do not even open for me with vs2010 builds. With a debug VS2010 build here is what I get when I try to open playlist or shader editor window:
Debug Assertion Failed!
Program: C:\Program Files\MPC-HC\mpc-hc.exe
File: f:\dd\vctools\vc7libs\ship\atlmfc\src\mfc\winfrm.cpp
Line: 1395
What I wonder is why you are compiling with vc7 libs? :S
XhmikosR
16th August 2010, 21:41
I don't. No idea why it says that. Anyway, here is the situation:
Default playlist/shader editor window is docked. With your patch everything works. Now in my case I had the playlist window floated. This is where it crashes and someone has to fix it.
Also good news: if I leave the playlist/shader window at the default state, docked, then no crash on exit.
The playlist/shader window didn't open for me but after deleting the following registry key, they opened since they defaults were restored
HKEY_CURRENT_USER\Software\Gabest\Media Player Classic\ToolBars
Dreamhacker
16th August 2010, 21:53
I don't. No idea why it says that. Anyway, here is the situation:
Default playlist/shader editor window is docked. With your patch everything works. Now in my case I had the playlist window floated. This is where it crashes and someone has to fix it. Also good news: if I leave the playlist/shader window at the default state, docked, then no crash on exit.
You are right, good thing you spotted that bug. I never tried to actually undock it, so it worked fine for me. :P
The problem is caused because m_hWnd member of the bar points back at itself in a way. But I believe it should be pointing to the CMainFrame object.
What I'm trying to find out now is WHY this pointer doesn't point to where it should.
mark0077
16th August 2010, 21:56
Hi all. Can anyone tell me does mpc-hc close down the filter chain correctly. Because when a movie ends, and I close mpc-hc, reclock doesn't fire the QUIT event, indicating its probably not getting closed down correctly during mpc-hc shut down.
See Jongs reply to my post over at the reclock forums.... http://forum.slysoft.com/showpost.php?p=275806&postcount=101
Maybe a developer can test / reproduce my problem where reclock doesn't seem to be closing down gracefully if mpc-hc video ends (reclock still loaded).... and then a manual mpc-hc close is executed.
tetsuo55
16th August 2010, 22:02
mark, see the posts above yours.
mark0077
16th August 2010, 22:31
thanks tetsuo, I assume you mean the problems being discussed lately about crashes on mpc-hc exit, are effecting me here.... ie reclock not getting shutdown gracefully as a result of these other issues.
mark0077
16th August 2010, 23:39
I've got a problem when using Haali as the Matroska splitter. If I uncheck the internal splitter I get a pin out error and the internal DXVA decoder does not load. It works fine with the internal splitter checked. Any ideas?
EDIT: Nevermind. Installed 2246 and all is well again.
EDIT2: I was wrong. It works on one particular source but all others give the pin error. The source that works has an old MS codec I think. Anything newer like x264 fails with the pin out error.
WTH!
I'm also having terrible throuble tonight with the haali media splitter and version 2249 at least. I get no truehd audio from m2ts files, and dts-ma from m2ts gives me a stuttering mess with audio streams changing every few seconds.... anyone know is there some incompatibility or issue with mpc-hc?
Snowknight26
17th August 2010, 00:00
Right clicking on the MPC-HC icon in the taskbar doesn't cause a menu to appear.
vBm
17th August 2010, 04:58
Right clicking on the MPC-HC icon in the taskbar doesn't cause a menu to appear.
It does here on r2257
Never had that problem thou.
rahzel
17th August 2010, 07:37
Ever since I've owned my radeon HD5450, I've been getting an error message using DXVA saying "display driver amdkmdap has stopped responding". It only happens on certain (high bitrate 1080p) movies like Avatar or Transformers. I decided to test the card out in my XP machine and I was error free.
My system is completely stable, and I've literally tried every "fix" for this common error.
What I basically want to know is, does it sound like my video card is not stable? I used VMR9 on my XP machine and EVR on my Win7 machine; does EVR require more performance? And it's also my understanding that Vista and up uses DXVA2 and XP uses DXVA1; does DXVA2 require more performance as well? This could explain the crash in 7 but not XP.
Sorry, this is kind of off topic.
MPC-HTPC
17th August 2010, 07:43
Dreamhacker,
just a question out of interest. Do you use for debugging of those nasty bugs the latest CSizingControlBar 2.45 or the one that is shipped with MPC-HC, which is version 2.43?
I know that Aleksoid already mentioned, that implenting the latest version does not solve those bugs, but maybe your bug hunting could also be a good opportunity to implement the latest version.
Either way, I hope that you can nail down the problem and solve it! My fingers are still kept crossed!
MPC-HTPC
17th August 2010, 07:46
Is there any difference between x64 version to x86?
I have WIN7 x64, should I be satisfied with x86 version?
There is no difference in functionality if you mean that by difference. I would recommend you to stick with the x86 version, even with Win7 x64, and be satisfied. :)
Dreamhacker
17th August 2010, 10:29
Dreamhacker,
just a question out of interest. Do you use for debugging of those nasty bugs the latest CSizingControlBar 2.45 or the one that is shipped with MPC-HC, which is version 2.43?
I know that Aleksoid already mentioned, that implenting the latest version does not solve those bugs, but maybe your bug hunting could also be a good opportunity to implement the latest version.
Either way, I hope that you can nail down the problem and solve it! My fingers are still kept crossed!
I think the only solution is to write a new class to replace it. Hunting bugs that are almost impossible to catch and obviously have existed in the class for 10 years is often a waste of time if you have the possibility to just write a new class. :p
MPC-HTPC
17th August 2010, 10:44
Yeah, you got a point there Dreamhacker. Furthermore, it is interesting to know that it would be better to just write a new class instead of hunting those bugs.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.