Fixed merge

This commit is contained in:
Christophe Riccio
2013-03-20 01:49:22 +01:00
8 changed files with 221 additions and 81 deletions

View File

@@ -432,6 +432,20 @@ namespace detail
/// @see gtc_half_float
hvec4 abs(hvec4 const & x);
/// Selects which vector each returned component comes
/// from. For a component of <a> that is false, the
/// corresponding component of x is returned. For a
/// component of a that is true, the corresponding
/// component of y is returned. Components of x and y that
/// are not selected are allowed to be invalid floating point
/// values and will have no effect on the results. Thus, this
/// provides different functionality than
/// genType mix(genType x, genType y, genType(a))
/// where a is a Boolean vector.
///
/// @see gtc_half_float
half mix(half const & x, half const & y, bool const & a);
/// @}
}// namespace glm

View File

@@ -1036,4 +1036,15 @@ namespace detail
float(v.w) >= float(0) ? v.w : -v.w);
}
template <>
GLM_FUNC_QUALIFIER glm::half mix
(
glm::half const & x,
glm::half const & y,
bool const & a
)
{
return a ? y : x;
}
}//namespace glm