Skip to content

Commit

Permalink
Respect spotlight direction (#718)
Browse files Browse the repository at this point in the history
Signed-off-by: Martin Pecka <peckama2@fel.cvut.cz>

Co-authored-by: Alejandro Hernández Cordero <ahcorde@gmail.com>
  • Loading branch information
peci1 and ahcorde authored Mar 29, 2021
1 parent 14d967d commit 4ea1956
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
5 changes: 5 additions & 0 deletions Migration.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,11 @@ release will remove the deprecated code.
* **Deprecated** `ignition::gazebo::gui::SnapPreviewPath`
* **Replacement** `ignition::gui::SnapFromPath`

* The `<direction>` tag of spot lights was previously not parsed by the
scene, so all spot lights shone in the direction corresponding to the
default `0 0 -1`. Since 5.x, the `<direction>` tag is correctly
processed.

## Ignition Gazebo 4.0.0 to 4.X.X

* Ignition Gazebo 4.0.0 enabled double sided material by default but this
Expand Down
1 change: 1 addition & 0 deletions src/rendering/SceneManager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1105,6 +1105,7 @@ rendering::LightPtr SceneManager::CreateLight(Entity _id,
spotLight->SetInnerAngle(_light.SpotInnerAngle());
spotLight->SetOuterAngle(_light.SpotOuterAngle());
spotLight->SetFalloff(_light.SpotFalloff());
spotLight->SetDirection(_light.Direction());
break;
}
case sdf::LightType::DIRECTIONAL:
Expand Down

0 comments on commit 4ea1956

Please sign in to comment.