summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri/r200/r200_context.h
diff options
context:
space:
mode:
authorRoland Scheidegger <rscheidegger@gmx.ch>2006-10-13 22:10:05 +0000
committerRoland Scheidegger <rscheidegger@gmx.ch>2006-10-13 22:10:05 +0000
commitcb977ae5f4c9fab5753c04bfdd8736978ad4feee (patch)
tree1f38b694427bb1021da66f6dee020af67b880c3d /src/mesa/drivers/dri/r200/r200_context.h
parent40b88fd1f3dedd0137b170a7272854e2bf4c3210 (diff)
implement ARB_point_parameters and ARB_point_sprite on r200. The code is nearly the same as outlined in bug #4707, except it disables perspective correction for point sprites to make them actually work. And, separate the state atom into two as the tcl parameters would overwrite vertex program parameters when active. Also implement the GL_VERTEX_PROGRAM_POINT_SIZE_ARB option to make vertex programs outputting a point size work correctly (untested). Smooth points will still always be size 1. While here, enable gouraud shading for fog when using fog coord.
Diffstat (limited to 'src/mesa/drivers/dri/r200/r200_context.h')
-rw-r--r--src/mesa/drivers/dri/r200/r200_context.h27
1 files changed, 24 insertions, 3 deletions
diff --git a/src/mesa/drivers/dri/r200/r200_context.h b/src/mesa/drivers/dri/r200/r200_context.h
index b7ee33aa6c..0d252eceaf 100644
--- a/src/mesa/drivers/dri/r200/r200_context.h
+++ b/src/mesa/drivers/dri/r200/r200_context.h
@@ -445,9 +445,29 @@ struct r200_state_atom {
/* SPR - point sprite state
*/
-#define SPR_CMD_0 0
-#define SPR_POINT_SPRITE_CNTL 1
-#define SPR_STATE_SIZE 2
+#define SPR_CMD_0 0
+#define SPR_POINT_SPRITE_CNTL 1
+#define SPR_STATE_SIZE 2
+
+#define PTP_CMD_0 0
+#define PTP_VPORT_SCALE_0 1
+#define PTP_VPORT_SCALE_1 2
+#define PTP_VPORT_SCALE_PTSIZE 3
+#define PTP_VPORT_SCALE_3 4
+#define PTP_CMD_1 5
+#define PTP_ATT_CONST_QUAD 6
+#define PTP_ATT_CONST_LIN 7
+#define PTP_ATT_CONST_CON 8
+#define PTP_ATT_CONST_3 9
+#define PTP_EYE_X 10
+#define PTP_EYE_Y 11
+#define PTP_EYE_Z 12
+#define PTP_EYE_3 13
+#define PTP_CLAMP_MIN 14
+#define PTP_CLAMP_MAX 15
+#define PTP_CLAMP_2 16
+#define PTP_CLAMP_3 17
+#define PTP_STATE_SIZE 18
#define VTX_COLOR(v,n) (((v)>>(R200_VTX_COLOR_0_SHIFT+(n)*2))&\
R200_VTX_COLOR_MASK)
@@ -614,6 +634,7 @@ struct r200_hw_state {
struct r200_state_atom vpp[2];
struct r200_state_atom atf;
struct r200_state_atom spr;
+ struct r200_state_atom ptp;
int max_state_size; /* Number of bytes necessary for a full state emit. */
GLboolean is_dirty, all_dirty;