#ifndef DRI_CONTEXT_H
#define DRI_CONTEXT_H
-#include "pipe/p_compiler.h"
-#include "drm.h"
#include "dri_util.h"
+#include "pipe/p_compiler.h"
+#include "hud/hud_context.h"
struct pipe_context;
struct pipe_fence;
-struct st_context;
+struct st_api;
+struct st_context_iface;
struct dri_drawable;
struct dri_context
__DRIdrawable *dPriv;
__DRIdrawable *rPriv;
- driOptionCache optionCache;
-
- drmLock *lock;
- boolean isLocked;
- boolean stLostLock;
- boolean wsLostLock;
-
unsigned int bind_count;
/* gallium */
+ struct st_api *stapi;
struct st_context_iface *st;
+ struct pp_queue_t *pp;
+ struct hud_context *hud;
};
-static INLINE struct dri_context *
+static inline struct dri_context *
dri_context(__DRIcontext * driContextPriv)
{
+ if (!driContextPriv)
+ return NULL;
return (struct dri_context *)driContextPriv->driverPrivate;
}
__DRIdrawable * driReadPriv);
struct dri_context *
-dri_get_current(void);
+dri_get_current(__DRIscreen * driScreenPriv);
boolean
-dri_create_context(const __GLcontextModes * visual,
- __DRIcontext * driContextPriv,
- void *sharedContextPrivate);
-
-/***********************************************************************
- * dri_extensions.c
- */
-void dri_init_extensions(struct dri_context *ctx);
+dri_create_context(gl_api api,
+ const struct gl_config * visual,
+ __DRIcontext * driContextPriv,
+ const struct __DriverContextConfig *ctx_config,
+ unsigned *error,
+ void *sharedContextPrivate);
#endif