Revert "mesa: fix texture updates for ATI_fragment_shader"
authorMarek Olšák <marek.olsak@amd.com>
Tue, 17 Oct 2017 01:08:47 +0000 (03:08 +0200)
committerMarek Olšák <marek.olsak@amd.com>
Tue, 17 Oct 2017 02:16:17 +0000 (04:16 +0200)
This reverts commit 9d54025cd1eee3f42b80c062d1f644904bf2ba41.

It breaks KOTOR.

Cc: 17.1 17.2 <mesa-stable@lists.freedesktop.org>
src/mesa/main/texstate.c

index 776806d632601540443993621eae15e69f7805fc..2146723d0864e989b615d76fdf6aec9a6e906ef5 100644 (file)
@@ -838,11 +838,9 @@ _mesa_update_texture_state(struct gl_context *ctx)
 
    memcpy(prog, ctx->_Shader->CurrentProgram, sizeof(prog));
 
-   if (prog[MESA_SHADER_FRAGMENT] == NULL) {
-      if (_mesa_arb_fragment_program_enabled(ctx))
-         prog[MESA_SHADER_FRAGMENT] = ctx->FragmentProgram.Current;
-      else if (_mesa_ati_fragment_shader_enabled(ctx))
-         prog[MESA_SHADER_FRAGMENT] = ctx->ATIFragmentShader.Current->Program;
+   if (prog[MESA_SHADER_FRAGMENT] == NULL &&
+       _mesa_arb_fragment_program_enabled(ctx)) {
+      prog[MESA_SHADER_FRAGMENT] = ctx->FragmentProgram.Current;
    }
 
    /* TODO: only set this if there are actual changes */