Log in

View Full Version : madVR - high quality video renderer (GPU assisted)


Pages : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 [494] 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329

turbojet
9th March 2014, 13:49
Originally Posted by turbojet View Post
Tried that in both user mode and admin mode, which should it be? It had no effect.


Did you reboot after using madLevelsTweaker? If that doesn't help then something else is going on. Make sure you disable (and set to neutral values) all options in the GPU control panel like color/gamma adjustments, dynamic contrast, skin tone adjustments, etc etc. Maybe a driver cleaning and reinstall will help? I'm not sure what else to suggest...

Yes, box is checked. nvidia control panel is all defaults which it looks like it's set to all application controlled. I'll try yet another clean install but I just did that yesterday. This has been something I've been noticing for months but it's starting to aggravate me now. It happens on 2 different computers+tv's too, both nvidia gpus.

6233638
9th March 2014, 13:53
What is the standard gamma curve of modern LCD TVs?There is no standard. I would use 2.2 gamma (1/0.45) if nothing has been specified in the madVR configuration though, as it is most likely to be used if a display does have a decent out of the box calibration.

Audionut
9th March 2014, 13:54
Isn't dithering the final step before rendering? In that case, shouldn't it (luminance) map to whatever the device is calibrated too? Based on the settings in the calibration tab.

Otherwise, wouldn't it be best to map back to the source profile?

James Freeman
9th March 2014, 13:56
turbojet,
I think for the last few driver versions Nvidia forced 0-255 with 60Hz, and 16-235 with 59Hz on HDMI output.
So if you set madLevelsTweaker to full range and refresh rate to 60Hz you get double expansion (clipped black and white).
Or changing to YCbCr444/RGB changes the range too in NCP.

It can be my display so don't take my word for it, test yourself.

6233638
9th March 2014, 14:02
Isn't dithering the final step before rendering? In that case, shouldn't it (luminance) map to whatever the device is calibrated too? Based on the settings in the calibration tab.I agree, it should follow the calibration tab. (and 3DLUTs will need a preference to set what their display is calibrated to)

Otherwise, wouldn't it be best to map back to the source profile?If I recall correctly, the end-to-end gamma target for BT.709 content is intended to be around 1.2

1.2/0.51 = 2.35

Though newer standards based upon measurements of mastering-grade monitors (BT.1886) have moved this to 2.40 rather than 2.35

Displays sold today are far more likely to be around 2.2 gamma than 2.35 out of the box though, which is why I would suggest using that value instead if nothing is specified.

turbojet
9th March 2014, 14:06
Clean driver install had no effect. The 250 is connected via s-video to a 59Hz crt with latest drivers. A 650 (327 drivers) is connected to 24/48/50/60Hz LCD via hdmi. I'll go check to see if there is a difference when switching refresh rate on the LCD.

iSunrise
9th March 2014, 14:10
What are you calibrating your screen to? BT.709 content should be viewed using the BT.1886 transfer function (which becomes a flat 2.40 gamma on high contrast displays) and never the BT.709 transfer function, which is intended for capture, not playback.
Depending on the content I view, I have several choices to go with. I know that Rec.709 is only intended for capturing/monitoring, but BT.709 still is the closest here. BT.1886 didn´t work out to well for me last time I tried. Then again, I´m not using DispCal or the ArgylCMS, I´m using the Eizo Colornavigator for this.

Audionut
9th March 2014, 14:12
(and 3DLUTs will need a preference to set what their display is calibrated to)

What does madVR currently do with a 3dlut selected? Unless I am missing something, there is no option to set a gamma in that case.

If the 3dlut doesn't contain that information, then I agree.

BT.1886 didn´t work out to well for me last time I tried. Then again, I´m not using DispCal or the ArgylCMS, I´m using the Eizo Colornavigator for this.

I found BT.1886 to be extremely useful on my display. It allowed me to effectively crush the blacks with display controls (making black actually look like black) (nothing retarded like setting the black control to 0, but crushed non the less), and the calibration lifts the shadow details on playback.

In essence, I now see excellent shadow detail, with actual blacks.

Previously, I would either have crushed blacks, or grey shadows. It was impossible (for me), to get the display to show a pure black with shadow detail.

iSunrise
9th March 2014, 14:22
PotP won't let me select the image source filter AFAIK, it'll always be "Image source". It would be most amazing if you could nail down the name of the still images source filters used in PotP & MPC and provide a picture-viewer mode in mVR that would kill all black frames(that keep coming and going more or less randomly, making it very hard to use) and allow to setup a custom profile with 256 neurons all the way :devil:
PotP just needs to support a way to select LAV as the source filter for tiff, png, jpeg, tga and bmp images (the PotP author only really needs to add these, because it already has checkboxes for several file formats that LAV supports), since nevcairiel already added that in 2012. In that case, madVR would take care of the rest.

leeperry
9th March 2014, 14:49
The trick is to do a 1D gamma ramp calibration first via ArgyllCMS, but then to "merge" the final 1D gamma ramps into the 3dlut.
And the 3DLUT+ArgyllCMS headaches will begin, otherwise you're stuck with a banding .cal file applied in 8bit by the GPU drivers after mVR's dithering....that's why I specifically wanted a display with proper calibration options(and applied in 10/12bit at that) so this would all be like waking up from a bad dream.

PotP just needs to support a way to select LAV as the source filter for tiff, png, jpeg, tga and bmp images (the PotP author only really needs to add these, because it already has checkboxes for several file formats that LAV supports), since nevcairiel already added that in 2012. In that case, madVR would take care of the rest.
And what would that change? Can mVR already run a picture-viewer mode when using LAV? Anyway, feature requests are closed so I'll keep playing hide & seek with the random black frames if I find the patience.

None of the images you posted thus far are all that close to overall brightness and gamma response of the original when viewed on my display.

Gamma is brighter than the original. BT.709 2.2 is darker than original. The rest are much, much darker.
Exactly what I'm seeing as well.

my display is calibrated to a BT.709 curve scaled to ambient light. Essentially it matches BT.709 near-black, and matches L* across the rest of the luminance range.
Personally, I chose the most acceptable gamma preset in my TV(that goes from -3 to +3, I picked -2 which is pretty dark..around 2.4), then I maxed out the contrast(not clipping in HCFR, everything's smooth there) and I set the brightness setting to my taste. I'm spot-on D65, blacks are slightly crushed but PQ is stunning and my CRT's always came with crushed blacks, I'm not all that interested in what happens in the 3 first levels(out of 256) tbh.

Things might be different if there were proper gamma settings/10 points white balance in my F5000 Sammy TV but only their "6" serie does that and anything higher that their "5" serie can't do BFI without FI duh...and I think I like slightly crushed blacks anyway. Definitely not going back to Argyll, especially after whining to Graeme for the Nth time about BT1886 looking funky and him sending me yet another possible bug fix....20 mins of flashing colors to end up with a crappy gamma curve are beyond my patience.

Eiffel
9th March 2014, 14:55
I've been a long time lurker on this thread, and am very pleased with the latest scaling options (most of my testing has been with old DVB movie recordings, which work best with NEEDI3 64 neurons for both chroma upscaling and double Luma resolution, no NEEDI3 chroma doubling, Lanczos 3AR impage upscaling and Bicubic AR downscaling, ordered dithering and no quality trade off using a Sapphire 7770 GPU and 1080p displays).

I've played with Error diffusion, but have to reduce the NEEDI3 doubling scaling to make it work, with is not as good (softCubic lacks some of the sharpness which I like)

While on the display topic, I have spent quite a bit of time getting 3Dluts to work well. This was easy on an IPS display but is proving much harder on my JVC HD750 projector, where -so far- I'm getting better results with manual calibration (11 Gamma points per primaries and CMS) than with a 3Dlut, in terms of gamma by color over the gray scale and fully saturated colours (the only place where 3Dluts consistently with is in terms of dE for less saturated colors).

Interestingly, depending on the projector gamma curves and gamut settings, the 3Dlut generated by Argyll CMS can be a flat 2.4 gamma, or increase to this level (with everything set exactly the same way including BT1886 target, dark room, etc.). I'd expect it to be more consistent (likely flat given the CR). I probably have more to learn!

I haven't played with dithering enough to comment, and am still pursing ideas to improve on the calibration results for the time being.

Asmodian
9th March 2014, 14:56
Argyll still seems to have issues with creating 3DLUTs which fail BTB/WTW clipping tests

This is intended to be a feature but I too would like an option to clip wtw/btb. BTB is clipped for me because I do no black point correction but Argyll 3DLUTs allow any primary that can to increase/decrease into wtw/btb as a way to avoid clipping.

Argyll has gotten much better at creating 3DLUTs, you might want to give it a try. It will fail clipping tests, of course, but I get very good results within the normal range (as measured with HCFR). Both Argyll and HCFR use madTPG. :)

Eiffel
9th March 2014, 15:04
20 mins of flashing colors to end up with a crappy gamma curve are beyond my patience.

This ain't too bad, a basic 3Dlut creation using the settings from http://www.avsforum.com/t/1471169/madvr-argyllcms, and a fast sensor (i1D3) takes 3 hours with my projector :)

