mirror of
https://github.com/brl/mutter.git
synced 2024-11-26 10:00:45 -05:00
make COGL_FEATURE_FOUR_CLIP_PLANES a private feature
Cogl doesn't currently expose public api for clip planes 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_FOUR_CLIP_PLANES which cogl now checks for internally. Reviewed-by: Neil Roberts <neil@linux.intel.com>
This commit is contained in:
parent
abbd28f484
commit
d045bea70e
@ -828,7 +828,8 @@ _cogl_clip_stack_flush (CoglClipStack *stack,
|
||||
modelview_stack =
|
||||
_cogl_framebuffer_get_modelview_stack (framebuffer);
|
||||
|
||||
has_clip_planes = cogl_features_available (COGL_FEATURE_FOUR_CLIP_PLANES);
|
||||
has_clip_planes =
|
||||
ctx->private_feature_flags & COGL_PRIVATE_FEATURE_FOUR_CLIP_PLANES;
|
||||
|
||||
if (has_clip_planes)
|
||||
disable_clip_planes ();
|
||||
|
@ -130,7 +130,8 @@ typedef enum
|
||||
COGL_PRIVATE_FEATURE_TEXTURE_2D_FROM_EGL_IMAGE = 1L<<0,
|
||||
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_OFFSCREEN_BLIT = 1L<<3,
|
||||
COGL_PRIVATE_FEATURE_FOUR_CLIP_PLANES = 1L<<4
|
||||
} CoglPrivateFeatureFlags;
|
||||
|
||||
/* Sometimes when evaluating pipelines, either during comparisons or
|
||||
|
@ -187,7 +187,7 @@ _cogl_gl_update_features (CoglContext *context,
|
||||
|
||||
GE( ctx, glGetIntegerv (GL_MAX_CLIP_PLANES, &max_clip_planes) );
|
||||
if (max_clip_planes >= 4)
|
||||
flags |= COGL_FEATURE_FOUR_CLIP_PLANES;
|
||||
private_flags |= COGL_PRIVATE_FEATURE_FOUR_CLIP_PLANES;
|
||||
|
||||
if (context->glGenRenderbuffers)
|
||||
flags |= COGL_FEATURE_OFFSCREEN;
|
||||
|
@ -78,7 +78,7 @@ _cogl_gles_update_features (CoglContext *context,
|
||||
int max_clip_planes;
|
||||
GE( context, glGetIntegerv (GL_MAX_CLIP_PLANES, &max_clip_planes) );
|
||||
if (max_clip_planes >= 4)
|
||||
flags |= COGL_FEATURE_FOUR_CLIP_PLANES;
|
||||
private_flags |= COGL_PRIVATE_FEATURE_FOUR_CLIP_PLANES;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user