Re: Status of CSP prelut?


"dbr/Ben" <b...@...>
 

Initial attempt at this, and an unrelated commit which prevents empty config sections being seralised:


On 09/02/2011, at 7:10 AM, Jeremy Selan wrote:

Looks good.

So for the case you outline below, you'd create a Lut1D op, where
from_min = 0.0, from_max = 4.0, and the lut values 0 ... 2.0 would go
in the lut.

I'd go with a fixed number of samples for now, using linear
interpolation between.  Let's just pick a big number for the short
term, say 2**12 or 2**16, and hard code it.   In the medium or long
term, we'll probably swap it out for analytical spline evaluation to
make it a non-issue.

-- Jeremy


On Mon, Feb 7, 2011 at 5:53 AM, dbr/Ben <b...@...> wrote:
Started attempting this, seems to be progressing well - thanks for the tips!

To be clear about the resampling. Given a prelut of:

0.0 2.0 4.0
0.0 1.0 2.0

..the code would linearly-interoplate between 0.0 and 4.0, sampling the spline and producing something like:

0.0 0.5 1.0 1.5 2.0

Assuming that is correct - how many samples should be made? A fixed amount? Configurable? Based on the number of spline points?

Could this be a problem if (for some perverse/contrived reason) you have a prelut of:

0.0 1.0 99999.0
0.0 1.0 2.0

On 04/02/2011, at 11:22 AM, Jeremy Selan wrote:

Ben,

So if you're still interested in implementing this feel free to take a
stab.

What you'll probably want to do is to copy the code from the specified
link,
add it to an anonymous namespace in the cspreader, and then use it at
load time to resample the and create a shaper lut1D. Just follow the
example on the normal 1d lut already being used for reference code.

(Also please add the appropriate copyright additions to our license
file).

If you're not up for this any longer, no worries.

-- Jeremy

On Feb 1, 11:07 pm, Malcolm Humphreys <malcol...@...>
wrote:
I was planning on doing this but have had a few other higher priority production things come up so it's been on the back burner.

Yes, we're waiting on spline interpolation code.

Malcolm will be the authority on which spline interpolation is
appropriate for the csp prelut, I'll let him comment on the details.
I'm not sure if a simple spline model is sufficient, or if more
advanced features (such as tangent controls) are necessary.

https://cinespacelutlib.svn.sourceforge.net/svnroot/cinespacelutlib/t...

Ben - Do you already have suitable spline code ready?  I have some
strong ideas for how I'd like the code to be implemented internally.
(The issue is whether the spline would be upsampled on load to a
regularized 1D lut, or instead if we should create a new native
SplineOp (which would likely require both CPU + GPU implementations).

SplineOp should sampled into the 1D lut on load (+1)







If you're not up for tackling the Op code, I'd be happy to do that
legwork, and then you could update the csp reader.

Do you have example CSP files that use the prelut? I'd love to look at them.

-- Jeremy

On Tue, Feb 1, 2011 at 2:46 PM, dbr/Ben <db...@...> wrote:
I was going to attempt to finish it off, but wanted to check if there's anything I should know before starting to prod around..

From the comments/old mailing list messages, it seems like it is mainly just waiting on a SplineOp class?

- Ben



Join {ocio-dev@lists.aswf.io to automatically receive all group messages.