diff options
author | Sybren A. Stüvel <sybren@blender.org> | 2020-09-04 13:26:24 +0300 |
---|---|---|
committer | Sybren A. Stüvel <sybren@blender.org> | 2020-09-04 13:37:56 +0300 |
commit | cc2b114a21bbd311bd5f497241403aab80fd79a1 (patch) | |
tree | e82e6cd6d1bdd38b118d71a8c089304580dd250e /source/blender | |
parent | 3e3e42cbcb899c879936ec596759a9c7e533dd5f (diff) |
Cleanup: Clang-Tidy readability-static-accessed-through-instance fixes
No functional changes.
Diffstat (limited to 'source/blender')
5 files changed, 7 insertions, 10 deletions
diff --git a/source/blender/compositor/operations/COM_WriteBufferOperation.cpp b/source/blender/compositor/operations/COM_WriteBufferOperation.cpp index 8cc53f8c6a9..640e3e3d381 100644 --- a/source/blender/compositor/operations/COM_WriteBufferOperation.cpp +++ b/source/blender/compositor/operations/COM_WriteBufferOperation.cpp @@ -128,7 +128,7 @@ void WriteBufferOperation::executeOpenCLRegion(OpenCLDevice *device, const unsigned int outputBufferWidth = outputBuffer->getWidth(); const unsigned int outputBufferHeight = outputBuffer->getHeight(); - const cl_image_format *imageFormat = device->determineImageFormat(outputBuffer); + const cl_image_format *imageFormat = OpenCLDevice::determineImageFormat(outputBuffer); cl_mem clOutputBuffer = clCreateImage2D(device->getContext(), CL_MEM_WRITE_ONLY | CL_MEM_USE_HOST_PTR, diff --git a/source/blender/io/collada/AnimationImporter.cpp b/source/blender/io/collada/AnimationImporter.cpp index 08d9386cb42..8e6e51fc282 100644 --- a/source/blender/io/collada/AnimationImporter.cpp +++ b/source/blender/io/collada/AnimationImporter.cpp @@ -2043,7 +2043,7 @@ bool AnimationImporter::evaluate_animation(COLLADAFW::Transformation *tm, mj = 0; } } - unit_converter->dae_matrix_to_mat4_(mat, matrix); + UnitConverter::dae_matrix_to_mat4_(mat, matrix); return true; } } diff --git a/source/blender/io/collada/SkinInfo.cpp b/source/blender/io/collada/SkinInfo.cpp index 5692d11d0c3..eef45a5be90 100644 --- a/source/blender/io/collada/SkinInfo.cpp +++ b/source/blender/io/collada/SkinInfo.cpp @@ -115,7 +115,7 @@ void SkinInfo::borrow_skin_controller_data(const COLLADAFW::SkinControllerData * weights.push_back(bc_get_float_value(weight, i)); } - unit_converter->dae_matrix_to_mat4_(bind_shape_matrix, skin->getBindShapeMatrix()); + UnitConverter::dae_matrix_to_mat4_(bind_shape_matrix, skin->getBindShapeMatrix()); } void SkinInfo::free() @@ -132,7 +132,7 @@ void SkinInfo::free() void SkinInfo::add_joint(const COLLADABU::Math::Matrix4 &matrix) { JointData jd; - unit_converter->dae_matrix_to_mat4_(jd.inv_bind_mat, matrix); + UnitConverter::dae_matrix_to_mat4_(jd.inv_bind_mat, matrix); joint_data.push_back(jd); } diff --git a/source/blender/io/collada/TransformReader.cpp b/source/blender/io/collada/TransformReader.cpp index 8ee31f80405..87b8763fb6a 100644 --- a/source/blender/io/collada/TransformReader.cpp +++ b/source/blender/io/collada/TransformReader.cpp @@ -130,7 +130,7 @@ void TransformReader::dae_scale_to_mat4(COLLADAFW::Transformation *tm, float m[4 void TransformReader::dae_matrix_to_mat4(COLLADAFW::Transformation *tm, float m[4][4]) { - unit_converter->dae_matrix_to_mat4_(m, ((COLLADAFW::Matrix *)tm)->getMatrix()); + UnitConverter::dae_matrix_to_mat4_(m, ((COLLADAFW::Matrix *)tm)->getMatrix()); } void TransformReader::dae_translate_to_v3(COLLADAFW::Transformation *tm, float v[3]) diff --git a/source/blender/io/collada/TransformWriter.cpp b/source/blender/io/collada/TransformWriter.cpp index b7455837379..0311f22fe11 100644 --- a/source/blender/io/collada/TransformWriter.cpp +++ b/source/blender/io/collada/TransformWriter.cpp @@ -47,9 +47,7 @@ void TransformWriter::add_joint_transform(COLLADASW::Node &node, } double dmat[4][4]; - UnitConverter *converter = new UnitConverter(); - converter->mat4_to_dae_double(dmat, local); - delete converter; + UnitConverter::mat4_to_dae_double(dmat, local); if (export_settings.get_object_transformation_type() == BC_TRANSFORMATION_TYPE_MATRIX) { node.addMatrix("transform", dmat); @@ -81,9 +79,8 @@ void TransformWriter::add_node_transform_ob(COLLADASW::Node &node, switch (export_settings.get_object_transformation_type()) { case BC_TRANSFORMATION_TYPE_MATRIX: { - UnitConverter converter; double d_obmat[4][4]; - converter.mat4_to_dae_double(d_obmat, f_obmat); + UnitConverter::mat4_to_dae_double(d_obmat, f_obmat); if (limit_precision) { BCMatrix::sanitize(d_obmat, LIMITTED_PRECISION); |