nevcairiel
9th March 2014, 15:08
Definitely not going back to Argyll, especially after whining to Graeme for the Nth time about BT1886 looking funky and him sending me yet another possible bug fix....20 mins of flashing colors to end up with a crappy gamma curve are beyond my patience.

So he actually tries to fix the bug and sends you versions to test, and you thank him by whining even more and calling his software names? :p
Remind me to never try to help you! :)

FWIW, my screen resulted in a really good calibrated result after Argyll, but truth be told my Sony screen was pretty close before, Gamma is and was good, only gamut needed a bit of adjustment, as the built-in controls aren't fine-grained enough.

leeperry
9th March 2014, 15:10
a basic 3Dlut creation using the settings from http://www.avsforum.com/t/1471169/madvr-argyllcms, and a fast sensor (i1D3) takes 3 hours with my projector
Killing 3 hours of light bulb for Argyll makes little sense to me, I'm sure your time & money might be much better spent. You're on the verge of OCD my good friend ;)

So he actually tries to fix the bug and sends you versions to test, and you thank him by whining even more
I've been whining for bug fixes regarding Argyll not working as I was expecting it to for years, I officially give up. I'm sure he'll easily find more dedicated testers.

turbojet
9th March 2014, 15:15
It wasn't actually overlay issues with the 650>hdmi>lcd tv. It' nvidia's drivers forcing pc levels on 25, 30, 50, 60hz and tv levels on 24 and 48 hz over hdmi. I had it setup to enable overlay only when ivtc was enabled so I thought overlay was the culprit like it has been for a long time on svideo. nvidia seems to be forcing pc levels on all dvi out, tv levels on s-video.

The level tweaker doesn't seem to have an effect on hdmi or s-video out with nvidia gpus, haven't tested dvi yet. Also it asks for admin privileges on windows 7 but not on 8.1. Other programs ask for it on 8.1.

Is there another workaround to force nvidia to output one level on hdmi or is there something madvr can do to work around nvidia's mess?

edit: http://blog.metaclassofnil.com/?p=83 this worked to fix hdmi levels. inf driver hack didn;t.

Also is there any reason why overlay is sending pc levels over svideo while window and fse are sending tv levels?

SamKook
9th March 2014, 15:34
Not sure which change did it since I didn't notice anything specific to it in the changelogs, but the jump from 0.87.4 to 0.87.6 made madvr work with Nvidia surround enabled so I can now use madvr again on my main pc with my 3 monitors enabled, thanks.
It created a "Generic Non-PnP Monitor" instead of using the "Asus NV Surround" one like before when it was failing(or maybe that's due to me updating to the latest driver).

jkauff
9th March 2014, 15:35
Sorry to interrupt the dithering discussion, but I noticed a puzzling occurrence on one particular DVD. The profile I use for standard DVDs using the latest madVR typically pushes my GTX 770 to about 90% load. Playing back this one b&w video, however, causes the load to drop down to 45% about once every minute, then it returns to normal. Playback looks fine--I just can't understand what's causing the drop in GPU load. Image doubling is enabled, BTW, and the fact that the drop is almost exactly 50% makes me wonder if the image doubling is involved.

Again, not a problem, I'm just curious.
Found my own solution. It's caused by LAV, using QuickSync for decoding. Happens in all DVD sources, but not when they're converted to MKV files. When I change to software decoding, GPU stays at 90%. Must be something about the way QS handles VOBs.

seiyafan
9th March 2014, 15:52
Another n00b question, will the dithering in LAV affect the dithering in MadVR? Because I saw a dithering option in LAV encoding, not sure what it does in relation to MadVR's dithering.

Q-the-STORM
9th March 2014, 16:38
Another n00b question, will the dithering in LAV affect the dithering in MadVR? Because I saw a dithering option in LAV encoding, not sure what it does in relation to MadVR's dithering.

LAV doesn't dither when you use madVR...

Ver Greeneyes
9th March 2014, 16:41
Here's the Avatar dithering comparison again, with added images using different transfer functions for linear light dithering:

|- gamma (http://madshi.net/avatar2bitGamma.png) -|- original (http://madshi.net/avatar8bit.png) -|- linear (pure power 1/0.45) (http://madshi.net/avatar2bitLinear.png) -|- linear (sRGB 2.4) (http://madshi.net/avatar2bitSRGB.png) -|- linear (BT.709 1/0.45) (http://madshi.net/avatar2bit709.png) -|Thanks! Out of these, sRGB preserves the most detail but also brightens the source somewhat. 709 is most correct in terms of hue, saturation and brightness, but still looks noticeably darker than the original near black. Unfortunately I don't have an easy way of looking at the images from far away while still switching between them quickly, so I had to make do with flipping back and forth between the original and the bit-reduced images from fairly up close. Both sRGB and 709 are pretty close to the original for me, which matches my somewhat hybrid calibration (Rec.709 adjusted for sRGB viewing conditions).

I should note that I viewed these in my browser (Firefox) with my Rec.709-focused ICC profile active (gfx.color_management.mode = 1) and 1D curves loaded into my videoLUT. Without the videoLUT (i.e. if madVR were applying the 1D curves from the 3DLUT prior to dithering) I would expect something native to my display's response to give the best match. And there's the rub - unless madVR were to take that into account*, I can't say what the best curve would be, but 1.0/0.45 is probably a fair approximation of consumer hardware.

* which would, in its simplest form, probably involve loading another file like a 3DLUT that just gives the 3xN value curves for transforming to linear light RGB. Out of curiosity, if you build the ability to load custom shader files into madVR, would you consider letting us override the gamma-light-to-linear-light-for-dithering function with with a suitably named shader? That way it's very much an advanced-users-only feature. We could generate a lookup table from our .cal file and bake it straight into the shader ;) (though honestly I don't know how bad that would be for performance)

Shiandow
9th March 2014, 16:57
* which would, in its simplest form, probably involve loading another file like a 3DLUT that just gives the 3xN value curves for transforming to linear light RGB. Out of curiosity, if you build the ability to load custom shader files into madVR, would you consider letting us override the gamma-light-to-linear-light-for-dithering function with with a suitably named shader? That way it's very much an advanced-users-only feature. We could generate a lookup table from our .cal file and bake it straight into the shader ;) (though honestly I don't know how bad that would be for performance)

