aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/state_trackers/vdpau/mixer.c
diff options
context:
space:
mode:
authorChristian König <[email protected]>2011-04-12 19:42:47 +0200
committerChristian König <[email protected]>2011-04-12 19:42:47 +0200
commit62373e8f9e948ac441d9fe355edfc0dca5f9df9c (patch)
tree3a3c1b5d3c8e1c357c45b41a22a1ce608d9ceb6c /src/gallium/state_trackers/vdpau/mixer.c
parent4f3fb1586aebfe248321e935651b5af92b5a8261 (diff)
vdpau: set at least a basic csc matrix
Diffstat (limited to 'src/gallium/state_trackers/vdpau/mixer.c')
-rw-r--r--src/gallium/state_trackers/vdpau/mixer.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/gallium/state_trackers/vdpau/mixer.c b/src/gallium/state_trackers/vdpau/mixer.c
index 2fe0f1ca6f4..83cbf8abdb1 100644
--- a/src/gallium/state_trackers/vdpau/mixer.c
+++ b/src/gallium/state_trackers/vdpau/mixer.c
@@ -26,8 +26,12 @@
**************************************************************************/
#include <vdpau/vdpau.h>
+
#include <util/u_memory.h>
#include <util/u_debug.h>
+
+#include <vl/vl_csc.h>
+
#include "vdpau_private.h"
VdpStatus
@@ -42,6 +46,7 @@ vlVdpVideoMixerCreate(VdpDevice device,
vlVdpVideoMixer *vmixer = NULL;
struct pipe_video_context *context;
VdpStatus ret;
+ float csc[16];
debug_printf("[VDPAU] Creating VideoMixer\n");
@@ -58,6 +63,14 @@ vlVdpVideoMixerCreate(VdpDevice device,
vmixer->device = dev;
vmixer->compositor = context->create_compositor(context);
+ vl_csc_get_matrix
+ (
+ debug_get_bool_option("G3DVL_NO_CSC", FALSE) ?
+ VL_CSC_COLOR_STANDARD_IDENTITY : VL_CSC_COLOR_STANDARD_BT_601,
+ NULL, true, csc
+ );
+ vmixer->compositor->set_csc_matrix(vmixer->compositor, csc);
+
/*
* TODO: Handle features and parameters
* */