From 2877f4eda3d1b0c7431039e3142ecf1a282a34b1 Mon Sep 17 00:00:00 2001 From: LaG1924 <12997935+LaG1924@users.noreply.github.com> Date: Tue, 21 Aug 2018 20:40:38 +0500 Subject: Update glm to 0.9.9.0 --- external/include/glm/gtx/wrap.inl | 52 +++++++++++++++++++-------------------- 1 file changed, 26 insertions(+), 26 deletions(-) (limited to 'external/include/glm/gtx/wrap.inl') diff --git a/external/include/glm/gtx/wrap.inl b/external/include/glm/gtx/wrap.inl index 941a803..83e350f 100644 --- a/external/include/glm/gtx/wrap.inl +++ b/external/include/glm/gtx/wrap.inl @@ -3,56 +3,56 @@ namespace glm { - template class vecType> - GLM_FUNC_QUALIFIER vecType clamp(vecType const& Texcoord) + template + GLM_FUNC_QUALIFIER vec clamp(vec const& Texcoord) { - return glm::clamp(Texcoord, vecType(0), vecType(1)); + return glm::clamp(Texcoord, vec(0), vec(1)); } - template - GLM_FUNC_QUALIFIER genType clamp(genType const & Texcoord) + template + GLM_FUNC_QUALIFIER genType clamp(genType const& Texcoord) { - return clamp(tvec1(Texcoord)).x; + return clamp(vec<1, genType, defaultp>(Texcoord)).x; } - template class vecType> - GLM_FUNC_QUALIFIER vecType repeat(vecType const& Texcoord) + template + GLM_FUNC_QUALIFIER vec repeat(vec const& Texcoord) { return glm::fract(Texcoord); } - template - GLM_FUNC_QUALIFIER genType repeat(genType const & Texcoord) + template + GLM_FUNC_QUALIFIER genType repeat(genType const& Texcoord) { - return repeat(tvec1(Texcoord)).x; + return repeat(vec<1, genType, defaultp>(Texcoord)).x; } - template class vecType> - GLM_FUNC_QUALIFIER vecType mirrorClamp(vecType const& Texcoord) + template + GLM_FUNC_QUALIFIER vec mirrorClamp(vec const& Texcoord) { return glm::fract(glm::abs(Texcoord)); } - template - GLM_FUNC_QUALIFIER genType mirrorClamp(genType const & Texcoord) + template + GLM_FUNC_QUALIFIER genType mirrorClamp(genType const& Texcoord) { - return mirrorClamp(tvec1(Texcoord)).x; + return mirrorClamp(vec<1, genType, defaultp>(Texcoord)).x; } - template class vecType> - GLM_FUNC_QUALIFIER vecType mirrorRepeat(vecType const& Texcoord) + template + GLM_FUNC_QUALIFIER vec mirrorRepeat(vec const& Texcoord) { - vecType const Abs = glm::abs(Texcoord); - vecType const Clamp = glm::mod(glm::floor(Abs), vecType(2)); - vecType const Floor = glm::floor(Abs); - vecType const Rest = Abs - Floor; - vecType const Mirror = Clamp + Rest; - return mix(Rest, vecType(1) - Rest, glm::greaterThanEqual(Mirror, vecType(1))); + vec const Abs = glm::abs(Texcoord); + vec const Clamp = glm::mod(glm::floor(Abs), vec(2)); + vec const Floor = glm::floor(Abs); + vec const Rest = Abs - Floor; + vec const Mirror = Clamp + Rest; + return mix(Rest, vec(1) - Rest, glm::greaterThanEqual(Mirror, vec(1))); } - template + template GLM_FUNC_QUALIFIER genType mirrorRepeat(genType const& Texcoord) { - return mirrorRepeat(tvec1(Texcoord)).x; + return mirrorRepeat(vec<1, genType, defaultp>(Texcoord)).x; } }//namespace glm -- cgit v1.2.3