On Tue, Feb 7, 2012 at 10:09 PM, Ian Romanick <i...@freedesktop.org> wrote: > On 02/07/2012 12:08 PM, Dave Airlie wrote: >> >> Hi guys, >> >> Is there any reason we need to update tex combiner state if we are >> using shaders? >> >> can we drop update_tex_combine updates to only the case where we don't >> have a fragment shader/program unless its from the FF shader? > > > I don't recall when update_tex_combine happens. Does it happen at draw-time > or state change-time? If it happens at state change-time, the state will > need to get updated when program 0 gets bound. Otherwise something like the > following would break: > > glUseProgram(my_prog); > glTexEnvi(GL_TEXTURE_2D, GL_TEXTURE_ENV_MODE, > GL_DECAL); > glUseProgram(0); > glDrawArrays(...);
IT happens in update_texture_state which happens on _NEW_TEXTURE, so it should be fine, since with the maintain fixed function stuff we update the program on _NEW_TEXTURE. Dave. _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev