diff options
-rw-r--r-- | intern/cycles/cmake/msvc_arch_flags.c | 14 | ||||
-rw-r--r-- | intern/cycles/kernel/shaders/node_voronoi_texture.osl | 3 | ||||
-rw-r--r-- | intern/cycles/render/shader.h | 2 | ||||
-rw-r--r-- | source/blender/editors/include/ED_object.h | 18 | ||||
-rw-r--r-- | source/blender/editors/object/object_modes.c | 12 | ||||
-rw-r--r-- | source/blender/freestyle/intern/stroke/StrokeRep.cpp | 2 | ||||
-rw-r--r-- | source/blender/gpu/opengl/gl_state.cc | 9 | ||||
-rw-r--r-- | source/blender/gpu/shaders/material/gpu_shader_material_tex_voronoi.glsl | 3 |
8 files changed, 33 insertions, 30 deletions
diff --git a/intern/cycles/cmake/msvc_arch_flags.c b/intern/cycles/cmake/msvc_arch_flags.c index 79dbd3b87ac..22fcc2c437a 100644 --- a/intern/cycles/cmake/msvc_arch_flags.c +++ b/intern/cycles/cmake/msvc_arch_flags.c @@ -14,25 +14,25 @@ * limitations under the License. */ -#include <stdio.h> #include <isa_availability.h> +#include <stdio.h> /* The MS CRT defines this */ extern int __isa_available; -const char* get_arch_flags() +const char *get_arch_flags() { - if (__isa_available >= __ISA_AVAILABLE_AVX2) { + if (__isa_available >= __ISA_AVAILABLE_AVX2) { return "/arch:AVX2"; } - if (__isa_available >= __ISA_AVAILABLE_AVX) { + if (__isa_available >= __ISA_AVAILABLE_AVX) { return "/arch:AVX"; } - return ""; + return ""; } int main() { - printf("%s\n", get_arch_flags()); - return 0; + printf("%s\n", get_arch_flags()); + return 0; } diff --git a/intern/cycles/kernel/shaders/node_voronoi_texture.osl b/intern/cycles/kernel/shaders/node_voronoi_texture.osl index b95abc7f362..e184c26aec8 100644 --- a/intern/cycles/kernel/shaders/node_voronoi_texture.osl +++ b/intern/cycles/kernel/shaders/node_voronoi_texture.osl @@ -179,7 +179,8 @@ void voronoi_distance_to_edge_1d(float w, float randomness, output float outDist float leftPointPosition = -1.0 + hash_float_to_float(cellPosition - 1.0) * randomness; float rightPointPosition = 1.0 + hash_float_to_float(cellPosition + 1.0) * randomness; float distanceToMidLeft = distance((midPointPosition + leftPointPosition) / 2.0, localPosition); - float distanceToMidRight = distance((midPointPosition + rightPointPosition) / 2.0, localPosition); + float distanceToMidRight = distance((midPointPosition + rightPointPosition) / 2.0, + localPosition); outDistance = min(distanceToMidLeft, distanceToMidRight); } diff --git a/intern/cycles/render/shader.h b/intern/cycles/render/shader.h index 993b467b396..897b0984a7e 100644 --- a/intern/cycles/render/shader.h +++ b/intern/cycles/render/shader.h @@ -104,7 +104,7 @@ class Shader : public Node { * However, graph optimization might remove the volume subgraph, but * since the user connected something to the volume output the surface * should still be transparent. - * Therefore, has_volume_connected stores whether some volume subtree + * Therefore, has_volume_connected stores whether some volume sub-tree * was connected before optimization. */ bool has_volume_connected; diff --git a/source/blender/editors/include/ED_object.h b/source/blender/editors/include/ED_object.h index bf9e30b756f..afaf11f5a8e 100644 --- a/source/blender/editors/include/ED_object.h +++ b/source/blender/editors/include/ED_object.h @@ -353,9 +353,9 @@ void ED_object_mode_generic_exit(struct Main *bmain, bool ED_object_mode_generic_has_data(struct Depsgraph *depsgraph, struct Object *ob); void ED_object_posemode_set_for_weight_paint(struct bContext *C, - struct Main *bmain, - struct Object *ob, - const bool is_mode_set); + struct Main *bmain, + struct Object *ob, + const bool is_mode_set); /* object_modifier.c */ enum { @@ -387,12 +387,12 @@ bool ED_object_modifier_move_to_index(struct ReportList *reports, const int index); bool ED_object_modifier_convert(struct ReportList *reports, - struct Main *bmain, - struct Depsgraph *depsgraph, - struct Scene *scene, - struct ViewLayer *view_layer, - struct Object *ob, - struct ModifierData *md); + struct Main *bmain, + struct Depsgraph *depsgraph, + struct Scene *scene, + struct ViewLayer *view_layer, + struct Object *ob, + struct ModifierData *md); bool ED_object_modifier_apply(struct Main *bmain, struct ReportList *reports, struct Depsgraph *depsgraph, diff --git a/source/blender/editors/object/object_modes.c b/source/blender/editors/object/object_modes.c index d4dd6617c53..bc05a62759f 100644 --- a/source/blender/editors/object/object_modes.c +++ b/source/blender/editors/object/object_modes.c @@ -315,9 +315,9 @@ static bool ed_object_mode_generic_exit_ex(struct Main *bmain, * This is in fits with the convention of selecting multiple objects and entering a mode. */ static void ed_object_posemode_set_for_weight_paint_ex(bContext *C, - Main *bmain, - Object *ob_arm, - const bool is_mode_set) + Main *bmain, + Object *ob_arm, + const bool is_mode_set) { View3D *v3d = CTX_wm_view3d(C); ViewLayer *view_layer = CTX_data_view_layer(C); @@ -347,9 +347,9 @@ static void ed_object_posemode_set_for_weight_paint_ex(bContext *C, } void ED_object_posemode_set_for_weight_paint(bContext *C, - Main *bmain, - Object *ob, - const bool is_mode_set) + Main *bmain, + Object *ob, + const bool is_mode_set) { if (ob->type == OB_GPENCIL) { GpencilVirtualModifierData virtualModifierData; diff --git a/source/blender/freestyle/intern/stroke/StrokeRep.cpp b/source/blender/freestyle/intern/stroke/StrokeRep.cpp index 0c004e0083e..3678461253c 100644 --- a/source/blender/freestyle/intern/stroke/StrokeRep.cpp +++ b/source/blender/freestyle/intern/stroke/StrokeRep.cpp @@ -21,11 +21,11 @@ #include <cmath> -#include "StrokeRep.h" #include "Stroke.h" #include "StrokeAdvancedIterators.h" #include "StrokeIterators.h" #include "StrokeRenderer.h" +#include "StrokeRep.h" #include "BKE_global.h" diff --git a/source/blender/gpu/opengl/gl_state.cc b/source/blender/gpu/opengl/gl_state.cc index 419cb8b0c9c..dc0317726a8 100644 --- a/source/blender/gpu/opengl/gl_state.cc +++ b/source/blender/gpu/opengl/gl_state.cc @@ -338,7 +338,7 @@ void GLStateManager::set_blend(const eGPUBlend value) /** * Factors to the equation. * SRC is fragment shader output. - * DST is framebuffer color. + * DST is frame-buffer color. * final.rgb = SRC.rgb * src_rgb + DST.rgb * dst_rgb; * final.a = SRC.a * src_alpha + DST.a * dst_alpha; **/ @@ -414,7 +414,8 @@ void GLStateManager::set_blend(const eGPUBlend value) } /* Always set the blend function. This avoid a rendering error when blending is disabled but - * GPU_BLEND_CUSTOM was used just before and the framebuffer is using more than 1 color targe */ + * GPU_BLEND_CUSTOM was used just before and the frame-buffer is using more than 1 color target. + */ glBlendFuncSeparate(src_rgb, dst_rgb, src_alpha, dst_alpha); if (value != GPU_BLEND_NONE) { glEnable(GL_BLEND); @@ -427,7 +428,7 @@ void GLStateManager::set_blend(const eGPUBlend value) /** \} */ /* -------------------------------------------------------------------- */ -/** \name Texture state managment +/** \name Texture State Management * \{ */ void GLStateManager::texture_bind(Texture *tex_, eGPUSamplerState sampler_type, int unit) @@ -455,7 +456,7 @@ void GLStateManager::texture_bind_temp(GLTexture *tex) // BLI_assert(!GLEW_ARB_direct_state_access); glActiveTexture(GL_TEXTURE0); glBindTexture(tex->target_, tex->tex_id_); - /* Will reset the first texture that was originaly bound to slot 0 back before drawing. */ + /* Will reset the first texture that was originally bound to slot 0 back before drawing. */ dirty_texture_binds_ |= 1UL; /* NOTE: This might leave this texture attached to this target even after update. * In practice it is not causing problems as we have incorrect binding detection diff --git a/source/blender/gpu/shaders/material/gpu_shader_material_tex_voronoi.glsl b/source/blender/gpu/shaders/material/gpu_shader_material_tex_voronoi.glsl index 470ce1a1fa7..40f76b9cacc 100644 --- a/source/blender/gpu/shaders/material/gpu_shader_material_tex_voronoi.glsl +++ b/source/blender/gpu/shaders/material/gpu_shader_material_tex_voronoi.glsl @@ -162,7 +162,8 @@ void node_tex_voronoi_distance_to_edge_1d(vec3 coord, float leftPointPosition = -1.0 + hash_float_to_float(cellPosition - 1.0) * randomness; float rightPointPosition = 1.0 + hash_float_to_float(cellPosition + 1.0) * randomness; float distanceToMidLeft = distance((midPointPosition + leftPointPosition) / 2.0, localPosition); - float distanceToMidRight = distance((midPointPosition + rightPointPosition) / 2.0, localPosition); + float distanceToMidRight = distance((midPointPosition + rightPointPosition) / 2.0, + localPosition); outDistance = min(distanceToMidLeft, distanceToMidRight); } |