Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
|
|
Thread Tools | Search this Thread | Display Modes |
4th August 2022, 08:35 | #81 | Link | |
͡҉҉ ̵̡̢̛̗̘̙̜̝̞̟̠͇̊̋̌̍̎̏̿̿
Join Date: Feb 2009
Location: No support in PM
Posts: 712
|
hello_hello:
Yes it is the expected behaviour. From the matrix doc: Quote:
__________________
dither 1.28.1 for AviSynth | avstp 1.0.4 for AviSynth development | fmtconv r30 for Vapoursynth & Avs+ | trimx264opt segmented encoding |
|
9th August 2022, 10:06 | #82 | Link |
Acid fr0g
Join Date: May 2002
Location: Italy
Posts: 2,580
|
Can I use fmtconv to replace the lines:
z_ConvertFormat(pixel_type="RGBP16", colorspace_op="2020:st2084:2020:limited=>rgb:st2084:2020:full", resample_filter_uv="spline64", dither_type="error_diffusion") and z_ConvertFormat(pixel_type="YUV420P10", colorspace_op="rgb:std-b67:2020:full=>2020:std-b67:2020:limited", resample_filter_uv="spline64", dither_type="error_diffusion") ? I'd like to try if there is any speed improvement over z.
__________________
@turment on Telegram |
11th August 2022, 20:23 | #83 | Link |
Registered User
Join Date: Nov 2009
Posts: 2,361
|
I think there might some error in the docs, for bobbing an interlaced source it shows interlaced(d) args as boolean, but in the function description as int type.
Also I'm trying to understand how do you do a chromatic adaptation with fmtconv. I tried the next but the result looks noop. Code:
fmtc_resample(css="444") fmtc_matrix(mat="709", bits=16) fmtc_transfer(transs="709", transd="linear") fmtc_primaries(prims="709", primd="709", ws=[0.3127,0.3290], wd=[0.33242, 0.34743]) # From D65 to D55 fmtc_transfer(transs="linear", transd="709") fmtc_matrix(mat="709", bits=16)
__________________
i7-4790K@Stock::GTX 1070] AviSynth+ filters and mods on GitHub + Discussion thread |
15th August 2022, 10:41 | #85 | Link |
͡҉҉ ̵̡̢̛̗̘̙̜̝̞̟̠͇̊̋̌̍̎̏̿̿
Join Date: Feb 2009
Location: No support in PM
Posts: 712
|
tormento:
Yes you can. I’m pretty sure z is faster, but you can try. Dogway: Thanks, indeed the examples haven’t been checked for long, and function prototypes slightly evolved since. I just fixed the doc. Your chromatic adaptation is right. How do you check it? Results may be subtle. Or maybe what you’re looking for is complete conversion, for example to make a picture displayed on a D55 monitor look exactly like the same picture displayed on a D65 monitor placed side by side?
__________________
dither 1.28.1 for AviSynth | avstp 1.0.4 for AviSynth development | fmtconv r30 for Vapoursynth & Avs+ | trimx264opt segmented encoding Last edited by cretindesalpes; 15th August 2022 at 10:47. |
15th August 2022, 12:20 | #86 | Link |
Registered User
Join Date: Nov 2009
Posts: 2,361
|
Yes I was expecting a warmer output, maybe I should try with D50. Eyes adapt to the white point specially at matching environment temperatures as there's not a single "white" in psychovisually terms. I was double checking as I had difficulties on color space conversions on non-standard illuminants.
__________________
i7-4790K@Stock::GTX 1070] AviSynth+ filters and mods on GitHub + Discussion thread |
16th August 2022, 12:30 | #88 | Link | |
Registered User
Join Date: Nov 2009
Posts: 2,361
|
Quote:
Code:
fmtc_bitdepth (bits=16) fmtc_resample (css="444",kernel="spline64") fmtc_matrix (mats="2020", matd="rgb", fulls=false, fulld=true) fmtc_bitdepth (bits=16, dmode=6)
__________________
i7-4790K@Stock::GTX 1070] AviSynth+ filters and mods on GitHub + Discussion thread Last edited by Dogway; 16th August 2022 at 14:41. |
|
21st August 2022, 00:40 | #92 | Link |
Acid fr0g
Join Date: May 2002
Location: Italy
Posts: 2,580
|
I was getting crazy, trying to find why BM3D_CUDA had some slight tint change and I found out that it is the combination of Convertbits and fmtconv that makes strange things.
Look at this comparison. Reality is that BM3D_CUDA needs RGB to work and... am I doing something silly or there is something terribly wrong? Image 0: original Image 1: OK SetMemoryMax() SetFilterMTMode("DEFAULT_MT_MODE", 3) LoadPlugin("D:\Eseguibili\Media\DGDecNV\DGDecodeNV.dll") DGSource("F:\In\Knights of Sidonia\Knights 01A.dgi") ConvertBits(32) ConvertBits(8) Prefetch(6) Image 2: WRONG!!! SetMemoryMax() SetFilterMTMode("DEFAULT_MT_MODE", 3) LoadPlugin("D:\Eseguibili\Media\DGDecNV\DGDecodeNV.dll") DGSource("F:\In\Knights of Sidonia\Knights 01A.dgi") ConvertBits(32) fmtc_bitdepth (bits=8,dmode=8) Prefetch(6)[ Image 3: WRONG!!! SetMemoryMax() SetFilterMTMode("DEFAULT_MT_MODE", 3) LoadPlugin("D:\Eseguibili\Media\DGDecNV\DGDecodeNV.dll") DGSource("F:\In\Knights of Sidonia\Knights 01A.dgi") fmtc_bitdepth (bits=32,dmode=8) ConvertBits(8) Prefetch(6) Image 4: OK SetMemoryMax() SetFilterMTMode("DEFAULT_MT_MODE", 3) LoadPlugin("D:\Eseguibili\Media\DGDecNV\DGDecodeNV.dll") DGSource("F:\In\Knights of Sidonia\Knights 01A.dgi") fmtc_bitdepth (bits=32,dmode=8) fmtc_bitdepth (bits=8,dmode=8) Prefetch(6)
__________________
@turment on Telegram Last edited by tormento; 21st August 2022 at 00:48. |
21st August 2022, 01:12 | #93 | Link | |
Registered User
Join Date: Jul 2018
Posts: 450
|
Quote:
For Image 3 change ConvertBits(8) to ConvertBits(8, fulls=true, fulld=false) |
|
21st August 2022, 10:36 | #95 | Link |
Acid fr0g
Join Date: May 2002
Location: Italy
Posts: 2,580
|
Ok, here things get tricky.
I need to convert to 32, then planar RGB and back to 8. I am getting some tint changes again. 00 original 01 LoadPlugin("D:\Eseguibili\Media\DGDecNV\DGDecodeNV.dll") DGSource("F:\In\Knights of Sidonia\Knights 01A.dgi") ConvertBits(32) ConvertToPlanarRGB() ConvertToYUV420() ConvertBits(8) 02 SetMemoryMax() LoadPlugin("D:\Eseguibili\Media\DGDecNV\DGDecodeNV.dll") DGSource("F:\In\Knights of Sidonia\Knights 01A.dgi") ConvertBits(32, fulls=false, fulld=true) ConvertToPlanarRGB() ConvertToYUV420() fmtc_bitdepth (bits=8,dmode=8) Even a ConvertToPlanarRGB() ConvertToYUV420() fmtc_bitdepth (bits=8,dmode=8) Gives slight wrong tint again. It happens even with: ConvertToPlanarRGB() ConvertToYUV420() I am getting crazy with conversions. EDIT: it seems that ConvertToYUV420(matrix="Rec709") fixed things. WTF.
__________________
@turment on Telegram Last edited by tormento; 21st August 2022 at 11:04. |
21st August 2022, 11:26 | #96 | Link |
Acid fr0g
Join Date: May 2002
Location: Italy
Posts: 2,580
|
I talked too early...
0 Original 1 PHP Code:
PHP Code:
__________________
@turment on Telegram |
21st August 2022, 12:17 | #97 | Link | |
Registered User
Join Date: Jul 2018
Posts: 1,070
|
Quote:
"ConvertBits(32) ConvertToPlanarRGB() w2xncnnvk(noise=0,model=0,gpu_thread=2) ConvertToYUV420(matrix="Rec709")" It looks in 32bit float matrix=Rec709 is no-op for range change ? It may be hidden feature of 32bit float AVS format. "ConvertBits(8) " It looks after any return back from float to integer you need to convert to narrow range (as usual integer moving picture data representation), so correct may be ConvertBits(8, fulls=true, fulld=false) or shorter ConvertBits(8, fulld=false) because fulls for 32bit float input will be auto-detected as true (?). AVS defaults looks like source of error if going into float: http://avisynth.nl/index.php/ConvertBits bool fulls = (auto) Conversion from and to float is always full-scale. bool fulld = fulls So as default 32bit float is full range and default fulld = fulls the simple ConvertBits(32) ConvertBits(8) will cause range convert from narrow to full. The only safe and transparent ConvertBits is 8<->16 integer. Last edited by DTL; 21st August 2022 at 12:43. |
|
22nd August 2022, 12:27 | #99 | Link | |
Broadcast Encoder
Join Date: Nov 2013
Location: Royal Borough of Kensington & Chelsea, UK
Posts: 2,904
|
Quote:
When you go to 32bit float, but stay in YUV, looks like it's still limited tv range, in fact even a simple: Code:
ColorBars(848, 480, pixel_type="YV12") ConvertBits(32) TurnRight.Histogram.TurnLeft The conversion to Full Range happens when Tormento calls "ConverttoPlanarRGB()" 'cause RGB by standard is full range. My "theory" was like yours, namely that when he called back ConverttoYUV420(matrix="Rec709") it was going to clip values rather than converting them back to limited, but no, I was wrong, in fact by doing all the operations he has in the script (except for Waifu) we get a perfectly identical image in terms of levels: Code:
#Limited tv range source ColorBars(848, 480, pixel_type="YV12") original=last #We go to 32bit float limited tv range ConvertBits(32) #We go from Limited TV Range YUV to Full Range RGB 32bit float ConvertToPlanarRGB() #We go back to Limited TV Range YUV 32bit float ConverttoYUV420(matrix="Rec709") #We go back to Limited TV Range YUV 8bit planar ConvertBits(8) converted=last #We compare the two images StackHorizontal(converted, original) So... it must be Waifu screwing it up, there's no other way... Last edited by FranceBB; 22nd August 2022 at 12:35. |
|
Thread Tools | Search this Thread |
Display Modes | |
|
|