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:
authorHans Goudey <h.goudey@me.com>2022-01-03 22:52:39 +0300
committerHans Goudey <h.goudey@me.com>2022-01-03 22:52:55 +0300
commit675d3cdd699d8c59cd886bcf5849e25002a69792 (patch)
tree15a25b1407896d872bf8d2e96ae03775a9e9e056
parent4e44cfa3d9969f0f3e175b53f116f377278a3245 (diff)
Cleanup: Clang tidy
-rw-r--r--source/blender/functions/FN_field.hh2
-rw-r--r--source/blender/functions/intern/field.cc2
-rw-r--r--source/blender/gpu/opengl/gl_shader.cc4
-rw-r--r--source/blender/modifiers/intern/MOD_mask.cc2
-rw-r--r--source/blender/nodes/shader/nodes/node_shader_fresnel.cc2
-rw-r--r--source/blender/nodes/shader/nodes/node_shader_vector_transform.cc2
6 files changed, 7 insertions, 7 deletions
diff --git a/source/blender/functions/FN_field.hh b/source/blender/functions/FN_field.hh
index b8cb05fecab..11f8a7e9b94 100644
--- a/source/blender/functions/FN_field.hh
+++ b/source/blender/functions/FN_field.hh
@@ -287,7 +287,7 @@ class FieldConstant : public FieldNode {
const CPPType &output_cpp_type(int output_index) const override;
const CPPType &type() const;
- const GPointer value() const;
+ GPointer value() const;
};
/**
diff --git a/source/blender/functions/intern/field.cc b/source/blender/functions/intern/field.cc
index 6a4d46c14f2..d6b83c42294 100644
--- a/source/blender/functions/intern/field.cc
+++ b/source/blender/functions/intern/field.cc
@@ -684,7 +684,7 @@ const CPPType &FieldConstant::type() const
return type_;
}
-const GPointer FieldConstant::value() const
+GPointer FieldConstant::value() const
{
return {type_, value_};
}
diff --git a/source/blender/gpu/opengl/gl_shader.cc b/source/blender/gpu/opengl/gl_shader.cc
index cd2c3caad46..8367b0de02b 100644
--- a/source/blender/gpu/opengl/gl_shader.cc
+++ b/source/blender/gpu/opengl/gl_shader.cc
@@ -47,7 +47,7 @@ GLShader::GLShader(const char *name) : Shader(name)
{
#if 0 /* Would be nice to have, but for now the Deferred compilation \
* does not have a GPUContext. */
- BLI_assert(GLContext::get() != NULL);
+ BLI_assert(GLContext::get() != nullptr);
#endif
shader_program_ = glCreateProgram();
@@ -58,7 +58,7 @@ GLShader::~GLShader()
{
#if 0 /* Would be nice to have, but for now the Deferred compilation \
* does not have a GPUContext. */
- BLI_assert(GLContext::get() != NULL);
+ BLI_assert(GLContext::get() != nullptr);
#endif
/* Invalid handles are silently ignored. */
glDeleteShader(vert_shader_);
diff --git a/source/blender/modifiers/intern/MOD_mask.cc b/source/blender/modifiers/intern/MOD_mask.cc
index f452b0c7091..090c4d5512e 100644
--- a/source/blender/modifiers/intern/MOD_mask.cc
+++ b/source/blender/modifiers/intern/MOD_mask.cc
@@ -702,7 +702,7 @@ static Mesh *modifyMesh(ModifierData *md, const ModifierEvalContext *UNUSED(ctx)
Object *armature_ob = mmd->ob_arm;
/* Return input mesh if there is no armature with bones. */
- if (ELEM(NULL, armature_ob, armature_ob->pose)) {
+ if (ELEM(nullptr, armature_ob, armature_ob->pose)) {
return mesh;
}
diff --git a/source/blender/nodes/shader/nodes/node_shader_fresnel.cc b/source/blender/nodes/shader/nodes/node_shader_fresnel.cc
index a6317c1adba..0a06cec407b 100644
--- a/source/blender/nodes/shader/nodes/node_shader_fresnel.cc
+++ b/source/blender/nodes/shader/nodes/node_shader_fresnel.cc
@@ -71,7 +71,7 @@ void register_node_type_sh_fresnel()
sh_node_type_base(&ntype, SH_NODE_FRESNEL, "Fresnel", NODE_CLASS_INPUT, 0);
node_type_socket_templates(&ntype, file_ns::sh_node_fresnel_in, file_ns::sh_node_fresnel_out);
node_type_gpu(&ntype, file_ns::node_shader_gpu_fresnel);
- node_type_exec(&ntype, NULL, NULL, file_ns::node_shader_exec_fresnel);
+ node_type_exec(&ntype, nullptr, nullptr, file_ns::node_shader_exec_fresnel);
nodeRegisterType(&ntype);
}
diff --git a/source/blender/nodes/shader/nodes/node_shader_vector_transform.cc b/source/blender/nodes/shader/nodes/node_shader_vector_transform.cc
index fc6a05d93b6..67766900189 100644
--- a/source/blender/nodes/shader/nodes/node_shader_vector_transform.cc
+++ b/source/blender/nodes/shader/nodes/node_shader_vector_transform.cc
@@ -100,7 +100,7 @@ static int gpu_shader_vect_transform(GPUMaterial *mat,
const char *vtransform = "direction_transform_m4v3";
const char *ptransform = "point_transform_m4v3";
- const char *func_name = 0;
+ const char *func_name = nullptr;
NodeShaderVectTransform *nodeprop = (NodeShaderVectTransform *)node->storage;