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:
authorJulian Eisel <eiseljulian@gmail.com>2017-02-22 20:52:07 +0300
committerJulian Eisel <eiseljulian@gmail.com>2017-02-22 20:54:56 +0300
commit9c106ff2112dedb4bb7e36f9c0805921c82aede0 (patch)
tree3d2628471423e0faac0962a7aa0dd09d5487406e /source/blender/editors
parentefc499cb991f1a432632d7c3a38070d36a3168b4 (diff)
Cleanup: Style
Diffstat (limited to 'source/blender/editors')
-rw-r--r--source/blender/editors/interface/interface_icons.c6
-rw-r--r--source/blender/editors/interface/interface_widgets.c6
-rw-r--r--source/blender/editors/interface/view2d.c6
-rw-r--r--source/blender/editors/screen/area.c50
-rw-r--r--source/blender/editors/screen/screendump.c4
-rw-r--r--source/blender/editors/sculpt_paint/paint_image.c4
-rw-r--r--source/blender/editors/space_action/action_draw.c4
-rw-r--r--source/blender/editors/space_console/console_draw.c4
-rw-r--r--source/blender/editors/space_file/file_draw.c10
-rw-r--r--source/blender/editors/space_node/drawnode.c12
-rw-r--r--source/blender/editors/space_outliner/outliner_edit.c2
-rw-r--r--source/blender/editors/space_outliner/outliner_select.c28
-rw-r--r--source/blender/editors/space_outliner/outliner_tools.c2
-rw-r--r--source/blender/editors/space_view3d/drawsimdebug.c6
-rw-r--r--source/blender/editors/space_view3d/view3d_draw.c40
-rw-r--r--source/blender/editors/space_view3d/view3d_draw_legacy.c2
-rw-r--r--source/blender/editors/space_view3d/view3d_fly.c4
-rw-r--r--source/blender/editors/space_view3d/view3d_walk.c4
-rw-r--r--source/blender/editors/uvedit/uvedit_draw.c6
19 files changed, 100 insertions, 100 deletions
diff --git a/source/blender/editors/interface/interface_icons.c b/source/blender/editors/interface/interface_icons.c
index 7d87527bdad..d6dcd0208f4 100644
--- a/source/blender/editors/interface/interface_icons.c
+++ b/source/blender/editors/interface/interface_icons.c
@@ -1051,9 +1051,9 @@ static void icon_draw_texture(
glTexEnvf(GL_TEXTURE_FILTER_CONTROL, GL_TEXTURE_LOD_BIAS, -0.5f);
glBindTexture(GL_TEXTURE_2D, icongltex.id);
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
- unsigned texCoord = add_attrib(format, "texCoord", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ unsigned int texCoord = add_attrib(format, "texCoord", GL_FLOAT, 2, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_IMAGE_COLOR);
if (rgb) immUniformColor3fvAlpha(rgb, alpha);
diff --git a/source/blender/editors/interface/interface_widgets.c b/source/blender/editors/interface/interface_widgets.c
index 6356ce1574c..ab6d14dd0e6 100644
--- a/source/blender/editors/interface/interface_widgets.c
+++ b/source/blender/editors/interface/interface_widgets.c
@@ -2351,9 +2351,9 @@ static void ui_draw_but_HSVCIRCLE(uiBut *but, uiWidgetColors *wcol, const rcti *
ui_color_picker_to_rgb(0.0f, 0.0f, hsv[2], colcent, colcent + 1, colcent + 2);
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
- unsigned color = add_attrib(format, "color", GL_FLOAT, 3, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ unsigned int color = add_attrib(format, "color", GL_FLOAT, 3, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_SMOOTH_COLOR);
diff --git a/source/blender/editors/interface/view2d.c b/source/blender/editors/interface/view2d.c
index bcac8d0b825..5c2d4cafd84 100644
--- a/source/blender/editors/interface/view2d.c
+++ b/source/blender/editors/interface/view2d.c
@@ -1468,9 +1468,9 @@ void UI_view2d_constant_grid_draw(View2D *v2d)
count_y = (v2d->cur.ymax - start_y) / step + 1;
if (count_x > 0 || count_y > 0) {
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
- unsigned color = add_attrib(format, "color", GL_FLOAT, 3, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ unsigned int color = add_attrib(format, "color", GL_FLOAT, 3, KEEP_FLOAT);
float theme_color[3];
UI_GetThemeColorShade3fv(TH_BACK, -10, theme_color);
diff --git a/source/blender/editors/screen/area.c b/source/blender/editors/screen/area.c
index cc47667772d..46864f6c549 100644
--- a/source/blender/editors/screen/area.c
+++ b/source/blender/editors/screen/area.c
@@ -92,9 +92,9 @@ static void region_draw_emboss(const ARegion *ar, const rcti *scirct)
glEnable(GL_BLEND);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
- unsigned color = add_attrib(format, "color", GL_UNSIGNED_BYTE, 4, NORMALIZE_INT_TO_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ unsigned int color = add_attrib(format, "color", GL_UNSIGNED_BYTE, 4, NORMALIZE_INT_TO_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_FLAT_COLOR);
immBegin(GL_LINE_STRIP, 5);
@@ -222,9 +222,9 @@ static void area_draw_azone_fullscreen(short x1, short y1, short x2, short y2, f
BLI_rcti_init(&click_rect, x, x + icon_size, y, y + icon_size);
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
- unsigned color = add_attrib(format, "color", GL_UNSIGNED_BYTE, 4, NORMALIZE_INT_TO_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ unsigned int color = add_attrib(format, "color", GL_UNSIGNED_BYTE, 4, NORMALIZE_INT_TO_FLOAT);
immAttrib4ub(color, 255, 0, 0, alpha_debug);
immBindBuiltinProgram(GPU_SHADER_2D_FLAT_COLOR);
@@ -255,9 +255,9 @@ static void area_draw_azone(short x1, short y1, short x2, short y2)
glEnable(GL_LINE_SMOOTH);
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
- unsigned col = add_attrib(format, "color", GL_UNSIGNED_BYTE, 4, NORMALIZE_INT_TO_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ unsigned int col = add_attrib(format, "color", GL_UNSIGNED_BYTE, 4, NORMALIZE_INT_TO_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_FLAT_COLOR);
immBegin(GL_LINES, 12);
@@ -297,8 +297,8 @@ static void region_draw_azone_icon(AZone *az)
float midx = az->x1 + (az->x2 - az->x1) * 0.5f;
float midy = az->y1 + (az->y2 - az->y1) * 0.5f;
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
/* outlined circle */
GPU_enable_program_point_size(); /* TODO: make a fixed-size shader to avoid this */
@@ -330,8 +330,8 @@ static void draw_azone_plus(float x1, float y1, float x2, float y2)
float width = 0.1f * U.widget_unit;
float pad = 0.2f * U.widget_unit;
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
glEnable(GL_BLEND);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
@@ -570,8 +570,8 @@ void ED_region_do_draw(bContext *C, ARegion *ar)
/* for debugging unneeded area redraws and partial redraw */
#if 0
glEnable(GL_BLEND);
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
immUniformColor4f(drand48(), drand48(), drand48(), 0.1f);
immRectf(pos, ar->drawrct.xmin - ar->winrct.xmin, ar->drawrct.ymin - ar->winrct.ymin,
@@ -2014,8 +2014,8 @@ void ED_region_panels(const bContext *C, ARegion *ar, const char *context, int c
/* view should be in pixelspace */
UI_view2d_view_restore(C);
glEnable(GL_BLEND);
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", COMP_I32, 2, CONVERT_INT_TO_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", COMP_I32, 2, CONVERT_INT_TO_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
immUniformThemeColor((ar->type->regionid == RGN_TYPE_PREVIEW) ? TH_PREVIEW_BACK : TH_BACK);
immRecti(pos, 0, 0, BLI_rcti_size_x(&ar->winrct), BLI_rcti_size_y(&ar->winrct) + 1);
@@ -2148,8 +2148,8 @@ void ED_region_info_draw(ARegion *ar, const char *text, float fill_color[4], con
glEnable(GL_BLEND);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_INT, 2, CONVERT_INT_TO_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_INT, 2, CONVERT_INT_TO_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
immUniformColor4fv(fill_color);
immRecti(pos, rect.xmin, rect.ymin, rect.xmax + 1, rect.ymax + 1);
@@ -2355,8 +2355,8 @@ void ED_region_image_metadata_draw(int x, int y, ImBuf *ibuf, const rctf *frame,
/* set up rect */
BLI_rctf_init(&rect, frame->xmin, frame->xmax, frame->ymax, frame->ymax + box_y);
/* draw top box */
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
immUniformThemeColor(TH_METADATA_BG);
immRectf(pos, rect.xmin, rect.ymin, rect.xmax, rect.ymax);
@@ -2380,8 +2380,8 @@ void ED_region_image_metadata_draw(int x, int y, ImBuf *ibuf, const rctf *frame,
/* set up box rect */
BLI_rctf_init(&rect, frame->xmin, frame->xmax, frame->ymin - box_y, frame->ymin);
/* draw top box */
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
immUniformThemeColor(TH_METADATA_BG);
immRectf(pos, rect.xmin, rect.ymin, rect.xmax, rect.ymax);
@@ -2409,8 +2409,8 @@ void ED_region_grid_draw(ARegion *ar, float zoomx, float zoomy)
UI_view2d_view_to_region(&ar->v2d, 0.0f, 0.0f, &x1, &y1);
UI_view2d_view_to_region(&ar->v2d, 1.0f, 1.0f, &x2, &y2);
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
immUniformThemeColorShade(TH_BACK, 20);
diff --git a/source/blender/editors/screen/screendump.c b/source/blender/editors/screen/screendump.c
index 6bfa51bf9fc..5a8ea10cb0a 100644
--- a/source/blender/editors/screen/screendump.c
+++ b/source/blender/editors/screen/screendump.c
@@ -456,8 +456,8 @@ static void screencast_draw_cursor(bContext *UNUSED(C), int x, int y, void *UNUS
glEnable(GL_LINE_SMOOTH);
glEnable(GL_BLEND);
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
diff --git a/source/blender/editors/sculpt_paint/paint_image.c b/source/blender/editors/sculpt_paint/paint_image.c
index ffaaed8ab42..9850b2c93f0 100644
--- a/source/blender/editors/sculpt_paint/paint_image.c
+++ b/source/blender/editors/sculpt_paint/paint_image.c
@@ -722,8 +722,8 @@ static void gradient_draw_line(bContext *UNUSED(C), int x, int y, void *customda
glEnable(GL_LINE_SMOOTH);
glEnable(GL_BLEND);
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_INT, 2, CONVERT_INT_TO_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_INT, 2, CONVERT_INT_TO_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
diff --git a/source/blender/editors/space_action/action_draw.c b/source/blender/editors/space_action/action_draw.c
index f2707b9399f..4c65207d9a0 100644
--- a/source/blender/editors/space_action/action_draw.c
+++ b/source/blender/editors/space_action/action_draw.c
@@ -204,8 +204,8 @@ void draw_channel_strips(bAnimContext *ac, SpaceAction *saction, ARegion *ar)
/* first backdrop strips */
y = (float)(-ACHANNEL_HEIGHT(ac));
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
diff --git a/source/blender/editors/space_console/console_draw.c b/source/blender/editors/space_console/console_draw.c
index c45b8acae0a..8055e262611 100644
--- a/source/blender/editors/space_console/console_draw.c
+++ b/source/blender/editors/space_console/console_draw.c
@@ -158,8 +158,8 @@ static int console_textview_line_color(struct TextViewContext *tvc, unsigned cha
int offl = 0, offc = 0;
int xy[2] = {CONSOLE_DRAW_MARGIN, CONSOLE_DRAW_MARGIN};
int pen[2];
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
xy[1] += tvc->lheight / 6;
console_cursor_wrap_offset(sc->prompt, tvc->console_width, &offl, &offc, NULL);
diff --git a/source/blender/editors/space_file/file_draw.c b/source/blender/editors/space_file/file_draw.c
index 06066372828..dff32a5f0d5 100644
--- a/source/blender/editors/space_file/file_draw.c
+++ b/source/blender/editors/space_file/file_draw.c
@@ -400,8 +400,8 @@ static void file_draw_preview(
/* border */
if (use_dropshadow) {
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2,KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2,KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
immUniformColor4f(0.0f, 0.0f, 0.0f, 0.4f);
@@ -481,9 +481,9 @@ static void draw_dividers(FileLayout *layout, View2D *v2d)
unsigned int vertex_ct = 0;
unsigned char col_hi[3], col_lo[3];
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_INT, 2, CONVERT_INT_TO_FLOAT);
- unsigned color = add_attrib(format, "color", GL_UNSIGNED_BYTE, 3, NORMALIZE_INT_TO_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_INT, 2, CONVERT_INT_TO_FLOAT);
+ unsigned int color = add_attrib(format, "color", GL_UNSIGNED_BYTE, 3, NORMALIZE_INT_TO_FLOAT);
vertex_ct = (v2d->cur.xmax - v2d->tot.xmin) / step + 1; /* paint at least 1 divider */
vertex_ct *= 4; /* vertex_count = 2 points per divider * 2 lines per divider */
diff --git a/source/blender/editors/space_node/drawnode.c b/source/blender/editors/space_node/drawnode.c
index 5940ed5f0c1..0b292e242f0 100644
--- a/source/blender/editors/space_node/drawnode.c
+++ b/source/blender/editors/space_node/drawnode.c
@@ -2176,8 +2176,8 @@ static void node_composit_backdrop_viewer(SpaceNode *snode, ImBuf *backdrop, bNo
const float cx = x + snode->zoom * backdropWidth * node->custom3;
const float cy = y + snode->zoom * backdropHeight * node->custom4;
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
@@ -2221,8 +2221,8 @@ static void node_composit_backdrop_boxmask(SpaceNode *snode, ImBuf *backdrop, bN
y3 = cy - (-sine * -halveBoxWidth + cosine * -halveBoxHeight) * snode->zoom;
y4 = cy - (-sine * halveBoxWidth + cosine * -halveBoxHeight) * snode->zoom;
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
@@ -2265,8 +2265,8 @@ static void node_composit_backdrop_ellipsemask(SpaceNode *snode, ImBuf *backdrop
y3 = cy - (-sine * -halveBoxWidth + cosine * -halveBoxHeight) * snode->zoom;
y4 = cy - (-sine * halveBoxWidth + cosine * -halveBoxHeight) * snode->zoom;
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
diff --git a/source/blender/editors/space_outliner/outliner_edit.c b/source/blender/editors/space_outliner/outliner_edit.c
index 7ef968fb33a..5f3931a4a77 100644
--- a/source/blender/editors/space_outliner/outliner_edit.c
+++ b/source/blender/editors/space_outliner/outliner_edit.c
@@ -855,7 +855,7 @@ bool outliner_set_flag(ListBase *lb, short flag, short set)
changed = true;
}
}
- else if (!has_flag){
+ else if (!has_flag) {
tselem->flag |= flag;
changed = true;
}
diff --git a/source/blender/editors/space_outliner/outliner_select.c b/source/blender/editors/space_outliner/outliner_select.c
index 38b83179e7f..85b4c33c3f1 100644
--- a/source/blender/editors/space_outliner/outliner_select.c
+++ b/source/blender/editors/space_outliner/outliner_select.c
@@ -199,7 +199,7 @@ static eOLDrawState tree_element_set_active_object(
}
static eOLDrawState tree_element_active_material(
- bContext *C, Scene* UNUSED(scene), SceneLayer *sl, SpaceOops *soops,
+ bContext *C, Scene *UNUSED(scene), SceneLayer *sl, SpaceOops *soops,
TreeElement *te, const eOLSetState set)
{
TreeElement *tes;
@@ -786,17 +786,17 @@ eOLDrawState tree_element_active(bContext *C, Scene *scene, SceneLayer *sl, Spac
}
break;
case ID_MA:
- return tree_element_active_material(C, scene, sl, soops, te, set);
+ return tree_element_active_material(C, scene, sl, soops, te, set);
case ID_WO:
- return tree_element_active_world(C, scene, sl, soops, te, set);
+ return tree_element_active_world(C, scene, sl, soops, te, set);
case ID_LA:
- return tree_element_active_lamp(C, scene, sl, soops, te, set);
+ return tree_element_active_lamp(C, scene, sl, soops, te, set);
case ID_TE:
- return tree_element_active_texture(C, scene, sl, soops, te, set);
+ return tree_element_active_texture(C, scene, sl, soops, te, set);
case ID_TXT:
- return tree_element_active_text(C, scene, sl, soops, te, set);
+ return tree_element_active_text(C, scene, sl, soops, te, set);
case ID_CA:
- return tree_element_active_camera(C, scene, sl, soops, te, set);
+ return tree_element_active_camera(C, scene, sl, soops, te, set);
}
return OL_DRAWSEL_NONE;
}
@@ -818,7 +818,7 @@ eOLDrawState tree_element_type_active(
case TSE_EBONE:
return tree_element_active_ebone(C, scene, te, tselem, set, recursive);
case TSE_MODIFIER:
- return tree_element_active_modifier(C, scene, sl, te, tselem, set);
+ return tree_element_active_modifier(C, scene, sl, te, tselem, set);
case TSE_LINKED_OB:
if (set != OL_SETSEL_NONE) {
tree_element_set_active_object(C, scene, sl, soops, te, set, false);
@@ -832,21 +832,21 @@ eOLDrawState tree_element_type_active(
case TSE_POSE_BASE:
return tree_element_active_pose(C, scene, sl, te, tselem, set);
case TSE_POSE_CHANNEL:
- return tree_element_active_posechannel(C, scene, sl, te, tselem, set, recursive);
+ return tree_element_active_posechannel(C, scene, sl, te, tselem, set, recursive);
case TSE_CONSTRAINT:
- return tree_element_active_constraint(C, scene, sl, te, tselem, set);
+ return tree_element_active_constraint(C, scene, sl, te, tselem, set);
case TSE_R_LAYER:
- return tree_element_active_renderlayer(C, scene, sl, te, tselem, set);
+ return tree_element_active_renderlayer(C, scene, sl, te, tselem, set);
case TSE_POSEGRP:
- return tree_element_active_posegroup(C, scene, sl, te, tselem, set);
+ return tree_element_active_posegroup(C, scene, sl, te, tselem, set);
case TSE_SEQUENCE:
return tree_element_active_sequence(C, scene, te, tselem, set);
case TSE_SEQUENCE_DUP:
return tree_element_active_sequence_dup(scene, te, tselem, set);
case TSE_KEYMAP_ITEM:
- return tree_element_active_keymap_item(C, scene, sl, te, tselem, set);
+ return tree_element_active_keymap_item(C, scene, sl, te, tselem, set);
case TSE_GP_LAYER:
- //return tree_element_active_gplayer(C, scene, s, te, tselem, set);
+ //return tree_element_active_gplayer(C, scene, s, te, tselem, set);
break;
case TSE_COLLECTION:
return tree_element_active_collection(C, te, tselem, set);
diff --git a/source/blender/editors/space_outliner/outliner_tools.c b/source/blender/editors/space_outliner/outliner_tools.c
index 10d29436c74..320e38e82be 100644
--- a/source/blender/editors/space_outliner/outliner_tools.c
+++ b/source/blender/editors/space_outliner/outliner_tools.c
@@ -809,7 +809,7 @@ static void modifier_cb(int event, TreeElement *te, TreeStoreElem *UNUSED(tselem
static void collection_cb(int event, TreeElement *te, TreeStoreElem *UNUSED(tselem), void *Carg)
{
bContext *C = (bContext *)Carg;
- Scene *scene= CTX_data_scene(C);
+ Scene *scene = CTX_data_scene(C);
LayerCollection *lc = te->directdata;
SceneCollection *sc = lc->scene_collection;
diff --git a/source/blender/editors/space_view3d/drawsimdebug.c b/source/blender/editors/space_view3d/drawsimdebug.c
index 2baa6304cd9..e47adbea657 100644
--- a/source/blender/editors/space_view3d/drawsimdebug.c
+++ b/source/blender/editors/space_view3d/drawsimdebug.c
@@ -49,9 +49,9 @@
static void draw_sim_debug_elements(SimDebugData *debug_data, float imat[4][4])
{
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 3, KEEP_FLOAT);
- unsigned color = add_attrib(format, "color", GL_FLOAT, 3, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 3, KEEP_FLOAT);
+ unsigned int color = add_attrib(format, "color", GL_FLOAT, 3, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_3D_FLAT_COLOR);
diff --git a/source/blender/editors/space_view3d/view3d_draw.c b/source/blender/editors/space_view3d/view3d_draw.c
index fe4574f2fda..325c81a3fd2 100644
--- a/source/blender/editors/space_view3d/view3d_draw.c
+++ b/source/blender/editors/space_view3d/view3d_draw.c
@@ -308,7 +308,7 @@ static void view3d_draw_debug_store_depth(ARegion *UNUSED(ar), DrawData *draw_da
if (GPU_viewport_debug_depth_is_valid(viewport)) {
if ((GPU_viewport_debug_depth_width(viewport) != w) ||
- (GPU_viewport_debug_depth_height(viewport) != h))
+ (GPU_viewport_debug_depth_height(viewport) != h))
{
GPU_viewport_debug_depth_free(viewport);
}
@@ -344,7 +344,7 @@ static void view3d_draw_debug(const bContext *C, ARegion *ar, DrawData *draw_dat
}
if (((v3d->tmp_compat_flag & V3D_DEBUG_SHOW_SCENE_DEPTH) != 0) ||
- ((v3d->tmp_compat_flag & V3D_DEBUG_SHOW_COMBINED_DEPTH) != 0))
+ ((v3d->tmp_compat_flag & V3D_DEBUG_SHOW_COMBINED_DEPTH) != 0))
{
/* draw */
if (GPU_viewport_debug_depth_is_valid(draw_data->viewport)) {
@@ -965,7 +965,7 @@ static void view3d_draw_outline_plates(const bContext *UNUSED(C))
#define DEBUG_GRID 0
-static void gridline_range(double x0, double dx, double max, int* first_out, int* count_out)
+static void gridline_range(double x0, double dx, double max, int *r_first, int *r_count)
{
/* determine range of gridlines that appear in this Area -- similar calc but separate ranges for x & y
* x0 is gridline 0, the axis in screen space
@@ -975,12 +975,12 @@ static void gridline_range(double x0, double dx, double max, int* first_out, int
int last = (int)floor((max - x0) / dx);
if (first <= last) {
- *first_out = first;
- *count_out = last - first + 1;
+ *r_first = first;
+ *r_count = last - first + 1;
}
else {
- *first_out = 0;
- *count_out = 0;
+ *r_first = 0;
+ *r_count = 0;
}
#if DEBUG_GRID
@@ -1125,9 +1125,9 @@ static void drawgrid(UnitSettings *unit, ARegion *ar, View3D *v3d, const char **
glDepthMask(GL_FALSE); /* disable write in zbuffer */
#endif
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", COMP_F32, 2, KEEP_FLOAT);
- unsigned color = add_attrib(format, "color", COMP_U8, 3, NORMALIZE_INT_TO_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", COMP_F32, 2, KEEP_FLOAT);
+ unsigned int color = add_attrib(format, "color", COMP_U8, 3, NORMALIZE_INT_TO_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_FLAT_COLOR);
@@ -1207,7 +1207,7 @@ static void drawgrid(UnitSettings *unit, ARegion *ar, View3D *v3d, const char **
}
}
else {
- if (dx >(GRID_MIN_PX_D * 10.0)) { /* start blending in */
+ if (dx > (GRID_MIN_PX_D * 10.0)) { /* start blending in */
rv3d->gridview /= sublines_fl;
dx /= sublines;
if (dx > (GRID_MIN_PX_D * 10.0)) { /* start blending in */
@@ -1301,9 +1301,9 @@ static void drawfloor(Scene *scene, View3D *v3d, const char **grid_unit, bool wr
unsigned char col_bg[3], col_grid_emphasise[3], col_grid_light[3];
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", COMP_F32, 2, KEEP_FLOAT);
- unsigned color = add_attrib(format, "color", COMP_U8, 3, NORMALIZE_INT_TO_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", COMP_F32, 2, KEEP_FLOAT);
+ unsigned int color = add_attrib(format, "color", COMP_U8, 3, NORMALIZE_INT_TO_FLOAT);
immBindBuiltinProgram(GPU_SHADER_3D_FLAT_COLOR);
@@ -1389,9 +1389,9 @@ static void drawfloor(Scene *scene, View3D *v3d, const char **grid_unit, bool wr
if (show_axis_x || show_axis_y || show_axis_z) {
/* draw axis lines -- sometimes grid floor is off, other times we still need to draw the Z axis */
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", COMP_F32, 3, KEEP_FLOAT);
- unsigned color = add_attrib(format, "color", COMP_U8, 3, NORMALIZE_INT_TO_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", COMP_F32, 3, KEEP_FLOAT);
+ unsigned int color = add_attrib(format, "color", COMP_U8, 3, NORMALIZE_INT_TO_FLOAT);
immBindBuiltinProgram(GPU_SHADER_3D_FLAT_COLOR);
immBegin(GL_LINES, (show_axis_x + show_axis_y + show_axis_z) * 2);
@@ -1547,9 +1547,9 @@ static void drawcursor(Scene *scene, ARegion *ar, View3D *v3d)
glLineWidth(1.0f);
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", COMP_F32, 2, KEEP_FLOAT);
- unsigned color = add_attrib(format, "color", COMP_U8, 3, NORMALIZE_INT_TO_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", COMP_F32, 2, KEEP_FLOAT);
+ unsigned int color = add_attrib(format, "color", COMP_U8, 3, NORMALIZE_INT_TO_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_FLAT_COLOR);
diff --git a/source/blender/editors/space_view3d/view3d_draw_legacy.c b/source/blender/editors/space_view3d/view3d_draw_legacy.c
index c4d980ec7e9..84f0e296a1f 100644
--- a/source/blender/editors/space_view3d/view3d_draw_legacy.c
+++ b/source/blender/editors/space_view3d/view3d_draw_legacy.c
@@ -24,7 +24,7 @@
* ***** END GPL LICENSE BLOCK *****
*/
-/** \file blender/editors/space_view3d/view3d_draw.c
+/** \file blender/editors/space_view3d/view3d_draw_legacy.c
* \ingroup spview3d
*/
diff --git a/source/blender/editors/space_view3d/view3d_fly.c b/source/blender/editors/space_view3d/view3d_fly.c
index b42afd3a7a9..328e0b03bb8 100644
--- a/source/blender/editors/space_view3d/view3d_fly.c
+++ b/source/blender/editors/space_view3d/view3d_fly.c
@@ -259,8 +259,8 @@ static void drawFlyPixel(const struct bContext *UNUSED(C), ARegion *UNUSED(ar),
x2 = xoff + 0.55f * fly->width;
y2 = yoff + 0.55f * fly->height;
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
diff --git a/source/blender/editors/space_view3d/view3d_walk.c b/source/blender/editors/space_view3d/view3d_walk.c
index d4e78035b84..8390d56c610 100644
--- a/source/blender/editors/space_view3d/view3d_walk.c
+++ b/source/blender/editors/space_view3d/view3d_walk.c
@@ -340,8 +340,8 @@ static void drawWalkPixel(const struct bContext *UNUSED(C), ARegion *ar, void *a
yoff = walk->ar->winy / 2;
}
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_INT, 2, CONVERT_INT_TO_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_INT, 2, CONVERT_INT_TO_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
diff --git a/source/blender/editors/uvedit/uvedit_draw.c b/source/blender/editors/uvedit/uvedit_draw.c
index 996b07b72ff..32e7bb44375 100644
--- a/source/blender/editors/uvedit/uvedit_draw.c
+++ b/source/blender/editors/uvedit/uvedit_draw.c
@@ -332,7 +332,7 @@ static void draw_uvs_stretch(SpaceImage *sima, Scene *scene, BMEditMesh *em, MTe
col[3] = 0.5f; /* hard coded alpha, not that nice */
- VertexFormat* format = immVertexFormat();
+ VertexFormat *format = immVertexFormat();
unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
unsigned int color = add_attrib(format, "color", GL_FLOAT, 3, KEEP_FLOAT);
@@ -902,7 +902,7 @@ static void draw_uvs(SpaceImage *sima, Scene *scene, SceneLayer *sl, Object *obe
int sel;
UI_GetThemeColor4ubv(TH_EDGE_SELECT, col1);
- VertexFormat* format = immVertexFormat();
+ VertexFormat *format = immVertexFormat();
pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
unsigned int color = add_attrib(format, "color", GL_UNSIGNED_BYTE, 4, NORMALIZE_INT_TO_FLOAT);
@@ -989,7 +989,7 @@ static void draw_uvs(SpaceImage *sima, Scene *scene, SceneLayer *sl, Object *obe
float cent[2];
bool col_set = false;
- VertexFormat* format = immVertexFormat();
+ VertexFormat *format = immVertexFormat();
pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
unsigned int color = add_attrib(format, "color", GL_UNSIGNED_BYTE, 3, NORMALIZE_INT_TO_FLOAT);