[vlc-commits] [Git][videolan/vlc][master] Remove unused fields from vlc_gl_format

Steve Lhomme (@robUx4) gitlab at videolan.org
Wed Nov 23 14:56:22 UTC 2022



Steve Lhomme pushed to branch master at VideoLAN / VLC


Commits:
9d25f27f by Romain Vimont at 2022-11-23T14:35:00+00:00
Remove unused fields from vlc_gl_format

Since commit 85f85230df103124658ae77df40991cfc84237b2, the fields
vlc_gl_format.visible_* are never read. Remove them.

- - - - -


3 changed files:

- modules/video_output/opengl/filters.c
- modules/video_output/opengl/importer.c
- modules/video_output/opengl/picture.h


Changes:

=====================================
modules/video_output/opengl/filters.c
=====================================
@@ -227,8 +227,6 @@ vlc_gl_filters_Append(struct vlc_gl_filters *filters, const char *name,
         size_t size = glfmt->tex_count * sizeof(GLsizei);
         memcpy(glfmt->tex_widths, prev_filter->plane_widths, size);
         memcpy(glfmt->tex_heights, prev_filter->plane_heights, size);
-        memcpy(glfmt->visible_widths, prev_filter->plane_widths, size);
-        memcpy(glfmt->visible_heights, prev_filter->plane_heights, size);
     }
 
     /* By default, the output size is the same as the input size. The filter


=====================================
modules/video_output/opengl/importer.c
=====================================
@@ -236,16 +236,10 @@ vlc_gl_importer_New(struct vlc_gl_interop *interop)
 
     /* Texture size */
     for (unsigned j = 0; j < interop->tex_count; j++) {
-        GLsizei vw = interop->fmt_out.i_visible_width  * interop->texs[j].w.num
-                  / interop->texs[j].w.den;
-        GLsizei vh = interop->fmt_out.i_visible_height * interop->texs[j].h.num
-                  / interop->texs[j].h.den;
         GLsizei w = (interop->fmt_out.i_visible_width + interop->fmt_out.i_x_offset) * interop->texs[j].w.num
                   / interop->texs[j].w.den;
         GLsizei h = (interop->fmt_out.i_visible_height + interop->fmt_out.i_y_offset) *  interop->texs[j].h.num
                   / interop->texs[j].h.den;
-        glfmt->visible_widths[j] = vw;
-        glfmt->visible_heights[j] = vh;
         if (supports_npot) {
             glfmt->tex_widths[j]  = w;
             glfmt->tex_heights[j] = h;


=====================================
modules/video_output/opengl/picture.h
=====================================
@@ -41,9 +41,6 @@ struct vlc_gl_format {
     GLsizei tex_widths[PICTURE_PLANE_MAX];
     GLsizei tex_heights[PICTURE_PLANE_MAX];
 
-    GLsizei visible_widths[PICTURE_PLANE_MAX];
-    GLsizei visible_heights[PICTURE_PLANE_MAX];
-
     uint32_t formats[PICTURE_PLANE_MAX];
 };
 



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/9d25f27f52879b401a4a62376e83274561aacb13

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/9d25f27f52879b401a4a62376e83274561aacb13
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list