#include "eval.h"
#endif
#include "get.h"
-#if FEATURE_feedback
#include "feedback.h"
-#endif
#include "fog.h"
#if FEATURE_EXT_framebuffer_object
#include "fbobject.h"
SET_DepthRange(exec, _mesa_DepthRange);
_mesa_init_drawpix_dispatch(exec);
+ _mesa_init_feedback_dispatch(exec);
-#if FEATURE_feedback
- SET_InitNames(exec, _mesa_InitNames);
- SET_FeedbackBuffer(exec, _mesa_FeedbackBuffer);
- SET_LoadName(exec, _mesa_LoadName);
- SET_PassThrough(exec, _mesa_PassThrough);
- SET_PopName(exec, _mesa_PopName);
- SET_PushName(exec, _mesa_PushName);
- SET_SelectBuffer(exec, _mesa_SelectBuffer);
- SET_RenderMode(exec, _mesa_RenderMode);
-#endif
SET_FogCoordPointerEXT(exec, _mesa_FogCoordPointerEXT);
SET_Fogf(exec, _mesa_Fogf);
SET_Fogfv(exec, _mesa_Fogfv);
#include "enums.h"
#include "extensions.h"
#include "fbobject.h"
-#if FEATURE_feedback
#include "feedback.h"
-#endif
#include "fog.h"
#include "framebuffer.h"
#include "get.h"
_mesa_init_eval( ctx );
#endif
_mesa_init_fbobjects( ctx );
-#if FEATURE_feedback
_mesa_init_feedback( ctx );
-#else
- ctx->RenderMode = GL_RENDER;
-#endif
_mesa_init_fog( ctx );
_mesa_init_histogram( ctx );
_mesa_init_hint( ctx );
#include "feedback.h"
#include "macros.h"
#include "mtypes.h"
+#include "glapi/dispatch.h"
-#if _HAVE_FULL_GL
+#if FEATURE_feedback
#define FB_3D 0x01
-void GLAPIENTRY
+static void GLAPIENTRY
_mesa_FeedbackBuffer( GLsizei size, GLenum type, GLfloat *buffer )
{
GET_CURRENT_CONTEXT(ctx);
}
-void GLAPIENTRY
+static void GLAPIENTRY
_mesa_PassThrough( GLfloat token )
{
GET_CURRENT_CONTEXT(ctx);
}
-#endif /* _HAVE_FULL_GL */
-
-
/**********************************************************************/
/** \name Selection */
/*@{*/
* Verifies we're not in selection mode, flushes the vertices and initialize
* the fields in __GLcontextRec::Select with the given buffer.
*/
-void GLAPIENTRY
+static void GLAPIENTRY
_mesa_SelectBuffer( GLsizei size, GLuint *buffer )
{
GET_CURRENT_CONTEXT(ctx);
* the hit record data in gl_selection. Marks new render mode in
* __GLcontextRec::NewState.
*/
-void GLAPIENTRY
+static void GLAPIENTRY
_mesa_InitNames( void )
{
GET_CURRENT_CONTEXT(ctx);
*
* sa __GLcontextRec::Select.
*/
-void GLAPIENTRY
+static void GLAPIENTRY
_mesa_LoadName( GLuint name )
{
GET_CURRENT_CONTEXT(ctx);
*
* sa __GLcontextRec::Select.
*/
-void GLAPIENTRY
+static void GLAPIENTRY
_mesa_PushName( GLuint name )
{
GET_CURRENT_CONTEXT(ctx);
*
* sa __GLcontextRec::Select.
*/
-void GLAPIENTRY
+static void GLAPIENTRY
_mesa_PopName( void )
{
GET_CURRENT_CONTEXT(ctx);
* __GLcontextRec::RenderMode and notifies the driver via the
* dd_function_table::RenderMode callback.
*/
-GLint GLAPIENTRY
+static GLint GLAPIENTRY
_mesa_RenderMode( GLenum mode )
{
GET_CURRENT_CONTEXT(ctx);
/*@}*/
+void
+_mesa_init_feedback_dispatch(struct _glapi_table *disp)
+{
+ SET_InitNames(disp, _mesa_InitNames);
+ SET_FeedbackBuffer(disp, _mesa_FeedbackBuffer);
+ SET_LoadName(disp, _mesa_LoadName);
+ SET_PassThrough(disp, _mesa_PassThrough);
+ SET_PopName(disp, _mesa_PopName);
+ SET_PushName(disp, _mesa_PushName);
+ SET_SelectBuffer(disp, _mesa_SelectBuffer);
+ SET_RenderMode(disp, _mesa_RenderMode);
+}
+
+
+#endif /* FEATURE_feedback */
+
+
/**********************************************************************/
/** \name Initialization */
/*@{*/
#define FEEDBACK_H
-#include "mtypes.h"
+#include "main/mtypes.h"
-extern void
-_mesa_init_feedback( GLcontext *ctx );
+#if FEATURE_feedback
+
+#define _MESA_INIT_FEEDBACK_FUNCTIONS(driver, impl) \
+ do { \
+ (driver)->RenderMode = impl ## RenderMode; \
+ } while (0)
extern void
_mesa_feedback_vertex( GLcontext *ctx,
_mesa_update_hitflag( GLcontext *ctx, GLfloat z );
-extern void GLAPIENTRY
-_mesa_PassThrough( GLfloat token );
+extern void
+_mesa_init_feedback_dispatch(struct _glapi_table *disp);
+
+#else /* FEATURE_feedback */
-extern void GLAPIENTRY
-_mesa_FeedbackBuffer( GLsizei size, GLenum type, GLfloat *buffer );
+#define _MESA_INIT_FEEDBACK_FUNCTIONS(driver, impl) do { } while (0)
-extern void GLAPIENTRY
-_mesa_SelectBuffer( GLsizei size, GLuint *buffer );
+static INLINE void
+_mesa_feedback_vertex( GLcontext *ctx,
+ const GLfloat win[4],
+ const GLfloat color[4],
+ GLfloat index,
+ const GLfloat texcoord[4] )
+{
+ /* render mode is always GL_RENDER */
+ ASSERT_NO_FEATURE();
+}
-extern void GLAPIENTRY
-_mesa_InitNames( void );
-extern void GLAPIENTRY
-_mesa_LoadName( GLuint name );
+static INLINE void
+_mesa_feedback_token( GLcontext *ctx, GLfloat token )
+{
+ /* render mode is always GL_RENDER */
+ ASSERT_NO_FEATURE();
+}
-extern void GLAPIENTRY
-_mesa_PushName( GLuint name );
+static INLINE void
+_mesa_update_hitflag( GLcontext *ctx, GLfloat z )
+{
+ /* render mode is always GL_RENDER */
+ ASSERT_NO_FEATURE();
+}
-extern void GLAPIENTRY
-_mesa_PopName( void );
+static INLINE void
+_mesa_init_feedback_dispatch(struct _glapi_table *disp)
+{
+}
-extern GLint GLAPIENTRY
-_mesa_RenderMode( GLenum mode );
+#endif /* FEATURE_feedback */
+extern void
+_mesa_init_feedback( GLcontext *ctx );
-#endif
+#endif /* FEEDBACK_H */