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 |
22nd November 2018, 22:16 | #1 | Link |
Registered User
Join Date: Dec 2017
Posts: 90
|
AviSynth+, basic filters that work with RGBAPS color format?
I'm doing the following:
Code:
video=FFVideoSource("HDRVideo.mkv") video=video.ConvertBits(16).ConvertToYUV444() video=Spline36ResizeMT(video,1920,800,SetAffinity=false).Sharpen(0.2) video=z_ConvertFormat(video,pixel_type="RGBPS",colorspace_op="2020ncl:st2084:2020:l=>rgb:linear:2020:l", dither_type="none").DGHable(exposure=0.1,d=0.00001,e=0.0295,f=0.3,a=5) video=z_ConvertFormat(video,pixel_type="YUV444P16",colorspace_op="rgb:linear:2020:l=>709:709:709:l",dither_type="ordered") video But here I was wondering, is there any way to adjust the image in the RGBPS color format? That's the format it has after the first call to z_ConvertFormat and as I understand it, this is a floating point format in which the image is stored in linear color space. It would be nice if I could make some very basic adjustments to the image in this colorspace. For example contrast, gain, etc. for a very rudimentary color correction. In particular I'd like trying to just scale the green channel down a little bit (say, multiply it with 0.95). Unfortunately RGBAdjust doesn't work in RGBPS. Tweak doesn't work for obvious reasons. Is there some kind of list of filters that actually are compatible with this color format? I know I could just make the tweaks after it's converted back to a "normal" color format, but I want to play around with the linear color space a bit. |
22nd November 2018, 23:18 | #3 | Link |
Registered User
Join Date: Sep 2007
Posts: 5,346
|
Levels() works in RGBPS ok too
Request: Can someone re-write HistogramRGBLevels , HistogramRGBParade, functions so they compatible with other bit depths? http://avisynth.nl/index.php/Histograms_in_RGB_%26_CMY |
23rd November 2018, 10:08 | #4 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,309
|
If you want, you can try this, if you're using my plugins (if you want to convert HDR PQ to SDR) :
Code:
video=FFVideoSource("HDRVideo.mkv") video=video.ConvertBits(16).ConvertToYUV444() video=Spline36ResizeMT(video,1920,800,SetAffinity=false).Sharpen(0.2) video=ConvertYUVtoLinearRGB(video,Color=0,OutputMode=2).DGHable(...) video=ConvertLinearRGBtoYUV() video
__________________
My github. |
23rd November 2018, 13:33 | #5 | Link | |
Registered User
Join Date: Dec 2017
Posts: 90
|
Quote:
Say I want to multiply the green channel with 0.98, how would I go about that? |
|
23rd November 2018, 13:36 | #6 | Link | |
Registered User
Join Date: Dec 2017
Posts: 90
|
Quote:
|
|
23rd November 2018, 15:49 | #8 | Link |
Registered User
Join Date: Dec 2017
Posts: 90
|
Fucking fantastic, thank you so much, now I think I get it! Though it seems that I have an older version where this will multiply the blue channel due to that GBR ordering bug, but no problem at all, I see the logic behind it now.
|
23rd November 2018, 16:08 | #9 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,309
|
As you're using one of my filters, Spline36ResizeMT, maybe you want to try/test those on my HDRTools, it's a plugin dedicated to HDR/SDR work, if you're interested or curious to check.
__________________
My github. Last edited by jpsdr; 23rd November 2018 at 16:12. |
23rd November 2018, 16:29 | #10 | Link | |
Registered User
Join Date: Dec 2017
Posts: 90
|
Quote:
Gonna check out your projects. |
|
Thread Tools | Search this Thread |
Display Modes | |
|
|