Simple convert of drawing emboss lines to new immediate mode.
Part of T49043
Differential D2271
draw region emboss with new immediate mode Authored by Anthony Edlin (krash) on Oct 4 2016, 10:31 AM.
Details
Diff Detail Event TimelineComment Actions Looks good! Challenge: get it down from 8 vertices to 5 with a GL_LINE_STRIP. (could get it down to 4 with GL_LINE_LOOP but Vulkan doesn't have line loops) Comment Actions Out of curiosity, did you use arcanist to send the patch? I can't apply the patch directly here. As for GL_LINE_STRIP I don't think you can do it with 5 vertices, given that the color change for half the lines. Comment Actions You totally can since GPU_SHADER_2D_FLAT_COLOR uses the color of each line segment's provoking vertex. Comment Actions New diff with only 5 verts as suggested. I noticed while fooling with this that it doesn't work in double pixel mode for retina like displays on linux, but it didn't work before either. I didn't use Arc, just uploaded a diff file. Comment Actions Perfect! @Anthony Edlin (krash) can you commit this, or should one of us do it & give you credit? |