aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authorStephane Marchesin <[email protected]>2006-04-14 23:47:45 +0000
committerStephane Marchesin <[email protected]>2006-04-14 23:47:45 +0000
commitb0c4cfed608f21f255b8637ec5ff499fc36ee302 (patch)
treeaa96ab1803f473ec5efa315f5585dc1bbbfa9329 /src/mesa
parent97d11ecd6c5d23f682db5c6ef7dfec89185ae307 (diff)
More work on the tcl code... still have to make my mind on a number of
things
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/nouveau/nouveau_context.h1
-rw-r--r--src/mesa/drivers/dri/nouveau/nouveau_tris.c14
-rw-r--r--src/mesa/drivers/dri/nouveau/nv10_swtcl.c6
-rw-r--r--src/mesa/drivers/dri/nouveau/nv10_swtcl.h1
4 files changed, 14 insertions, 8 deletions
diff --git a/src/mesa/drivers/dri/nouveau/nouveau_context.h b/src/mesa/drivers/dri/nouveau/nouveau_context.h
index e09d804ccf1..c23b633bb93 100644
--- a/src/mesa/drivers/dri/nouveau/nouveau_context.h
+++ b/src/mesa/drivers/dri/nouveau/nouveau_context.h
@@ -92,6 +92,7 @@ typedef struct nouveau_context {
/* Vertex state */
GLuint vertex_size;
+ char *verts;
struct tnl_attr_map vertex_attrs[VERT_ATTRIB_MAX];
GLuint vertex_attr_count;
diff --git a/src/mesa/drivers/dri/nouveau/nouveau_tris.c b/src/mesa/drivers/dri/nouveau/nouveau_tris.c
index 53a18d2f738..8622b9349cb 100644
--- a/src/mesa/drivers/dri/nouveau/nouveau_tris.c
+++ b/src/mesa/drivers/dri/nouveau/nouveau_tris.c
@@ -87,7 +87,7 @@ void nouveauFallback(struct nouveau_context *nmesa, GLuint bit, GLboolean mode)
}
_swsetup_Wakeup(ctx);
- nmesa->renderIndex = ~0;
+ nmesa->render_index = ~0;
}
}
else {
@@ -95,14 +95,18 @@ void nouveauFallback(struct nouveau_context *nmesa, GLuint bit, GLboolean mode)
if (oldfallback == bit) {
_swrast_flush( ctx );
- nouveauInitTriFunctions(ctx);
+ if (nmesa->screen->card_type<NV_10) {
+ //nv03TriInitFunctions(ctx);
+ } else {
+ nv10TriInitFunctions(ctx);
+ }
_tnl_invalidate_vertex_state( ctx, ~0 );
_tnl_invalidate_vertices( ctx, ~0 );
_tnl_install_attrs( ctx,
nmesa->vertex_attrs,
nmesa->vertex_attr_count,
- nmesa->ViewportMatrix.m, 0 );
+ nmesa->viewport.m, 0 );
}
}
}
@@ -112,8 +116,8 @@ void nouveauRunPipeline( GLcontext *ctx )
{
struct nouveau_context *nmesa = NOUVEAU_CONTEXT(ctx);
- if (nmesa->newState) {
- nmesa->newRenderState |= nmesa->newState;
+ if (nmesa->new_state) {
+ nmesa->new_render_state |= nmesa->new_state;
}
_tnl_run_pipeline( ctx );
diff --git a/src/mesa/drivers/dri/nouveau/nv10_swtcl.c b/src/mesa/drivers/dri/nouveau/nv10_swtcl.c
index e04a4ece5e8..9a1748f48ac 100644
--- a/src/mesa/drivers/dri/nouveau/nv10_swtcl.c
+++ b/src/mesa/drivers/dri/nouveau/nv10_swtcl.c
@@ -593,8 +593,8 @@ static void nv10ChooseRenderState(GLcontext *ctx)
index = NOUVEAU_MAX_TRIFUNC; /* flat specular */
}
- if (nmesa->renderIndex != index) {
- nmesa->renderIndex = index;
+ if (nmesa->render_index != index) {
+ nmesa->render_index = index;
tnl->Driver.Render.Points = rast_tab[index].points;
tnl->Driver.Render.Line = rast_tab[index].line;
@@ -792,7 +792,7 @@ static void nv10RenderPrimitive( GLcontext *ctx, GLuint prim )
/* Initialization. */
/**********************************************************************/
-void nouveauTriInitFunctions(GLcontext *ctx)
+void nv10TriInitFunctions(GLcontext *ctx)
{
struct nouveau_context *nmesa = NOUVEAU_CONTEXT(ctx);
TNLcontext *tnl = TNL_CONTEXT(ctx);
diff --git a/src/mesa/drivers/dri/nouveau/nv10_swtcl.h b/src/mesa/drivers/dri/nouveau/nv10_swtcl.h
index fd57eeaa958..03338fbe134 100644
--- a/src/mesa/drivers/dri/nouveau/nv10_swtcl.h
+++ b/src/mesa/drivers/dri/nouveau/nv10_swtcl.h
@@ -34,6 +34,7 @@ USE OR OTHER DEALINGS IN THE SOFTWARE.
extern void nv10Fallback( GLcontext *ctx, GLuint bit, GLboolean mode );
extern void nv10FinishPrimitive(struct nouveau_context *nmesa);
extern void nv10RenderStart(GLcontext *ctx);
+extern void nv10TriInitFunctions(GLcontext *ctx);
#define FALLBACK( nmesa, bit, mode ) nouveauFallback( nmesa->glCtx, bit, mode )
#endif /* __NV10_SWTCL_H__ */