View Full Version : Media Player Classic Home Cinema (MPC-HC) - DXVA!
Kado
16th February 2009, 16:13
But using 1024x768 reduces the quality of the subtitles visibly. I don't use any additional filters in the chain. Enabling and disabling the status (CTRL+J) helps with the frame drops.
The issue in the edit part of this post (http://forum.doom9.org/showthread.php?p=1250212#post1250212) happens with me as well but the picture only shows if if pause then play it again or skip to somewhere else after the image got stuck.
@Egh
OK. :)
cca
16th February 2009, 16:17
@kado see my edited post above, even with the texture reduction the rendering engine is still too slow even for a 2.5GHz Quadcore. Unacceptable for everyday usage.
clsid
16th February 2009, 16:22
Wouldn't it be possible to somehow detect if a subtitle is animated during the parsing? For example if certain tags are encountered. Then send that information upstream to the subtitle renderer.
Kado
16th February 2009, 16:33
@cca
For me to avoid that I use no buffering as it only drops frames before the subtitle presentation and not always, even with desktop resolution, and cpu usage is normal.
Beliyaal idea and efforts were good but something is going wrong there.
tetsuo55
16th February 2009, 16:36
MPC and Vobsub accepts ASS tags in .srt subtitles. You can make positioning, coloring, animations, karaoke etc with .srt subtitles too. I have .srt files that have these effects. So you can add .srt to animated subtitles category.
ASS is basically an upgrade from SRT, so a program that can read both can decode both.
Accurately though, an SRT file should not have any styling information, if it does it is a misnamed ASS.
For best results the subtitle renderer should be smart enough to detect the content
---
Best solution is if the animated part is optimized to the point that it doesn't add any overhead at all to non-animated subtitles
cca
16th February 2009, 16:51
ASS karaoke effects can be very CPU taxing if done in real time, some kind of buffering solution is needed, the current buffering in the SVN builds are texture based, but with ASS each frame can need a different texture. So either you need to increase the buffered textures a lot, or use some other kind of buffering.
For example, with VSFilter if you use the EVR buffers or use Haali render which also has a lot of buffering, even effects that will cause jerkiness and dropped frames normally with renderers like VMR9 or Overlay mixer can be displayed, because the CPU is rendering them ahead of time.
alexins
16th February 2009, 17:10
Media Player Classic HomeCinema (x86/x64), svn 997 (http://www.xvidvideo.ru/content/view/630/1/)
Supported languages: CN, CZ, DE, EN, ES, FR, HU, IT, KR, PL, RU, SK, TR, UA
Changes log (http://www.xvidvideo.ru/content/view/7/17/)
Beliyaal
16th February 2009, 17:23
ASS karaoke effects can be very CPU taxing if done in real time, some kind of buffering solution is needed, the current buffering in the SVN builds are texture based, but with ASS each frame can need a different texture. So either you need to increase the buffered textures a lot, or use some other kind of buffering.
For example, with VSFilter if you use the EVR buffers or use Haali render which also has a lot of buffering, even effects that will cause jerkiness and dropped frames normally with renderers like VMR9 or Overlay mixer can be displayed, because the CPU is rendering them ahead of time.
The problem with buffering the subtitles in the same frames as the video is that the subtitles will be the same resolution as the video. If EVR buffers work the 10 buffers available for subtitles shouldn't be a problem.
Not sure what is causing the performance problems, but it might be possible to fix it. I have some ideas what might be causing it.
cca
16th February 2009, 17:36
The problem with buffering the subtitles in the same frames as the video is that the subtitles will be the same resolution as the video. If EVR buffers work the 10 buffers available for subtitles shouldn't be a problem.
Not sure what is causing the performance problems, but it might be possible to fix it. I have some ideas what might be causing it.
Well, I can only theorize and express my thoughts, but I am no coder. I hope that by discussing and testing a solution to the problem will be found eventually :) .
carnage_pl
16th February 2009, 20:11
Core 2 Duo 4300.
V9 subtitles=ON CPU usage 10-20%.
V12 subtitles=ON CPU 60-70%.
V12 subtitles=OFF or animation=OFF CPU 10-20%.
I have the same problem
Pyr0
16th February 2009, 21:10
can anyone else confirm that the option to standby after playback doesn't work since the change in build 983: CHANGED: Prevent display or computer to sleep during playback. please?
http://img91.imageshack.us/img91/2631/standbyaj2.jpg
pdanpdan
16th February 2009, 22:18
I don't know if it's a bug or not, but:
- I have a TV set in extended mode (2nd display), and mpc interface is on the 1st display
- I play a file with D3D Fullscreen / Full Screen Monitor = Display 2
- I press Ctrl+C
- the interface is shown on the 2nd display
Is there any way that I can make the interface return on the 1st display on close? MPC-HC 1.2.997.0 + Beliyaal Fixes Ver 12. Thank you.
Beliyaal
16th February 2009, 22:54
New version available:
* Fixed memory leak causing stuttering with buffered subtitles.
* Better dirty rect reporting to D3D for subtitle texture update (better performance).
* Added more resolutions to options for max subtitle texture size.
* Subtitle queue statistics added to renderer stats.
High CPU usage when rendering subtitles cause much less stuttering now. There still is some stuttering, but I cannot fix that until I do an overhaul of the jitter code.
Mercury_22
17th February 2009, 00:20
New version available:
* Fixed memory leak causing stuttering with buffered subtitles.
* Better dirty rect reporting to D3D for subtitle texture update (better performance).
* Added more resolutions to options for max subtitle texture size.
* Subtitle queue statistics added to renderer stats.
High CPU usage when rendering subtitles cause much less stuttering now. There still is some stuttering, but I cannot fix that until I do an overhaul of the jitter code.
A new bug ! :
Your version 13 plays a 1080i60 vc1 m2ts file at 30 frame rate but the SVN version it's playing smooth the same file with the same settings at 60frame rate ! :helpful: :(
EDIT: your version 8 it's also playing correct & smooth at 60 frame rate
EDIT 2: tested your versions 9, 10, 11, 12, too and the problem it's starting with version 12 !! Ver 12:
* Fixed out of sync because incorrect correction of frame times.
PLEASE fix this :helpful: it's causing a very bad video and flickering subtitles
Sample VC-1 1080i60 M2TS (http://rapidshare.com/files/198995619/TEST_1080i60vc1.m2ts.html)
P.S. Both internal VC-1 filters, DXVA & NON-DXVA still not working with this type of file
Rille
17th February 2009, 00:28
I'll be working on judder issues this weekend, hopefully the next build will be better.
Only tested one movie so far (with v12) but played fine without me having to pause once =)
daMaster
17th February 2009, 00:32
@daMaster: it does look that way to me, too from as long as I can remember with any DXVA decoder not just MPC DXVA one including CoreAVC with CUDA decoder used in vanilla MPC by clsid. So It might not be MPC-HC fault.
Did you see my original post? I compared the Cyberlink PowerDVD decoder running in DXVA mode to the MPC Video Decoder running in DXVA mode. There is no memory leak with the Cyberlink decoder but there is with the MPC Video Decoder.
Here is my original post: http://forum.doom9.org/showthread.php?p=1248688#post1248688
Klaus_1250
17th February 2009, 04:52
@Beliyaal: First of all, thanx for your patches. Latest version play back content smooth as butter (combined with Reclock, Powerstrip and custom monitor timings). Never seen such a straight line
Except when using subtitles, which is no different than the normal MPC-HC, in which I get occasionally delayed/dropped frames because the subtitle rendering takes too long :-( (watching high-def h264 anime with styled subs) Performance issues (high CPU use) seem to be solved in v13 of your patchset
Machine is a P4 3.2, 2GB with Ati 3850AGP using Win XP SP3 and VMR9 renderless.
Sidenote: The reported screen refresh rate I see in MPC-HC is usually not correct, probably because Powerstrip changes it when starting playback using reclock.
Sidenote2: MPC still doesn't handle in-file framerate changes correctly (24-->60); it speeds up, but only makes it halfway and drops the rest of the frames (997 with and without reclock/powerstrip)
THX-UltraII
17th February 2009, 08:57
@Beliyaal: Keep up the good work! You re aiming for the best version ever made of MPC-HC! big thumbs up!!!
a general question about MPC-HC:
At the external filter options you can select 3 different options per filter: Prefer, Block and Merit. I think I understand Prefer and Block (they just do what they say correct?) but what is Merit (standard a filter is on this option).
Kado
17th February 2009, 12:29
@THX-UltraII
Filters are registered in windows with a "merit", filters with higher merit will tried to be used first, like a ticket queue. In MPC you can set the merit manually for your selected filters but thats only valid for mpc and not other players.
@Klaus_1250
Here the frame rate changes from 24 to 60 and I get no dropped frames whatsoever.
Mercury_22
17th February 2009, 12:30
@Beliyaal: Keep up the good work! You re aiming for the best version ever made of MPC-HC! big thumbs up!!!
a general question about MPC-HC:
At the external filter options you can select 3 different options per filter: Prefer, Block and Merit. I think I understand Prefer and Block (they just do what they say correct?) but what is Merit (standard a filter is on this option).
From RadLight FilterManager Each filter is registered with a merit value. When the
filter graph manager builds a graph, it enumerates all the
filters registered with the correct media type. Then it
tries them in order of merit, from highest to lowest. (It
uses additional criteria to choose between filters with
equal merit.) It never tries filters with a merit value less
than or equal to MERIT_DO_NOT_USE. A filter that
should never be considered for ordinary playback should
have a merit of MERIT_DO_NOT_USE or less. Filters can
be registered with intermediate values not defined by
this enumeration, such as MERIT_NORMAL + 1.
STANDARDIZED MERIT VALUES
MERIT_PREFERRED = 0x800000
MERIT_NORMAL = 0x600000
MERIT_UNLIKELY = 0x400000
MERIT_DO_NOT_USE = 0x200000
MERIT_SW_COMPRESSOR = 0x100000
MERIT_HW_COMPRESSOR = 0x100050
I hope this helps :)
THX-UltraII
17th February 2009, 12:53
and when I ReClock, Haali Media Splitter, AVC Video Decoder and AC3Filter as external filters, can I set them all on prefer?
One thing I did notice is that it makes no difference if I set these 4 filters in the external filters or leave the external filters empty. They are used anyway. So the external filter use is a questionmark for me anyway.
Mercury_22
17th February 2009, 13:12
and when I ReClock, Haali Media Splitter, AVC Video Decoder and AC3Filter as external filters, can I set them all on prefer?
One thing I did notice is that it makes no difference if I set these 4 filters in the external filters or leave the external filters empty. They are used anyway. So the external filter use is a questionmark for me anyway.
This is because they already have the highest merit on your system and you didn't check the corresponding internal filters
Use RadLight FilterManager (http://www.dvbviewer.info/forum/index.php?showtopic=2543&view=findpost&p=190573) to see all the directshow filters merit on your system
THX-UltraII
17th February 2009, 13:37
This is because they already have the highest merit on your system and you didn't check the corresponding internal filters
Use RadLight FilterManager (http://www.dvbviewer.info/forum/index.php?showtopic=2543&view=findpost&p=190573) to see all the directshow filters merit on your system
thxz, Ill try this tonight.
NanoBot
17th February 2009, 14:00
Hi,
I would like to remind the developers to a request concerning multi monitor environments I made a while ago:
http://forum.doom9.org/showthread.php?p=1222592#post1222592
As far I have traced the thread for other opinions about my suggestion, I only found
http://forum.doom9.org/showthread.php?p=1222632#post1222632
where Leak supports my idea, that the main window should stay on the monitor where MPC was initially started.
That's why I would like to renew my proposal made in my posting cited above.
C.U. NanoBot
cca
17th February 2009, 14:02
New version available:
* Fixed memory leak causing stuttering with buffered subtitles.
* Better dirty rect reporting to D3D for subtitle texture update (better performance).
* Added more resolutions to options for max subtitle texture size.
* Subtitle queue statistics added to renderer stats.
High CPU usage when rendering subtitles cause much less stuttering now. There still is some stuttering, but I cannot fix that until I do an overhaul of the jitter code.
This version is much better, but I 'm sure there is still room for improvement. You are certainly on the right track!
xiulet
17th February 2009, 15:29
A new bug ! :
Your version 13 plays a 1080i60 vc1 m2ts file at 30 frame rate but the SVN version it's playing smooth the same file with the same settings at 60frame rate ! :helpful: :(
EDIT: your version 8 it's also playing correct & smooth at 60 frame rate
EDIT 2: tested your versions 9, 10, 11, 12, too and the problem it's starting with version 12 !!
PLEASE fix this :helpful: it's causing a very bad video and flickering subtitles
Sample VC-1 1080i60 M2TS (http://rapidshare.com/files/198995619/TEST_1080i60vc1.m2ts.html)
P.S. Both internal VC-1 filters, DXVA & NON-DXVA still not working with this type of file
i can't see this video with 997 :O Using mpeg/ps/ts/pva internal filter, neither dxva or normal vc-1.
saludos, adéu.
Mercury_22
17th February 2009, 16:14
i can't see this video with 997 :O Using mpeg/ps/ts/pva internal filter, neither dxva or normal vc-1.
saludos, adéu.
Like I've said before Both internal VC-1 filters, DXVA & NON-DXVA still not working with this type of file and starting with version 12 Beliyaal's version it's using a WRONG frame rate for VC-1 i m2ts files !
(and I was so happy that finally MPC-HC it's able to play correct my VC-1i blu-ray, now it's broken again :mad:)
Use WMVideo Decoder DMO (uncheck BOTH VC-1 internal filters )!
Edit: maybe this is a clue : The same m2ts VC-1, 1080i60 file it's reported by eac3to as 60 Frame rate (the frame rate used by ver 11) and by tsMuxeR as 29.97 Frame rate ( the frame rate used by ver 12 ):confused:
STaRGaZeR
17th February 2009, 16:46
Another thing to consider: in your builds when the player is set to Playback->Playback->Repeat forever and the file ends, the image freezes for 3-4 seconds, then it resumes showing the frames located 3-4 seconds after the beginning of the file. Sound plays fine from the beginning as it should, so it's only the video part.
Beliyaal, this seems to be mitigated when the number of EVR buffers is low, like 3 or 5 instead of 20, just to let you know.
hdboy
17th February 2009, 18:04
Hi,
I would like to remind the developers to a request concerning multi monitor environments I made a while ago:
http://forum.doom9.org/showthread.php?p=1222592#post1222592
As far I have traced the thread for other opinions about my suggestion, I only found
http://forum.doom9.org/showthread.php?p=1222632#post1222632
where Leak supports my idea, that the main window should stay on the monitor where MPC was initially started.
That's why I would like to renew my proposal made in my posting cited above.
C.U. NanoBot
I second this request.
Motivation: my 2nd 'monitor' is my TV, and due to the room constraint, I cannot place my PC where I can operate it and see the TV at the same time. So having the controls (that means the controls, seek bar, and any dialog) on my PC monitor while playing video on the TV would be golden.
also, very often, with certain combination of filter and renderer, starting in primary monitor then switching to full screen to the TV results in no video. I have to start mpc with command line argument /monitor 2 for it to work. So it would be nice to have a way to start video display in 2nd monitor while leaving controls in the 1st at startup.
Lastly, I don't know if this is feasible but what would be ideal is to be able to mirror full screen video in 2nd monitor. mpc would behave normally in the 1st monitor, with controls and video, but the video would be mirrored full screen on the 2nd monitor. I guess you would have to have 2 renderers going at the same time, but would you need 2 decoders as well?
video cards have this feature, but it only works on overlay, suffers from aspect ratio bugs, and in the case of nvidia, no longer works on vista. Would be great if mpc can do this itself. I'd like to hear from the devs whether they think it's feasible (even if they don't think it's worth doing :) mpc dual monitor support is already very good; making it great would really put the 'home cinema' in mpc-hc.
Pyr0
17th February 2009, 18:22
can anyone else confirm that the option to standby after playback doesn't work since the change in build 983: CHANGED: Prevent display or computer to sleep during playback. please?
http://img91.imageshack.us/img91/2631/standbyaj2.jpg
Nobody has a spare 30 seconds to do a quick test ?
Klaus_1250
17th February 2009, 18:27
@Klaus_1250
Here the frame rate changes from 24 to 60 and I get no dropped frames whatsoever.
Thanx for the info. Did some more testing. If the screen is in 60Hz, MPC-HC copes with the frame-rate change. If it is any other, it doesn't. If the refresh-rate was changed at the start of playback, the problem seems to be bigger :-(
XhmikosR
17th February 2009, 18:30
@Pyr0: With rev997 on Vista SP1 32bit it works fine.
Kado
17th February 2009, 18:48
Thanx for the info. Did some more testing. If the screen is in 60Hz, MPC-HC copes with the frame-rate change. If it is any other, it doesn't. If the refresh-rate was changed at the start of playback, the problem seems to be bigger :-(
I did some tests before and VMR9 and EVR output at the max the refresh rate is set, in my case 60hz=60franmes max.
Klaus_1250
17th February 2009, 18:59
I did some tests before and VMR9 and EVR output at the max the refresh rate is set, in my case 60hz=60franmes max.
In my case, I can choose between 60, 70 and 75 (+ 59,94 and 72 with reclock/powerstrip). For ~24fps, I switch to 72Hz, but as the frame-rate goes to 60, I end up with 45-48fps.
Rille
17th February 2009, 20:08
Only tested one movie so far (with v12) but played fine without me having to pause once =)
Went out of sync today again about 30 mins. into Heroes =(
http://img300.imageshack.us/img300/244/v12judderbk6.th.jpg (http://img300.imageshack.us/my.php?image=v12judderbk6.jpg)
Worked fine again after pausing for a few secs.
cca
17th February 2009, 20:52
@Beliyaal:
In my last post I wasn't very detailed, here are some more details. Version 13 no longer drops frames even when I play the opening of Rozen Maiden. I 've set the subtitle buffers at 10, which is the max setting, can this be increased? I ask because I see the buffers empty fast when playing this particular video, but my PC is fast enough and it doesn't get to zero, so no frames drop.
Another issue, the vsync is not very good, I get much better results if I disable VSync and use the ReClock vsync correction, then I get perfectly smooth playback. My specs are in my signature, using ATI Catalyst 9.1, aero is enabled, EVR buffers at 20.
Kado
17th February 2009, 21:46
I still get blinking subtitles with gg's Maria+Holic even with buffer at 10. Can provide the subtitles if required. Otherwise the video plays fine.
cca
17th February 2009, 22:00
I still get blinking subtitles with gg's Maria+Holic even with buffer at 10. Can provide the subtitles if required. Otherwise the video plays fine.
Just tried Maria+Holic episode 6, plays absolutely fine here. It's even DXVA compatible (never tried it before, as I needed VSfilter for proper subs!).
ikarad
17th February 2009, 22:11
I have a problem with dxva.
I see a video at 29.970 fps but in MPC-HC video is at 60 fps.
http://nsa05.casimages.com/img/2009/02/17/mini_090217101454251621.jpg (http://www.casimages.com/img.php?i=090217101454251621.jpg)
is-it normal?
Dxva accelerate video or not? I think it is not normal.
I use MPC-HC 1.2.997, vmr9 renderless, xp sp3, geforce gtx280 182.05
one question: How desactivate dxva because before there was an option to activate or desactivate and now it doesn't exist?
Kado
17th February 2009, 22:16
@cca
Try episode 4 @ min 9.55 where Ryuuken is being called a stalker and the subs display "shivering" on the upper right corner. They don't blink always, so try a few times.
@ikarad
Tried to use mediainfo to see the frame rate? Maybe it's interlaced? Also fraps says that it's 60frames.
cca
17th February 2009, 22:42
@cca
Try episode 4 @ min 9.55 where Ryuuken is being called a stalker and the subs display "shivering" on the upper right corner. They don't blink always, so try a few times.
Ok, It does indeed blink, I was able to reproduce it. Not only there, immediately when the episode starts I saw blinking. Probably bugs that will be sorted out over time hopefully.
ikarad
17th February 2009, 23:04
@cca
Try episode 4 @ min 9.55 where Ryuuken is being called a stalker and the subs display "shivering" on the upper right corner. They don't blink always, so try a few times.
@ikarad
Tried to use mediainfo to see the frame rate? Maybe it's interlaced? Also fraps says that it's 60frames.
yes it's interlaced.
But if I use H264 codec from ffdshow my video is at 29.97 fps as indicated above.
I tried to advance frame per frame and I notice that dxva add some frames. It is very strange and it isn't normal.
Although, if deinterlaced was correct, my video must be at 30 i/s or 24 i/s (if inverse telecine was used) and not 60 i/s.
tetsuo55
17th February 2009, 23:21
Beliyaal build 13
Ati HD2400pro AGP
Ati Catalyst 8.5 HOTFIX
X-Fi with latest drivers set to entertainment mode
WinXP SP2 fully patched, DirectX november
VMR9
-Everything disabled except Accurate V-Sync in options
-Everything disabled in renderer settings(right click menu) except accurate V-Sync
***Note if have to manually uncheck V-Sync on every restart of the player***
-Internal DXVA decoder, h264
-Internal DTS decoder (with default settings)
only this setting will give me an almost straight line(it looks like it was drawn by a 5 year old)
Randomly i will get higher jitter for a fraction of a second. all the jitter is between 0 and 2 ms when it happens
Any other setting will give me a constant jitter, no combination of settings gives me a flat line. jitter is sometimes visable and can cause image corruption due to the DXVA decoder not recieving its data on time.
I guess that fixing the jitter might completely fix the remaining DXVA problems(apart from the decoder limitations)
cca
17th February 2009, 23:31
Argh, after the first time I managed to reproduce the blinking subtitles problem, I must have tried like 30 times the same episode, and I couldn't reproduce it but only 1 or 2 times. Sneaky problem!
EDIT: May be related or not, but I think there is a memory leak somewhere, unless it's the buffers. I notice like 600MB allocated for MPC at this moment.
EDIT2: I see the memory usage increase every time I open another file, it's consistent.
kutjong
17th February 2009, 23:37
yes it's interlaced.
But if I use H264 codec from ffdshow my video is at 29.97 fps as indicated above.
I tried to advance frame per frame and I notice that dxva add some frames. It is very strange and it isn't normal.
Although, if deinterlaced was correct, my video must be at 30 i/s or 24 i/s (if inverse telecine was used) and not 60 i/s.
Nothing wrong with 60 fps. It just means that a deinterlacer that doubles the framerate is used, and this is good, full temporal resolution is retained since your source is 60 fields/s.
Rectal Prolapse
17th February 2009, 23:57
Quote:
Originally Posted by Rectal Prolapse View Post
bwahn, I think you also need to compile the Baseclasses.
Simplest way is to copy only the .cpp and .h files from the SDK's Baseclasses' directory into the baseclasses directory of the mpc-hc trunk (it should already be existing and have a Visual Studio project inside it but no source code files). Then in Visual Studio build the Baseclasses project in the MPC-HC solution.
Leak says:
Is that (still) supposed to work? Because if I only do that the BaseClasses solution compiles fine, but I'm getting 46 errors all over when compiling the MPC-HC solution that it can't find 'streams.h'...
Hey Leak - those instructions I think only apply to the really early versions of MPC-HC (probably 1.1.0.0 or even earlier). I believe the new MPC-HCs include the BaseClasses project, OR they already refer to the new Platform SDK version. I don't remember exactly.
Leak
18th February 2009, 01:15
I believe the new MPC-HCs include the BaseClasses project,
Nope, the BaseClasses folder only contains a project file.
OR they already refer to the new Platform SDK version. I don't remember exactly.
I'm using the latest one for Vista (6.0A), but I have to add the BaseClasses samples directory in VC2008's global include directories for everything to compile - but I just don't think that should be neccessary since not every project I compile needs them...
daMaster
18th February 2009, 01:24
I see the memory usage increase every time I open another file, it's consistent.
I've been posting about this memory leak for over a week now and it is an issue that seems to be ignored by the devs over and over as I've received no responses to my posts.
Here are my various posts and that of an NVidia user confirming the same leak. The leak is in the MPC Video Decoder DirectShow filter in DXVA mode. I have also reported the issue here: https://sourceforge.net/forum/forum.php?thread_id=2994581&forum_id=583789
I've discovered a memory leak in the MPC Video Decoder v1.2.908.0 (DirectShow filter MPCVideoDec.ax) when using DXVA for H.264/AVC/VC1 with the following set up:
- OS: Vista
- GPU: ATI Radeon HD 3470, Catalyst 9.1 drivers
- DirectShow media player: MediaPortal
- Renderer: EVR
When I play a 720p/1080p H.264 video and then stop it, there's some residual memory that doesn't get cleaned up. After playing and stopping 12-15 such HD videos, that accumulation of residual memory gets up to 800-900 MB!
If I disable DXVA decoding in the MPC Video Decoder's property page, then this memory leak does not occur, so it would seem it only happens with hardware acceleration.
Here is a ProcessExplorer (http://download.sysinternals.com/Files/ProcessExplorer.zip) performance graph of the MediaPortal.exe process comparing the private bytes usage with the PowerDVD 8 H.264/AVC/VC1 decoder (LEFT) and the MPC Video Decoder (RIGHT). Each private bytes spike is when a video is playing and the following dip is when a video is stopped. As you can see, with the PowerDVD 8 decoder the private bytes usage returns pretty much to the amount it was before the video was played. On the right hand with MPC Video Decoder, the private bytes usage is slightly higher after each video is stopped than what it was before the video was started.
http://img21.imageshack.us/img21/4913/mpcmemoryleakhd0.png
Can other folks that use the MPC Video Decoder with DXVA test this out to help validate the issue? I am hoping users with different video cards (NVidia vs. ATI) and different DirectShow media players can test this out to see if they have the same issue.
I've already reported this issue on the MPC SourceForge open discussion forum: Memory leak in DirectShow filter MPCVideoDec (https://sourceforge.net/forum/forum.php?thread_id=2994581&forum_id=583789). I am really hoping the MPC devs will be able to fix this since MPC Video Decoder is my preferred decoder. It is more lenient than the PowerDVD 8 decoder and I find the picture quality is slightly better (smoother motion), but I can't use it with this memory leak since after a while I have to restart MediaPortal once it starts crashing.
So I also managed to reproduce this in mplayerc.exe. I set it up to use MPC Video Decoder as an external DirectShow filter and just kept playing and re-opening the same 1080p MKV file.
Here is the ProcessExplorer performance graph showing the private bytes usage of mplayerc.exe:
http://img11.imageshack.us/img11/128/croppercapture22da1.png
Hello
Just to confirm the findings of damaster...
Running Vista 32 (SP1) and using a NVidia 9400 IGP whilst using MPCVideoDec DirectShow filter to decode a 1080p mkv file I find the following memory retention problem arises...
http://www.freeimagehosting.net/uploads/th.51f8a59c7d.jpg (http://www.freeimagehosting.net/image.php?51f8a59c7d.jpg)
as you can note the retention of the memory increase after the file is played back and then replayed again.
Using the PowerDVD 8 filter I get the following...
http://www.freeimagehosting.net/uploads/th.926834f4ca.jpg (http://www.freeimagehosting.net/image.php?926834f4ca.jpg)
...the memory retention does not happen and the usage remains constant regardless of how often the file is played.
The above is repeatable each and every time when using the noted filters.
I did read the article and I already clearly understand memory usage (I'm a software engineer as well).
This is indeed a memory leak if I've ever seen one. With every invocation and usage of the MPC Video Decoder in DXVA mode to play a video it uses up a certain amount of memory, let's say X bytes. When the video is stopped, it should release those X bytes that were previously allocated, however it does not. It only releases Y bytes where Y < X. As a result, you have a leak of X - Y bytes. As one continues to play N movies, that leak grows, such that the process now uses N * (X - Y) bytes which are wasted because they were never properly de-allocated. The problem here is that the value of (X - Y) is rather large and so after playing about 16 1080p videos in DXVA mode, N * (X - Y) reaches nearly 1GB! How you can say this is not a memory leak is beyond me.
Note that in software decoding mode this is not a problem at all and (X - Y) is so tiny it is negligible or Y = ~X.
If you understand mem allocation, then I don't need to explain to you that somewhere in the code some memory is not being de-allocated correctly in DXVA mode or some object is not being de-referenced or cleaned up.
Pyr0
18th February 2009, 01:30
@Pyr0: With rev997 on Vista SP1 32bit it works fine.
Thank you for the input XhmikosR, it's greatly appreciated :)
Can anybody test in Vista x64 SP1 please?
when i try to use the standby option in either mpchc version (x86/x64) the monitor blanks, but the system does not power down. but this only happens with the builds after 982
cca
18th February 2009, 08:15
To prevent misunderstandings, I must clarify that my last posts about memory leak etc are about Beliyaal's patched version 13, they do not concern the pure SVN version or the standalone decoder package.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.