From d42d60bc1e0a1c3b472b21d3cd203279879f7d95 Mon Sep 17 00:00:00 2001 From: wm4 Date: Tue, 6 Jan 2015 16:49:53 +0100 Subject: csputils: replace float[3][4] with a struct Not being able to use the 3x3 part of the matrix was annoying, so split it into a float[3][3] matrix and a separate float[3] constant vector. --- demux/demux_disc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'demux') diff --git a/demux/demux_disc.c b/demux/demux_disc.c index 751b81281f..69643a0053 100644 --- a/demux/demux_disc.c +++ b/demux/demux_disc.c @@ -95,15 +95,15 @@ static void add_dvd_streams(demuxer_t *demuxer) struct mp_csp_params csp = MP_CSP_PARAMS_DEFAULTS; csp.int_bits_in = 8; csp.int_bits_out = 8; - float cmatrix[3][4]; - mp_get_yuv2rgb_coeffs(&csp, cmatrix); + struct mp_cmat cmatrix; + mp_get_yuv2rgb_coeffs(&csp, &cmatrix); char *s = talloc_strdup(sh, ""); s = talloc_asprintf_append(s, "palette: "); for (int i = 0; i < 16; i++) { int color = info.palette[i]; int c[3] = {(color >> 16) & 0xff, (color >> 8) & 0xff, color & 0xff}; - mp_map_int_color(cmatrix, 8, c); + mp_map_int_color(&cmatrix, 8, c); color = (c[2] << 16) | (c[1] << 8) | c[0]; if (i != 0) -- cgit v1.2.3