I think such a lookup table won't be much good since it require interpolation, and if you simply use linear interpolation then I think the shader won't do that much.

If you want to do it that way then I think the best way to do it is not to store the entire gamma curve in a lookup table but the 'local' gamma i.e. the slope in log-log space. I believe that this will give you the best result with relatively little effort. Here's a shader that uses this 'trick' to approximate an sRGB curve:


#define depth 255
sampler s0 : register(s0);

float4 main(float2 tex : TEXCOORD0) : COLOR
{
float4 c0 = tex2D(s0, tex);
float4 low = floor(depth*c0)/depth;
float4 hi = low+(1/depth);
float4 gamma = max(1,2.4*low/(low+0.055));
float4 c1 = (pow(c0,gamma)-pow(low,gamma))/(pow(hi,gamma)-pow(low,gamma));
return low+(c1/depth);
}


You should get pretty decent results even if the 'gamma' is slightly wrong so you probably don't need a lookup table for all 256 different values. And if you try to edit this code make sure that you use either 'low' or 'hi' to calculate the gamma, changing the gamma midway can lead to very strange results.

Ver Greeneyes
9th March 2014, 17:07
I think such a lookup table won't be much good since it require interpolation, and if you simply use linear interpolation then I think the shader won't do that much.I disagree. Even a 3x256 lookup table will be a very good approximation to your display's gamma curve, linear interpolation won't harm that (linear interpolation is just a better approximation than a step function). And there's nothing stopping you in principal from using a 3x1024 lookup table or bigger. Remember, all we're looking for here is the distance between two 8-bit values to approximate the error and how much of it was diffused.

Of course if you're using a videoLUT, then you could skip the lookup table and just use the expression for the curve you calibrated to. But a display's native response isn't likely to be that smooth.

Shiandow
9th March 2014, 17:20
I disagree. Even a 3x256 lookup table will be a very good approximation to your display's gamma curve.

I agree, but if a linear interpolation is good enough then you can achieve that by just using gamma light dithering. It makes no sense to try to improve on a linear interpolation of the actual gamma curve of your monitor, by using a linear interpolation of a measurement of the same gamma curve.

kasper93
9th March 2014, 17:30
Here's the Avatar dithering comparison again, with added images using different transfer functions for linear light dithering:

|- gamma (http://madshi.net/avatar2bitGamma.png) -|- original (http://madshi.net/avatar8bit.png) -|- linear (pure power 1/0.45) (http://madshi.net/avatar2bitLinear.png) -|- linear (sRGB 2.4) (http://madshi.net/avatar2bitSRGB.png) -|- linear (BT.709 1/0.45) (http://madshi.net/avatar2bit709.png) -|

Again, make sure you watch these at 100%. Having your browser zoom these will totally screw up everything.

The key point to take from this screenshot comparison is that dithering in gamma light is not correct. I hope everybody can agree with that now? Which image looks best to you will directly depend on how your display is calibrated. The image created with the transfer function nearest to your display calibration should look nearest to the original 8bit image to your eyes.

Linear light looks better, a lot. I should say, closer to original :) I think BT.709 is best for this image, but it's really close to sRGB, I mean I couldn't pick obvious winner.

I may have missed something, but "use colored noise" doesn't seem to have effect on ED. But works for others...

Ver Greeneyes
9th March 2014, 17:33
I agree, but if a linear interpolation is good enough then you can achieve that by just using gamma light dithering. It makes no sense to try to improve on a linear interpolation of the actual gamma curve of your monitor, by using a linear interpolation of a measurement of the same gamma curve.The 'linear interpolation' that gamma light uses is just a straight line, it isn't an interpolation at all. Dithering uses it to weight the fractional error, determining how many pixels end up as brighter than the original and how many end up as darker. With linear weights, the effect that a bright pixel has on a dark pixel is weighted the same as the effect of a dark pixel on a bright pixel. By transforming into linear light first, they are weighted differently. In addition, patches of the same color will compute the remaining error differently depending on the weighting curve.

Now I agree that for very small differences between adjacent pixels (1/255 or less), you'd need a lookup table bigger than 3x256 for it to have an effect. Which also means that using gamma light versus linear light doesn't make a very big difference in 8-bit mode. But if we're striving for perfection, a > 8-bit lookup table would be best. A 12-bit table (3x4096) would cover the smallest differences that humans can discern, but that might have a bigger impact on performance (I don't know). 11-bit seems to be the limit of what madVR's dithering can do as far as calibration is concerned.

Shiandow
9th March 2014, 17:50
Now I agree that for very small differences between adjacent pixels (1/255 or less), you'd need a lookup table bigger than 3x256 for it to have an effect. Which also means that using gamma light versus linear light doesn't make a very big difference in 8-bit mode. But if we're striving for perfection, a > 8-bit lookup table would be best.

Those very small differences are precisely the part that the linear light shader changes, if you use that shader with a gamma curve which is linear in-between adjacent values then there will be no difference between the input and the output.

Ver Greeneyes
9th March 2014, 18:07
Those very small differences are precisely the part that the linear light shader changes, if you use that shader with a gamma curve which is linear in-between adjacent values then there will be no difference between the input and the output.Right, so for a 6-bit+FRC monitor an 8-bit table would make a difference in 6-bit mode, and for an 8-bit monitor you'd need something bigger. As a proof of concept you could test with an 8-bit table in 3-bit mode, just so long as you scale up for actual viewing.

I'll admit I didn't think through the implications completely before, but I still think the principle is sound. One sticking point is that ArgyllCMS only generates 256-value tables, but there's no reason it couldn't use some higher order interpolation to output a 4096-value one. I think it uses some B-spline-based interpolation internally to smooth the calibration a little before using it - perhaps a cubic spline interpolation with a monotonicity constraint* would be best for the final output.

* while minimizing the 2nd order discontinuity

Shiandow
9th March 2014, 18:34
Right, so for a 6-bit+FRC monitor an 8-bit table would make a difference in 6-bit mode, and for an 8-bit monitor you'd need something bigger. As a proof of concept you could test with an 8-bit table in 3-bit mode, just so long as you scale up for actual viewing.

How exactly are you going to create a larger than 8-bit LUT if your display is only capable of displaying 8-bits? Which values will you measure to identify the points inbetween? The same for a 6-bit monitor, how do you define what the gamma curve should look like at values where you can't measure it? The best method I can think of is to calculate the local gamma and use that to create an interpolation.

Ver Greeneyes
9th March 2014, 19:41
How exactly are you going to create a larger than 8-bit LUT if your display is only capable of displaying 8-bits? Which values will you measure to identify the points inbetween? The same for a 6-bit monitor, how do you define what the gamma curve should look like at values where you can't measure it? The best method I can think of is to calculate the local gamma and use that to create an interpolation.Just use the table given by dispcal and interpolate between the values (this would be easiest in dispcal itself, since it also knows what the target gamma curve was, including any viewing conditions transformation). As long as the values given by dispcal are monotonic it shouldn't be hard.

e-t172
9th March 2014, 19:44
So I got frame drop/presentation glitches issues when using madVR with a 780 Ti. To be fair it's almost perfect but I still get at least one frame drop or other discontinuity every 10 minutes or so (it seems to happen at random times). I tried every combination of flushing settings/queue depths/use separate device for presentation/disable composition imaginable (well, almost) without any success. I'm out of ideas and asking for help.

Try to check if your card operates within the normal range with tools like MSI-Afterburner.

