full range vs legal range

160 views
Skip to first unread message

Satheesh Ram

unread,
Jan 26, 2016, 3:09:11 PM1/26/16
to tuttleofx-user
Hi,
I am using Tuttle OFX host and plugins for image processing(which includes OIIOReader, OIIOWriter, DPXWriter, reader/writer plugins related to DPX, TIF, EXR, PPM files). I am wondering how to specify that source has pixels in legal range or full range to the plugins.  I didnt find any paramter related to full vs legal range in those reader/writer plugins. How does Tuttle pipeline handle this case?

Clément Champetier

unread,
Jan 27, 2016, 6:18:36 AM1/27/16
to tuttleofx-user
Hello,

I'm not sure what are you talking about : the bit depth (32f, 16, 8) or the RoD of images? Or something else?
If it is bit depth, all readers have a parameter bitDepth to specify it.
If it is RoD, the EXR reader has a parameter outputData that could be "display" or "data" to output the display window or all the data of exr file.

Does this help?

Satheesh Ram

unread,
Jan 27, 2016, 6:56:35 AM1/27/16
to tuttleofx-user
Hi Clement,
My bad. lemme explain the question more clearly.

For 8 bit pixels, full range is 0 - 255, legal range is 16-235. Input image source could be in full or legal range. The knowledge on legal or full range may/may not be available within a file format metadata. But it affects the color conversion matrix that is used for RGB to YUV and vice versa. Same options available for 10bit input as well; full range is 0-1024. legal range is 64-940. When converting 10bit pixel value to 32 bit float, I believe knowledge on full vs legal source has to be used to get the scaling factor. 

How do we handle these generically in all plugins under Tuttle OFX?





--
You received this message because you are subscribed to a topic in the Google Groups "tuttleofx-user" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tuttleofx-user/AU-oV_FNpEs/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tuttleofx-use...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
Satheesh Ram

cl.cha...@gmail.com

unread,
Jan 29, 2016, 5:40:55 AM1/29/16
to tuttleofx-user
Ok thanks for your explanation, now it's clear.

This notion is not included in OpenFX, since the full/legal range is a legacy from the video world.

So the color range needs to be managed by reader/writer at the library level (inside the plugins). After few research, it appears that ffmpeg manages color range, so our reader based on ffmpeg does too, with color range option and its values:
"unspecified" auto
"mpeg" 16-235
"jpeg" 0-255

Example:
sam do avreader input v_color_range="mpeg" // viewer

But according to ffmpeg issue tracker, it appears that this option has several bugs (https://trac.ffmpeg.org/ticket/443).

Could you test this option with your data and tell us your results?

Maybe an other solution to this issue could be to create an OpenFX plugin which applies the color transform, according to input parameters, to an input image from legal range to full range (and vice versa)?
Reply all
Reply to author
Forward
0 new messages