Better driver notification on changes.
[mesa.git] / src / mesa / main / rastpos.c
index 23285d02757e1fceb1f08529d608e05784e7eca3..507eb9f98432f0b34575510b557f0a1cc2abcc15 100644 (file)
@@ -466,7 +466,7 @@ raster_pos4f(GLcontext *ctx, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
                                    + ctx->Viewport._WindowMap.m[MAT_TY]);
       ctx->Current.RasterPos[2] = (ndc[2] * ctx->Viewport._WindowMap.m[MAT_SZ]
                                    + ctx->Viewport._WindowMap.m[MAT_TZ])
-                                  / ctx->DepthMaxF;
+                                  / ctx->DrawBuffer->_DepthMaxF;
       ctx->Current.RasterPos[3] = clip[3];
 
       /* compute raster distance */