mirror of
https://github.com/brl/mutter.git
synced 2024-12-24 12:02:04 +00:00
make COGL_FEATURE_PBOS a private feature
Cogl provides a consistent public interface regardless of whether the underlying GL driver supports PBOs so it doesn't make much sense to have this feature as part of the public api. We can't break the api by removing the enum but at least we no longer ever set the feature flag. We now have a replacement private feature flag COGL_PRIVATE_FEATURE_PBOS which cogl now checks for internally. Reviewed-by: Neil Roberts <neil@linux.intel.com>
This commit is contained in:
parent
d045bea70e
commit
69b44ac86d
@ -77,7 +77,7 @@ _cogl_init_feature_overrides (CoglContext *ctx)
|
||||
ctx->feature_flags &= ~COGL_FEATURE_VBOS;
|
||||
|
||||
if (G_UNLIKELY (COGL_DEBUG_ENABLED (COGL_DEBUG_DISABLE_PBOS)))
|
||||
ctx->feature_flags &= ~COGL_FEATURE_PBOS;
|
||||
ctx->private_feature_flags &= ~COGL_PRIVATE_FEATURE_PBOS;
|
||||
|
||||
if (G_UNLIKELY (COGL_DEBUG_ENABLED (COGL_DEBUG_DISABLE_ARBFP)))
|
||||
ctx->feature_flags &= ~COGL_FEATURE_SHADERS_ARBFP;
|
||||
|
@ -131,7 +131,8 @@ typedef enum
|
||||
COGL_PRIVATE_FEATURE_MESA_PACK_INVERT = 1L<<1,
|
||||
COGL_PRIVATE_FEATURE_STENCIL_BUFFER = 1L<<2,
|
||||
COGL_PRIVATE_FEATURE_OFFSCREEN_BLIT = 1L<<3,
|
||||
COGL_PRIVATE_FEATURE_FOUR_CLIP_PLANES = 1L<<4
|
||||
COGL_PRIVATE_FEATURE_FOUR_CLIP_PLANES = 1L<<4,
|
||||
COGL_PRIVATE_FEATURE_PBOS = 1L<<5
|
||||
} CoglPrivateFeatureFlags;
|
||||
|
||||
/* Sometimes when evaluating pipelines, either during comparisons or
|
||||
|
@ -76,7 +76,7 @@ _cogl_pixel_buffer_new (unsigned int size)
|
||||
|
||||
_COGL_GET_CONTEXT (ctx, COGL_INVALID_HANDLE);
|
||||
|
||||
if (!cogl_features_available (COGL_FEATURE_PBOS))
|
||||
if (!(ctx->private_feature_flags & COGL_PRIVATE_FEATURE_PBOS))
|
||||
use_malloc = TRUE;
|
||||
else
|
||||
use_malloc = FALSE;
|
||||
|
@ -200,7 +200,7 @@ _cogl_gl_update_features (CoglContext *context,
|
||||
|
||||
if (COGL_CHECK_GL_VERSION (gl_major, gl_minor, 2, 1) ||
|
||||
_cogl_check_extension ("GL_EXT_pixel_buffer_object", gl_extensions))
|
||||
flags |= COGL_FEATURE_PBOS;
|
||||
private_flags |= COGL_PRIVATE_FEATURE_PBOS;
|
||||
|
||||
if (COGL_CHECK_GL_VERSION (gl_major, gl_minor, 2, 0) ||
|
||||
_cogl_check_extension ("GL_ARB_point_sprite", gl_extensions))
|
||||
|
Loading…
Reference in New Issue
Block a user