mirror of
https://github.com/brl/mutter.git
synced 2025-06-13 16:59:30 +00:00
Replace cogl_color_set_from_* with cogl_color_init_from_*
The former is not yet "officially" deprecated by the latter, but it's confusing to have them both in the code base.
This commit is contained in:
@ -27,7 +27,7 @@ _text_paint_cb (ClutterActor *actor)
|
||||
|
||||
/* Create a #ccc color and premultiply it */
|
||||
CoglColor color;
|
||||
cogl_color_set_from_4ub (&color, 0xcc, 0xcc, 0xcc, real_opacity);
|
||||
cogl_color_init_from_4ub (&color, 0xcc, 0xcc, 0xcc, real_opacity);
|
||||
cogl_color_premultiply (&color);
|
||||
|
||||
/* Finally, render the Text layout at a given offset using the color */
|
||||
|
@ -50,7 +50,7 @@ _update_progress_cb (ClutterTimeline *timeline,
|
||||
* depending on the current progress of the timeline
|
||||
*/
|
||||
CoglColor constant;
|
||||
cogl_color_set_from_4ub (&constant, 0x00, 0x00, 0x00, 0xff * progress);
|
||||
cogl_color_init_from_4ub (&constant, 0x00, 0x00, 0x00, 0xff * progress);
|
||||
|
||||
/* This sets the value of the constant color we use when combining
|
||||
* the two layers
|
||||
|
@ -35,9 +35,9 @@ _clone_paint_cb (ClutterActor *actor)
|
||||
/* figure out the two colors for the reflection: the first is
|
||||
* full color and the second is the same, but at 0 opacity
|
||||
*/
|
||||
cogl_color_set_from_4f (&color_1, 1.0, 1.0, 1.0, opacity / 255.);
|
||||
cogl_color_init_from_4f (&color_1, 1.0, 1.0, 1.0, opacity / 255.);
|
||||
cogl_color_premultiply (&color_1);
|
||||
cogl_color_set_from_4f (&color_2, 1.0, 1.0, 1.0, 0.0);
|
||||
cogl_color_init_from_4f (&color_2, 1.0, 1.0, 1.0, 0.0);
|
||||
cogl_color_premultiply (&color_2);
|
||||
|
||||
/* now describe the four vertices of the quad; since it has
|
||||
|
Reference in New Issue
Block a user