bugfixes to minor issues reported by Sean Bell

metadata
Wenzel Jakob 2012-04-08 20:10:48 -04:00
parent cdf9b2c517
commit 9f8307291a
2 changed files with 1 additions and 2 deletions

View File

@ -387,7 +387,6 @@ template <typename T> inline T absDot(const TVector3<T> &v1, const TVector3<T> &
} }
template <typename T> inline TVector3<T> cross(const TVector3<T> &v1, const TVector3<T> &v2) { template <typename T> inline TVector3<T> cross(const TVector3<T> &v1, const TVector3<T> &v2) {
/* Left-handed vector cross product */
return TVector3<T>( return TVector3<T>(
(v1.y * v2.z) - (v1.z * v2.y), (v1.y * v2.z) - (v1.z * v2.y),
(v1.z * v2.x) - (v1.x * v2.z), (v1.z * v2.x) - (v1.x * v2.z),

View File

@ -244,7 +244,7 @@ Spectrum MIPMap::getTexel(int level, int x, int y) const {
int levelWidth = m_levelWidth[level]; int levelWidth = m_levelWidth[level];
int levelHeight = m_levelHeight[level]; int levelHeight = m_levelHeight[level];
if (x <= 0 || y < 0 || x >= levelWidth || y >= levelHeight) { if (x < 0 || y < 0 || x >= levelWidth || y >= levelHeight) {
switch (m_wrapMode) { switch (m_wrapMode) {
case ERepeat: case ERepeat:
x = modulo(x, levelWidth); x = modulo(x, levelWidth);