Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/space_view3d/view3d_navigate_walk.c
| Show First 20 Lines • Show All 329 Lines • ▼ Show 20 Lines | static void drawWalkPixel(const struct bContext *UNUSED(C), ARegion *region, void *arg) | ||||
| else { | else { | ||||
| xoff = walk->region->winx / 2; | xoff = walk->region->winx / 2; | ||||
| yoff = walk->region->winy / 2; | yoff = walk->region->winy / 2; | ||||
| } | } | ||||
| GPUVertFormat *format = immVertexFormat(); | GPUVertFormat *format = immVertexFormat(); | ||||
| uint pos = GPU_vertformat_attr_add(format, "pos", GPU_COMP_I32, 2, GPU_FETCH_INT_TO_FLOAT); | uint pos = GPU_vertformat_attr_add(format, "pos", GPU_COMP_I32, 2, GPU_FETCH_INT_TO_FLOAT); | ||||
| immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR); | immBindBuiltinProgram(GPU_SHADER_3D_UNIFORM_COLOR); | ||||
| immUniformThemeColorAlpha(TH_VIEW_OVERLAY, 1.0f); | immUniformThemeColorAlpha(TH_VIEW_OVERLAY, 1.0f); | ||||
| immBegin(GPU_PRIM_LINES, 8); | immBegin(GPU_PRIM_LINES, 8); | ||||
| /* North */ | /* North */ | ||||
| immVertex2i(pos, xoff, yoff + inner_length); | immVertex2i(pos, xoff, yoff + inner_length); | ||||
| immVertex2i(pos, xoff, yoff + outter_length); | immVertex2i(pos, xoff, yoff + outter_length); | ||||
| ▲ Show 20 Lines • Show All 1,105 Lines • Show Last 20 Lines | |||||