diff options
| author | Felix Morgner <felix.morgner@gmail.com> | 2026-08-24 11:16:07 +0200 |
|---|---|---|
| committer | Felix Morgner <felix.morgner@gmail.com> | 2026-08-24 11:16:07 +0200 |
| commit | c068f22329d5cc722622a2183bbb22eef2093df7 (patch) | |
| tree | 12d56c1aede67988a55e241364606bfbb4dba933 /src/libraries/glm/gtx/int_10_10_10_2.inl | |
| download | openparsec-main.tar.xz openparsec-main.zip | |
Diffstat (limited to 'src/libraries/glm/gtx/int_10_10_10_2.inl')
| -rwxr-xr-x | src/libraries/glm/gtx/int_10_10_10_2.inl | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/libraries/glm/gtx/int_10_10_10_2.inl b/src/libraries/glm/gtx/int_10_10_10_2.inl new file mode 100755 index 0000000..f6b15d7 --- /dev/null +++ b/src/libraries/glm/gtx/int_10_10_10_2.inl @@ -0,0 +1,19 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////// +// OpenGL Mathematics Copyright (c) 2005 - 2012 G-Truc Creation (www.g-truc.net) +/////////////////////////////////////////////////////////////////////////////////////////////////// +// Created : 2010-07-07 +// Updated : 2010-07-07 +// Licence : This source is under MIT License +// File : glm/gtx/int_10_10_10_2.inl +/////////////////////////////////////////////////////////////////////////////////////////////////// + +namespace glm +{ + GLM_FUNC_QUALIFIER dword uint10_10_10_2_cast + ( + glm::vec4 const & v + ) + { + return dword(uint(v.x * 2047.f) << 0 | uint(v.y * 2047.f) << 10 | uint(v.z * 2047.f) << 20 | uint(v.w * 3.f) << 30); + } +}//namespace glm |
