View Full Version : madVR - high quality video renderer (GPU assisted)
wanezhiling
29th December 2013, 09:35
what about YV12?
http://forum.doom9.org/showpost.php?p=1565744&postcount=12801
http://forum.doom9.org/showpost.php?p=1599253&postcount=14
And YV12 doesn't work with EVR on ATI.:)
nevcairiel
29th December 2013, 09:38
NV12 is the only valid choice for 4:2:0 video. Trying to work around bad driver configuration by using YUY2 and degrading quality in the same step is just a bad idea.
nevcairiel
29th December 2013, 09:41
2. On same display, 24 fps source, interframe/svp to 60 fps, displays at 72hz, no smoothmotion, judder. Expect 60hz, no smoothmotion or judder.
4. On a 60hz display, 24 fps source, interpolated to 60 fps, smoothmotion is enabled. Expect smoothmotion disabled.
There are pretty much the same reason, i expect.
madVR acts on the information it gets through the DirectShow graph, if it says 24 fps, it'll do that.
The video decoder will say 24 fps, as expected. If you have a post-processor that changes this, the post-processor should also change this information *before* it reaches madVR, or madVR wouldn't know that its not getting 24 fps, but 60 fps.
In short, blame ffdshow/SVP, they need to inform madVR that its getting 60 fps instead of 24 fps, or madVR just doesn't have any better information to act on.
wanezhiling
29th December 2013, 10:00
Yeah I agree with you, the workaround is really a bad idea.
ATI and Intel are both notorious for having extremely destructive video settings enabled by default, and NV12 will make these settings work when using VMR/EVR. This really exists, blame these manufacturers. :)
turbojet
29th December 2013, 10:56
So in other words, madvr can't workaround the ffdshow fps issue? Slim chance someone would fix it in ffdshow.
6233638
29th December 2013, 11:19
Yeah I saw this option but I also happen to have genuine 25p material, ideally I would need a 24Hz hotkey but I guess I'll just map the "display mode switcher" toggle hotkey and roll the refresh rate on my own for 25p@24Hz.I find that 25fps native content is very rare. Typically I encounter 24fps content sped-up to 25p, or 50fps content. (which madVR outputs at 50Hz)
James Freeman
29th December 2013, 12:40
Anyone heard about Upscaling using motion interpolation?
Basically it reads few frames and decides what the new "Hi-Res" lines should look like.
Its much more CPU intensive but MUCH better looking than Lanczos/Jinc, or any other "static" upscaler will ever be.
Here is the samples page where you can compare many static upscalers and this method:
http://www.infognition.com/articles/video_resize_shootout.html
It's also what the HD to 4K upscaler does (real time) in the new "Ultra-D" technology.
DragonQ
29th December 2013, 12:48
I find that 25fps native content is very rare. Typically I encounter 24fps content sped-up to 25p, or 50fps content. (which madVR outputs at 50Hz)
Nah, not rare at all. Plenty of UK TV is native 25p, e.g. most drama and some comedies.
LigH
29th December 2013, 12:54
Anyone heard about Upscaling using motion interpolation?
Reminds me on an ancient (2004) topic in the German doom9/Gleitz forum about Temporal Super Resolution (http://forum.gleitz.info/showthread.php?15845), used for VCD-DVD (and worse) upscaling in those times; today it would probably use EDI techniques (Edge Directed Interpolation).
G_M_C
29th December 2013, 12:55
No new release ?
I was hoping for a Christmas-New Year surprise release :D Alas ....
Anyway, from holland i wish Madshi and Nevcairiel, and everybody else on Doom9, a happy new year !
James Freeman
29th December 2013, 17:47
Uh-Oh... I think I found a major "thing" (not saying a bug) with all the Chroma Upscaling modes.
How I got on to it:
I decided to test the built-in (MPC-HC) chroma upsampling pixel shader.
I turned off MadVR Chroma Upscaling (set to Nearest Neighbor).
Turned on "YV12 Chroma Upsampling" pixel shader (Pre-Resize), and WOW it looks better to me compared to any one of the modes MadVR has.
To get to the root of this:
I looked closer at Red patches of a test image to find what MadVR does with its chroma upsampling.
I have found that MadVR moves the whole chroma image 2 pixels (or 1) to the left while leaving darker area on the right (From Billinear to Jinc), while the internal mpc-hc shader does not.
In an HD video this is unacceptable because the moved chroma covers an area that should not be colored even if its one pixel.
I also find the Pixel Shader Chroma Upscaler looks way better in terms of ringing and sharpness.
If anyone wants to try this or confirm, please do.
You'll need a video with primary red color in the image and freeze it.
Use this video (its a test pattern):
http://www.mediafire.com/watch/378rx2q72znxsiy/DVD%20Chroma%20(420).mkv
Just jump in MadVR between Nearest Neighbor and any one of the Chroma modes (even Billinear).
Now leave MadVR at Nearest Neighbor and turn on the "YV12 Chroma Upsampling" pixel shader (Pre-Resize).
You can even now select any chroma mode in MadVR with the pixel shader enabled to confirm that it still moves the chroma image to the left.
It very well might be just me with my eagle eyes.
But you're welcome to try it for yourself.
EDIT:
Apparently the internal Pixel Shader chroma upsampler does a simple Billinear upscaling (no surprise here).
BUT, it still does it better than the MadVR Billinear because MadVR moves the whole Chroma image to the Left and leaves a dark shadow on the right.
Anyone please confirm with this sample video:
http://www.mediafire.com/watch/378rx2q72znxsiy/DVD%20Chroma%20(420).mkv
Or any one of these (480, 720, 1080, download the 4:2:0 version):
http://www.mediafire.com/folder/xdwi61cstb3d3/Chroma%20%2B%20Resolution%20-%20Test%20Patterns
EDIT 2:
Not to say that MadVR Chroma Upscaling does a bad job (its actually the best), but what its doing wrong is moving the Cr chroma to the left.
mikser
29th December 2013, 20:05
I have a problem with video stuttering when using MadVR (MPC-HC 1.7.0.7621 + Lav 0.58.1.0 + MadVR).
Haven't had any problems with MadVR previously even when using the latest development version. Then I noticed that video started stutter. Very noticeably and making the video unwatchable (if and when it stutters). Sometimes it stutters constantly, sometimes for a few seconds every 5 seconds, sometimes for a second every minute.
The issue has been very strange because the average and even max stats are clearly smaller than the required frame interval.
The video material doesn't really matter. It stutters on 720p@60fps -> 1080p and at some xvid 24fps file viewed without up/downscale.
Trying to change scaling algorithms didn't help.
Tried to change all other MadVR settings and it doesn't change much.
There is stutter in both window and exclusive modes
Sometimes the stutter comes at the same place of the video, sometimes it doesn't (vice versa).
Tried to default MadVR settings - doesn't help.
Downgrading (via uninstall and install) to madVR_0.86.11 didn't help.
WindowsXP, DirectX and video drivers are patched with latest fixes.
When tried to switch video decoder to Haali, the video works fine (and looks like shit).
I have had this issue for at least a month now, but had nothing specific to report so I was quiet. I am writing now because today I had two separate revelations:
1. I put 2 and 2 together and got an idea how the whole mess started. It might have started when I had to change both my monitor and my video card.
- Viewsonic 24 -> Philips 273EL (273E3L?)
- Nvidia 9800 GTX+ -> GeForce GTX 650
And yes, I have installed the new monitor drivers, updated video drivers and deleted my old monitor drivers (my device manager doesn't show old monitor nor old video card).
2. Today I noticed that the Ctrl-J statistics shows that my display Hz is constantly changing. I might be wrong but I don't remember it doing that before. Certainly not constantly, with every statistics update (about every second). When 720p@60fps video is paused, the Hz are jumping between 58.X and 60.2Hz But most importantly, when I start playing the video, the jumping becomes even wilder. 55Hz and 50 Hz and happening constantly. Even numbers like 0Hz (zero!) are seen all the time.
Clock deviation can be both - and +. I don't know what that actually means, so you can tell me if -0.04 or +0.05 is bad or not.
So it seems that this constant change of Hz can the the reason why video (MadVR?) is constantly stuttering.
btw. I don't use smooth motion. And no, turning it on doesn't help.
So what can I do to fix the issue or to provide enough information for you to fix it?
You are my only hope because incredibly, Googling this hz constantly changing issue didn't return any relevant info. Video card settings don't have anything about "flowing/adaptive Hz".
michkrol
29th December 2013, 20:46
Uh-Oh... I think I found a major "thing" (not saying a bug) with all the Chroma Upscaling modes.
Does it happen with material "in the wild", like movie trailers you can download or similar?
I see this behavior with your file, but not with any of ~10 random samples from my collection I've checked.
It might have something to do with chroma sample location not being interpreted correctly by madVR or being marked wrong in the file. I remember madshi mentioning that madVR assumes H264's default chroma sample location, but can't find this post right now. Your file is H264, so it might be uncommon or even half-broken - perhaps you encoded it with non-default settings, used mainly for transcoding from other (older) formats?
Video card settings don't have anything about "flowing/adaptive Hz".
Not sure, but you might have problem with adaptive vsync technology, supported by GF650, but not GF9800. Look for it in nvidia's settings and disable it. I don't own an nvidia card, so I can't be sure.
6233638
29th December 2013, 20:54
Uh-Oh... I think I found a major "thing" (not saying a bug) with all the Chroma Upscaling modes
...If I recall correctly, the chroma position is shifted with Bilinear (and possibly Nearest Neighbor?) but should be correct with other algorithms.
If you're seeing problems with the chroma position and using something more demanding than Bilinear, I think it's a problem with the video encoding.
That said, being able to tag a video in a way which corrects for this might be useful.
I have a problem with video stuttering when using MadVR (MPC-HC 1.7.0.7621 + Lav 0.58.1.0 + MadVR).Try doing a clean install of the latest WHQL drivers from Nvidia, and make sure you're back on 0.86.11 and not a test build.
nevcairiel
29th December 2013, 21:08
Uh-Oh... I think I found a major "thing" (not saying a bug) with all the Chroma Upscaling modes.
What you found is that hard color borders don't look perfect with any interpolated algorithms. Its the same problem as low-resolution old computer game footage has, it actually looks better with NN because this color-bleed effect on hard borders does not occur.
Luckily, any actual movie content will never have a hard high-contrast color border like this, so in the real world this is not even a thing.
magus
29th December 2013, 22:45
Hello I have recently got a new computer and decided to see if I could use madvr with high settings again. I have been out of the loop for a while but full exclusive mode always says out of memory for me everytime. To fix this I have to either turn off nvdia stereoscopic 3d mode in the nvidia settings panel or turn off exclusive mode in madvr panel.
Google turned this up: http://www.svp-team.com/forum/viewtopic.php?id=1484
It seems someone else had this problem earlier in this thread when I searched: http://forum.doom9.org/showpost.php?p=1648384&postcount=20418
He says re installing the drivers fixed the problem but I'm guessing all it did was change the nvidia settings to default which would turn the 3d off in nvidia panel.
I was wondering if this is how it is supposed to work or it's just a bug with exclusive mode. I would like to use exclusive mode but it is not that big of a problem since I can just turn it off.
mikser
30th December 2013, 01:55
Not sure, but you might have problem with adaptive vsync technology, supported by GF650, but not GF9800. Look for it in nvidia's settings and disable it. I don't own an nvidia card, so I can't be sure.
What an excellent guess!
I found the "Nvidia Control Panel / Manage 3D settings / Vertical sync" option, put it on "Off" and everything works fine now. Thanks a lot!
The problem here is that "Adaptive" and "Adaptive (half refresh rate)" weren't turned on in the first place, actually. That option was set up as "Use the 3D application setting". So my guess is that this issue can be fixed in MadVR by MadVR telling the drivers not to use Adaptive vsync (neither of the provided options), not to use "Vsync = on" (this also caused problems), but to strictly use "Vsync = off".
6233638
30th December 2013, 02:25
The problem here is that "Adaptive" and "Adaptive (half refresh rate)" weren't turned on in the first place, actually. That option was set up as "Use the 3D application setting". So my guess is that this issue can be fixed in MadVR by MadVR telling the drivers not to use Adaptive vsync (neither of the provided options), not to use "Vsync = on" (this also caused problems), but to strictly use "Vsync = off".V-Sync should be left on "Use application setting" unless you have a specific need to change it from this, which should be done on a per-application basis, not a global one.
I hate that Nvidia did not seem to properly educate people on what Adaptive V-Sync does. It causes so many problems when people enable it without knowing what they're doing.
Frankly, I don't think it should be an option for people to use Adaptive V-Sync globally. (the people that need it could enable it via Nvidia Inspector)
Its main purpose is for games where you cannot enable triple-buffering (either the game doesn't offer it, or you don't want the additional frame of latency) and your system is almost holding a steady framerate, but will occasionally dip 5-10% below that.
E.g. a game that runs at 60fps most of the time, but will sometimes drop to the 55-60fps range.
Adaptive V-Sync lets the game tear to avoid dropping from 60fps to 30fps.
G-Sync fixes this problem by adjusting the display's refresh rate to match the framerate, so it is always synced, without requiring triple-buffering.
James Freeman
30th December 2013, 09:37
If I recall correctly, the chroma position is shifted with Bilinear (and possibly Nearest Neighbor?) but should be correct with other algorithms.
No, its not correct with any of the MadVR Chroma Upscaling algorithms except Nearest Neighbor which is actually doing nothing (turned off).
The chroma image is shifted to the left even with Billinear (and up).
What you found is that hard color borders don't look perfect with any interpolated algorithms.
No.
What I found is that MadVR Chroma Upscaling is moving the whole chroma information to the left while leaving darker area on the right (especially with Red color),
while the simple Pixel Shader does NOT.
MadVR is striving for best picture quality without compromise, while a VISIBLE fundamental problem exists.
Yes, it is most visible in a test pattern and not in actual movies, but that's how problems are found.
How do you calibrate your TV, movie or test patterns?
I'll say it again,
It's unacceptable that MadVR has artifacts with all of its upscalers while an even simpler pixel shader billinear upscaler does not.
Samples:
Comparing MadVR win pixel shader upscaler.
Direct download (click on download).
Look at the circles move (especially the magenta) with madvr.
http://www.mediafire.com/watch/7g110qzabmbr6ru/Chroma%20Shift.avi
Test Pattern shows movement to the left with darker area on the right (Red stripes).
Look at the line between the Magenta and Green colors, you can clearly see the Cr chroma moving 1-2 pixels to the left.
http://www.mediafire.com/watch/47xkwc69s7237j7/Chroma%20Shift%202.avi
If that won't make you realize this is a real problem I don't know what will.
EDIT 2:
Not to say that MadVR Chroma Upscaling does a bad job (its actually the best), but what its doing wrong is moving the Cr chroma to the left a little.
nevcairiel
30th December 2013, 10:12
What you are seeing is the effect of 4:2:0 chroma on hard color borders. The chroma is not moved.
I suggest you read up how 4:2:0 chroma works, especially with the mpeg2 chroma position. It explains this effect nicely. My guess is that the pixel shader you are testing does not use the correct chroma position, which simply looks differently.
Who says that the NN mode isn't simply wrong?
NN is not something worth comparing to really.
Compare it to other renderes, to DXVA2 scaling modes (which are performed by the GPU and not madVR), to software scalers, they all look the same.
Are you really going to claim everyone did it wrong for all these years, including GPU manufacturers? :)
In any case, if you are so certain, then open a bug report in madVRs bug tracker.
James Freeman
30th December 2013, 11:09
My guess is that the pixel shader you are testing does not use the correct chroma position, which simply looks different.
No,
Every other renderer I tried (including the built-in MPC-HC ones) are doing fine.
Its MadVR's chroma that looks wrong.
Compare it to other renderes, to DXVA2 scaling modes (which are performed by the GPU and not madVR), to software scalers, they all look the same.
NO they don't and that's the whole point !!!
Even MPC-HC internal EVR looks less smudged and not shifted, compared to MadVR Chroma upscalers.
Are you really going to claim everyone did it wrong for all these years, including GPU manufacturers? :)
No.
Just MadVR with its current Chroma Upsampling algorithms.
In any case, if you are so certain, then open a bug report in madVRs bug tracker.
I think my posts will be enough for a report.
Even better Sample:
*download the original.
http://www.mediafire.com/watch/hcke9ly1nbwndw8/Chroma%20Shift%203.avi
You can watch this video in B&W (Saturation -100) to see the chroma shift even clearer.
Anyway I'm waiting to hear what madshi thinks about it.
AngelGraves13
30th December 2013, 11:24
New features I'd like to see most...
High Frame Rate Conversion - Basically Smooth Motion on steroids that eliminates all motion blur and makes motion similar to Hobbit's 48fps. Something like SmoothVideo Project without all the settings and added programs.
Add/Remove Grain Filter - Sometimes it's nice to watch movies with added grain...like Predator (UHE) where DNR is too strong. Low/Med/High. Great for covering up bad masters and low-quality files. Also, a remove grain filter for those that might want it.
Dynamic Contrast Enhancement - Adjust Contrast for every frame. Low/Med/High settings
nevcairiel
30th December 2013, 12:24
I think my posts will be enough for a report.
madshi wants actual bug reports in his bug tracker. If you want to make sure it gets his attention and it gets fixed, post it there.
Here is even the link for you:
http://madVR.bugs.madshi.net
DragonQ
30th December 2013, 12:46
New features I'd like to see most...
High Frame Rate Conversion - Basically Smooth Motion on steroids that eliminates all motion blur and makes motion similar to Hobbit's 48fps. Something like SmoothVideo Project without all the settings and added programs.
Add/Remove Grain Filter - Sometimes it's nice to watch movies with added grain...like Predator (UHE) where DNR is too strong. Low/Med/High. Great for covering up bad masters and low-quality files. Also, a remove grain filter for those that might want it.
Dynamic Contrast Enhancement - Adjust Contrast for every frame. Low/Med/High settings
Ew, ew, and ew.
madshi
30th December 2013, 13:57
Sometimes I'd like to compare whether the video upscaled by madVR looks better than the same material pre-scaled. Since the resolution obviously differs, would it be possible to have an option that tells madVR to pass i.e. MPC-HC's save image function the upscaled version of the frame instead of the source frame? Or is it something MPC-HC would have to implement?
Currently madVR does what the Microsoft screenshot interface asks for. But I understand that it's not always what users want. It's on my long term to do list to make it user adjustable at which rendering stage (before or after scaling, before or after subtitle rendering etc) the screenshot is made.
I had to reinstall windows 8.0 (some games were not compatible with 8.1...) and the issue is still there. I have a Nvidia Geforce GTX 660 so it seems the workaround is not compatible with Nvidia GPU.
Feel free to create a bug entry in the bug tracker, to remind me to look into this.
Sorry for my typo.
It should be:
DXVA2 native doesn't work for me when "present several frames in advance" is disabled and "enable automatic fullscreen exclusive mode" is enabled.
Hmmmm... I'm not fully sure why that's the case. Can anybody else reproduce this? FWIW, disabling "present several frames in advance" is not recommended, anyway. And personally, I prefer software decoding. Still, it should work, of course.
turbojet, it was just because you didn't disable PotPlayer internal video post-processing filter (http://i1.tietuku.com/x15ws9rdr.png) and then it outputed YUY2 which is not well-compatible with madVR on NVIDIA platforms.
Good catch! :)
While this can be worked around in potplayer what might be the real issue; madvr, nvidia hardware or nvidia drivers?
Could it be madvr inputting yuy2, ivtc (problem), converting to yv12? If so wouldn't converting to yv12 before ivtc fix it?
I never saw a 4:2:2 or 4:4:4 telecined movie source yet. All telecined movie sources I've ever seen were 4:2:0. Because of that I didn't take the time to add support for 4:2:2 or 4:4:4 sources, for the IVTC algorithm. I would consider it a bug, though, that madVR doesn't notice that the input format is not supported and then produces image artifacts. So that's something I should fix. I don't plan on adding support for 4:2:2 IVTC, though.
can someone confirm that 60i with 3:2 forced film mode played at 60 hz has a judder even with smoothmotion? i'm pretty sure that worked before.
Just tested this with a DVD movie, and it worked just fine here. This might have to do with the timestamps, though. If the timestamps are royally screwed up, playback can't be smooth. Basically Smooth Motion FRC does not try to make motion smooth, it just tries to display every frame at exactly the correct timestamp, as if the display had an infinite refresh rate. So if the timestamps are not smooth, Smooth Motion FRC can't work properly.
Maybe at some point in the future I could try to analyze the timestamps and artficially smoothen them, but that's not a feature planned for the near future.
In short, blame ffdshow/SVP, they need to inform madVR that its getting 60 fps instead of 24 fps, or madVR just doesn't have any better information to act on.
Agreed.
So in other words, madvr can't workaround the ffdshow fps issue?
It's not impossible for madVR to detect, but it's currently not implemented. And that's not a bug. madVR behaves correctly. I might implement auto detection of source framerates at some time in the future, but probably not any time soon.
Anyone heard about Upscaling using motion interpolation?
Basically it reads few frames and decides what the new "Hi-Res" lines should look like.
Its much more CPU intensive but MUCH better looking than Lanczos/Jinc, or any other "static" upscaler will ever be.
Here is the samples page where you can compare many static upscalers and this method:
http://www.infognition.com/articles/video_resize_shootout.html
Sorry, but I can't take any website serious if they claim that Bicubic looks better than NNEDI3. That's more than ridiculous. Either they've totally screwed up their tests/measurements, or their test methods are not capable of properly measuring what looks good to our eyes, or they intentionally manipulated the test results. See here:
castle 2x Bicubic (http://madshi.net/castle2xBicubic.png)
castle 2x NNEDI3 (http://madshi.net/castle2xNnedi3.png)
Look especially at the roof lines. NNEDI3 is so much better. Yet the graph on the website you linked claims that Bicubic is better than NNEDI3. That's just crazy.
If you want my honest opinion about super-resolution techniques: I think it sounds great in theory. But I've yet to see it produce good results for real life DVD or Blu-Ray sources. This topic has been discussed in the avisynth section before. The opinion of the gurus there was that super-resolution only works if the original video contains aliasing. And you can see that in the low resolution videos on that website you linked: They're heavily aliased. They probably scaled the high-res videos down by using decimation/nearest neighbor sampling, or something like that. But that is not how DVDs or Blu-Rays look.
If I recall correctly, the chroma position is shifted with Bilinear (and possibly Nearest Neighbor?) but should be correct with other algorithms.
In the first madVR versions chroma position was shifted half a pixel to the right (compared to where it should be) when using Bilinear. This problem was fixed a couple of versions ago. Nearest Neighbor by design can't do a half pixel shift, so the chroma position is incorrect when using Nearest Neighbor.
Hello I have recently got a new computer and decided to see if I could use madvr with high settings again. I have been out of the loop for a while but full exclusive mode always says out of memory for me everytime. To fix this I have to either turn off nvdia stereoscopic 3d mode in the nvidia settings panel or turn off exclusive mode in madvr panel.
Not sure why. But if the NVidia stereoscopic 3d mode makes problems, that's probably out of madVR's control.
If it claims you're running out of memory, you could try lowering the GPU queue size and/or the number of prepresented frames to save GPU memory (if the complaint is about GPU memory, otherwise try lowering the CPU queue size) to see if that helps.
No, its not correct with any of the MadVR Chroma Upscaling algorithms except Nearest Neighbor which is actually doing nothing (turned off).
The chroma image is shifted to the left even with Billinear (and up).
MadVR is striving for best picture quality without compromise, while a VISIBLE fundamental problem exists.
You really did find a fundamental problem. But the problem is not in madVR, it's in the videos you were using to test this. Please check the MPEG2 and h264 specs. Or look here:
http://www.poynton.com/PDFs/Chroma_subsampling_notation.pdf
All newer video codecs (MPEG2, VC-1, h264) have the chroma position moved half a pixel to the left, when using 4:2:0 or 4:2:2 chroma subsampling. While MPEG1 had it centered. The specs are very very clear about this.
madVR properly moves the chroma channel half a pixel to the left. When using "Nearest Neighbor" in madVR + the "YV12 Chroma Upsampling" shader, the chroma channel is displayed centered instead, which is correct for MPEG1, but incorrect for MPEG2, VC-1 and h264.
So basically what you found is that the test videos are encoded incorrectly.
High Frame Rate Conversion - Basically Smooth Motion on steroids that eliminates all motion blur and makes motion similar to Hobbit's 48fps. Something like SmoothVideo Project without all the settings and added programs.
Not planned. At least not for the near future. You can use ffdshow/AviSynth with SVP.
Add/Remove Grain Filter - Sometimes it's nice to watch movies with added grain...like Predator (UHE) where DNR is too strong. Low/Med/High. Great for covering up bad masters and low-quality files. Also, a remove grain filter for those that might want it.
You can tell madVR that your display can do 7bit or 6bit, only. In that case madVR applies a higher dithering/grain level. Maybe that does what you want? If not, you can simply write a little pixel shader and use it (in MPC-HC/BE at least).
Dynamic Contrast Enhancement - Adjust Contrast for every frame. Low/Med/High settings
I believe such an algorithm is bad. What could make sense is to watch a video over a longer time period to detect the overall range the video is encoded in (e.g. fullrange, limited range or even double/triple expanded) and then use that information to automatically adjust madVR's input levels. But adjusting such things *per frame* will in many cases lead to image pumping and other artifacts.
James Freeman
30th December 2013, 14:56
All newer video codecs (MPEG2, VC-1, h264) have the chroma position moved half a pixel to the left.
So basically what you found is that the test videos are encoded incorrectly.
LOL, that simple. :o
My encoding line was:
x264.exe -o output.avi input.avi
You think that problem lies here?
Meh, made a jackass of myself...Again. :D
Thank for the clarification madshi.
huhn
30th December 2013, 15:39
madshi interested in a sample where the ivtc filter can't handle 3:2 (anime (8:7, 5:5, 3:2)) no captions or 2:2 motions on top.
the really interesting part in this is that if you go back without restarting the clip and watch it again it works fine.
and a clip from 3:2 to 2:2:2:4 detected as 3:2 into 2:2 for secs and than as 4:2:2:2 but with tons of dropped frames simply unwatchable.
My encoding line was:
x264.exe -o output.avi input.avi
You think that problem lies here?
yeah kind of you may should add a lot more for 100 % correct playback like colorprim, range, colormatrix and transfer
chromaloc
Default: 0
Sets the chroma sample location. (as defined in Annex E of the ITU-T Specification).
Values range from 0 to 5.
See x264's vui.txt
Recommendation:
If you transcode from MPEG1 with proper subsampled 4:2:0, and don't do any color space conversion, you should set this option to 1.
If you transcode from MPEG2 with proper subsampled 4:2:0, and don't do any color space conversion, you should set this option to 0.
If you transcode from MPEG4 with proper subsampled 4:2:0, and don't do any color space conversion, you should set this option to 0.
Otherwise, default.
that's what's missing http://mewiki.project357.com/wiki/X264_Settings#chromaloc
James Freeman
30th December 2013, 15:48
@huhn
The input.avi is a simple screen recording with lossless compression and rgb32 colors.
The x264 does its magic automatically (4:2:0 etc...),
You still think I need to use the chromaloc function?
madshi
30th December 2013, 16:10
My encoding line was:
x264.exe -o output.avi input.avi
You think that problem lies here?
I'm not an expert in encoding. I suppose feeding the encoder with RGB might be part of the problem. Although in theory the encoder should be smart enough to perform the chroma subsampling in such a way that the chroma channel is at the right position. So maybe this could actually count as an x264 bug.
madshi interested in a sample where the ivtc filter can't handle 3:2 (anime (8:7, 5:5, 3:2)) no captions or 2:2 motions on top.
the really interesting part in this is that if you go back without restarting the clip and watch it again it works fine.
Sure, such clips are always welcome. However, it'll be a while before I find time to look into deinterlacing/IVTC again. So many other things that need attention at the moment.
nevcairiel
30th December 2013, 16:15
I'm not an expert in encoding. I suppose feeding the encoder with RGB might be part of the problem. Although in theory the encoder should be smart enough to perform the chroma subsampling in such a way that the chroma channel is at the right position. So maybe this could actually count as an x264 bug.
x264 uses swscale for re-scaling such things, which is so old that mpeg1 chroma was the correct thing to do when it was new.
For better results, use a more advanced scaler, possibly through AviSynth, and feed x264 that as input.
madshi
30th December 2013, 16:21
Ah, ok, that makes sense. Maybe it should be reported to x264 as a bug. If x264 isn't able to subsample chroma correctly then it should error out with RGB input. Producing incorrect results is a bad idea, IMHO.
6233638
30th December 2013, 16:32
Sorry, but I can't take any website serious if they claim that Bicubic looks better than NNEDI3. That's more than ridiculous. Either they've totally screwed up their tests/measurements, or their test methods are not capable of properly measuring what looks good to our eyes, or they intentionally manipulated the test results.This is why PSNR (http://en.wikipedia.org/wiki/Peak_signal-to-noise_ratio) is not really used for this type of comparison any more. SSIM (http://en.wikipedia.org/wiki/Structural_similarity) generally produces more perceptually correct results, but you still need to do a visual comparison.
So many other things that need attention at the moment.castle 2x NNEDI3Hmm...
huhn
30th December 2013, 17:33
Ah, ok, that makes sense. Maybe it should be reported to x264 as a bug. If x264 isn't able to subsample chroma correctly then it should error out with RGB input. Producing incorrect results is a bad idea, IMHO.
but it can encode in rgb directly is bad but it is capable of it.
that's what i don't get he inputs rgb but it encodes YCbCr 4:2:0.
and what conversion is used for rgb -> yua bt601, bt709 or nothing??
like nevcairiel said avisynth and add the right tags to it.
madshi
30th December 2013, 18:39
Hmm...
Shushh...
nevcairiel
30th December 2013, 19:03
that's what i don't get he inputs rgb but it encodes YCbCr 4:2:0.
It always does that, unless you actually tell it to encode in 4:4:4 or RGB directly. I assume thats done to produce the most compatible files.
turbojet
30th December 2013, 20:51
I haven't seen 4:2:2 telecined source either. It would be nice if madvr could work around conversion to 4:2:2 though.
While I don't interpolate myself, I do occasionally decimate with avisynth because madvr's ivtc doesn't handle some situations such as this simple one (http://www.sendspace.com/file/5c3mfa) which is telecined material that was deinterlaced so every fifth frame is a duplicate. It would be nice if this would work without disabling display changer and smoothmotion. I would think MadVR would be able to handle this. I suppose I could ask in the ffdshow thread, resizing avisynth works fine with player and madvr, is this being passed from ffdshow or is it calculated by player/madvr?
On bigger screens a lot of grain can be unbearable. NCIS: LA has a lot of grain, I'll try to remember to cut a sample of it when it airs again in a few weeks. I haven't messed with any avisynth filters for it but will do, after seeing madvr's deband vs avsiynth methods, it would be interesting to see what madshi could do when/if he finds time for something like this though. One thing about madvr's deband is it doesn't add grain, at least not much, while avisynth deband filters do, but in most cases the no added grain is desirable imo. I really don't get dynamic contrast, it's become very common feature on lcd's but it looks horrible imo, lcd's need to work on getting deeper blacks, not brighter.
I don't think still pictures do nnedi3 much justice, while there are definitely some pros and a few cons of the still picture castle comparison to bicubic. At 24fps those cons pretty much disappear IME.
James Freeman
30th December 2013, 21:19
I have dug dipper into the chroma analysis, and....
Yes, the actual chroma on a blu-ray is shifted 1 pixel to the right.
And when selecting a Chroma Upscaler in MadVR this moves the chroma 1 pixel to the left where it should be. (yes I feel stupid right now) :rolleyes:
I also included a nice video of my reference blu ray to show you guys how bad (low-res) a blu-ray chroma really is,
And how of a good job MadVR Chroma Upsampling really does.
Please download this clip and bask you eyes in amazement of:
The Ugliness of Blu Ray Chroma (http://www.mediafire.com/watch/bqu5lq188mu4k7a/Blu%20Ray%20Chroma.avi)
Well.. you learn something new every day.. only I do it loudly. :D
huhn
30th December 2013, 21:22
While I don't interpolate myself, I do occasionally decimate with avisynth because madvr's ivtc doesn't handle some situations such as this simple one which is telecined material that was deinterlaced so every fifth frame is a duplicate. It would be nice if this would work without disabling display changer and smoothmotion.
that would be inverse telecine (edit: field matched is the right word) but this sample is not inverse telecine it is 3 frames plus 2 >bob< frames. madvr gets 29p and handle it like true 29p nothing to fix there just wrong/bad encoded.
pirlouy
30th December 2013, 22:11
Dynamic Contrast Enhancement
I believe such an algorithm is bad. What could make sense is to watch a video over a longer time period to detect the overall range the video is encoded in (e.g. fullrange, limited range or even double/triple expanded) and then use that information to automatically adjust madVR's input levels. But adjusting such things *per frame* will in many cases lead to image pumping and other artifacts.
A lot of TV offer this. This setting allows a better visual. I guess it have some drawbacks, but no artifacts. Sure it does not respect the source, but it's a feeling: image looks better.
On LCD, the other dynamic contrast called "dynamic contrast (http://en.wikipedia.org/wiki/Contrast_ratio#Dynamic_Contrast_.28DC.29)" is a problem, and at least on my TV, he can't be disabled. I suspect it of causing flickering.
Razoola
30th December 2013, 22:50
I don't like the idea of these enhancements (IFC, DCE etc). My panel has many options like this and I have them all turned off.
I must admit the idea of an upscaler that takes a few frames of information into account when up scaling sounds interesting. I also would also be interested in experimentation of forcing a panel that supports 3D at 120hz to display a normal 2D picture at that rate. Its just not possible to put a 3D panel into a 120hz refresh rate via windows unless its a dedicated PC monitor. I think most only go to 120hz when they have 3d material sent down the HDMI. So what Im suggesting there is to send a standard 2D 24fps frame to the panel as 3D (make the frame the same for both the left and right eye). I think that would be intresting because plasmas at least do not have options to watch 2D at 120hz unless you activate IFC but that sucks. I guess it may allow for picture improvement (esp in motion scenes) but then again it might be worse.
turbojet
30th December 2013, 23:25
that would be inverse telecine (edit: field matched is the right word) but this sample is not inverse telecine it is 3 frames plus 2 >bob< frames. madvr gets 29p and handle it like true 29p nothing to fix there just wrong/bad encoded.
It is badly encoded and a bit much to expect madvr to find and remove dupes by default but using deint=ivtc I'd expect to handle it, the pattern doesn't get any simpler. Instead madvr does an unnecessary deinterlace and chooses the wrong frames to remove.
magus
31st December 2013, 01:59
I also would also be interested in experimentation of forcing a panel that supports 3D at 120hz to display a normal 2D picture at that rate. Its just not possible to put a 3D panel into a 120hz refresh rate via windows unless its a dedicated PC monitor. I think most only go to 120hz when they have 3d material sent down the HDMI.
I don't know if this has anything to do with what you said but I have a 120hz monitor and when I watch movies on it madvr says the display is 120hz and composition rate is also 120hz(on the cntrl+j screen). Also does anyone know if there is an advantage in watching movies in 120hz. Right now I just use it for games which is nice.
Not sure why. But if the NVidia stereoscopic 3d mode makes problems, that's probably out of madVR's control.
If it claims you're running out of memory, you could try lowering the GPU queue size and/or the number of prepresented frames to save GPU memory (if the complaint is about GPU memory, otherwise try lowering the CPU queue size) to see if that helps.
Reducing the GPU and CPU queue did not work but turning off present frames in advance made the out of memory error go away. But turning off the present frames in advance also makes my 3d icon and 3d glasses turn on in fullscreen exclusive mode(weird, I guess nvidia thinks exclusive mode with present frames in advance turned off is a 3d application?). I also noticed that the average stats for rendering and present are higher when 3d mode is forced on(by turning off present frames in advance) even though it doesn't say out of memory anymore.
Anyway I figured the best option as of now is to turn off all 3d related options in nvidia when I'm not playing games.
leeperry
31st December 2013, 02:08
I must admit the idea of an upscaler that takes a few frames of information into account when up scaling sounds interesting.
vReveal is the only consumer software that enhances video with genuine super-resolution technology. It uses patented algorithms to analyze and extract information from multiple frames to reconstruct single, enhanced frame. vReveal has the unique ability to increase resolution and remove noise in all your videos. (http://notebooks.com/2009/03/24/amazing-new-cuda-powered-video-enhancement/)
This thing can run in realtime apparently, too bad vReveal might very well have gone belly up as their domain name is a 404 now. This woulda killed in mVR :)
huhn
31st December 2013, 02:18
It is badly encoded and a bit much to expect madvr to find and remove dupes by default but using deint=ivtc I'd expect to handle it, the pattern doesn't get any simpler. Instead madvr does an unnecessary deinterlace and chooses the wrong frames to remove.
that's not the point of ivtc the sample is progessive and nothing else.
ivtc is not simply removing duplicates if it does this terrible thinks will hppen anime is from time to time 5 fps or even lower that'S not how ivtc works.
ivtc removes duplicates from filedmatching but how to field match a progressive source? use it on interlaced videos and nothing else.
Guest
31st December 2013, 03:10
use it on interlaced videos and nothing else. More precisely, use it on telecined video.
Xaurus
31st December 2013, 03:33
I don't like the idea of these enhancements (IFC, DCE etc). My panel has many options like this and I have them all turned off.
I agree. Hopefully madshi won't waste time on stuff like that.
Razoola
31st December 2013, 08:52
I don't know if this has anything to do with what you said but I have a 120hz monitor and when I watch movies on it madvr says the display is 120hz and composition rate is also 120hz(on the cntrl+j screen). Also does anyone know if there is an advantage in watching movies in 120hz. Right now I just use it for games which is nice.
I also have a 120hz pc dedicated monitor. If you are using 2 displays though with AERO enabled you cannot take the composition rate as the refresh rate on the 2nd display. The composition rate is always the refresh rate of the primary display. My 2nd display is a 3D plasma and although madVR reports 120hz composition rate the actual refresh rate of the panel is 24hz (as reported by the panel, windows and madVR in the display value).
yok833
31st December 2013, 18:59
I agree. Hopefully madshi won't waste time on stuff like that.
It depends of how would be the result with new algorithms from madshi... It is turned off on your TV because you are not happy with the results... Me, I would be happy of each new option that could improve the picture quality of my movies :)
Razoola
31st December 2013, 19:49
We have those turned off because we want our picture to match how the director of the movie wanted them to be. Once you start changing settings adding dynamic contrast etc you begin to ruin the experience of getting lost in the film experience. This is because the atmosphere the director is trying to create with lighting is lost.
yok833
31st December 2013, 21:20
We have those turned off because we want our picture to match how the director of the movie wanted them to be. Once you start changing settings adding dynamic contrast etc you begin to ruin the experience of getting lost in the film experience. This is because the atmosphere the director is trying to create with lighting is lost.
I totally agree with you about respecting the atmosphere of the director.. but is it incompatible ? Depending of your TV or your source, a noise reduction, a sharpen filter or a dynamic contrast algorithm (specially cooked by madshi!!)... can maybe help in getting closer of the original atmosphere?
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.