From 6e8d21d72f35767e07081a8bee4323aaaf5e2aae Mon Sep 17 00:00:00 2001 From: Kristian Høgsberg Date: Mon, 25 Feb 2008 16:14:37 -0500 Subject: Remove GetMSC DriverAPI function. The DriverAPI is internal to the DRI drivers and GetDrawableMSC obsoletes GetMSC. Also, since the DRI driver interface has not yet been released, just drop the getMSC function from the DRI interface instead using the ABI preserving version mechanism. Finally, using void pointer privates in the DRI interface is not allowed, always pass the actual types around (__DRIdrawable in this case) to enhance type safety and readability of the code. --- src/mesa/drivers/dri/common/dri_util.c | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) (limited to 'src/mesa/drivers/dri/common/dri_util.c') diff --git a/src/mesa/drivers/dri/common/dri_util.c b/src/mesa/drivers/dri/common/dri_util.c index 01751582fa..9928a0f031 100644 --- a/src/mesa/drivers/dri/common/dri_util.c +++ b/src/mesa/drivers/dri/common/dri_util.c @@ -450,22 +450,13 @@ static void driSwapBuffers(__DRIdrawable *drawable) &rect, 1, GL_TRUE); } -static int driDrawableGetMSC( __DRIscreen *screen, void *drawablePrivate, +static int driDrawableGetMSC( __DRIscreen *screen, __DRIdrawable *drawable, int64_t *msc ) { __DRIscreenPrivate *sPriv = screen->private; + __DRIdrawablePrivate *dPriv = drawable->private; - return sPriv->DriverAPI.GetDrawableMSC( sPriv, drawablePrivate, msc ); -} - -/** - * Called directly from a number of higher-level GLX functions. - */ -static int driGetMSC( __DRIscreen *screen, void *drawablePrivate, int64_t *msc ) -{ - __DRIscreenPrivate *sPriv = screen->private; - - return sPriv->DriverAPI.GetMSC( sPriv, msc ); + return sPriv->DriverAPI.GetDrawableMSC(sPriv, dPriv, msc); } static int driWaitForMSC(__DRIdrawable *drawable, int64_t target_msc, @@ -496,7 +487,6 @@ static int driWaitForMSC(__DRIdrawable *drawable, int64_t target_msc, const __DRImediaStreamCounterExtension driMediaStreamCounterExtension = { { __DRI_MEDIA_STREAM_COUNTER, __DRI_MEDIA_STREAM_COUNTER_VERSION }, - driGetMSC, driWaitForMSC, driDrawableGetMSC, }; -- cgit v1.2.3