rpms/mesa/devel .cvsignore, 1.33, 1.34 mesa-7.1-link-shared.patch, 1.3, 1.4 mesa-7.1-nukeglthread-debug.patch, 1.3, 1.4 mesa.spec, 1.231, 1.232 radeon-rewrite.patch, 1.9, 1.10 sources, 1.33, 1.34 mesa-7.3-fixes-from-7.4-branch.patch, 1.1, NONE

Dave Airlie airlied at fedoraproject.org
Sun Mar 22 02:20:47 UTC 2009


Author: airlied

Update of /cvs/pkgs/rpms/mesa/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv15479

Modified Files:
	.cvsignore mesa-7.1-link-shared.patch 
	mesa-7.1-nukeglthread-debug.patch mesa.spec 
	radeon-rewrite.patch sources 
Removed Files:
	mesa-7.3-fixes-from-7.4-branch.patch 
Log Message:
* Fri Mar 20 2009 Dave Airlie <airlied at redhat.com> 7.5-0.1
- bump to snapshot of mesa master
- mainly has intel dri2 tfp fixes + radeon rewrite patch



Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/mesa/devel/.cvsignore,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -r1.33 -r1.34
--- .cvsignore	8 Feb 2009 08:01:36 -0000	1.33
+++ .cvsignore	22 Mar 2009 02:20:15 -0000	1.34
@@ -2,3 +2,4 @@
 xdriinfo-1.0.2.tar.bz2
 MesaDemos-7.3.tar.bz2
 MesaLib-7.3.tar.bz2
+mesa-20090322.tar.bz2

mesa-7.1-link-shared.patch:

Index: mesa-7.1-link-shared.patch
===================================================================
RCS file: /cvs/pkgs/rpms/mesa/devel/mesa-7.1-link-shared.patch,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- mesa-7.1-link-shared.patch	14 Aug 2008 06:35:21 -0000	1.3
+++ mesa-7.1-link-shared.patch	22 Mar 2009 02:20:15 -0000	1.4
@@ -5,8 +5,8 @@
  
  
  
--default: $(TOP)/$(LIB_DIR) subdirs
-+default: $(TOP)/$(LIB_DIR) $(TOP)/$(LIB_DIR)/libdricore.so subdirs
+-default: $(TOP)/$(LIB_DIR) subdirs dri.pc
++default: $(TOP)/$(LIB_DIR) $(TOP)/$(LIB_DIR)/libdricore.so subdirs dri.pc
  
  
  $(TOP)/$(LIB_DIR):
@@ -58,8 +58,8 @@
  
  $(LIBNAME): $(OBJECTS) $(MESA_MODULES) $(WINOBJ) Makefile $(TOP)/src/mesa/drivers/dri/Makefile.template
  	$(MKLIB) -o $@ -noprefix -linker '$(CC)' -ldflags '$(LDFLAGS)' \
--		$(OBJECTS) $(MESA_MODULES) $(WINOBJ) $(DRI_LIB_DEPS)
-+		$(OBJECTS) $(WINOBJ) \
+-		$(OBJECTS) $(PIPE_DRIVERS) $(MESA_MODULES) $(WINOBJ) $(DRI_LIB_DEPS)
++		$(OBJECTS) $(PIPE_DRIVERS) $(WINOBJ) \
 +		-L$(TOP)/$(LIB_DIR) -Wl,-R$(DRI_DRIVER_INSTALL_DIR) -ldricore \
 +		$(DRI_LIB_DEPS)
  

mesa-7.1-nukeglthread-debug.patch:

