vl: Add support for max level query v2
[mesa.git] / src / gallium / drivers / r300 / r300_fs.c
index 051b29217ad18479021553be89799aa2794b4475..6e1b4e44ad3ef3e17736b1c29af2970d32b54854 100644 (file)
@@ -149,6 +149,8 @@ static void get_external_state(
     struct r300_textures_state *texstate = r300->textures_state.state;
     unsigned i;
 
+    state->alpha_to_one = r300->alpha_to_one && r300->msaa_enable;
+
     for (i = 0; i < texstate->sampler_state_count; i++) {
         struct r300_sampler_state *s = texstate->sampler_states[i];
         struct r300_sampler_view *v = texstate->sampler_views[i];
@@ -212,7 +214,7 @@ static void get_external_state(
                 state->unit[i].wrap_mode = RC_WRAP_NONE;
             }
 
-            if (t->b.b.b.target == PIPE_TEXTURE_3D)
+            if (t->b.b.target == PIPE_TEXTURE_3D)
                 state->unit[i].clamp_and_scale_before_fetch = TRUE;
         }
     }
@@ -442,7 +444,7 @@ static void r300_translate_fragment_shader(
 
     /* Setup the compiler. */
     memset(&compiler, 0, sizeof(compiler));
-    rc_init(&compiler.Base);
+    rc_init(&compiler.Base, &r300->fs_regalloc_state);
     DBG_ON(r300, DBG_FP) ? compiler.Base.Debug |= RC_DBG_LOG : 0;
     DBG_ON(r300, DBG_P_STAT) ? compiler.Base.Debug |= RC_DBG_STATS : 0;