mirror of
https://github.com/brl/mutter.git
synced 2024-11-28 19:10:43 -05:00
cogl: Rename feature OFFSCREEN_BLIT to BLIT_FRAMEBUFFER
The feature is not limited to offscreen framebuffer blits anymore since "cogl: Allow glBlitFramebuffer between onscreen/offscreen". https://gitlab.gnome.org/GNOME/mutter/merge_requests/615
This commit is contained in:
parent
45289b3d65
commit
55c084e6e1
@ -158,7 +158,7 @@ _cogl_blit_framebuffer_begin (CoglBlitData *data)
|
|||||||
supported. */
|
supported. */
|
||||||
if ((_cogl_texture_get_format (data->src_tex) & COGL_PREMULT_BIT) !=
|
if ((_cogl_texture_get_format (data->src_tex) & COGL_PREMULT_BIT) !=
|
||||||
(_cogl_texture_get_format (data->dst_tex) & COGL_PREMULT_BIT) ||
|
(_cogl_texture_get_format (data->dst_tex) & COGL_PREMULT_BIT) ||
|
||||||
!_cogl_has_private_feature (ctx, COGL_PRIVATE_FEATURE_OFFSCREEN_BLIT))
|
!_cogl_has_private_feature (ctx, COGL_PRIVATE_FEATURE_BLIT_FRAMEBUFFER))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
dst_offscreen = _cogl_offscreen_new_with_texture_full
|
dst_offscreen = _cogl_offscreen_new_with_texture_full
|
||||||
|
@ -377,7 +377,7 @@ _cogl_push_framebuffers (CoglFramebuffer *draw_buffer,
|
|||||||
*
|
*
|
||||||
* This blits a region of the color buffer of the source buffer
|
* This blits a region of the color buffer of the source buffer
|
||||||
* to the destination buffer. This function should only be
|
* to the destination buffer. This function should only be
|
||||||
* called if the COGL_PRIVATE_FEATURE_OFFSCREEN_BLIT feature is
|
* called if the COGL_PRIVATE_FEATURE_BLIT_FRAMEBUFFER feature is
|
||||||
* advertised.
|
* advertised.
|
||||||
*
|
*
|
||||||
* The source and destination rectangles are defined in offscreen
|
* The source and destination rectangles are defined in offscreen
|
||||||
|
@ -1356,7 +1356,7 @@ _cogl_blit_framebuffer (CoglFramebuffer *src,
|
|||||||
int dst_x1, dst_y1, dst_x2, dst_y2;
|
int dst_x1, dst_y1, dst_x2, dst_y2;
|
||||||
|
|
||||||
g_return_if_fail (_cogl_has_private_feature
|
g_return_if_fail (_cogl_has_private_feature
|
||||||
(ctx, COGL_PRIVATE_FEATURE_OFFSCREEN_BLIT));
|
(ctx, COGL_PRIVATE_FEATURE_BLIT_FRAMEBUFFER));
|
||||||
|
|
||||||
/* The buffers must use the same premult convention */
|
/* The buffers must use the same premult convention */
|
||||||
g_return_if_fail ((src->internal_format & COGL_PREMULT_BIT) ==
|
g_return_if_fail ((src->internal_format & COGL_PREMULT_BIT) ==
|
||||||
|
@ -42,7 +42,7 @@ typedef enum
|
|||||||
{
|
{
|
||||||
COGL_PRIVATE_FEATURE_TEXTURE_2D_FROM_EGL_IMAGE,
|
COGL_PRIVATE_FEATURE_TEXTURE_2D_FROM_EGL_IMAGE,
|
||||||
COGL_PRIVATE_FEATURE_MESA_PACK_INVERT,
|
COGL_PRIVATE_FEATURE_MESA_PACK_INVERT,
|
||||||
COGL_PRIVATE_FEATURE_OFFSCREEN_BLIT,
|
COGL_PRIVATE_FEATURE_BLIT_FRAMEBUFFER,
|
||||||
COGL_PRIVATE_FEATURE_FOUR_CLIP_PLANES,
|
COGL_PRIVATE_FEATURE_FOUR_CLIP_PLANES,
|
||||||
COGL_PRIVATE_FEATURE_PBOS,
|
COGL_PRIVATE_FEATURE_PBOS,
|
||||||
COGL_PRIVATE_FEATURE_VBOS,
|
COGL_PRIVATE_FEATURE_VBOS,
|
||||||
|
@ -387,7 +387,7 @@ _cogl_framebuffer_gl_flush_state (CoglFramebuffer *draw_buffer,
|
|||||||
/* NB: Currently we only take advantage of binding separate
|
/* NB: Currently we only take advantage of binding separate
|
||||||
* read/write buffers for framebuffer blit purposes. */
|
* read/write buffers for framebuffer blit purposes. */
|
||||||
g_return_if_fail (_cogl_has_private_feature
|
g_return_if_fail (_cogl_has_private_feature
|
||||||
(ctx, COGL_PRIVATE_FEATURE_OFFSCREEN_BLIT));
|
(ctx, COGL_PRIVATE_FEATURE_BLIT_FRAMEBUFFER));
|
||||||
|
|
||||||
_cogl_framebuffer_gl_bind (draw_buffer, GL_DRAW_FRAMEBUFFER);
|
_cogl_framebuffer_gl_bind (draw_buffer, GL_DRAW_FRAMEBUFFER);
|
||||||
_cogl_framebuffer_gl_bind (read_buffer, GL_READ_FRAMEBUFFER);
|
_cogl_framebuffer_gl_bind (read_buffer, GL_READ_FRAMEBUFFER);
|
||||||
|
@ -421,7 +421,7 @@ _cogl_driver_update_features (CoglContext *ctx,
|
|||||||
|
|
||||||
if (ctx->glBlitFramebuffer)
|
if (ctx->glBlitFramebuffer)
|
||||||
COGL_FLAGS_SET (private_features,
|
COGL_FLAGS_SET (private_features,
|
||||||
COGL_PRIVATE_FEATURE_OFFSCREEN_BLIT, TRUE);
|
COGL_PRIVATE_FEATURE_BLIT_FRAMEBUFFER, TRUE);
|
||||||
|
|
||||||
if (ctx->glRenderbufferStorageMultisampleIMG)
|
if (ctx->glRenderbufferStorageMultisampleIMG)
|
||||||
{
|
{
|
||||||
|
@ -330,7 +330,7 @@ _cogl_driver_update_features (CoglContext *context,
|
|||||||
|
|
||||||
if (context->glBlitFramebuffer)
|
if (context->glBlitFramebuffer)
|
||||||
COGL_FLAGS_SET (private_features,
|
COGL_FLAGS_SET (private_features,
|
||||||
COGL_PRIVATE_FEATURE_OFFSCREEN_BLIT, TRUE);
|
COGL_PRIVATE_FEATURE_BLIT_FRAMEBUFFER, TRUE);
|
||||||
|
|
||||||
if (_cogl_check_extension ("GL_OES_element_index_uint", gl_extensions))
|
if (_cogl_check_extension ("GL_OES_element_index_uint", gl_extensions))
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user