Tried that, nothing seems out of the ordinary. I tried putting the GPU in high performance mode (in the NVidia per-program power management settings) and setting the Windows power options to performance mode as well, no luck.

Personally, I would try the 327.23 drivers first

AFAIK 327.23 doesn't support the 780 Ti, it's too old.

madshi: are you interested in a log for this issue? I'm all out of ideas here. Even the old rendering path has the exact same issue on my system.

Shiandow
9th March 2014, 20:06
Just use the table given by dispcal and interpolate between the values (this would be easiest in dispcal itself, since it also knows what the target gamma curve was, including any viewing conditions transformation). As long as the values given by dispcal are monotonic it shouldn't be hard.

I agree with that method, but a linear interpolation won't be enough. I saw you suggested some other methods in your previous comment, those should probably be better. Basically what I was trying to say is that it might be a good idea to do this interpolation in log-log space, the main reason I think so is that the Rec. 709 and sRGB gamma curve are largely linear in log-log space, this should make interpolation easier.

XMonarchY
9th March 2014, 20:20
|- gamma (http://madshi.net/avatar2bitGamma.png) -|- original (http://madshi.net/avatar8bit.png) -|- linear (pure power 1/0.45) (http://madshi.net/avatar2bitLinear.png) -|- linear (sRGB 2.4) (http://madshi.net/avatar2bitSRGB.png) -|- linear (BT.709 1/0.45) (http://madshi.net/avatar2bit709.png) -|

Again, make sure you watch these at 100%. Having your browser zoom these will totally screw up everything.

The key point to take from this screenshot comparison is that dithering in gamma light is not correct. I hope everybody can agree with that now? Which image looks best to you will directly depend on how your display is calibrated. The image created with the transfer function nearest to your display calibration should look nearest to the original 8bit image to your eyes.

My TV is calibrated to Rec709/sRGB with BT.1886 gamma curve using ArgyllCMS LUT. The best image that mimics the original is the Linear BT.709 and the next best one is Gamma. Others are too dark. I know Graeme firmly considers BT.1886 gamma to be THE gamma to use, but I am not sure how it relates to dithering gamma...

James Freeman
9th March 2014, 20:32
As we can see, people voted for every single one of the screenshots as looking closest to their monitor gamma.
The question remains, how will madshi solve these differences in preferred transfer function and make everybody happy (again)?

Time shows madshi does not disappoint satisfying our videophile needs (or the differences between them).

XMonarchY
9th March 2014, 20:38
As we can see, people voted for every single one of the screenshots as looking closest to their monitor gamma.
The question remains, how will madshi solve these differences in preferred transfer function and make everybody happy (again)?

Time shows madshi does not disappoint satisfying our videophile needs.

Why can't dithering use same exact transfer function as the video? Is it because we do not know the exact gamma tone that was used for whatever content mastering? Isn't there a linear gamma default of some kind?

nevcairiel
9th March 2014, 20:40
The question remains, how will madshi solve these differences in preferred transfer function and make everybody happy (again)?

IMHO people need to stop judging too much at low bitdepth.
At 8-bit, any of the linear ones will probably solve the issue that Gamma presents, since the effect is miniscule there.

James Freeman
9th March 2014, 20:41
Why can't dithering use same exact transfer function as the video? Is it because we do not know the exact gamma tone that was used for whatever content mastering? Isn't there a linear gamma default of some kind?

As strange as it sounds, its because of your display device unique gamma curve and not the video content gamma curve, one user selects one picture and the other user selects another.

IMHO people need to stop judging too much at low bitdepth.
At 8-bit, any of the linear ones will probably solve the issue that Gamma presents, since the effect is miniscule there.
True, but...
We could have said the same when we tested dithering, but then we would not get to where we are now.
Probable we would have been satisfied by one of the first Direct Compute builds.

Let me post a small phrase from the Audiophile/Videophile book (which I just made up):
"Hearing or Seeing means nothing, Its KNOWING* that really counts..."
*Can easily be transferred from person to person by (a relatively weak) subconscious suggestion.
:D

Actually, it does not matter.
IMO madVR goal is to make the best picture quality whether less observant (or could not care less) user sees it or not.
Its not about "good enough", its about "The best of the best" which madVR currently holds the medal for.

MistahBonzai
9th March 2014, 23:33
Thanks! Out of these, sRGB preserves the most detail but also brightens the source somewhat. 709 is most correct in terms of hue, saturation and brightness, but still looks noticeably darker than the original near black. Unfortunately I don't have an easy way of looking at the images from far away while still switching between them quickly, so I had to make do with flipping back and forth between the original and the bit-reduced images from fairly up close. Both sRGB and 709 are pretty close to the original for me, which matches my somewhat hybrid calibration (Rec.709 adjusted for sRGB viewing conditions).

I should note that I viewed these in my browser (Firefox) with my Rec.709-focused ICC profile active (gfx.color_management.mode = 1) and 1D curves loaded into my videoLUT.

Belated input here... Having an apparently similar 'monitor calibration' I viewed the images much as you did if I expanded them in the Chrome browser by pressing the little "+". Otherwise they appeared much like the others who said that "avatar2bitgamma" was closest - if fact it was almost an exact match between it and the original 8 bit image (excluding dither of course).

So.. Having never considered browser color management in the many years ago I discovered it was a crap shoot - I always DL to perform image evaluations - I figured the time had come to take another look. Like you I selected gfx.color_management.mode = 1 in the latest Firefox (Aurora 29.0.a2) along with defining my CalibratedMonitorProfile.icc profile as default.

While cross checking between Chrome and Aurora using the test files I could see no determinable difference. Nor between them and a local copy displayed via Picasa Image Viewer. If I'm wrong I'm consistently wrong :)

cyberbeing
9th March 2014, 23:48
AFAIK 327.23 doesn't support the 780 Ti, it's too old.

If you want to use OpenCL try the following driver with the modded inf I created. Q-the-STORM who also has a GTX 780 Ti had success installing it with the modified inf on Win7 x64:

Quadro 321.10 (December 17, 2013) (http://www.nvidia.co.uk/download/driverResults.aspx/71564/en-uk) + Modifed Inf for GTX 780 Ti (https://www.mediafire.com/?vrbwgb4wo4m9rao)
I can confirm it works with madVR OpenCL.

markanini
10th March 2014, 01:21
Am I the only one that thinks perceived the tone response is downright atrocious with gamma in the avatar comparison?

Asmodian
10th March 2014, 01:45
A 12-bit table (3x4096) would cover the smallest differences that humans can discern, but that might have a bigger impact on performance (I don't know). 11-bit seems to be the limit of what madVR's dithering can do as far as calibration is concerned.

I bet a 12-bit table (3x4096) would have a rather negative effect on performance seeing as it would be 8 GB. :p


Does anyone see shadows that are too dark with linear light dithering in 8 bit? I assume no one noticed too light of shadows in 8 bit with gamma dithering? I know I didn't.

If we cannot notice the difference between the two extremes in 8 bit wouldn't any of the linear light dither options, being mathematically more correct, be fine for normal use? :o

Best of the best can be taken too far...

linear (pure power 1/0.45) looks the best to me, or maybe sRGB.

Anime Viewer
10th March 2014, 01:56
Just want to double check, in MPC under LAV video decoder, what's a good hardware decoder to use? Is it none?


Here is a strong argument for the None choice.

https://forums.geforce.com/default/topic/527075/geforce-drivers/hardware-acceleration-decoding-issue/1/

Run it with each of the different settings you can choose for LAV hardware acceleration. Changes are you'll experience pixelation (but not dropped frames) when you run the video clip there (http://www.sendspace.com/file/vl06bq) with any of the hardware acceleration options selected, but not have the issue if you choose none.

Granted just because DVX2 may cause pixelation in LAV doesn't mean you couldn't use it as an upscaling or downscaling in madVR. As you'll see if you use it in any of the madVR settings, and play the same video clip it shouldn't pixelate.

Ver Greeneyes
10th March 2014, 02:04
I bet a 12-bit table (3x4096) would have a rather negative effect on performance seeing as it would be 8 GB. :pI'm just talking about 3 1D curves, not a 4096^3 3DLUT :P Inverting the whole 3DLUT and increasing its resolution would be pretty insane ;)

leeperry
10th March 2014, 03:00
IMHO people need to stop judging too much at low bitdepth.
At 8-bit, any of the linear ones will probably solve the issue that Gamma presents, since the effect is miniscule there.
I like to nitpick as much as the next guy but I just watched "Out of the Furnace" on BD and PQ was outstanding with mono-static A4...and God forbid, that was in GL :p

Asmodian
10th March 2014, 04:13
I strongly encourage you to consider an option for loading a GPU gamma ramp with madVR via shaders for Windowed & FSE mode as well:

[X]Disable GPU Gamma Ramp Globally
....[X]Reload GPU Gamma Ramp via Shaders

I do get slightly better results even within 16-235 using collink "-H" and running madVR in overlay mode compared to using "-a" in FSE or overlay. I do use -r256 in collink as well. I notice better white and black points, especially when using "-a", with -r256 but it takes a long time. :p

I'm just talking about 3 1D curves, not a 4096^3 3DLUT :P Inverting the whole 3DLUT and increasing its resolution would be pretty insane ;)

madVR already uses 16 bit 1D LUTs, only need to invert them. :)

That might be overkill for 8-bit but then everyone with a good calibration could watch in 4-bit without noticing if they were not close to the screen. ;)

