[virglrenderer-devel] [RFC PATCH 1/7] vrend: remove superflous caps initialization

Gert Wollny gert.wollny at collabora.com
Mon Jul 23 10:37:59 UTC 2018


The field is memset to zero at the beginning, so there is mo need to
clear each flag seperately.

Signed-off-by: Gert Wollny <gert.wollny at collabora.com>
---
 src/vrend_renderer.c | 39 ---------------------------------------
 1 file changed, 39 deletions(-)

diff --git a/src/vrend_renderer.c b/src/vrend_renderer.c
index 4086abd..e5ca585 100644
--- a/src/vrend_renderer.c
+++ b/src/vrend_renderer.c
@@ -7382,45 +7382,6 @@ static void vrend_renderer_fill_caps_gles(uint32_t set, UNUSED uint32_t version,
       fill_capset2 = true;
    }
 
-   caps->v1.bset.indep_blend_enable = 0;
-   caps->v1.bset.conditional_render = 0;
-
-   caps->v1.bset.poly_stipple = 0;
-   caps->v1.bset.color_clamping = 0;
-
-   caps->v1.bset.instanceid = 0;
-
-   caps->v1.bset.primitive_restart = 0;
-
-   caps->v1.bset.fragment_coord_conventions = 0;
-   caps->v1.bset.depth_clip_disable = 0;
-   caps->v1.bset.seamless_cube_map = 0;
-
-   caps->v1.bset.seamless_cube_map_per_texture = 0;
-
-   caps->v1.bset.mirror_clamp = 0;
-   caps->v1.bset.indep_blend_func = 0;
-   caps->v1.bset.cube_map_array = 0;
-   caps->v1.bset.texture_query_lod = 0;
-   caps->v1.bset.has_indirect_draw = 0;
-   caps->v1.bset.has_sample_shading = 0;
-
-   caps->v1.bset.start_instance = 0;
-
-   caps->v1.bset.shader_stencil_export = 0;
-
-   caps->v1.bset.streamout_pause_resume = 0;
-
-   caps->v1.max_dual_source_render_targets = 0;
-
-   caps->v1.max_dual_source_render_targets = 0;
-
-   caps->v1.max_tbo_size = 0;
-
-   caps->v1.max_texture_gather_components = 0;
-
-   caps->v1.max_viewports = 1;
-
    if (gles_ver >= 30) {
       glGetIntegerv(GL_MAX_ARRAY_TEXTURE_LAYERS, &max);
       caps->v1.max_texture_array_layers = max;
-- 
2.16.4



More information about the virglrenderer-devel mailing list