aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/gallium
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2013-07-16 08:53:23 +0200
committermarha <marha@users.sourceforge.net>2013-07-16 08:53:23 +0200
commit06f4de23ace4de1fd628c37891214f0a4ecb77db (patch)
tree38ba52b20ef6060eab6e9b91e2c022e7a953e06b /mesalib/src/gallium
parentffce4319c2fb6f4f663cc5a9660e1d5837fcde87 (diff)
downloadvcxsrv-06f4de23ace4de1fd628c37891214f0a4ecb77db.tar.gz
vcxsrv-06f4de23ace4de1fd628c37891214f0a4ecb77db.tar.bz2
vcxsrv-06f4de23ace4de1fd628c37891214f0a4ecb77db.zip
libxcb xcb-proto mesa xkbcomp git update 16 Jul 2013
libxcb commit 45619dc71e9411a526d7c69595cf615b1b1206cf libxcb/xcb-proto commit 56a82005ac388fcb7a4d1c82e07c7e72eaf69a32 xkbcomp commit 1cd5c50c54b06de2238d6d7675d0a3c65a21414d mesa commit e4fdf1b008ce29c5b5a52985c586b61f35d31e4c
Diffstat (limited to 'mesalib/src/gallium')
-rw-r--r--mesalib/src/gallium/auxiliary/Makefile.sources2
-rw-r--r--mesalib/src/gallium/auxiliary/hud/hud_context.c16
-rw-r--r--mesalib/src/gallium/auxiliary/util/u_blit.c28
-rw-r--r--mesalib/src/gallium/auxiliary/util/u_format_tests.c5
-rw-r--r--mesalib/src/gallium/auxiliary/util/u_pstipple.c10
5 files changed, 34 insertions, 27 deletions
diff --git a/mesalib/src/gallium/auxiliary/Makefile.sources b/mesalib/src/gallium/auxiliary/Makefile.sources
index 47517626d..acbcef7e2 100644
--- a/mesalib/src/gallium/auxiliary/Makefile.sources
+++ b/mesalib/src/gallium/auxiliary/Makefile.sources
@@ -44,6 +44,7 @@ C_SOURCES := \
hud/hud_fps.c \
hud/hud_driver_query.c \
os/os_misc.c \
+ os/os_process.c \
os/os_time.c \
pipebuffer/pb_buffer_fenced.c \
pipebuffer/pb_buffer_malloc.c \
@@ -172,6 +173,7 @@ GALLIVM_SOURCES := \
gallivm/lp_bld_format_aos.c \
gallivm/lp_bld_format_aos_array.c \
gallivm/lp_bld_format_float.c \
+ gallivm/lp_bld_format_srgb.c \
gallivm/lp_bld_format_soa.c \
gallivm/lp_bld_format_yuv.c \
gallivm/lp_bld_gather.c \
diff --git a/mesalib/src/gallium/auxiliary/hud/hud_context.c b/mesalib/src/gallium/auxiliary/hud/hud_context.c
index 47566d816..c4a4f1877 100644
--- a/mesalib/src/gallium/auxiliary/hud/hud_context.c
+++ b/mesalib/src/gallium/auxiliary/hud/hud_context.c
@@ -407,8 +407,8 @@ hud_draw(struct hud_context *hud, struct pipe_resource *tex)
hud->fb_width = tex->width0;
hud->fb_height = tex->height0;
- hud->constants.two_div_fb_width = 2.0 / hud->fb_width;
- hud->constants.two_div_fb_height = 2.0 / hud->fb_height;
+ hud->constants.two_div_fb_width = 2.0f / hud->fb_width;
+ hud->constants.two_div_fb_height = 2.0f / hud->fb_height;
cso_save_framebuffer(cso);
cso_save_sample_mask(cso);
@@ -488,7 +488,7 @@ hud_draw(struct hud_context *hud, struct pipe_resource *tex)
hud->constants.color[0] = 0;
hud->constants.color[1] = 0;
hud->constants.color[2] = 0;
- hud->constants.color[3] = 0.666;
+ hud->constants.color[3] = 0.666f;
hud->constants.translate[0] = 0;
hud->constants.translate[1] = 0;
hud->constants.scale[0] = 1;
@@ -564,7 +564,7 @@ void
hud_pane_set_max_value(struct hud_pane *pane, uint64_t value)
{
pane->max_value = value;
- pane->yscale = -(int)pane->inner_height / (double)pane->max_value;
+ pane->yscale = -(int)pane->inner_height / (float)pane->max_value;
}
static struct hud_pane *
@@ -636,8 +636,8 @@ hud_graph_add_value(struct hud_graph *gr, uint64_t value)
gr->vertices[1] = gr->vertices[(gr->index-1)*2+1];
gr->index = 1;
}
- gr->vertices[(gr->index)*2+0] = gr->index*2;
- gr->vertices[(gr->index)*2+1] = value;
+ gr->vertices[(gr->index)*2+0] = (float) (gr->index * 2);
+ gr->vertices[(gr->index)*2+1] = (float) value;
gr->index++;
if (gr->num_vertices < gr->pane->max_num_vertices) {
@@ -717,8 +717,8 @@ hud_parse_env_var(struct hud_context *hud, const char *env)
*/
period_env = getenv("GALLIUM_HUD_PERIOD");
if (period_env) {
- float p = atof(period_env);
- if (p >= 0.0) {
+ float p = (float) atof(period_env);
+ if (p >= 0.0f) {
period = (unsigned) (p * 1000 * 1000);
}
}
diff --git a/mesalib/src/gallium/auxiliary/util/u_blit.c b/mesalib/src/gallium/auxiliary/util/u_blit.c
index 07418be45..8cc080cc9 100644
--- a/mesalib/src/gallium/auxiliary/util/u_blit.c
+++ b/mesalib/src/gallium/auxiliary/util/u_blit.c
@@ -596,10 +596,10 @@ util_blit_pixels(struct blit_state *ctx,
t1 = 1.0f;
}
else {
- s0 = 0;
- s1 = srcW;
- t0 = 0;
- t1 = srcH;
+ s0 = 0.0f;
+ s1 = (float) srcW;
+ t0 = 0.0f;
+ t1 = (float) srcH;
}
u_sampler_view_default_template(&sv_templ, tex, tex->format);
@@ -630,10 +630,10 @@ util_blit_pixels(struct blit_state *ctx,
return;
}
- s0 = srcX0;
- s1 = srcX1;
- t0 = srcY0;
- t1 = srcY1;
+ s0 = (float) srcX0;
+ s1 = (float) srcX1;
+ t0 = (float) srcY0;
+ t1 = (float) srcY1;
normalized = sampler_view->texture->target != PIPE_TEXTURE_RECT;
if(normalized)
{
@@ -685,8 +685,8 @@ util_blit_pixels(struct blit_state *ctx,
ctx->sampler.normalized_coords = normalized;
ctx->sampler.min_img_filter = filter;
ctx->sampler.mag_img_filter = filter;
- ctx->sampler.min_lod = src_level;
- ctx->sampler.max_lod = src_level;
+ ctx->sampler.min_lod = (float) src_level;
+ ctx->sampler.max_lod = (float) src_level;
/* Depth stencil state, fragment shader and sampler setup depending on what
* we blit.
@@ -839,10 +839,10 @@ util_blit_pixels_tex(struct blit_state *ctx,
assert(tex->width0 != 0);
assert(tex->height0 != 0);
- s0 = srcX0;
- s1 = srcX1;
- t0 = srcY0;
- t1 = srcY1;
+ s0 = (float) srcX0;
+ s1 = (float) srcX1;
+ t0 = (float) srcY0;
+ t1 = (float) srcY1;
if(normalized)
{
diff --git a/mesalib/src/gallium/auxiliary/util/u_format_tests.c b/mesalib/src/gallium/auxiliary/util/u_format_tests.c
index 26e7acb62..64224cd2e 100644
--- a/mesalib/src/gallium/auxiliary/util/u_format_tests.c
+++ b/mesalib/src/gallium/auxiliary/util/u_format_tests.c
@@ -883,8 +883,13 @@ util_format_test_cases[] =
/* Minimum positive normal */
{PIPE_FORMAT_R16_FLOAT, PACKED_1x16(0xffff), PACKED_1x16(0x0400), UNPACKED_1x1( 6.10352E-5, 0.0, 0.0, 1.0)},
+ /* XXX: Now that we disable denormals this test cases fails, except on
+ * IvyBridge processors which have intrinsics dedicated to half-float
+ * packing/unpacking. */
+#if 0
/* Max denormal */
{PIPE_FORMAT_R16_FLOAT, PACKED_1x16(0xffff), PACKED_1x16(0x03FF), UNPACKED_1x1( 6.09756E-5, 0.0, 0.0, 1.0)},
+#endif
/* Minimum positive denormal */
{PIPE_FORMAT_R16_FLOAT, PACKED_1x16(0xffff), PACKED_1x16(0x0001), UNPACKED_1x1( 5.96046E-8, 0.0, 0.0, 1.0)},
diff --git a/mesalib/src/gallium/auxiliary/util/u_pstipple.c b/mesalib/src/gallium/auxiliary/util/u_pstipple.c
index 68804ae98..640305f9e 100644
--- a/mesalib/src/gallium/auxiliary/util/u_pstipple.c
+++ b/mesalib/src/gallium/auxiliary/util/u_pstipple.c
@@ -75,7 +75,7 @@ util_pstipple_update_stipple_texture(struct pipe_context *pipe,
/*
* Load alpha texture.
* Note: 0 means keep the fragment, 255 means kill it.
- * We'll negate the texel value and use KILP which kills if value
+ * We'll negate the texel value and use KILL_IF which kills if value
* is negative.
*/
for (i = 0; i < 32; i++) {
@@ -252,7 +252,7 @@ free_bit(uint bitfield)
* declare new registers
* MUL texTemp, INPUT[wincoord], 1/32;
* TEX texTemp, texTemp, sampler;
- * KIL -texTemp; # if -texTemp < 0, KILL fragment
+ * KILL_IF -texTemp; # if -texTemp < 0, kill fragment
* [...original code...]
*/
static void
@@ -340,7 +340,7 @@ pstip_transform_inst(struct tgsi_transform_context *ctx,
/*
- * Insert new MUL/TEX/KILP instructions at start of program
+ * Insert new MUL/TEX/KILL_IF instructions at start of program
* Take gl_FragCoord, divide by 32 (stipple size), sample the
* texture and kill fragment if needed.
*
@@ -379,9 +379,9 @@ pstip_transform_inst(struct tgsi_transform_context *ctx,
newInst.Src[1].Register.Index = pctx->freeSampler;
ctx->emit_instruction(ctx, &newInst);
- /* KIL -texTemp; # if -texTemp < 0, KILL fragment */
+ /* KILL_IF -texTemp; # if -texTemp < 0, kill fragment */
newInst = tgsi_default_full_instruction();
- newInst.Instruction.Opcode = TGSI_OPCODE_KIL;
+ newInst.Instruction.Opcode = TGSI_OPCODE_KILL_IF;
newInst.Instruction.NumDstRegs = 0;
newInst.Instruction.NumSrcRegs = 1;
newInst.Src[0].Register.File = TGSI_FILE_TEMPORARY;