MCPcopy Create free account
hub / github.com/OpenImageDebugger/OpenImageDebugger / rotation

Method rotation

src/math/linear_algebra.cpp:148–159  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

146}
147
148mat4 mat4::rotation(const float angle) {
149 using Eigen::Affine3f;
150 using Eigen::AngleAxisf;
151 using Eigen::Vector3f;
152
153 auto result = mat4{};
154 auto t = Affine3f::Identity();
155 t.rotate(AngleAxisf(angle, Vector3f(0.0f, 0.0f, 1.0f)));
156
157 result.mat_ = t.matrix();
158 return result;
159}
160
161mat4 mat4::translation(const vec4& vector) {
162 using Eigen::Affine3f;

Callers

nothing calls this directly

Calls 1

rotateMethod · 0.80

Tested by

no test coverage detected