Commits on Source (13)
-
The clean-up following this patch will set the render intent field to NULL when it does not apply (blend-to-output transformation). Make sure we handle it. In the search param string, fix a typo, and stop claiming we get a render intent from a profile; we never do. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
0d3fa818 -
Render intent does not depend on the output (profile), so drop that argument. Render intent does not apply in blend-to-output category in our design, so make it NULL there. Then, we only need to check the surface for a render intent from a client. The assert is dropped, because we don't need to advertise to clients all the rendering intents we support internally. Even though we do. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
07eeed8f -
The plan is to have the frontend decide on the EOTF mode and colorimetry mode, but also the frontend is responsible for setting up a color profile that matches the chosen modes. Therefore we don't need to care about the modes explicitly here. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
e6551ef4 -
This perhaps better explains what the issue here is. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
5d6e7115 -
Refactoring to allow the next patch, no functional changes. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
7ccb9736 -
Refactor and rename retrieve_eotf_and_output_inv_eotf(). Refactoring to make the calls more convenient to read, and preparation for changing the object types for the curves. ensure_output_profile_extract() reserves a place for another function that works on parametric profiles instead of ICC profiles. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
3488e240 -
Return an error string so we can report the cause in more detail. For consistency, add checking for VCGT dup failure, so we can report that too. Leaking partial VCGT array on VCGT dup failure is fixed. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
547dc273 -
I did not understand the old comments. The new comments explain what happens here. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
570b348f -
cmsHPROFILE is a typedef of void *. This means you can change the type of pointer variable to or from cmsHPROFILE, and the compiler will not see any difference. The compiler is happy to implicitly cast any pointer type to cmsHPROFILE and back. In order to bring some type safety for future refactorings that will be doing such type changes, introduce a wrapper struct. The wrapper being an actual unique type will not allow implicit casting. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
236ee19e -
We need it as a cms profile, so let's make it one to start with. We even gain non-fatal error handling. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
fd63243c -
We need it as a cms profile, so let's make it one to start with. We even gain non-datal error handling. This will also be useful in rewriting output_inv_eotf_vcgt next. The type change of vcgt_curves is required to be able to call cmsCreateLinearizationDeviceLinkTHR(), even though everything about vcgt_curves should be doubly const. The curves are populated on demand and cached in cmsHPROFILE, so we also must not explicitly free them. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
98454720 -
Stop special-casing the blend-to-output category, and pass it through the same mechnisms and optimizations as all other transformations. In the future, more curve types will be added to weston_color_transform, meaning that blend-to-output does not always have to be a LUT. It could become a parametric curve, which is more efficient and more precise to compute, when VCGT does not exist. Drop the special crafting of output_inv_eotf_vcgt LUT and replace it with inv_eotf cms profile. inv_eotf will be combined with vcgt cms profile as a chain as needed instead. Blend-to-output transformations do not use a render intent, but we have to tell cmsCreateMultiprofileTransformTHR() something, so arbitrarily pick ICC-Absolute render intent for it. Now all color transformations go through xform_realize_chain(), where the documentation is improved. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
4b9fa23e -
There is no reason why cmlcms_fill_in_3dlut() would not work for blend-to-output category, so the assert is a little misplaced. However, there would be a bug if 3D LUT was used for blend-to-output, because we should never fail to optimize that chain. Put the assert where it belongs. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
5223b843