Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/editors/transform/transform.c')
-rw-r--r--source/blender/editors/transform/transform.c32
1 files changed, 16 insertions, 16 deletions
diff --git a/source/blender/editors/transform/transform.c b/source/blender/editors/transform/transform.c
index e9abdd80d20..dab53c04806 100644
--- a/source/blender/editors/transform/transform.c
+++ b/source/blender/editors/transform/transform.c
@@ -1689,13 +1689,13 @@ typedef enum {
} ArrowDirection;
#define POS_INDEX 0
-/* NOTE: this --^ is a bit hackish, but simplifies Gwn_VertFormat usage among functions
+/* NOTE: this --^ is a bit hackish, but simplifies GPUVertFormat usage among functions
* private to this file - merwin
*/
static void drawArrow(ArrowDirection d, short offset, short length, short size)
{
- immBegin(GWN_PRIM_LINES, 6);
+ immBegin(GPU_PRIM_LINES, 6);
switch (d) {
case LEFT:
@@ -1732,7 +1732,7 @@ static void drawArrow(ArrowDirection d, short offset, short length, short size)
static void drawArrowHead(ArrowDirection d, short size)
{
- immBegin(GWN_PRIM_LINES, 4);
+ immBegin(GPU_PRIM_LINES, 4);
switch (d) {
case LEFT:
@@ -1765,7 +1765,7 @@ static void drawArc(float size, float angle_start, float angle_end, int segments
float angle;
int a;
- immBegin(GWN_PRIM_LINE_STRIP, segments + 1);
+ immBegin(GPU_PRIM_LINE_STRIP, segments + 1);
for (angle = angle_start, a = 0; a < segments; angle += delta, a++) {
immVertex2f(POS_INDEX, cosf(angle) * size, sinf(angle) * size);
@@ -1817,7 +1817,7 @@ static void drawHelpline(bContext *UNUSED(C), int x, int y, void *customdata)
/* Dashed lines first. */
if (ELEM(t->helpline, HLP_SPRING, HLP_ANGLE)) {
- const uint shdr_pos = GWN_vertformat_attr_add(immVertexFormat(), "pos", GWN_COMP_F32, 2, GWN_FETCH_FLOAT);
+ const uint shdr_pos = GPU_vertformat_attr_add(immVertexFormat(), "pos", GPU_COMP_F32, 2, GPU_FETCH_FLOAT);
UNUSED_VARS_NDEBUG(shdr_pos); /* silence warning */
BLI_assert(shdr_pos == POS_INDEX);
@@ -1835,7 +1835,7 @@ static void drawHelpline(bContext *UNUSED(C), int x, int y, void *customdata)
immUniform1f("dash_width", 6.0f);
immUniform1f("dash_factor", 0.5f);
- immBegin(GWN_PRIM_LINES, 2);
+ immBegin(GPU_PRIM_LINES, 2);
immVertex2fv(POS_INDEX, cent);
immVertex2f(POS_INDEX, tmval[0], tmval[1]);
immEnd();
@@ -1844,7 +1844,7 @@ static void drawHelpline(bContext *UNUSED(C), int x, int y, void *customdata)
}
/* And now, solid lines. */
- uint pos = GWN_vertformat_attr_add(immVertexFormat(), "pos", GWN_COMP_F32, 2, GWN_FETCH_FLOAT);
+ uint pos = GPU_vertformat_attr_add(immVertexFormat(), "pos", GPU_COMP_F32, 2, GPU_FETCH_FLOAT);
UNUSED_VARS_NDEBUG(pos); /* silence warning */
BLI_assert(pos == POS_INDEX);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
@@ -7052,7 +7052,7 @@ static void drawEdgeSlide(TransInfo *t)
GPU_matrix_push();
GPU_matrix_mul(TRANS_DATA_CONTAINER_FIRST_OK(t)->obedit->obmat);
- uint pos = GWN_vertformat_attr_add(immVertexFormat(), "pos", GWN_COMP_F32, 3, GWN_FETCH_FLOAT);
+ uint pos = GPU_vertformat_attr_add(immVertexFormat(), "pos", GPU_COMP_F32, 3, GPU_FETCH_FLOAT);
immBindBuiltinProgram(GPU_SHADER_3D_UNIFORM_COLOR);
@@ -7069,7 +7069,7 @@ static void drawEdgeSlide(TransInfo *t)
GPU_line_width(line_size);
immUniformThemeColorShadeAlpha(TH_EDGE_SELECT, 80, alpha_shade);
- immBeginAtMost(GWN_PRIM_LINES, 4);
+ immBeginAtMost(GPU_PRIM_LINES, 4);
if (curr_sv->v_side[0]) {
immVertex3fv(pos, curr_sv->v_side[0]->co);
immVertex3fv(pos, curr_sv->v_co_orig);
@@ -7082,7 +7082,7 @@ static void drawEdgeSlide(TransInfo *t)
immUniformThemeColorShadeAlpha(TH_SELECT, -30, alpha_shade);
GPU_point_size(ctrl_size);
- immBegin(GWN_PRIM_POINTS, 1);
+ immBegin(GPU_PRIM_POINTS, 1);
if (slp->flipped) {
if (curr_sv->v_side[1]) immVertex3fv(pos, curr_sv->v_side[1]->co);
}
@@ -7093,7 +7093,7 @@ static void drawEdgeSlide(TransInfo *t)
immUniformThemeColorShadeAlpha(TH_SELECT, 255, alpha_shade);
GPU_point_size(guide_size);
- immBegin(GWN_PRIM_POINTS, 1);
+ immBegin(GPU_PRIM_POINTS, 1);
interp_line_v3_v3v3v3(co_mark, co_b, curr_sv->v_co_orig, co_a, fac);
immVertex3fv(pos, co_mark);
immEnd();
@@ -7107,7 +7107,7 @@ static void drawEdgeSlide(TransInfo *t)
GPU_line_width(line_size);
immUniformThemeColorShadeAlpha(TH_EDGE_SELECT, 80, alpha_shade);
- immBegin(GWN_PRIM_LINES, sld->totsv * 2);
+ immBegin(GPU_PRIM_LINES, sld->totsv * 2);
/* TODO(campbell): Loop over all verts */
sv = sld->sv;
@@ -7687,12 +7687,12 @@ static void drawVertSlide(TransInfo *t)
GPU_line_width(line_size);
- const uint shdr_pos = GWN_vertformat_attr_add(immVertexFormat(), "pos", GWN_COMP_F32, 3, GWN_FETCH_FLOAT);
+ const uint shdr_pos = GPU_vertformat_attr_add(immVertexFormat(), "pos", GPU_COMP_F32, 3, GPU_FETCH_FLOAT);
immBindBuiltinProgram(GPU_SHADER_3D_UNIFORM_COLOR);
immUniformThemeColorShadeAlpha(TH_EDGE_SELECT, 80, alpha_shade);
- immBegin(GWN_PRIM_LINES, sld->totsv * 2);
+ immBegin(GPU_PRIM_LINES, sld->totsv * 2);
if (is_clamp) {
sv = sld->sv;
for (i = 0; i < sld->totsv; i++, sv++) {
@@ -7718,7 +7718,7 @@ static void drawVertSlide(TransInfo *t)
GPU_point_size(ctrl_size);
- immBegin(GWN_PRIM_POINTS, 1);
+ immBegin(GPU_PRIM_POINTS, 1);
immVertex3fv(shdr_pos, (slp->flipped && slp->use_even) ?
curr_sv->co_link_orig_3d[curr_sv->co_link_curr] :
curr_sv->co_orig_3d);
@@ -7761,7 +7761,7 @@ static void drawVertSlide(TransInfo *t)
immUniform1f("dash_width", 6.0f);
immUniform1f("dash_factor", 0.5f);
- immBegin(GWN_PRIM_LINES, 2);
+ immBegin(GPU_PRIM_LINES, 2);
immVertex3fv(shdr_pos, curr_sv->co_orig_3d);
immVertex3fv(shdr_pos, co_dest_3d);
immEnd();