summaryrefslogtreecommitdiff
path: root/src/mesa/swrast/s_context.h
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2007-05-18 14:14:12 -0700
committerEric Anholt <eric@anholt.net>2007-05-18 14:14:12 -0700
commit1bdee1853627e08894bd267b8f0ec176a1b5978f (patch)
tree78c3b8bb81e866de4544d2621abb633b008095ab /src/mesa/swrast/s_context.h
parentc085e350df593ab2af60f53b86265db4c3eab38a (diff)
parent4fca6bfa5d211a093c54b0bbeadaa38081e8c141 (diff)
Merge branch 'master' into i915-unification
Conflicts: src/mesa/drivers/dri/common/dri_bufmgr.c src/mesa/drivers/dri/common/dri_drmpool.c src/mesa/drivers/dri/i915tex/intel_batchpool.c src/mesa/drivers/dri/i915tex/intel_buffer_objects.c src/mesa/drivers/dri/i915tex/intel_regions.c src/mesa/drivers/dri/i915tex/intel_screen.c src/mesa/drivers/dri/i915tex/intel_screen.h
Diffstat (limited to 'src/mesa/swrast/s_context.h')
-rw-r--r--src/mesa/swrast/s_context.h36
1 files changed, 28 insertions, 8 deletions
diff --git a/src/mesa/swrast/s_context.h b/src/mesa/swrast/s_context.h
index 3a9a48922e..c8333b8e0a 100644
--- a/src/mesa/swrast/s_context.h
+++ b/src/mesa/swrast/s_context.h
@@ -1,8 +1,8 @@
/*
* Mesa 3-D graphics library
- * Version: 6.5.2
+ * Version: 6.5.3
*
- * Copyright (C) 1999-2006 Brian Paul All Rights Reserved.
+ * Copyright (C) 1999-2007 Brian Paul All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
@@ -46,6 +46,7 @@
#include "mtypes.h"
#include "swrast.h"
#include "s_span.h"
+#include "prog_execute.h"
typedef void (*texture_sample_func)(GLcontext *ctx,
@@ -137,12 +138,10 @@ typedef struct
GLbitfield _ColorOutputsMask;
GLuint _NumColorOutputs;
- /** Fragment attributes to compute during rasterization.
- * Mask of FRAG_BIT_* flags.
- */
- GLbitfield _FragmentAttribs;
- GLuint _MinFragmentAttrib; /**< Lowest bit set in _FragmentAttribs */
- GLuint _MaxFragmentAttrib; /**< Highest bit set in _FragmentAttribs + 1 */
+ /** List/array of the fragment attributes to interpolate */
+ GLuint _ActiveAttribs[FRAG_ATTRIB_MAX];
+ /** Number of fragment attributes to interpolate */
+ GLuint _NumActiveAttribs;
/* Accum buffer temporaries.
*/
@@ -222,12 +221,18 @@ typedef struct
validate_texture_image_func ValidateTextureImage;
+ /** State used during execution of fragment programs */
+ struct gl_program_machine FragProgMachine;
+
} SWcontext;
extern void
_swrast_validate_derived( GLcontext *ctx );
+extern void
+_swrast_update_texture_samplers(GLcontext *ctx);
+
#define SWRAST_CONTEXT(ctx) ((SWcontext *)ctx->swrast_context)
@@ -270,4 +275,19 @@ _swrast_validate_derived( GLcontext *ctx );
#define FixedToChan(X) FixedToInt(X)
#endif
+
+/**
+ * For looping over fragment attributes in the pointe, line
+ * triangle rasterizers.
+ */
+#define ATTRIB_LOOP_BEGIN \
+ { \
+ GLuint a; \
+ for (a = 0; a < swrast->_NumActiveAttribs; a++) { \
+ const GLuint attr = swrast->_ActiveAttribs[a];
+
+#define ATTRIB_LOOP_END } }
+
+
+
#endif