[mutter] cogl/tests: Port to cogl_texture_2d_new_from_data



commit 8ca20e709c9343d9ac41a1773f145d5e1a8d313b
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date:   Thu Mar 31 13:02:54 2022 -0300

    cogl/tests: Port to cogl_texture_2d_new_from_data
    
    Drop cogl_texture_new_from_data() in favour of the undeprecated
    cogl_texture_2d_new_from_data().
    
    Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2355>

 cogl/tests/conform/test-pipeline-user-matrix.c | 27 ++++++++++++++------------
 1 file changed, 15 insertions(+), 12 deletions(-)
---
diff --git a/cogl/tests/conform/test-pipeline-user-matrix.c b/cogl/tests/conform/test-pipeline-user-matrix.c
index 689eeeae98..ac538717ee 100644
--- a/cogl/tests/conform/test-pipeline-user-matrix.c
+++ b/cogl/tests/conform/test-pipeline-user-matrix.c
@@ -69,18 +69,21 @@ paint (TestState *state)
   graphene_matrix_init_identity (&matrix);
   cogl_framebuffer_set_modelview_matrix (test_fb, &matrix);
 
-  tex0 = cogl_texture_new_from_data (2, 2,
-                                     COGL_TEXTURE_NO_ATLAS,
-                                     COGL_PIXEL_FORMAT_RGB_888,
-                                     COGL_PIXEL_FORMAT_ANY,
-                                     6,
-                                     data0);
-  tex1 = cogl_texture_new_from_data (2, 2,
-                                     COGL_TEXTURE_NO_ATLAS,
-                                     COGL_PIXEL_FORMAT_RGB_888,
-                                     COGL_PIXEL_FORMAT_ANY,
-                                     6,
-                                     data1);
+  tex0 = cogl_texture_2d_new_from_data (test_ctx,
+                                        2, 2,
+                                        COGL_PIXEL_FORMAT_RGB_888,
+                                        6,
+                                        data0,
+                                        &error);
+  g_assert_no_error (error);
+
+  tex1 = cogl_texture_2d_new_from_data (test_ctx,
+                                        2, 2,
+                                        COGL_PIXEL_FORMAT_RGB_888,
+                                        6,
+                                        data1,
+                                        &error);
+  g_assert_no_error (error);
 
   pipeline = cogl_pipeline_new (test_ctx);
 


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