Ver Greeneyes
10th March 2014, 04:43
madVR already uses 16 bit 1D LUTs, only need to invert them. :)That's pretty much what I'm suggesting. The problem is that as discussed, you'd need more than 256 entries for it to have an effect (so you need to apply some sort of interpolation to generate more points), and you'd have to apply the calibration's target curve on top of them to get linear RGB. And then madVR still needs to actually use it during dithering. Since madshi doesn't want to implement something complicated like that for very little gain (and I don't blame him), and since he mentioned the possibility of loading shaders directly into madVR before, I was suggesting that he could allow a custom shader to override the transfer function used during dithering.

iSunrise
10th March 2014, 05:01
I like to nitpick as much as the next guy but I just watched "Out of the Furnace" on BD and PQ was outstanding with mono-static A4...and God forbid, that was in GL :p
Just asking, but how is that post even helpful when all you did was watch the movie at 8bit gamma light, when you didn't compare it with linear light? At least provide us with something we can work with.

Which one is gamma and which one is linear (both at 8bit):

http://abload.de/thumb/a5rqe4.png (http://abload.de/image.php?img=a5rqe4.png)http://abload.de/thumb/bofr1f.png (http://abload.de/image.php?img=bofr1f.png)

Which one looks closer to the previous ones:

http://abload.de/thumb/abd2pa7.png (http://abload.de/image.php?img=abd2pa7.png)http://abload.de/thumb/ba85orw.png (http://abload.de/image.php?img=ba85orw.png)

It doesn´t matter if you inspect the pixels themselves or look at it from a distance, there are very obvious differences.

My TV is calibrated to Rec709/sRGB with BT.1886 gamma curve using ArgyllCMS LUT. The best image that mimics the original is the Linear BT.709 and the next best one is Gamma. Others are too dark. I know Graeme firmly considers BT.1886 gamma to be THE gamma to use, but I am not sure how it relates to dithering gamma...
Yes, same thing I´m seeing here (when I´m on Rec709). So it seems for BT.1886/709 the "linear BT.709" is the only really useful option, whereas for sRGB displays, it´s the sRGB curve (it would be interesting to see 2.2 gamma on sRGB, too, though).

The "gamma" example is way too bright, whereas the "linear" example is a bit too dark. If I switch to sRGB, though, the linear is more accurate, while the gamma one still retains the elevated (brighter) look.

Asmodian
10th March 2014, 05:01
The problem is that as discussed, you'd need more than 256 entries for it to have an effect (so you need to apply sort of interpolation to generate more points)

Ah sorry, I understand. I think I missed a page. :o

James Freeman
10th March 2014, 08:44
....whereas for sRGB displays, it´s the sRGB curve (it would be interesting to see 2.2 gamma on sRGB, too, though).

The "gamma" example is way too bright, whereas the "linear" example is a bit too dark. If I switch to sRGB, though, the linear is more accurate, while the gamma one still retains the elevated (brighter) look.

I'm doing the tests in 3/4 bit to see the difference clearer.

On my display:
Linear Power 2.2 is too dark.
Linear sRGB 2.4 is almost there, but very little too dark.
Linear BT.709 is a little too bright.
Gamma is nothing like the original image, very bright.

So my display falls somewhere between sRGB 2.4 & BT.709.
I think sRGB 2.2 might be it for my display.

I experimented with the Gamma slider in Nvidia Control Panel and managed to make my display match (+/-) the Linear Power 2.2 and sRGB 2.4 images madshi posted.
I use a 3DLUT in madVR calibrated to power 2.2, so the gamma curve will be perfect 2.2 there.
I do not load VideoLUT curves (or include them in the 3DLUT) because they create banding, even in madVR when GPU gamma ramp is disabled.
I just "Profile" the monitor (w/ 128 Neutral patches) without "Calibrating" and create a 3DLUT (2.2 Relative), this gives me a 2.2 curve with no banding what so ever.

leeperry
10th March 2014, 12:03
all you did was watch the movie at 8bit gamma light, when you didn't compare it with linear light
LL looks terribly dull on my rig, maybe the internal post-processing of my TV isn't compatible for some reason. My point is that as nev said, you guys seem to focus a tad too much on low bit-depths and LL isn't quite a magic bullet to everyone.