David Rose 18 anni fa
parent
commit
43101ae12e

+ 4 - 0
panda/src/dxgsg8/dxGraphicsStateGuardian8.cxx

@@ -1922,6 +1922,10 @@ reset() {
 
   void dx_set_stencil_functions (StencilRenderStates *stencil_render_states);
   dx_set_stencil_functions (_stencil_render_states);
+
+  // Now that the GSG has been initialized, make it available for
+  // optimizations.
+  add_gsg(this);
 }
 
 ////////////////////////////////////////////////////////////////////

+ 4 - 0
panda/src/dxgsg9/dxGraphicsStateGuardian9.cxx

@@ -3027,6 +3027,10 @@ reset() {
 
   void dx_set_stencil_functions (StencilRenderStates *stencil_render_states);
   dx_set_stencil_functions (_stencil_render_states);
+
+  // Now that the GSG has been initialized, make it available for
+  // optimizations.
+  add_gsg(this);
 }
 
 ////////////////////////////////////////////////////////////////////