Commit 170195b5 authored by Ville Syrjälä's avatar Ville Syrjälä

lib/igt_color_encoding: Appease c90

Apparently we stil build in c90 mode or something with autotools. It
doesn't like mixed code and declarations.

v2: Do it the sane way (Chris)

Cc: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Ville Syrjälä's avatarVille Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Chris Wilson's avatarChris Wilson <chris@chris-wilson.co.uk>
parent d4678419
......@@ -36,11 +36,9 @@ static const struct color_encoding color_encodings[IGT_NUM_COLOR_ENCODINGS] = {
static struct igt_mat4 rgb_to_ycbcr_matrix(const struct color_encoding *e)
{
float kr, kg, kb;
kr = e->kr;
kb = e->kb;
kg = 1.0f - kr - kb;
float kr = e->kr;
float kb = e->kb;
float kg = 1.0f - kr - kb;
struct igt_mat4 ret = {
.d[m(0, 0)] = kr,
......@@ -63,11 +61,9 @@ static struct igt_mat4 rgb_to_ycbcr_matrix(const struct color_encoding *e)
static struct igt_mat4 ycbcr_to_rgb_matrix(const struct color_encoding *e)
{
float kr, kg, kb;
kr = e->kr;
kb = e->kb;
kg = 1.0f - kr - kb;
float kr = e->kr;
float kb = e->kb;
float kg = 1.0f - kr - kb;
struct igt_mat4 ret = {
.d[m(0, 0)] = 1.0f,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment