Bypass wires.
authorClément Foucault <foucault.clem@gmail.com>
Thu, 2 Feb 2017 15:54:15 +0000 (16:54 +0100)
committerClément Foucault <foucault.clem@gmail.com>
Thu, 2 Feb 2017 15:54:15 +0000 (16:54 +0100)
source/blender/draw/engines/clay/clay.c

index e1b38926a07981b635817193066245ebdc90bca8..e5188760c0b2b3612f084d955f7f42a44cb17c8e 100644 (file)
@@ -542,7 +542,7 @@ static void CLAY_create_cache(CLAY_PassList *passes, const struct bContext *C)
                MaterialRuntimeClay **runtime;
                DRW_render_settings_get(NULL, RE_engine_id_BLENDER_CLAY, (void ***)&runtime);
 
-               passes->clay_pass = DRW_pass_create("Clay Pass", DRW_STATE_WRITE_COLOR);
+               passes->clay_pass = DRW_pass_create("Clay Pass", DRW_STATE_WRITE_COLOR | DRW_STATE_WRITE_DEPTH | DRW_STATE_DEPTH_LESS);
 
                default_shgrp = CLAY_shgroup_create(passes->clay_pass, &(*runtime)->material_id);
                DRW_shgroup_uniform_block(default_shgrp, "material_block", data.mat_ubo, 0);
@@ -575,10 +575,10 @@ static void CLAY_create_cache(CLAY_PassList *passes, const struct bContext *C)
                                DRW_shgroup_call_add(depthbatch, geom, ob->obmat);
                                DRW_shgroup_call_add(default_shgrp, geom, ob->obmat);
 
-                               DRW_shgroup_wire_overlay(passes->wire_overlay_pass, ob);
+                               //DRW_shgroup_wire_overlay(passes->wire_overlay_pass, ob);
 
                                do_outlines  = ((ob->base_flag & BASE_SELECTED) != 0);
-                               DRW_shgroup_wire_outline(passes->wire_outline_pass, ob, false, false, do_outlines);
+                               //DRW_shgroup_wire_outline(passes->wire_outline_pass, ob, false, false, do_outlines);
 
                                /* When encountering a new material :
                                 * - Create new Batch
@@ -650,8 +650,8 @@ static void CLAY_view_draw(RenderEngine *UNUSED(engine), const struct bContext *
 
        /* Pass 4 : Overlays */
        DRW_framebuffer_texture_attach(buffers->default_fb, textures->depth, 0);
-       DRW_draw_pass(passes->wire_overlay_pass);
-       DRW_draw_pass(passes->wire_outline_pass);
+       //DRW_draw_pass(passes->wire_overlay_pass);
+       //DRW_draw_pass(passes->wire_outline_pass);
        DRW_draw_pass(passes->non_meshes_pass);
        DRW_draw_pass(passes->ob_center_pass);