Skip to content

Commit

Permalink
Minor fix for projector visibility flags
Browse files Browse the repository at this point in the history
Signed-off-by: Ian Chen <[email protected]>
  • Loading branch information
iche033 committed Sep 25, 2023
1 parent 4190ff6 commit 84b4015
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion ogre2/src/Ogre2Projector.cc
Original file line number Diff line number Diff line change
Expand Up @@ -163,9 +163,11 @@ void Ogre2Projector::UpdateCameraListener()
{
// if a custom visibility flag is set, we will need to use a listener
// for toggling the visibility of the decal
if (this->VisibilityFlags() == GZ_VISIBILITY_ALL)
if ((this->VisibilityFlags() & GZ_VISIBILITY_ALL) == GZ_VISIBILITY_ALL)
{
this->dataPtr->decalNode->setVisible(true);
this->dataPtr->decalNode->getCreator()->setDecalsDiffuse(
this->dataPtr->decal->getDiffuseTexture());

Check warning on line 170 in ogre2/src/Ogre2Projector.cc

View check run for this annotation

Codecov / codecov/patch

ogre2/src/Ogre2Projector.cc#L169-L170

Added lines #L169 - L170 were not covered by tests

for (auto &ogreCamIt : this->dataPtr->camerasWithListener)
{
Expand Down

0 comments on commit 84b4015

Please sign in to comment.