From b071050b9eda9d5e5185e582dbe9f4adba863ccc Mon Sep 17 00:00:00 2001 From: marha Date: Tue, 18 Jun 2013 08:23:14 +0200 Subject: libX11 libXmu libxcb/xcb-proto mesa mkfontscale pixman xkeyboard-config git update 18 June 2013 libxcb/xcb-proto commit e5f7c750815cb5170db363a2e5b09639b7354733 xkeyboard-config commit 30d804538462213ed01e8efc0b44a8e5a0aff990 libX11 commit 9dfb0f3c0a761590bcdc1f3396b1e064da4e18e8 pixman commit 279bdcda7ec3af8ac06312f4514b1b082a279544 mkfontscale commit f731c5c36f28ddd0f25f474d2991c96f9a7a915c libXmu commit e46ecb4e02b7f919b11efa79448d4db71d1deb69 mesa commit eb2021507556633cd6ba64cda26653e3c43e80df --- .../src/gallium/auxiliary/util/u_simple_shaders.c | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) (limited to 'mesalib/src/gallium/auxiliary/util/u_simple_shaders.c') diff --git a/mesalib/src/gallium/auxiliary/util/u_simple_shaders.c b/mesalib/src/gallium/auxiliary/util/u_simple_shaders.c index c53c2d024..c93d75469 100644 --- a/mesalib/src/gallium/auxiliary/util/u_simple_shaders.c +++ b/mesalib/src/gallium/auxiliary/util/u_simple_shaders.c @@ -322,11 +322,12 @@ util_make_fragment_tex_shader_writestencil(struct pipe_context *pipe, void * util_make_fragment_passthrough_shader(struct pipe_context *pipe, int input_semantic, - int input_interpolate) + int input_interpolate, + boolean write_all_cbufs) { static const char shader_templ[] = "FRAG\n" - "PROPERTY FS_COLOR0_WRITES_ALL_CBUFS 1\n" + "%s" "DCL IN[0], %s[0], %s\n" "DCL OUT[0], COLOR[0]\n" @@ -337,7 +338,9 @@ util_make_fragment_passthrough_shader(struct pipe_context *pipe, struct tgsi_token tokens[1000]; struct pipe_shader_state state = {tokens}; - sprintf(text, shader_templ, tgsi_semantic_names[input_semantic], + sprintf(text, shader_templ, + write_all_cbufs ? "PROPERTY FS_COLOR0_WRITES_ALL_CBUFS 1\n" : "", + tgsi_semantic_names[input_semantic], tgsi_interpolate_names[input_interpolate]); if (!tgsi_text_translate(text, tokens, Elements(tokens))) { @@ -352,6 +355,18 @@ util_make_fragment_passthrough_shader(struct pipe_context *pipe, } +void * +util_make_empty_fragment_shader(struct pipe_context *pipe) +{ + struct ureg_program *ureg = ureg_create(TGSI_PROCESSOR_FRAGMENT); + if (ureg == NULL) + return NULL; + + ureg_END(ureg); + return ureg_create_shader_and_destroy(ureg, pipe); +} + + /** * Make a fragment shader that copies the input color to N output colors. */ -- cgit v1.2.3