[gtk/wip/chergert/glproto: 694/920] make autorelease framebuffer private




commit da0ee2ff346efd0d9d838684470cc5cba9b42063
Author: Christian Hergert <chergert redhat com>
Date:   Wed Jan 13 11:10:11 2021 -0800

    make autorelease framebuffer private
    
    this isn't needed now that we have a render target helper

 gsk/next/gskgldriver.c        |  7 ++--
 gsk/next/gskgldriverprivate.h | 74 +++++++++++++++++++++----------------------
 2 files changed, 39 insertions(+), 42 deletions(-)
---
diff --git a/gsk/next/gskgldriver.c b/gsk/next/gskgldriver.c
index 4e9a2d7ddb..a8386f5aa3 100644
--- a/gsk/next/gskgldriver.c
+++ b/gsk/next/gskgldriver.c
@@ -263,14 +263,13 @@ failure:
  * @self: a #GskNextDriver
  * @framebuffer_id: the id of the OpenGL framebuffer
  *
- * Marks @framebuffer_id to be deleted when the current frame
- * has completed.
+ * Marks @framebuffer_id to be deleted when the current frame has cmopleted.
  */
-void
+static void
 gsk_next_driver_autorelease_framebuffer (GskNextDriver *self,
                                          guint          framebuffer_id)
 {
-  g_return_if_fail (GSK_IS_NEXT_DRIVER (self));
+  g_assert (GSK_IS_NEXT_DRIVER (self));
 
   g_array_append_val (self->autorelease_framebuffers, framebuffer_id);
 }
diff --git a/gsk/next/gskgldriverprivate.h b/gsk/next/gskgldriverprivate.h
index 13f4429891..79980f77cd 100644
--- a/gsk/next/gskgldriverprivate.h
+++ b/gsk/next/gskgldriverprivate.h
@@ -103,44 +103,42 @@ struct _GskNextDriver
   guint in_frame : 1;
 };
 
-GskNextDriver *gsk_next_driver_new                     (GskGLCommandQueue    *command_queue,
-                                                        gboolean              debug,
-                                                        GError              **error);
-GdkGLContext  *gsk_next_driver_get_context             (GskNextDriver        *self);
-void           gsk_next_driver_autorelease_framebuffer (GskNextDriver        *self,
-                                                        guint                 framebuffer_id);
-gboolean       gsk_next_driver_create_render_target    (GskNextDriver        *self,
-                                                        int                   width,
-                                                        int                   height,
-                                                        int                   min_filter,
-                                                        int                   mag_filter,
-                                                        GskGLRenderTarget   **render_target);
-guint          gsk_next_driver_release_render_target   (GskNextDriver        *self,
-                                                        GskGLRenderTarget    *render_target,
-                                                        gboolean              release_texture);
-void           gsk_next_driver_begin_frame             (GskNextDriver        *self);
-void           gsk_next_driver_end_frame               (GskNextDriver        *self);
-guint          gsk_next_driver_lookup_texture          (GskNextDriver        *self,
-                                                        const GskTextureKey  *key);
-void           gsk_next_driver_cache_texture           (GskNextDriver        *self,
-                                                        const GskTextureKey  *key,
-                                                        guint                 texture_id);
-guint          gsk_next_driver_load_texture            (GskNextDriver        *self,
-                                                        GdkTexture           *texture,
-                                                        int                   min_filter,
-                                                        int                   mag_filter);
-GskGLTexture  *gsk_next_driver_create_texture          (GskNextDriver        *self,
-                                                        float                 width,
-                                                        float                 height,
-                                                        int                   min_filter,
-                                                        int                   mag_filter);
-GskGLTexture  *gsk_next_driver_acquire_texture         (GskNextDriver        *self,
-                                                        float                 width,
-                                                        float                 height,
-                                                        int                   min_filter,
-                                                        int                   mag_filter);
-void           gsk_next_driver_release_texture         (GskNextDriver        *self,
-                                                        GskGLTexture         *texture);
+GskNextDriver *gsk_next_driver_new                   (GskGLCommandQueue    *command_queue,
+                                                      gboolean              debug,
+                                                      GError              **error);
+GdkGLContext  *gsk_next_driver_get_context           (GskNextDriver        *self);
+gboolean       gsk_next_driver_create_render_target  (GskNextDriver        *self,
+                                                      int                   width,
+                                                      int                   height,
+                                                      int                   min_filter,
+                                                      int                   mag_filter,
+                                                      GskGLRenderTarget   **render_target);
+guint          gsk_next_driver_release_render_target (GskNextDriver        *self,
+                                                      GskGLRenderTarget    *render_target,
+                                                      gboolean              release_texture);
+void           gsk_next_driver_begin_frame           (GskNextDriver        *self);
+void           gsk_next_driver_end_frame             (GskNextDriver        *self);
+guint          gsk_next_driver_lookup_texture        (GskNextDriver        *self,
+                                                      const GskTextureKey  *key);
+void           gsk_next_driver_cache_texture         (GskNextDriver        *self,
+                                                      const GskTextureKey  *key,
+                                                      guint                 texture_id);
+guint          gsk_next_driver_load_texture          (GskNextDriver        *self,
+                                                      GdkTexture           *texture,
+                                                      int                   min_filter,
+                                                      int                   mag_filter);
+GskGLTexture  *gsk_next_driver_create_texture        (GskNextDriver        *self,
+                                                      float                 width,
+                                                      float                 height,
+                                                      int                   min_filter,
+                                                      int                   mag_filter);
+GskGLTexture  *gsk_next_driver_acquire_texture       (GskNextDriver        *self,
+                                                      float                 width,
+                                                      float                 height,
+                                                      int                   min_filter,
+                                                      int                   mag_filter);
+void           gsk_next_driver_release_texture       (GskNextDriver        *self,
+                                                      GskGLTexture         *texture);
 
 G_END_DECLS
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]