diff options
author | Keith Whitwell <[email protected]> | 2004-01-05 09:43:42 +0000 |
---|---|---|
committer | Keith Whitwell <[email protected]> | 2004-01-05 09:43:42 +0000 |
commit | 790734045b69c47b1525fbf9106a7ca5a8eb7416 (patch) | |
tree | 6d071a1bfea29d14bc132414cc62a18e0b5fb51f /src/mesa/tnl/t_context.h | |
parent | effc73931f86c7961b4eb296d2d4c5d91624a9e3 (diff) |
Re-commit t_vertex.[ch] changes to fd.o server.
Diffstat (limited to 'src/mesa/tnl/t_context.h')
-rw-r--r-- | src/mesa/tnl/t_context.h | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/src/mesa/tnl/t_context.h b/src/mesa/tnl/t_context.h index 1d148be214d..ab146b29305 100644 --- a/src/mesa/tnl/t_context.h +++ b/src/mesa/tnl/t_context.h @@ -160,6 +160,7 @@ enum { #define _TNL_BIT_TEX(u) (1 << (_TNL_ATTRIB_TEX0 + (u))) + #define _TNL_BITS_MAT_ANY (_TNL_BIT_MAT_FRONT_AMBIENT | \ _TNL_BIT_MAT_BACK_AMBIENT | \ _TNL_BIT_MAT_FRONT_DIFFUSE | \ @@ -456,6 +457,7 @@ struct tnl_pipeline_stage { * call to 'run'. */ + /* Private data for the pipeline stage: */ void *privatePtr; @@ -494,6 +496,22 @@ struct tnl_pipeline { }; +struct tnl_clipspace_attr { + int attrib; + int vertoffset; + int vertattrsize; + GLfloat *inputptr; + int inputstride; + + void (*insert)( const struct tnl_clipspace_attr *a, + char *v, const GLfloat *input ); + + void (*extract)( const struct tnl_clipspace_attr *a, + GLfloat *output, const char *v ); + + const GLfloat *vp; +}; + typedef void (*points_func)( GLcontext *ctx, GLuint first, GLuint last ); @@ -513,6 +531,26 @@ typedef void (*setup_func)( GLcontext *ctx, GLuint new_inputs); + + +struct tnl_clipspace { + GLboolean need_extras; + + GLuint new_inputs; + + GLubyte *vertex_buf; + GLuint vertex_size; + GLuint max_vertex_size; + + struct tnl_clipspace_attr attr[_TNL_ATTRIB_MAX]; + GLuint attr_count; + + void (*emit)( GLcontext *ctx, GLuint start, GLuint end, void *dest ); + interp_func interp; + copy_pv_func copy_pv; +}; + + struct tnl_device_driver { /*** *** TNL Pipeline @@ -643,6 +681,11 @@ typedef struct { struct tnl_vertex_arrays array_inputs; + /* Clipspace/ndc/window vertex managment: + */ + struct tnl_clipspace clipspace; + + /* Probably need a better configuration mechanism: */ GLboolean NeedNdcCoords; @@ -650,6 +693,10 @@ typedef struct { GLboolean CalcDListNormalLengths; GLboolean IsolateMaterials; + /* + */ + GLuint render_inputs; + GLvertexformat exec_vtxfmt; GLvertexformat save_vtxfmt; |