diff options
author | George Sapountzis <[email protected]> | 2010-03-26 18:44:39 +0200 |
---|---|---|
committer | George Sapountzis <[email protected]> | 2010-03-26 18:44:39 +0200 |
commit | fc35d203c70a89b723e5ebeff1918e7607d67a79 (patch) | |
tree | 3e390ea8d71efa072669536016973fd757ec32ec /src/gallium/state_trackers/dri/common | |
parent | 5b07257fdbb5a93f432b8eaf3a41f39b26bdb1f3 (diff) |
st/dri: add comment about the ifdef in dri_screen.c
Diffstat (limited to 'src/gallium/state_trackers/dri/common')
-rw-r--r-- | src/gallium/state_trackers/dri/common/dri_screen.c | 23 |
1 files changed, 10 insertions, 13 deletions
diff --git a/src/gallium/state_trackers/dri/common/dri_screen.c b/src/gallium/state_trackers/dri/common/dri_screen.c index cbd7563938e..821c1dea626 100644 --- a/src/gallium/state_trackers/dri/common/dri_screen.c +++ b/src/gallium/state_trackers/dri/common/dri_screen.c @@ -344,8 +344,11 @@ dri_init_screen_helper(struct dri_screen *screen, return dri_fill_in_modes(screen, pixel_bits); } -#ifndef __NOT_HAVE_DRM_H - +/** + * DRI driver virtual function table. + * + * DRI versions differ in their implementation of init_screen and swap_buffers. + */ const struct __DriverAPIRec driDriverAPI = { .DestroyScreen = dri_destroy_screen, .CreateContext = dri_create_context, @@ -354,6 +357,9 @@ const struct __DriverAPIRec driDriverAPI = { .DestroyBuffer = dri_destroy_buffer, .MakeCurrent = dri_make_current, .UnbindContext = dri_unbind_context, + +#ifndef __NOT_HAVE_DRM_H + .GetSwapInfo = dri_get_swap_info, .GetDrawableMSC = driDrawableGetMSC32, .WaitForMSC = driWaitForMSC32, @@ -362,23 +368,14 @@ const struct __DriverAPIRec driDriverAPI = { .InitScreen = dri1_init_screen, .SwapBuffers = dri1_swap_buffers, .CopySubBuffer = dri1_copy_sub_buffer, -}; #else -const struct __DriverAPIRec driDriverAPI = { - .DestroyScreen = dri_destroy_screen, - .CreateContext = dri_create_context, - .DestroyContext = dri_destroy_context, - .CreateBuffer = dri_create_buffer, - .DestroyBuffer = dri_destroy_buffer, - .MakeCurrent = dri_make_current, - .UnbindContext = dri_unbind_context, - .InitScreen = drisw_init_screen, .SwapBuffers = drisw_swap_buffers, -}; #endif +}; + /* vim: set sw=3 ts=8 sts=3 expandtab: */ |