summaryrefslogtreecommitdiffstats
path: root/src/mesa/swrast/s_pointtemp.h
diff options
context:
space:
mode:
authorDaniel Borca <[email protected]>2004-09-13 08:47:01 +0000
committerDaniel Borca <[email protected]>2004-09-13 08:47:01 +0000
commita9ea1628da5f17274cd7ee023f438046dc992073 (patch)
tree23bcf6e863b2e02e9967534aae683b8e93fe992d /src/mesa/swrast/s_pointtemp.h
parente54464e9d3035e3f785bcfaf924e947b522427d6 (diff)
changes towards GL_ARB_point_sprite (two-zero)
Diffstat (limited to 'src/mesa/swrast/s_pointtemp.h')
-rw-r--r--src/mesa/swrast/s_pointtemp.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/mesa/swrast/s_pointtemp.h b/src/mesa/swrast/s_pointtemp.h
index 3686e6a72e8..1cfdf002afd 100644
--- a/src/mesa/swrast/s_pointtemp.h
+++ b/src/mesa/swrast/s_pointtemp.h
@@ -292,7 +292,13 @@ NAME ( GLcontext *ctx, const SWvertex *vert )
if (ctx->Texture.Unit[u]._ReallyEnabled) {
if (ctx->Point.CoordReplace[u]) {
GLfloat s = 0.5F + (x + 0.5F - vert->win[0]) / size;
- GLfloat t = 0.5F - (y + 0.5F - vert->win[1]) / size;
+ GLfloat t;
+#if GL_VERSION_2_0
+ if (ctx->Point.SpriteOrigin == GL_LOWER_LEFT)
+ t = 0.5F + (y + 0.5F - vert->win[1]) / size;
+ else /* GL_UPPER_LEFT */
+#endif
+ t = 0.5F - (y + 0.5F - vert->win[1]) / size;
span->array->texcoords[u][count][0] = s;
span->array->texcoords[u][count][1] = t;
span->array->texcoords[u][count][3] = 1.0F;