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:
authorCampbell Barton <ideasman42@gmail.com>2012-06-13 02:05:33 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-06-13 02:05:33 +0400
commit2e8a2f7668e5687a0a9a5087e76eeb739c818b2b (patch)
tree75aa5fe8746df4cd369afff88c4fd367cb78f72c /source/blender/collada/TransformReader.cpp
parent46c95d37c6fae2268a7f39f90ef46e9c3c696e3f (diff)
style cleanup
Diffstat (limited to 'source/blender/collada/TransformReader.cpp')
-rw-r--r--source/blender/collada/TransformReader.cpp19
1 files changed, 10 insertions, 9 deletions
diff --git a/source/blender/collada/TransformReader.cpp b/source/blender/collada/TransformReader.cpp
index 4c7fde8ef17..be615f83787 100644
--- a/source/blender/collada/TransformReader.cpp
+++ b/source/blender/collada/TransformReader.cpp
@@ -29,7 +29,8 @@
#include "TransformReader.h"
-TransformReader::TransformReader(UnitConverter* conv) : unit_converter(conv) {}
+TransformReader::TransformReader(UnitConverter *conv) : unit_converter(conv) {
+}
void TransformReader::get_node_mat(float mat[][4], COLLADAFW::Node *node, std::map<COLLADAFW::UniqueId, Animation> *animation_map, Object *ob)
{
@@ -43,7 +44,7 @@ void TransformReader::get_node_mat(float mat[][4], COLLADAFW::Node *node, std::m
COLLADAFW::Transformation *tm = node->getTransformations()[i];
COLLADAFW::Transformation::TransformationType type = tm->getTransformationType();
- switch (type) {
+ switch (type) {
case COLLADAFW::Transformation::TRANSLATE:
dae_translate_to_mat4(tm, cur);
break;
@@ -60,7 +61,7 @@ void TransformReader::get_node_mat(float mat[][4], COLLADAFW::Node *node, std::m
case COLLADAFW::Transformation::SKEW:
fprintf(stderr, "LOOKAT and SKEW transformations are not supported yet.\n");
break;
- }
+ }
copy_m4_m4(copy, mat);
mult_m4_m4m4(mat, copy, cur);
@@ -78,7 +79,7 @@ void TransformReader::get_node_mat(float mat[][4], COLLADAFW::Node *node, std::m
void TransformReader::dae_rotate_to_mat4(COLLADAFW::Transformation *tm, float m[][4])
{
- COLLADAFW::Rotate *ro = (COLLADAFW::Rotate*)tm;
+ COLLADAFW::Rotate *ro = (COLLADAFW::Rotate *)tm;
COLLADABU::Math::Vector3& axis = ro->getRotationAxis();
const float angle = (float)DEG2RAD(ro->getRotationAngle());
const float ax[] = {axis[0], axis[1], axis[2]};
@@ -90,7 +91,7 @@ void TransformReader::dae_rotate_to_mat4(COLLADAFW::Transformation *tm, float m[
void TransformReader::dae_translate_to_mat4(COLLADAFW::Transformation *tm, float m[][4])
{
- COLLADAFW::Translate *tra = (COLLADAFW::Translate*)tm;
+ COLLADAFW::Translate *tra = (COLLADAFW::Translate *)tm;
COLLADABU::Math::Vector3& t = tra->getTranslation();
unit_m4(m);
@@ -102,24 +103,24 @@ void TransformReader::dae_translate_to_mat4(COLLADAFW::Transformation *tm, float
void TransformReader::dae_scale_to_mat4(COLLADAFW::Transformation *tm, float m[][4])
{
- COLLADABU::Math::Vector3& s = ((COLLADAFW::Scale*)tm)->getScale();
+ COLLADABU::Math::Vector3& s = ((COLLADAFW::Scale *)tm)->getScale();
float size[3] = {(float)s[0], (float)s[1], (float)s[2]};
size_to_mat4(m, size);
}
void TransformReader::dae_matrix_to_mat4(COLLADAFW::Transformation *tm, float m[][4])
{
- unit_converter->dae_matrix_to_mat4_(m, ((COLLADAFW::Matrix*)tm)->getMatrix());
+ unit_converter->dae_matrix_to_mat4_(m, ((COLLADAFW::Matrix *)tm)->getMatrix());
}
void TransformReader::dae_translate_to_v3(COLLADAFW::Transformation *tm, float v[3])
{
- dae_vector3_to_v3(((COLLADAFW::Translate*)tm)->getTranslation(), v);
+ dae_vector3_to_v3(((COLLADAFW::Translate *)tm)->getTranslation(), v);
}
void TransformReader::dae_scale_to_v3(COLLADAFW::Transformation *tm, float v[3])
{
- dae_vector3_to_v3(((COLLADAFW::Scale*)tm)->getScale(), v);
+ dae_vector3_to_v3(((COLLADAFW::Scale *)tm)->getScale(), v);
}
void TransformReader::dae_vector3_to_v3(const COLLADABU::Math::Vector3 &v3, float v[3])