From bfb0e4f967cf3e7c3342613a217baf79137de824 Mon Sep 17 00:00:00 2001 From: hizzlekizzle Date: Tue, 12 Jun 2018 08:49:45 -0500 Subject: [PATCH] correct yellow tint in ntsc 320px svideo preset --- ntsc/shaders/ntsc-rgbyuv.inc | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/ntsc/shaders/ntsc-rgbyuv.inc b/ntsc/shaders/ntsc-rgbyuv.inc index ccf8fd3..27fb136 100644 --- a/ntsc/shaders/ntsc-rgbyuv.inc +++ b/ntsc/shaders/ntsc-rgbyuv.inc @@ -1,21 +1,20 @@ -mat3 yiq2rgb_mat = mat3( - 1.0, 1.0, 1.0, - 0.956, -0.2720, -1.1060, - 0.6210, -0.6474, 1.7046 -); +const mat3 yiq2rgb_mat = mat3( + 1.0, 0.956, 0.6210, + 1.0, -0.2720, -0.6474, + 1.0, -1.1060, 1.7046); vec3 yiq2rgb(vec3 yiq) { - return (yiq * yiq2rgb_mat); + return yiq * yiq2rgb_mat; } -mat3 yiq_mat = mat3( - 0.2989, 0.5959, 0.2115, - 0.5870, -0.2744, -0.5229, - 0.1140, -0.3216, 0.3114 +const mat3 yiq_mat = mat3( + 0.2989, 0.5870, 0.1140, + 0.5959, -0.2744, -0.3216, + 0.2115, -0.5229, 0.3114 ); vec3 rgb2yiq(vec3 col) { - return (col * yiq_mat); + return col * yiq_mat; }