Ogeon/palette

Improve the (non-)linear transfer function trait

Ogeon opened this issue · 0 comments

Ogeon commented

Description

We should try to split the TransferFn trait into at least FromLinear and IntoLinear. That should cover cases where it's not so trivial, or even impossible, to reverse the process.

I have also considered baking in number type conversion to allow possibly better quantization quality and conversion speed, but I have to read up some more on that. That could perhaps be covered separately with a more precise IntoComponent option.

Motivation

The current setup assumes both that the process can be reversed and that the output type should be the same as the input type. That may not always be the case.