Index: mesa-7.1-nukeglthread-debug.patch
===================================================================
RCS file: /cvs/pkgs/rpms/mesa/devel/mesa-7.1-nukeglthread-debug.patch,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- mesa-7.1-nukeglthread-debug.patch	27 Feb 2009 09:41:56 -0000	1.3
+++ mesa-7.1-nukeglthread-debug.patch	22 Mar 2009 02:20:15 -0000	1.4
@@ -13,12 +13,3 @@
     /* point the renderbufer's region to the texture image region */
     intel_image = intel_texture_image(newImage);
     if (irb->region != intel_image->mt->region) {
-@@ -674,8 +669,6 @@ intel_finish_render_texture(GLcontext * 
- {
-    struct intel_renderbuffer *irb = intel_renderbuffer(att->Renderbuffer);
- 
--   DBG("End render texture (tid %x) tex %u\n", _glthread_GetID(), att->Texture->Name);
--
-    if (irb) {
-       /* just release the region */
-       intel_region_release(&irb->region);


Index: mesa.spec
===================================================================
RCS file: /cvs/pkgs/rpms/mesa/devel/mesa.spec,v
retrieving revision 1.231
retrieving revision 1.232
diff -u -r1.231 -r1.232
--- mesa.spec	19 Mar 2009 15:23:12 -0000	1.231
+++ mesa.spec	22 Mar 2009 02:20:15 -0000	1.232
@@ -14,41 +14,38 @@
 
 %define manpages gl-manpages-1.0.1
 %define xdriinfo xdriinfo-1.0.2
-%define gitdate 20081220
+%define gitdate 20090322
 #% define snapshot 
 
 Summary: Mesa graphics libraries
 Name: mesa
-Version: 7.3
-Release: 13%{?dist}
+Version: 7.5
+Release: 0.1%{?dist}
 License: MIT
 Group: System Environment/Libraries
 URL: http://www.mesa3d.org
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
-Source0: http://downloads.sf.net/mesa3d/MesaLib-%{version}.tar.bz2
-Source1: http://downloads.sf.net/mesa3d/MesaDemos-%{version}.tar.bz2
+#Source0: http://downloads.sf.net/mesa3d/MesaLib-%{version}.tar.bz2
 #Source0: http://www.mesa3d.org/beta/MesaLib-%{version}%{?snapshot}.tar.bz2
 #Source1: http://www.mesa3d.org/beta/MesaDemos-%{version}%{?snapshot}.tar.bz2
-#Source0: %{name}-%{gitdate}.tar.bz2
+Source0: %{name}-%{gitdate}.tar.bz2
+#Source1: http://downloads.sf.net/mesa3d/MesaDemos-%{version}.tar.bz2
 Source2: %{manpages}.tar.bz2
 Source3: make-git-snapshot.sh
 
 Source5: http://www.x.org/pub/individual/app/%{xdriinfo}.tar.bz2
 
-Patch0: mesa-7.3-fixes-from-7.4-branch.patch
 Patch1: mesa-7.1-osmesa-version.patch
 Patch2: mesa-7.1-nukeglthread-debug.patch
 Patch3: mesa-no-mach64.patch
 
-Patch5: mesa-7.3-dri-configs-fixes.patch
 Patch6: radeon-rewrite.patch
 
 Patch7: mesa-7.1-link-shared.patch
 Patch9: intel-revert-vbl.patch
 
 Patch12: mesa-7.1-disable-intel-classic-warn.patch
-Patch13: mesa-7.3-965-texture-size.patch
 
 BuildRequires: pkgconfig autoconf automake
 %if %{with_dri}
@@ -167,18 +164,15 @@
 
 
 %prep
-%setup -q -n Mesa-%{version}%{?snapshot} -b0 -b1 -b2 -b5
-#%setup -q -n mesa-%{gitdate} -b2 -b5
-%patch0 -p1 -b .mesa74
+#%setup -q -n mesa-%{version}%{?snapshot} -b0 -b2 -b5
+%setup -q -n mesa-%{gitdate} -b2 -b5
 %patch1 -p1 -b .osmesa
 %patch2 -p1 -b .intel-glthread
 %patch3 -p0 -b .no-mach64
-%patch5 -p1 -b .driconfigs
 %patch6 -p1 -b .radeon-rewrite
 %patch7 -p1 -b .dricore
 %patch9 -p1 -b .intel-vbl
 %patch12 -p1 -b .intel-nowarn
-%patch13 -p1 -b .965-texture
 
 # Hack the demos to use installed data files
 sed -i 's,../images,%{_libdir}/mesa-demos-data,' progs/demos/*.c
@@ -225,6 +219,7 @@
 %configure %{common_flags} \
     --disable-glw \
     --disable-glut \
+    --disable-gallium \
     --disable-gl-osmesa \
     --with-driver=%{driver} \
     --with-dri-driverdir=%{_libdir}/dri
@@ -262,7 +257,11 @@
 
 # strip out undesirable headers
 pushd $RPM_BUILD_ROOT%{_includedir}/GL 
-rm [a-fh-np-wyz]*.h gg*.h glf*.h
+rm [a-fh-np-wyz]*.h gg*.h glf*.h glew.h glut*.h glxew.h
+popd
+
+pushd $RPM_BUILD_ROOT%{_libdir}
+rm libEGL* demodriver.so
 popd
 
 # XXX demos, since they don't install automatically.  should fix that.
@@ -419,6 +418,7 @@
 %{_bindir}/texdown
 %{_bindir}/texenv
 %{_bindir}/texobj
+%{_bindir}/textures
 %{_bindir}/trispd
 %{_bindir}/tunnel
 %{_bindir}/tunnel2
@@ -427,6 +427,10 @@
 %{_libdir}/mesa-demos-data
 
 %changelog
+* Fri Mar 20 2009 Dave Airlie <airlied at redhat.com> 7.5-0.1
+- bump to snapshot of mesa master
+- mainly has intel dri2 tfp fixes + radeon rewrite patch
+
 * Thu Mar 19 2009 Orion Poplawski <orion at cora.nwra.com> 7.3-13
 - Update libdrm requirement to >= 2.4.3 to match source
 

radeon-rewrite.patch:

View full diff with command:
/usr/bin/cvs -f diff  -kk -u -N -r 1.9 -r 1.10 radeon-rewrite.patch
Index: radeon-rewrite.patch
===================================================================
RCS file: /cvs/pkgs/rpms/mesa/devel/radeon-rewrite.patch,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- radeon-rewrite.patch	10 Mar 2009 01:07:15 -0000	1.9
+++ radeon-rewrite.patch	22 Mar 2009 02:20:15 -0000	1.10
@@ -1,53 +1,5 @@
-commit 2ea80bec3da9c62a3abc1d88b0edf9d2f1c9f258
-Author: Dave Airlie <airlied at redhat.com>
-Date:   Tue Mar 10 11:01:57 2009 +1000
-
-    r200: add hw clears
-
-commit 6c28708e141d047fc44369eac08cfb9a47f22c87
-Author: Dave Airlie <airlied at redhat.com>
-Date:   Mon Mar 9 13:51:39 2009 +1000
-
-    radeon/r200/r300: update from latest radeon-rewrite branch
-
-commit 38262b6fc16f627a66e1475b729047ffe8258803
-Author: Dave Airlie <airlied at redhat.com>
-Date:   Mon Mar 9 13:46:44 2009 +1000
-
-    r300: remove some links
-
-commit 263b887d85e3eac9a32673c8ed3004c3129ce997
-Author: Dave Airlie <airlied at redhat.com>
-Date:   Sun Feb 15 17:03:47 2009 +1000
-
-    radeon: add cflags to decide whether to link libdrm_radeon or not.
-    
-    You don't need libdrm_radeon for the legacy driver to build,
-    only for the experimental mm/cs paths.
-
-commit 61e6b2aee3069700db397f26d7ae1384641367ff
-Author: Ian Romanick <idr at freedesktop.org>
-Date:   Fri Jan 9 15:43:17 2009 -0800
-
-    Track two sets of back-face stencil state
-    
-    Track separate back-face stencil state for OpenGL 2.0 /
-    GL_ATI_separate_stencil and GL_EXT_stencil_two_side.  This allows all
-    three to be enabled in a driver.  One set of state is set via the 2.0
-    or ATI functions and is used when STENCIL_TEST_TWO_SIDE_EXT is
-    disabled.  The other is set by StencilFunc and StencilOp when the
-    active stencil face is set to BACK.  The GL_EXT_stencil_two_side spec has
-    more details.
-    
-    http://opengl.org/registry/specs/EXT/stencil_two_side.txt
-
-commit 86691da4b5f43be625ec510b7fe40657b9985783
-Author: Dave Airlie <airlied at redhat.com>
-Date:   Wed Mar 4 16:51:14 2009 +1000
-
-    radeon/r100/r200: import latest merge
 diff --git a/configs/autoconf.in b/configs/autoconf.in
-index 4a89716..f18d119 100644
+index b61d7f3..0f9306d 100644
 --- a/configs/autoconf.in
 +++ b/configs/autoconf.in
 @@ -20,6 +20,8 @@ CXXFLAGS = @CPPFLAGS@ @CXXFLAGS@ \
@@ -58,21 +10,21 @@
 +RADEON_LDFLAGS = @RADEON_LDFLAGS@
  
  # Assembler
- ASM_SOURCES = @ASM_SOURCES@
+ MESA_ASM_SOURCES = @MESA_ASM_SOURCES@
 diff --git a/configure.ac b/configure.ac
-index 73caf00..48f4eac 100644
+index 46070fd..4164d37 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -413,6 +413,8 @@ AC_SUBST([SRC_DIRS])
- AC_SUBST([GLU_DIRS])
- AC_SUBST([DRIVER_DIRS])
- AC_SUBST([WINDOW_SYSTEM])
+@@ -456,6 +456,8 @@ AC_SUBST([GALLIUM_WINSYS_DRM_DIRS])
+ AC_SUBST([GALLIUM_DRIVERS_DIRS])
+ AC_SUBST([GALLIUM_AUXILIARY_DIRS])
+ AC_SUBST([GALLIUM_STATE_TRACKERS_DIRS])
 +AC_SUBST([RADEON_CFLAGS])
 +AC_SUBST([RADEON_LDFLAGS])
  
  dnl
  dnl User supplied program configuration
-@@ -540,6 +542,13 @@ dri)
+@@ -583,6 +585,13 @@ dri)
      GL_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED dri2proto >= $DRI2PROTO_REQUIRED"
      DRI_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED"
  
@@ -86,53 +38,6 @@
      # find the DRI deps for libGL
      if test "$x11_pkgconfig" = yes; then
          # add xcb modules if necessary
-diff --git a/src/mesa/drivers/dri/i965/brw_cc.c b/src/mesa/drivers/dri/i965/brw_cc.c
-index fa8121e..abae4b3 100644
---- a/src/mesa/drivers/dri/i965/brw_cc.c
-+++ b/src/mesa/drivers/dri/i965/brw_cc.c
-@@ -84,6 +84,7 @@ static void
- cc_unit_populate_key(struct brw_context *brw, struct brw_cc_unit_key *key)
- {
-    struct gl_stencil_attrib *stencil = brw->attribs.Stencil;
-+   const unsigned back = stencil->_BackFace;
- 
-    memset(key, 0, sizeof(*key));
- 
-@@ -100,13 +101,13 @@ cc_unit_populate_key(struct brw_context *brw, struct brw_cc_unit_key *key)
-       key->stencil_test_mask[0] = stencil->ValueMask[0];
-    }
-    if (key->stencil_two_side) {
--      key->stencil_func[1] = stencil->Function[1];
--      key->stencil_fail_op[1] = stencil->FailFunc[1];
--      key->stencil_pass_depth_fail_op[1] = stencil->ZFailFunc[1];
--      key->stencil_pass_depth_pass_op[1] = stencil->ZPassFunc[1];
--      key->stencil_ref[1] = stencil->Ref[1];
--      key->stencil_write_mask[1] = stencil->WriteMask[1];
--      key->stencil_test_mask[1] = stencil->ValueMask[1];
-+      key->stencil_func[1] = stencil->Function[back];
-+      key->stencil_fail_op[1] = stencil->FailFunc[back];
-+      key->stencil_pass_depth_fail_op[1] = stencil->ZFailFunc[back];
-+      key->stencil_pass_depth_pass_op[1] = stencil->ZPassFunc[back];
-+      key->stencil_ref[1] = stencil->Ref[back];
-+      key->stencil_write_mask[1] = stencil->WriteMask[back];
-+      key->stencil_test_mask[1] = stencil->ValueMask[back];
-    }
- 
-    if (brw->attribs.Color->_LogicOpEnabled)
-diff --git a/src/mesa/drivers/dri/i965/brw_wm.c b/src/mesa/drivers/dri/i965/brw_wm.c
-index c50b0d2..24149cf 100644
---- a/src/mesa/drivers/dri/i965/brw_wm.c
-+++ b/src/mesa/drivers/dri/i965/brw_wm.c
-@@ -189,8 +189,7 @@ static void brw_wm_populate_key( struct brw_context *brw,
-       lookup |= IZ_STENCIL_TEST_ENABLE_BIT;
- 
-       if (brw->attribs.Stencil->WriteMask[0] ||
--	  (brw->attribs.Stencil->_TestTwoSide &&
--	   brw->attribs.Stencil->WriteMask[1]))
-+	  brw->attribs.Stencil->WriteMask[brw->attribs.Stencil->_BackFace])
- 	 lookup |= IZ_STENCIL_WRITE_ENABLE_BIT;
-    }
- 
 diff --git a/src/mesa/drivers/dri/r200/Makefile b/src/mesa/drivers/dri/r200/Makefile
 index e9144ac..e593ed9 100644
 --- a/src/mesa/drivers/dri/r200/Makefile
@@ -830,7 +735,7 @@
 -   cmd[0].wait.flags = flags;
 -}
 diff --git a/src/mesa/drivers/dri/r200/r200_context.c b/src/mesa/drivers/dri/r200/r200_context.c
-index 5531e0a..10a6362 100644
+index c067515..10a6362 100644
 --- a/src/mesa/drivers/dri/r200/r200_context.c
 +++ b/src/mesa/drivers/dri/r200/r200_context.c
 @@ -54,7 +54,6 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -841,24 +746,16 @@
  #include "r200_pixel.h"
  #include "r200_tex.h"
  #include "r200_swtcl.h"
-@@ -62,14 +61,12 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+@@ -62,6 +61,8 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  #include "r200_maos.h"
  #include "r200_vertprog.h"
  
--#define need_GL_ARB_multisample
--#define need_GL_ARB_texture_compression
--#define need_GL_ARB_vertex_buffer_object
 +#include "radeon_span.h"
 +
  #define need_GL_ARB_vertex_program
  #define need_GL_ATI_fragment_shader
  #define need_GL_EXT_blend_minmax
- #define need_GL_EXT_fog_coord
--#define need_GL_EXT_multi_draw_arrays
- #define need_GL_EXT_secondary_color
- #define need_GL_EXT_blend_equation_separate
- #define need_GL_EXT_blend_func_separate
-@@ -82,9 +79,6 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+@@ -78,9 +79,6 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  #include "vblank.h"
  #include "utils.h"
  #include "xmlpool.h" /* for symbolic values of enum-type options */
@@ -868,7 +765,7 @@
  
  /* Return various strings for glGetString().
   */
-@@ -93,8 +87,8 @@ static const GLubyte *r200GetString( GLcontext *ctx, GLenum name )
+@@ -89,8 +87,8 @@ static const GLubyte *r200GetString( GLcontext *ctx, GLenum name )
     r200ContextPtr rmesa = R200_CONTEXT(ctx);
     static char buffer[128];
     unsigned   offset;
@@ -879,7 +776,7 @@
  
     switch ( name ) {
     case GL_VENDOR:
-@@ -105,7 +99,7 @@ static const GLubyte *r200GetString( GLcontext *ctx, GLenum name )
+@@ -101,7 +99,7 @@ static const GLubyte *r200GetString( GLcontext *ctx, GLenum name )
  				     agp_mode );
  
        sprintf( & buffer[ offset ], " %sTCL",
[...3332 lines suppressed...]
-           ctx->Stencil.ValueMask[face] == mask &&
-           ctx->Stencil.Ref[face] == ref)
-@@ -218,9 +202,12 @@ _mesa_StencilFunc( GLenum func, GLint ref, GLuint mask )
-       ctx->Stencil.Function[face] = func;
-       ctx->Stencil.Ref[face] = ref;
-       ctx->Stencil.ValueMask[face] = mask;
--      if (ctx->Driver.StencilFuncSeparate) {
--         ctx->Driver.StencilFuncSeparate(ctx, face ? GL_BACK : GL_FRONT,
--                                         func, ref, mask);
-+
-+      /* Only propagate the change to the driver if EXT_stencil_two_side
-+       * is enabled.
-+       */
-+      if (ctx->Driver.StencilFuncSeparate && ctx->Stencil.TestTwoSide) {
-+         ctx->Driver.StencilFuncSeparate(ctx, GL_BACK, func, ref, mask);
-       }
-    }
-    else {
-@@ -237,7 +224,9 @@ _mesa_StencilFunc( GLenum func, GLint ref, GLuint mask )
-       ctx->Stencil.Ref[0]       = ctx->Stencil.Ref[1]       = ref;
-       ctx->Stencil.ValueMask[0] = ctx->Stencil.ValueMask[1] = mask;
-       if (ctx->Driver.StencilFuncSeparate) {
--         ctx->Driver.StencilFuncSeparate(ctx, GL_FRONT_AND_BACK,
-+         ctx->Driver.StencilFuncSeparate(ctx,
-+					 ((ctx->Stencil.TestTwoSide)
-+					  ? GL_FRONT : GL_FRONT_AND_BACK),
-                                          func, ref, mask);
-       }
-    }
-@@ -259,17 +248,23 @@ void GLAPIENTRY
- _mesa_StencilMask( GLuint mask )
- {
-    GET_CURRENT_CONTEXT(ctx);
-+   const GLint face = ctx->Stencil.ActiveFace;
-+
-    ASSERT_OUTSIDE_BEGIN_END(ctx);
- 
--   if (ctx->Extensions.EXT_stencil_two_side) {
--      /* only set active face state */
--      const GLint face = ctx->Stencil.ActiveFace;
-+   if (face != 0) {
-+      /* Only modify the EXT_stencil_two_side back-face state.
-+       */
-       if (ctx->Stencil.WriteMask[face] == mask)
-          return;
-       FLUSH_VERTICES(ctx, _NEW_STENCIL);
-       ctx->Stencil.WriteMask[face] = mask;
--      if (ctx->Driver.StencilMaskSeparate) {
--         ctx->Driver.StencilMaskSeparate(ctx, face ? GL_BACK : GL_FRONT, mask);
-+
-+      /* Only propagate the change to the driver if EXT_stencil_two_side
-+       * is enabled.
-+       */
-+      if (ctx->Driver.StencilMaskSeparate && ctx->Stencil.TestTwoSide) {
-+         ctx->Driver.StencilMaskSeparate(ctx, GL_BACK, mask);
-       }
-    }
-    else {
-@@ -280,7 +275,10 @@ _mesa_StencilMask( GLuint mask )
-       FLUSH_VERTICES(ctx, _NEW_STENCIL);
-       ctx->Stencil.WriteMask[0] = ctx->Stencil.WriteMask[1] = mask;
-       if (ctx->Driver.StencilMaskSeparate) {
--         ctx->Driver.StencilMaskSeparate(ctx, GL_FRONT_AND_BACK, mask);
-+         ctx->Driver.StencilMaskSeparate(ctx,
-+					 ((ctx->Stencil.TestTwoSide)
-+					  ? GL_FRONT : GL_FRONT_AND_BACK),
-+					  mask);
-       }
-    }
- }
-@@ -304,6 +302,8 @@ void GLAPIENTRY
- _mesa_StencilOp(GLenum fail, GLenum zfail, GLenum zpass)
- {
-    GET_CURRENT_CONTEXT(ctx);
-+   const GLint face = ctx->Stencil.ActiveFace;
-+
-    ASSERT_OUTSIDE_BEGIN_END(ctx);
- 
-    if (!validate_stencil_op(ctx, fail)) {
-@@ -319,9 +319,8 @@ _mesa_StencilOp(GLenum fail, GLenum zfail, GLenum zpass)
-       return;
-    }
- 
--   if (ctx->Extensions.EXT_stencil_two_side) {
-+   if (face != 0) {
-       /* only set active face state */
--      const GLint face = ctx->Stencil.ActiveFace;
-       if (ctx->Stencil.ZFailFunc[face] == zfail &&
-           ctx->Stencil.ZPassFunc[face] == zpass &&
-           ctx->Stencil.FailFunc[face] == fail)
-@@ -330,9 +329,12 @@ _mesa_StencilOp(GLenum fail, GLenum zfail, GLenum zpass)
-       ctx->Stencil.ZFailFunc[face] = zfail;
-       ctx->Stencil.ZPassFunc[face] = zpass;
-       ctx->Stencil.FailFunc[face] = fail;
--      if (ctx->Driver.StencilOpSeparate) {
--         ctx->Driver.StencilOpSeparate(ctx, face ? GL_BACK : GL_FRONT,
--                                       fail, zfail, zpass);
-+
-+      /* Only propagate the change to the driver if EXT_stencil_two_side
-+       * is enabled.
-+       */
-+      if (ctx->Driver.StencilOpSeparate && ctx->Stencil.TestTwoSide) {
-+         ctx->Driver.StencilOpSeparate(ctx, GL_BACK, fail, zfail, zpass);
-       }
-    }
-    else {
-@@ -349,7 +351,9 @@ _mesa_StencilOp(GLenum fail, GLenum zfail, GLenum zpass)
-       ctx->Stencil.ZPassFunc[0] = ctx->Stencil.ZPassFunc[1] = zpass;
-       ctx->Stencil.FailFunc[0]  = ctx->Stencil.FailFunc[1]  = fail;
-       if (ctx->Driver.StencilOpSeparate) {
--         ctx->Driver.StencilOpSeparate(ctx, GL_FRONT_AND_BACK,
-+         ctx->Driver.StencilOpSeparate(ctx,
-+				       ((ctx->Stencil.TestTwoSide)
-+					? GL_FRONT : GL_FRONT_AND_BACK),
-                                        fail, zfail, zpass);
-       }
-    }
-@@ -372,7 +376,7 @@ _mesa_ActiveStencilFaceEXT(GLenum face)
- 
-    if (face == GL_FRONT || face == GL_BACK) {
-       FLUSH_VERTICES(ctx, _NEW_STENCIL);
--      ctx->Stencil.ActiveFace = (face == GL_FRONT) ? 0 : 1;
-+      ctx->Stencil.ActiveFace = (face == GL_FRONT) ? 0 : 2;
-    }
-    else {
-       _mesa_error(ctx, GL_INVALID_ENUM, "glActiveStencilFaceEXT(face)");
-@@ -513,19 +517,16 @@ _mesa_StencilMaskSeparate(GLenum face, GLuint mask)
- void
- _mesa_update_stencil(GLcontext *ctx)
- {
--   if (ctx->Extensions.EXT_stencil_two_side) {
--      ctx->Stencil._TestTwoSide = ctx->Stencil.TestTwoSide;
--   }
--   else {
--      ctx->Stencil._TestTwoSide = 
--         (ctx->Stencil.Function[0] != ctx->Stencil.Function[1] ||
--          ctx->Stencil.FailFunc[0] != ctx->Stencil.FailFunc[1] ||
--          ctx->Stencil.ZPassFunc[0] != ctx->Stencil.ZPassFunc[1] ||
--          ctx->Stencil.ZFailFunc[0] != ctx->Stencil.ZFailFunc[1] ||
--          ctx->Stencil.Ref[0] != ctx->Stencil.Ref[1] ||
--          ctx->Stencil.ValueMask[0] != ctx->Stencil.ValueMask[1] ||
--          ctx->Stencil.WriteMask[0] != ctx->Stencil.WriteMask[1]);
--   }
-+   const GLint face = ctx->Stencil._BackFace;
-+
-+   ctx->Stencil._TestTwoSide =
-+       (ctx->Stencil.Function[0] != ctx->Stencil.Function[face] ||
-+	ctx->Stencil.FailFunc[0] != ctx->Stencil.FailFunc[face] ||
-+	ctx->Stencil.ZPassFunc[0] != ctx->Stencil.ZPassFunc[face] ||
-+	ctx->Stencil.ZFailFunc[0] != ctx->Stencil.ZFailFunc[face] ||
-+	ctx->Stencil.Ref[0] != ctx->Stencil.Ref[face] ||
-+	ctx->Stencil.ValueMask[0] != ctx->Stencil.ValueMask[face] ||
-+	ctx->Stencil.WriteMask[0] != ctx->Stencil.WriteMask[face]);
- }
- 
- 
-@@ -544,17 +545,24 @@ _mesa_init_stencil(GLcontext *ctx)
-    ctx->Stencil.ActiveFace = 0;  /* 0 = GL_FRONT, 1 = GL_BACK */
-    ctx->Stencil.Function[0] = GL_ALWAYS;
-    ctx->Stencil.Function[1] = GL_ALWAYS;
-+   ctx->Stencil.Function[2] = GL_ALWAYS;
-    ctx->Stencil.FailFunc[0] = GL_KEEP;
-    ctx->Stencil.FailFunc[1] = GL_KEEP;
-+   ctx->Stencil.FailFunc[2] = GL_KEEP;
-    ctx->Stencil.ZPassFunc[0] = GL_KEEP;
-    ctx->Stencil.ZPassFunc[1] = GL_KEEP;
-+   ctx->Stencil.ZPassFunc[2] = GL_KEEP;
-    ctx->Stencil.ZFailFunc[0] = GL_KEEP;
-    ctx->Stencil.ZFailFunc[1] = GL_KEEP;
-+   ctx->Stencil.ZFailFunc[2] = GL_KEEP;
-    ctx->Stencil.Ref[0] = 0;
-    ctx->Stencil.Ref[1] = 0;
-+   ctx->Stencil.Ref[2] = 0;
-    ctx->Stencil.ValueMask[0] = ~0U;
-    ctx->Stencil.ValueMask[1] = ~0U;
-+   ctx->Stencil.ValueMask[2] = ~0U;
-    ctx->Stencil.WriteMask[0] = ~0U;
-    ctx->Stencil.WriteMask[1] = ~0U;
-+   ctx->Stencil.WriteMask[2] = ~0U;
-    ctx->Stencil.Clear = 0;
- }
-diff --git a/src/mesa/swrast/s_stencil.c b/src/mesa/swrast/s_stencil.c
-index c925922..2e84dde 100644
---- a/src/mesa/swrast/s_stencil.c
-+++ b/src/mesa/swrast/s_stencil.c
-@@ -997,10 +997,12 @@ stencil_and_ztest_pixels( GLcontext *ctx, SWspan *span, GLuint face )
- GLboolean
- _swrast_stencil_and_ztest_span(GLcontext *ctx, SWspan *span)
- {
-+   const GLuint face = (span->facing == 0) ? 0 : ctx->Stencil._BackFace;
-+
-    if (span->arrayMask & SPAN_XY)
--      return stencil_and_ztest_pixels(ctx, span, span->facing);
-+      return stencil_and_ztest_pixels(ctx, span, face);
-    else
--      return stencil_and_ztest_span(ctx, span, span->facing);
-+      return stencil_and_ztest_span(ctx, span, face);
- }
- 
- 


Index: sources
===================================================================
RCS file: /cvs/pkgs/rpms/mesa/devel/sources,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -r1.33 -r1.34
--- sources	8 Feb 2009 08:01:38 -0000	1.33
+++ sources	22 Mar 2009 02:20:16 -0000	1.34
@@ -1,4 +1,3 @@
 6ae05158e678f4594343f32c2ca50515  gl-manpages-1.0.1.tar.bz2
 a5ec51ed9f0a55dc3462d90d52ff899c  xdriinfo-1.0.2.tar.bz2
-3f0741394069bdf2329565a387396cda  MesaDemos-7.3.tar.bz2
-781e7811a6ed5c97b2b8defefc8ffbc9  MesaLib-7.3.tar.bz2
+2469ad7640d26d1aed61452cfe62fd49  mesa-20090322.tar.bz2


--- mesa-7.3-fixes-from-7.4-branch.patch DELETED ---




More information about the fedora-extras-commits mailing list