Skip to content
Snippets Groups Projects
Commit 17552fdc authored by Yoel's avatar Yoel
Browse files

Added fromWorldN to transform

parent aed5a8ba
No related branches found
No related tags found
No related merge requests found
...@@ -4,6 +4,7 @@ namespace util { ...@@ -4,6 +4,7 @@ namespace util {
util::Transformation::Transformation(const Mat4& matrix) util::Transformation::Transformation(const Mat4& matrix)
: toWorld(matrix), : toWorld(matrix),
fromWorld(matrix.invertFull()), fromWorld(matrix.invertFull()),
toWorldN(matrix.invertFull().transpose()) { toWorldN(matrix.invertFull().transpose()),
fromWorldN(matrix.invertFull().invertFull().transpose()) {
} }
} // namespace util } // namespace util
...@@ -5,6 +5,6 @@ namespace util { ...@@ -5,6 +5,6 @@ namespace util {
class Transformation { class Transformation {
public: public:
Transformation(const Mat4& matrix); Transformation(const Mat4& matrix);
const Mat4 toWorld, fromWorld, toWorldN; const Mat4 toWorld, fromWorld, toWorldN, fromWorldN;
}; };
} // namespace util } // namespace util
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment