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:
authorCampbell Barton <ideasman42@gmail.com>2019-05-01 04:09:22 +0300
committerCampbell Barton <ideasman42@gmail.com>2019-05-01 04:13:14 +0300
commit909665a0d4ed23620afc537c583a6e84cdee50b9 (patch)
treeada49fe1ae8d78bc5e0c7a79fcccbc2ceaa8a8b8 /source/blender/editors/gpencil
parentf70470b540b78c220f9679c6de2efb4bafc80648 (diff)
ClangFormat: run with ReflowComments on source/
Prepare for enabling ReflowComments.
Diffstat (limited to 'source/blender/editors/gpencil')
-rw-r--r--source/blender/editors/gpencil/annotate_paint.c31
-rw-r--r--source/blender/editors/gpencil/drawgpencil.c2
-rw-r--r--source/blender/editors/gpencil/gpencil_brush.c4
-rw-r--r--source/blender/editors/gpencil/gpencil_edit.c4
-rw-r--r--source/blender/editors/gpencil/gpencil_fill.c2
-rw-r--r--source/blender/editors/gpencil/gpencil_paint.c25
-rw-r--r--source/blender/editors/gpencil/gpencil_undo.c6
-rw-r--r--source/blender/editors/gpencil/gpencil_utils.c17
8 files changed, 44 insertions, 47 deletions
diff --git a/source/blender/editors/gpencil/annotate_paint.c b/source/blender/editors/gpencil/annotate_paint.c
index 7babbadb205..73230e5fb0e 100644
--- a/source/blender/editors/gpencil/annotate_paint.c
+++ b/source/blender/editors/gpencil/annotate_paint.c
@@ -285,17 +285,17 @@ static bool gp_stroke_filtermval(tGPsdata *p, const float mval[2], float pmval[2
return true;
/* check if mouse moved at least certain distance on both axes (best case)
- * - aims to eliminate some jitter-noise from input when trying to draw straight lines freehand
- */
+ * - aims to eliminate some jitter-noise from input when trying to draw straight lines freehand
+ */
}
else if ((dx > MIN_MANHATTEN_PX) && (dy > MIN_MANHATTEN_PX)) {
return true;
/* Check if the distance since the last point is significant enough:
- * - Prevents points being added too densely
- * - Distance here doesn't use sqrt to prevent slowness.
- * We should still be safe from overflows though.
- */
+ * - Prevents points being added too densely
+ * - Distance here doesn't use sqrt to prevent slowness.
+ * We should still be safe from overflows though.
+ */
}
else if ((dx * dx + dy * dy) > MIN_EUCLIDEAN_PX * MIN_EUCLIDEAN_PX) {
return true;
@@ -1361,7 +1361,7 @@ static void gp_paint_initstroke(tGPsdata *p, eGPencil_PaintModes paintmode, Deps
if (has_layer_to_erase == false) {
p->status = GP_STATUS_CAPTURE;
- //if (G.debug & G_DEBUG)
+ // if (G.debug & G_DEBUG)
printf("Error: Eraser will not be affecting anything (gpencil_paint_init)\n");
return;
}
@@ -1544,14 +1544,13 @@ static void gpencil_draw_eraser(bContext *UNUSED(C), int x, int y, void *p_ptr)
immUniform1f("dash_width", 12.0f);
immUniform1f("dash_factor", 0.5f);
- imm_draw_circle_wire_2d(
- shdr_pos,
- x,
- y,
- p->radius,
- /* XXX Dashed shader gives bad results with sets of small segments currently,
- * temp hack around the issue. :( */
- max_ii(8, p->radius / 2)); /* was fixed 40 */
+ imm_draw_circle_wire_2d(shdr_pos,
+ x,
+ y,
+ p->radius,
+ /* XXX Dashed shader gives bad results with sets of small segments
+ * currently, temp hack around the issue. :( */
+ max_ii(8, p->radius / 2)); /* was fixed 40 */
immUnbindProgram();
@@ -2234,7 +2233,7 @@ static int gpencil_draw_modal(bContext *C, wmOperator *op, const wmEvent *event)
}
}
- //printf("\tGP - handle modal event...\n");
+ // printf("\tGP - handle modal event...\n");
/* Exit painting mode (and/or end current stroke)
*
diff --git a/source/blender/editors/gpencil/drawgpencil.c b/source/blender/editors/gpencil/drawgpencil.c
index 76e13ec4eb5..ef74aa28b63 100644
--- a/source/blender/editors/gpencil/drawgpencil.c
+++ b/source/blender/editors/gpencil/drawgpencil.c
@@ -919,7 +919,7 @@ static void gp_draw_strokes(tGPDdraw *tgpw)
}
/* 3D Fill */
- //if ((dflag & GP_DRAWDATA_FILL) && (gps->totpoints >= 3)) {
+ // if ((dflag & GP_DRAWDATA_FILL) && (gps->totpoints >= 3)) {
if ((gps->totpoints >= 3) && (tgpw->disable_fill != 1)) {
/* set color using material, tint color and opacity */
interp_v3_v3v3(tfill, gp_style->fill_rgba, tgpw->tintcolor, tgpw->tintcolor[3]);
diff --git a/source/blender/editors/gpencil/gpencil_brush.c b/source/blender/editors/gpencil/gpencil_brush.c
index 8225e9bae78..9777a8190c1 100644
--- a/source/blender/editors/gpencil/gpencil_brush.c
+++ b/source/blender/editors/gpencil/gpencil_brush.c
@@ -1326,7 +1326,7 @@ static bool gpsculpt_brush_init(bContext *C, wmOperator *op)
gpsculpt_brush_header_set(C, gso);
/* setup cursor drawing */
- //WM_cursor_modal_set(CTX_wm_window(C), BC_CROSSCURSOR);
+ // WM_cursor_modal_set(CTX_wm_window(C), BC_CROSSCURSOR);
if (gso->sa->spacetype != SPACE_VIEW3D) {
ED_gpencil_toggle_brush_cursor(C, true, NULL);
}
@@ -2007,7 +2007,7 @@ static int gpsculpt_brush_modal(bContext *C, wmOperator *op, const wmEvent *even
/* Painting mbut release = Stop painting (back to idle) */
case LEFTMOUSE:
- //BLI_assert(event->val == KM_RELEASE);
+ // BLI_assert(event->val == KM_RELEASE);
if (is_modal) {
/* go back to idling... */
gso->is_painting = false;
diff --git a/source/blender/editors/gpencil/gpencil_edit.c b/source/blender/editors/gpencil/gpencil_edit.c
index 7b65a51e8a9..463c2144276 100644
--- a/source/blender/editors/gpencil/gpencil_edit.c
+++ b/source/blender/editors/gpencil/gpencil_edit.c
@@ -619,7 +619,7 @@ static void gp_duplicate_points(const bGPDstroke *gps,
else if (i == gps->totpoints - 1) {
len = i - start_idx + 1;
}
- //printf("copying from %d to %d = %d\n", start_idx, i, len);
+ // printf("copying from %d to %d = %d\n", start_idx, i, len);
/* make copies of the relevant data */
if (len) {
@@ -1212,7 +1212,7 @@ void GPENCIL_OT_copy(wmOperatorType *ot)
ot->poll = gp_stroke_edit_poll;
/* flags */
- //ot->flag = OPTYPE_REGISTER;
+ // ot->flag = OPTYPE_REGISTER;
}
/* --------------------- */
diff --git a/source/blender/editors/gpencil/gpencil_fill.c b/source/blender/editors/gpencil/gpencil_fill.c
index 616db4b73f7..96f405fab2f 100644
--- a/source/blender/editors/gpencil/gpencil_fill.c
+++ b/source/blender/editors/gpencil/gpencil_fill.c
@@ -455,7 +455,7 @@ static void get_pixel(const ImBuf *ibuf, const int idx, float r_col[4])
/* set pixel data (rgba) at index */
static void set_pixel(ImBuf *ibuf, int idx, const float col[4])
{
- //BLI_assert(idx <= ibuf->x * ibuf->y);
+ // BLI_assert(idx <= ibuf->x * ibuf->y);
if (ibuf->rect) {
uint *rrect = &ibuf->rect[idx];
uchar ccol[4];
diff --git a/source/blender/editors/gpencil/gpencil_paint.c b/source/blender/editors/gpencil/gpencil_paint.c
index 21ddfc3cd13..b1b29356060 100644
--- a/source/blender/editors/gpencil/gpencil_paint.c
+++ b/source/blender/editors/gpencil/gpencil_paint.c
@@ -372,10 +372,10 @@ static bool gp_stroke_filtermval(tGPsdata *p, const float mval[2], float mvalo[2
return true;
/* Check if the distance since the last point is significant enough:
- * - Prevents points being added too densely
- * - Distance here doesn't use sqrt to prevent slowness.
- * We should still be safe from overflows though.
- */
+ * - Prevents points being added too densely
+ * - Distance here doesn't use sqrt to prevent slowness.
+ * We should still be safe from overflows though.
+ */
}
else if ((dx * dx + dy * dy) > MIN_EUCLIDEAN_PX * MIN_EUCLIDEAN_PX) {
return true;
@@ -2319,14 +2319,13 @@ static void gpencil_draw_eraser(bContext *UNUSED(C), int x, int y, void *p_ptr)
immUniform1f("dash_width", 12.0f);
immUniform1f("dash_factor", 0.5f);
- imm_draw_circle_wire_2d(
- shdr_pos,
- x,
- y,
- p->radius,
- /* XXX Dashed shader gives bad results with sets of small segments currently,
- * temp hack around the issue. :( */
- max_ii(8, p->radius / 2)); /* was fixed 40 */
+ imm_draw_circle_wire_2d(shdr_pos,
+ x,
+ y,
+ p->radius,
+ /* XXX Dashed shader gives bad results with sets of small segments
+ * currently, temp hack around the issue. :( */
+ max_ii(8, p->radius / 2)); /* was fixed 40 */
immUnbindProgram();
@@ -3508,7 +3507,7 @@ static int gpencil_draw_modal(bContext *C, wmOperator *op, const wmEvent *event)
}
}
- //printf("\tGP - handle modal event...\n");
+ // printf("\tGP - handle modal event...\n");
/* Exit painting mode (and/or end current stroke).
*
diff --git a/source/blender/editors/gpencil/gpencil_undo.c b/source/blender/editors/gpencil/gpencil_undo.c
index bf077d528dd..7b57dacd3e4 100644
--- a/source/blender/editors/gpencil/gpencil_undo.c
+++ b/source/blender/editors/gpencil/gpencil_undo.c
@@ -68,7 +68,7 @@ int ED_undo_gpencil_step(bContext *C, int step, const char *name)
gpd_ptr = ED_gpencil_data_get_pointers(C, NULL);
if (step == 1) { /* undo */
- //printf("\t\tGP - undo step\n");
+ // printf("\t\tGP - undo step\n");
if (cur_node->prev) {
if (!name || STREQ(cur_node->name, name)) {
cur_node = cur_node->prev;
@@ -77,7 +77,7 @@ int ED_undo_gpencil_step(bContext *C, int step, const char *name)
}
}
else if (step == -1) {
- //printf("\t\tGP - redo step\n");
+ // printf("\t\tGP - redo step\n");
if (cur_node->next) {
if (!name || STREQ(cur_node->name, name)) {
cur_node = cur_node->next;
@@ -134,7 +134,7 @@ void gpencil_undo_push(bGPdata *gpd)
{
bGPundonode *undo_node;
- //printf("\t\tGP - undo push\n");
+ // printf("\t\tGP - undo push\n");
if (cur_node) {
/* remove all un-done nodes from stack */
diff --git a/source/blender/editors/gpencil/gpencil_utils.c b/source/blender/editors/gpencil/gpencil_utils.c
index 0d920641c5d..129bd01574c 100644
--- a/source/blender/editors/gpencil/gpencil_utils.c
+++ b/source/blender/editors/gpencil/gpencil_utils.c
@@ -1689,14 +1689,13 @@ void ED_gpencil_brush_draw_eraser(Brush *brush, int x, int y)
immUniform1f("dash_width", 12.0f);
immUniform1f("dash_factor", 0.5f);
- imm_draw_circle_wire_2d(
- shdr_pos,
- x,
- y,
- radius,
- /* XXX Dashed shader gives bad results with sets of small segments currently,
- * temp hack around the issue. :( */
- max_ii(8, radius / 2)); /* was fixed 40 */
+ imm_draw_circle_wire_2d(shdr_pos,
+ x,
+ y,
+ radius,
+ /* XXX Dashed shader gives bad results with sets of small segments
+ * currently, temp hack around the issue. :( */
+ max_ii(8, radius / 2)); /* was fixed 40 */
immUnbindProgram();
@@ -2514,7 +2513,7 @@ void ED_gpencil_select_toggle_all(bContext *C, int action)
case SEL_SELECT:
pt->flag |= GP_SPOINT_SELECT;
break;
- //case SEL_DESELECT:
+ // case SEL_DESELECT:
// pt->flag &= ~GP_SPOINT_SELECT;
// break;
case SEL_INVERT: