Update Light to set direction when setting orientation

This commit is contained in:
Ryan Huffman 2015-03-03 12:41:51 -08:00
parent 29340b6586
commit 3fef8a1622

View file

@ -44,6 +44,7 @@ void Light::setPosition(const Vec3& position) {
}
void Light::setOrientation(const glm::quat& orientation) {
setDirection(orientation * glm::vec3(0.0f, 0.0f, -1.0f));
_transform.setRotation(orientation);
}