Cleanup: Source Code Typos
Corrects approximately 36 spelling errors in source variable names. Differential Revision: https://developer.blender.org/D10347 Reviewed by Hans Goudey
This commit is contained in:
parent
9e81e1c33f
commit
f362dad19b
|
@ -1042,7 +1042,7 @@ class PREFERENCES_OT_studiolight_new(Operator):
|
|||
default="StudioLight",
|
||||
)
|
||||
|
||||
ask_overide = False
|
||||
ask_override = False
|
||||
|
||||
def execute(self, context):
|
||||
import os
|
||||
|
@ -1057,8 +1057,8 @@ class PREFERENCES_OT_studiolight_new(Operator):
|
|||
|
||||
filepath_final = os.path.join(path_studiolights, filename)
|
||||
if os.path.isfile(filepath_final):
|
||||
if not self.ask_overide:
|
||||
self.ask_overide = True
|
||||
if not self.ask_override:
|
||||
self.ask_override = True
|
||||
return wm.invoke_props_dialog(self, width=320)
|
||||
else:
|
||||
for studio_light in prefs.studio_lights:
|
||||
|
@ -1078,7 +1078,7 @@ class PREFERENCES_OT_studiolight_new(Operator):
|
|||
|
||||
def draw(self, _context):
|
||||
layout = self.layout
|
||||
if self.ask_overide:
|
||||
if self.ask_override:
|
||||
layout.label(text="Warning, file already exists. Overwrite existing file?")
|
||||
else:
|
||||
layout.prop(self, "filename")
|
||||
|
|
|
@ -98,9 +98,9 @@ static void greasepencil_copy_data(Main *UNUSED(bmain),
|
|||
/* Apply local layer transform to all frames. Calc the active frame is not enough
|
||||
* because onion skin can use more frames. This is more slow but required here. */
|
||||
if (gpl_dst->actframe != NULL) {
|
||||
bool transfomed = ((!is_zero_v3(gpl_dst->location)) || (!is_zero_v3(gpl_dst->rotation)) ||
|
||||
(!is_one_v3(gpl_dst->scale)));
|
||||
if (transfomed) {
|
||||
bool transformed = ((!is_zero_v3(gpl_dst->location)) || (!is_zero_v3(gpl_dst->rotation)) ||
|
||||
(!is_one_v3(gpl_dst->scale)));
|
||||
if (transformed) {
|
||||
loc_eul_size_to_mat4(
|
||||
gpl_dst->layer_mat, gpl_dst->location, gpl_dst->rotation, gpl_dst->scale);
|
||||
bool do_onion = ((gpl_dst->onion_flag & GP_LAYER_ONIONSKIN) != 0);
|
||||
|
@ -2902,14 +2902,14 @@ void BKE_gpencil_update_layer_transforms(const Depsgraph *depsgraph, Object *ob)
|
|||
}
|
||||
|
||||
/* Calc local layer transform. */
|
||||
bool transfomed = ((!is_zero_v3(gpl->location)) || (!is_zero_v3(gpl->rotation)) ||
|
||||
(!is_one_v3(gpl->scale)));
|
||||
if (transfomed) {
|
||||
bool transformed = ((!is_zero_v3(gpl->location)) || (!is_zero_v3(gpl->rotation)) ||
|
||||
(!is_one_v3(gpl->scale)));
|
||||
if (transformed) {
|
||||
loc_eul_size_to_mat4(gpl->layer_mat, gpl->location, gpl->rotation, gpl->scale);
|
||||
}
|
||||
|
||||
/* only redo if any change */
|
||||
if (changed || transfomed) {
|
||||
if (changed || transformed) {
|
||||
LISTBASE_FOREACH (bGPDstroke *, gps, &gpl->actframe->strokes) {
|
||||
bGPDspoint *pt;
|
||||
int i;
|
||||
|
@ -2919,7 +2919,7 @@ void BKE_gpencil_update_layer_transforms(const Depsgraph *depsgraph, Object *ob)
|
|||
mul_m4_v3(cur_mat, &pt->x);
|
||||
}
|
||||
|
||||
if (transfomed) {
|
||||
if (transformed) {
|
||||
mul_m4_v3(gpl->layer_mat, &pt->x);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -333,7 +333,7 @@ static struct bUnitCollection buPowerCollection = {buPowerDef, 3, 0, UNIT_COLLEC
|
|||
/* Temperature */
|
||||
static struct bUnitDef buMetricTempDef[] = {
|
||||
{"kelvin", "kelvin", "K", NULL, "Kelvin", "KELVIN", 1.0f, 0.0, B_UNIT_DEF_NONE}, /* Base unit. */
|
||||
{"celsius", "celsius", "°C", "C", "Celsius", "CELCIUS", 1.0f, 273.15, B_UNIT_DEF_NONE},
|
||||
{"celsius", "celsius", "°C", "C", "Celsius", "CELSIUS", 1.0f, 273.15, B_UNIT_DEF_NONE},
|
||||
NULL_UNIT,
|
||||
};
|
||||
static struct bUnitCollection buMetricTempCollection = {buMetricTempDef, 0, 0, UNIT_COLLECTION_LENGTH(buMetricTempDef)};
|
||||
|
|
|
@ -240,9 +240,9 @@ void KeyingNode::convertToOperations(NodeConverter &converter,
|
|||
|
||||
if (keying_data->blur_pre) {
|
||||
/* Chroma pre-blur operation for input of keying operation. */
|
||||
NodeOperationOutput *preBluredImage = setupPreBlur(
|
||||
NodeOperationOutput *preBlurredImage = setupPreBlur(
|
||||
converter, inputImage, keying_data->blur_pre);
|
||||
converter.addLink(preBluredImage, keyingOperation->getInputSocket(0));
|
||||
converter.addLink(preBlurredImage, keyingOperation->getInputSocket(0));
|
||||
}
|
||||
else {
|
||||
converter.mapInputSocket(inputImage, keyingOperation->getInputSocket(0));
|
||||
|
|
|
@ -270,12 +270,12 @@ GPENCIL_tLayer *gpencil_layer_cache_add(GPENCIL_PrivateData *pd,
|
|||
|
||||
const bool is_in_front = (ob->dtx & OB_DRAW_IN_FRONT);
|
||||
const bool is_screenspace = (gpd->flag & GP_DATA_STROKE_KEEPTHICKNESS) != 0;
|
||||
const bool overide_vertcol = (pd->v3d_color_type != -1);
|
||||
const bool override_vertcol = (pd->v3d_color_type != -1);
|
||||
const bool is_vert_col_mode = (pd->v3d_color_type == V3D_SHADING_VERTEX_COLOR) ||
|
||||
GPENCIL_VERTEX_MODE(gpd) || pd->is_render;
|
||||
bool is_masked = (gpl->flag & GP_LAYER_USE_MASK) && !BLI_listbase_is_empty(&gpl->mask_layers);
|
||||
|
||||
float vert_col_opacity = (overide_vertcol) ?
|
||||
float vert_col_opacity = (override_vertcol) ?
|
||||
(is_vert_col_mode ? pd->vertex_paint_opacity : 0.0f) :
|
||||
pd->is_render ? gpl->vertex_paint_opacity :
|
||||
pd->vertex_paint_opacity;
|
||||
|
|
|
@ -4,7 +4,7 @@ layout(triangle_strip, max_vertices = 4) out;
|
|||
|
||||
in vec4 finalColor[2];
|
||||
in vec4 finalColorOuter[2];
|
||||
in int selectOveride[2];
|
||||
in int selectOverride[2];
|
||||
|
||||
flat out vec4 finalColorOuter_f;
|
||||
out vec4 finalColor_f;
|
||||
|
@ -80,7 +80,7 @@ void main()
|
|||
#ifdef USE_WORLD_CLIP_PLANES
|
||||
world_clip_planes_set_clip_distance(gl_in[1].gl_ClipDistance);
|
||||
#endif
|
||||
vec4 final_color = (selectOveride[0] == 0) ? finalColor[1] : finalColor[0];
|
||||
vec4 final_color = (selectOverride[0] == 0) ? finalColor[1] : finalColor[0];
|
||||
do_vertex(final_color, pos1, half_size, edge_ofs.xy);
|
||||
do_vertex(final_color, pos1, -half_size, -edge_ofs.xy);
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@ out vec4 finalColor;
|
|||
out vec4 finalColorOuter;
|
||||
#endif
|
||||
#ifdef USE_GEOM_SHADER
|
||||
out int selectOveride;
|
||||
out int selectOverride;
|
||||
#endif
|
||||
|
||||
bool test_occlusion()
|
||||
|
@ -59,10 +59,10 @@ void main()
|
|||
#elif defined(EDGE)
|
||||
# ifdef FLAT
|
||||
finalColor = EDIT_MESH_edge_color_inner(m_data.y);
|
||||
selectOveride = 1;
|
||||
selectOverride = 1;
|
||||
# else
|
||||
finalColor = EDIT_MESH_edge_vertex_color(m_data.y);
|
||||
selectOveride = (m_data.y & EDGE_SELECTED);
|
||||
selectOverride = (m_data.y & EDGE_SELECTED);
|
||||
# endif
|
||||
|
||||
float crease = float(m_data.z) / 255.0;
|
||||
|
|
|
@ -444,13 +444,13 @@ static void annotation_stroke_arrow_calc_points_segment(float stroke_points[8],
|
|||
const float ref_point[2],
|
||||
const float dir_cw[2],
|
||||
const float dir_ccw[2],
|
||||
const float lenght,
|
||||
const float length,
|
||||
const float sign)
|
||||
{
|
||||
stroke_points[0] = ref_point[0] + dir_cw[0] * lenght * sign;
|
||||
stroke_points[1] = ref_point[1] + dir_cw[1] * lenght * sign;
|
||||
stroke_points[2] = ref_point[0] + dir_ccw[0] * lenght * sign;
|
||||
stroke_points[3] = ref_point[1] + dir_ccw[1] * lenght * sign;
|
||||
stroke_points[0] = ref_point[0] + dir_cw[0] * length * sign;
|
||||
stroke_points[1] = ref_point[1] + dir_cw[1] * length * sign;
|
||||
stroke_points[2] = ref_point[0] + dir_ccw[0] * length * sign;
|
||||
stroke_points[3] = ref_point[1] + dir_ccw[1] * length * sign;
|
||||
}
|
||||
|
||||
static void annotation_stroke_arrow_calc_points(tGPspoint *point,
|
||||
|
@ -459,7 +459,7 @@ static void annotation_stroke_arrow_calc_points(tGPspoint *point,
|
|||
float stroke_points[8],
|
||||
const int arrow_style)
|
||||
{
|
||||
const int arrow_lenght = 8;
|
||||
const int arrow_length = 8;
|
||||
float norm_dir[2];
|
||||
copy_v2_v2(norm_dir, stroke_dir);
|
||||
normalize_v2(norm_dir);
|
||||
|
@ -468,22 +468,22 @@ static void annotation_stroke_arrow_calc_points(tGPspoint *point,
|
|||
|
||||
switch (arrow_style) {
|
||||
case GP_STROKE_ARROWSTYLE_OPEN:
|
||||
mul_v2_fl(norm_dir, arrow_lenght);
|
||||
stroke_points[0] = corner[0] + inv_norm_dir_clockwise[0] * arrow_lenght + norm_dir[0];
|
||||
stroke_points[1] = corner[1] + inv_norm_dir_clockwise[1] * arrow_lenght + norm_dir[1];
|
||||
stroke_points[2] = corner[0] + inv_norm_dir_counterclockwise[0] * arrow_lenght + norm_dir[0];
|
||||
stroke_points[3] = corner[1] + inv_norm_dir_counterclockwise[1] * arrow_lenght + norm_dir[1];
|
||||
mul_v2_fl(norm_dir, arrow_length);
|
||||
stroke_points[0] = corner[0] + inv_norm_dir_clockwise[0] * arrow_length + norm_dir[0];
|
||||
stroke_points[1] = corner[1] + inv_norm_dir_clockwise[1] * arrow_length + norm_dir[1];
|
||||
stroke_points[2] = corner[0] + inv_norm_dir_counterclockwise[0] * arrow_length + norm_dir[0];
|
||||
stroke_points[3] = corner[1] + inv_norm_dir_counterclockwise[1] * arrow_length + norm_dir[1];
|
||||
break;
|
||||
case GP_STROKE_ARROWSTYLE_SEGMENT:
|
||||
annotation_stroke_arrow_calc_points_segment(stroke_points,
|
||||
corner,
|
||||
inv_norm_dir_clockwise,
|
||||
inv_norm_dir_counterclockwise,
|
||||
arrow_lenght,
|
||||
arrow_length,
|
||||
1.0f);
|
||||
break;
|
||||
case GP_STROKE_ARROWSTYLE_CLOSED:
|
||||
mul_v2_fl(norm_dir, arrow_lenght);
|
||||
mul_v2_fl(norm_dir, arrow_length);
|
||||
if (point != NULL) {
|
||||
add_v2_v2(&point->x, norm_dir);
|
||||
copy_v2_v2(corner, &point->x);
|
||||
|
@ -492,13 +492,13 @@ static void annotation_stroke_arrow_calc_points(tGPspoint *point,
|
|||
corner,
|
||||
inv_norm_dir_clockwise,
|
||||
inv_norm_dir_counterclockwise,
|
||||
arrow_lenght,
|
||||
arrow_length,
|
||||
-1.0f);
|
||||
stroke_points[4] = corner[0] - norm_dir[0];
|
||||
stroke_points[5] = corner[1] - norm_dir[1];
|
||||
break;
|
||||
case GP_STROKE_ARROWSTYLE_SQUARE:
|
||||
mul_v2_fl(norm_dir, arrow_lenght * 1.5f);
|
||||
mul_v2_fl(norm_dir, arrow_length * 1.5f);
|
||||
if (point != NULL) {
|
||||
add_v2_v2(&point->x, norm_dir);
|
||||
copy_v2_v2(corner, &point->x);
|
||||
|
@ -507,7 +507,7 @@ static void annotation_stroke_arrow_calc_points(tGPspoint *point,
|
|||
corner,
|
||||
inv_norm_dir_clockwise,
|
||||
inv_norm_dir_counterclockwise,
|
||||
arrow_lenght * 0.75f,
|
||||
arrow_length * 0.75f,
|
||||
-1.0f);
|
||||
stroke_points[4] = stroke_points[0] - norm_dir[0];
|
||||
stroke_points[5] = stroke_points[1] - norm_dir[1];
|
||||
|
|
|
@ -86,7 +86,7 @@ static EnumPropertyItem prop_color_filter_types[] = {
|
|||
{COLOR_FILTER_SATURATION, "SATURATION", 0, "Saturation", "Change saturation"},
|
||||
{COLOR_FILTER_VALUE, "VALUE", 0, "Value", "Change value"},
|
||||
|
||||
{COLOR_FILTER_BRIGHTNESS, "BRIGTHNESS", 0, "Brightness", "Change brightness"},
|
||||
{COLOR_FILTER_BRIGHTNESS, "BRIGHTNESS", 0, "Brightness", "Change brightness"},
|
||||
{COLOR_FILTER_CONTRAST, "CONTRAST", 0, "Contrast", "Change contrast"},
|
||||
|
||||
{COLOR_FILTER_SMOOTH, "SMOOTH", 0, "Smooth", "Smooth colors"},
|
||||
|
|
Loading…
Reference in New Issue