|
|
|
@ -1,7 +1,7 @@ |
|
|
|
|
///////////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
/// OpenGL Mathematics (glm.g-truc.net)
|
|
|
|
|
///
|
|
|
|
|
/// Copyright (c) 2005 - 2014 G-Truc Creation (www.g-truc.net)
|
|
|
|
|
/// Copyright (c) 2005 - 2015 G-Truc Creation (www.g-truc.net)
|
|
|
|
|
/// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
|
|
|
/// of this software and associated documentation files (the "Software"), to deal
|
|
|
|
|
/// in the Software without restriction, including without limitation the rights
|
|
|
|
@ -104,11 +104,11 @@ namespace glm |
|
|
|
|
///
|
|
|
|
|
/// @see <a href="http://www.opengl.org/sdk/docs/manglsl/xhtml/faceforward.xml">GLSL faceforward man page</a>
|
|
|
|
|
/// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 8.5 Geometric Functions</a>
|
|
|
|
|
template <typename genType> |
|
|
|
|
GLM_FUNC_DECL genType faceforward( |
|
|
|
|
genType const & N, |
|
|
|
|
genType const & I, |
|
|
|
|
genType const & Nref); |
|
|
|
|
template <typename T, precision P, template <typename, precision> class vecType> |
|
|
|
|
GLM_FUNC_DECL vecType<T, P> faceforward( |
|
|
|
|
vecType<T, P> const & N, |
|
|
|
|
vecType<T, P> const & I, |
|
|
|
|
vecType<T, P> const & Nref); |
|
|
|
|
|
|
|
|
|
/// For the incident vector I and surface orientation N,
|
|
|
|
|
/// returns the reflection direction : result = I - 2.0 * dot(N, I) * N.
|
|
|
|
|