/*
* Authors:
- * Keith Whitwell <keith@tungstengraphics.com>
+ * Keith Whitwell <keithw@vmware.com>
*/
#ifndef __R200_CONTEXT_H__
#include "drm.h"
#include "radeon_drm.h"
#include "dri_util.h"
-#include "texmem.h"
#include "main/macros.h"
#include "main/mtypes.h"
#include "r200_reg.h"
#include "r200_vertprog.h"
-#define ENABLE_HW_3D_TEXTURE 1 /* XXX this is temporary! */
-
#ifndef R200_EMIT_VAP_PVS_CNTL
#error This driver requires a newer libdrm to compile
#endif
#include "radeon_screen.h"
#include "radeon_common.h"
-#include "radeon_lock.h"
-
struct r200_context;
typedef struct r200_context r200ContextRec;
typedef struct r200_context *r200ContextPtr;
#define CST_RB3D_DEPTHXY_OFFSET 3
#define CST_CMD_2 4
#define CST_RE_AUX_SCISSOR_CNTL 5
-#define CST_CMD_3 6
-#define CST_RE_SCISSOR_TL_0 7
-#define CST_RE_SCISSOR_BR_0 8
-#define CST_CMD_4 9
-#define CST_SE_VAP_CNTL_STATUS 10
-#define CST_CMD_5 11
-#define CST_RE_POINTSIZE 12
-#define CST_CMD_6 13
-#define CST_SE_TCL_INPUT_VTX_0 14
-#define CST_SE_TCL_INPUT_VTX_1 15
-#define CST_SE_TCL_INPUT_VTX_2 16
-#define CST_SE_TCL_INPUT_VTX_3 17
-#define CST_STATE_SIZE 18
+#define CST_CMD_4 6
+#define CST_SE_VAP_CNTL_STATUS 7
+#define CST_CMD_5 8
+#define CST_RE_POINTSIZE 9
+#define CST_CMD_6 10
+#define CST_SE_TCL_INPUT_VTX_0 11
+#define CST_SE_TCL_INPUT_VTX_1 12
+#define CST_SE_TCL_INPUT_VTX_2 13
+#define CST_SE_TCL_INPUT_VTX_3 14
+#define CST_STATE_SIZE 15
#define PRF_CMD_0 0
#define PRF_PP_TRI_PERF 1
#define PRF_STATE_SIZE 3
-#define SCI_CMD_0 0
-#define SCI_RE_AUX 1
-#define SCI_CMD_1 2
-#define SCI_XY_1 3
-#define SCI_CMD_2 4
-#define SCI_XY_2 5
-#define SCI_STATE_SIZE 6
+#define SCI_CMD_1 0
+#define SCI_XY_1 1
+#define SCI_CMD_2 2
+#define SCI_XY_2 3
+#define SCI_STATE_SIZE 4
#define R200_QUERYOBJ_CMD_0 0
#define R200_QUERYOBJ_DATA_0 1
struct ati_fragment_shader *afs_loaded;
};
-#define R200_CONTEXT(ctx) ((r200ContextPtr)(ctx->DriverCtx))
+
+static inline r200ContextPtr
+R200_CONTEXT(struct gl_context *ctx)
+{
+ return (r200ContextPtr) ctx;
+}
extern void r200DestroyContext( __DRIcontext *driContextPriv );
extern GLboolean r200CreateContext( gl_api api,
- const __GLcontextModes *glVisual,
+ const struct gl_config *glVisual,
__DRIcontext *driContextPriv,
+ unsigned major_version,
+ unsigned minor_version,
+ uint32_t flags,
+ bool notify_reset,
+ unsigned *error,
void *sharedContextPrivate);
extern GLboolean r200MakeCurrent( __DRIcontext *driContextPriv,
__DRIdrawable *driDrawPriv,