mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 16:41:02 +02:00
Merge pull request #4371 from huffman/light-radius
Update Light to set direction when setting orientation
This commit is contained in:
commit
9649ed9936
1 changed files with 1 additions and 0 deletions
|
@ -44,6 +44,7 @@ void Light::setPosition(const Vec3& position) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void Light::setOrientation(const glm::quat& orientation) {
|
void Light::setOrientation(const glm::quat& orientation) {
|
||||||
|
setDirection(orientation * glm::vec3(0.0f, 0.0f, -1.0f));
|
||||||
_transform.setRotation(orientation);
|
_transform.setRotation(orientation);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue