Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/sculpt_paint/paint_image_ops_paint.cc
| Show First 20 Lines • Show All 247 Lines • ▼ Show 20 Lines | if (pop) { | ||||
| GPU_line_smooth(true); | GPU_line_smooth(true); | ||||
| GPU_blend(GPU_BLEND_ALPHA); | GPU_blend(GPU_BLEND_ALPHA); | ||||
| 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); | ||||
| ARegion *region = pop->vc.region; | ARegion *region = pop->vc.region; | ||||
| immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR); | immBindBuiltinProgram(GPU_SHADER_3D_UNIFORM_COLOR); | ||||
| GPU_line_width(4.0); | GPU_line_width(4.0); | ||||
| immUniformColor4ub(0, 0, 0, 255); | immUniformColor4ub(0, 0, 0, 255); | ||||
| immBegin(GPU_PRIM_LINES, 2); | immBegin(GPU_PRIM_LINES, 2); | ||||
| immVertex2i(pos, x, y); | immVertex2i(pos, x, y); | ||||
| immVertex2i( | immVertex2i( | ||||
| pos, pop->startmouse[0] + region->winrct.xmin, pop->startmouse[1] + region->winrct.ymin); | pos, pop->startmouse[0] + region->winrct.xmin, pop->startmouse[1] + region->winrct.ymin); | ||||
| ▲ Show 20 Lines • Show All 270 Lines • Show Last 20 Lines | |||||