color-lcms: rename get_xform() to to_cmlcms_xform()
"Get" could imply increasing reference count, and color transform objects indeed are reference counted, but this function does not do that. Rename it to reduce confusion. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
This commit is contained in:
parent
6fe294c18a
commit
ce51a04013
@ -88,7 +88,7 @@ get_cprof_or_stock_sRGB(struct weston_color_manager_lcms *cm,
|
||||
static void
|
||||
cmlcms_destroy_color_transform(struct weston_color_transform *xform_base)
|
||||
{
|
||||
struct cmlcms_color_transform *xform = get_xform(xform_base);
|
||||
struct cmlcms_color_transform *xform = to_cmlcms_xform(xform_base);
|
||||
|
||||
cmlcms_color_transform_destroy(xform);
|
||||
}
|
||||
|
@ -208,7 +208,7 @@ struct cmlcms_color_transform {
|
||||
};
|
||||
|
||||
static inline struct cmlcms_color_transform *
|
||||
get_xform(struct weston_color_transform *xform_base)
|
||||
to_cmlcms_xform(struct weston_color_transform *xform_base)
|
||||
{
|
||||
return container_of(xform_base, struct cmlcms_color_transform, base);
|
||||
}
|
||||
|
@ -91,7 +91,7 @@ static void
|
||||
cmlcms_fill_in_output_inv_eotf_vcgt(struct weston_color_transform *xform_base,
|
||||
float *values, unsigned len)
|
||||
{
|
||||
struct cmlcms_color_transform *xform = get_xform(xform_base);
|
||||
struct cmlcms_color_transform *xform = to_cmlcms_xform(xform_base);
|
||||
struct cmlcms_color_profile *p = xform->search_key.output_profile;
|
||||
|
||||
assert(p && "output_profile");
|
||||
@ -102,7 +102,7 @@ static void
|
||||
cmlcms_fill_in_pre_curve(struct weston_color_transform *xform_base,
|
||||
float *values, unsigned len)
|
||||
{
|
||||
struct cmlcms_color_transform *xform = get_xform(xform_base);
|
||||
struct cmlcms_color_transform *xform = to_cmlcms_xform(xform_base);
|
||||
|
||||
fill_in_curves(xform->pre_curve, values, len);
|
||||
}
|
||||
@ -111,7 +111,7 @@ static void
|
||||
cmlcms_fill_in_post_curve(struct weston_color_transform *xform_base,
|
||||
float *values, unsigned len)
|
||||
{
|
||||
struct cmlcms_color_transform *xform = get_xform(xform_base);
|
||||
struct cmlcms_color_transform *xform = to_cmlcms_xform(xform_base);
|
||||
|
||||
fill_in_curves(xform->post_curve, values, len);
|
||||
}
|
||||
@ -135,7 +135,7 @@ static void
|
||||
cmlcms_fill_in_3dlut(struct weston_color_transform *xform_base,
|
||||
float *lut, unsigned int len)
|
||||
{
|
||||
struct cmlcms_color_transform *xform = get_xform(xform_base);
|
||||
struct cmlcms_color_transform *xform = to_cmlcms_xform(xform_base);
|
||||
float rgb_in[3];
|
||||
float rgb_out[3];
|
||||
unsigned int index;
|
||||
|
Loading…
Reference in New Issue
Block a user