diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2022-10-12 18:33:33 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2022-10-12 18:39:23 +0300 |
commit | 0610fc38b9daf22272c1172c02a6ca6ddca7b3cb (patch) | |
tree | 077baa0da97f59e8fb23db1c99861675a55bd206 | |
parent | 7a9a83f4a0207a130165f55c380536fbf31d8a68 (diff) |
DRW: View: Expose matrices through interface
-rw-r--r-- | source/blender/draw/intern/draw_view.hh | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/source/blender/draw/intern/draw_view.hh b/source/blender/draw/intern/draw_view.hh index 4fc74e3e890..94fb62508bb 100644 --- a/source/blender/draw/intern/draw_view.hh +++ b/source/blender/draw/intern/draw_view.hh @@ -79,6 +79,26 @@ class View { return -(data_.winmat[3][2] + 1.0f) / data_.winmat[2][2]; } + const float4x4 &viewmat() const + { + return data_.viewmat; + } + + const float4x4 &viewinv() const + { + return data_.viewinv; + } + + const float4x4 &winmat() const + { + return data_.winmat; + } + + const float4x4 &wininv() const + { + return data_.wininv; + } + private: /** Called from draw manager. */ void bind(); |