summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri/nouveau/nv30_state.c
diff options
context:
space:
mode:
authorStephane Marchesin <marchesin@icps.u-strasbg.fr>2006-11-18 00:36:22 +0000
committerStephane Marchesin <marchesin@icps.u-strasbg.fr>2006-11-18 00:36:22 +0000
commitae9c633a21a20394f39cd3c8adfa34d212945fae (patch)
tree013c4ac19e1a88e2cb5999112c7141c1258b081d /src/mesa/drivers/dri/nouveau/nv30_state.c
parente722e3480f3a5b975c05b584f9acef222c2c9d6b (diff)
More state functions
Diffstat (limited to 'src/mesa/drivers/dri/nouveau/nv30_state.c')
-rw-r--r--src/mesa/drivers/dri/nouveau/nv30_state.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/nouveau/nv30_state.c b/src/mesa/drivers/dri/nouveau/nv30_state.c
index dffd97b4e5..12a45d3ea9 100644
--- a/src/mesa/drivers/dri/nouveau/nv30_state.c
+++ b/src/mesa/drivers/dri/nouveau/nv30_state.c
@@ -466,7 +466,13 @@ void (*RenderMode)(GLcontext *ctx, GLenum mode );
/** Define the scissor box */
void (*Scissor)(GLcontext *ctx, GLint x, GLint y, GLsizei w, GLsizei h);
/** Select flat or smooth shading */
-void (*ShadeModel)(GLcontext *ctx, GLenum mode);
+void nv30ShadeModel(GLcontext *ctx, GLenum mode)
+{
+ nouveauContextPtr nmesa = NOUVEAU_CONTEXT(ctx);
+
+ BEGIN_RING_SIZE(NvSub3D, NV30_TCL_PRIMITIVE_3D_SHADE_MODEL, 1);
+ OUT_RING(mode);
+}
/** OpenGL 2.0 two-sided StencilFunc */
static void nv30StencilFuncSeparate(GLcontext *ctx, GLenum face, GLenum func,
@@ -579,8 +585,8 @@ void nv30InitStateFuncs(struct dd_function_table *func)
func->ReadBuffer = nv30ReadBuffer;
func->RenderMode = nv30RenderMode;
func->Scissor = nv30Scissor;
- func->ShadeModel = nv30ShaderModel;
#endif
+ func->ShadeModel = nv30ShadeModel;
func->StencilFuncSeparate = nv30StencilFuncSeparate;
func->StencilMaskSeparate = nv30StencilMaskSeparate;
func->StencilOpSeparate = nv30StencilOpSeparate;