Skip to content

Commit

Permalink
Add a warning when the wrong visibility flags are set
Browse files Browse the repository at this point in the history
Signed-off-by: Matias N. Goldberg <[email protected]>
  • Loading branch information
darksylinc committed Dec 10, 2022
1 parent 3fac6a7 commit 710e666
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions ogre2/src/Ogre2Camera.cc
Original file line number Diff line number Diff line change
Expand Up @@ -376,6 +376,12 @@ Ogre::Camera *Ogre2Camera::OgreCamera() const
//////////////////////////////////////////////////
void Ogre2Camera::SetVisibilityMask(uint32_t _mask)
{
if (_mask & ~Ogre::VisibilityFlags::RESERVED_VISIBILITY_FLAGS)
{
ignerr << "Ogre2Camera::SetVisibilityMask: Mask bits " << std::hex
<< ~Ogre::VisibilityFlags::RESERVED_VISIBILITY_FLAGS << std::dec
<< " are set but will be ignored by ogre2 backend." << std::endl;
}
BaseSensor::SetVisibilityMask(_mask);
if (this->renderTexture)
this->renderTexture->SetVisibilityMask(_mask);
Expand Down

0 comments on commit 710e666

Please sign in to comment.