Skip to content

Commit

Permalink
[Metal] Revert RenderOrder is in different scale in Reverse Z gazebos…
Browse files Browse the repository at this point in the history
…im#514

Signed-off-by: Rhys Mainwaring <[email protected]>
  • Loading branch information
srmainwaring committed Jul 7, 2022
1 parent 67ee5db commit 39495c7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion ogre2/src/Ogre2Material.cc
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,8 @@ void Ogre2Material::SetRenderOrder(const float _renderOrder)
Ogre::Root *root = Ogre2RenderEngine::Instance()->OgreRoot();
Ogre::RenderSystem *renderSystem = root->getRenderSystem();

if (renderSystem->isReverseDepth())
if (renderSystem->isReverseDepth() &&
Ogre2RenderEngine::Instance()->GraphicsAPI() != GraphicsAPI::METAL)
{
// Reverse depth needs 100x scale AND ends up being superior
// See https://github.com/gazebosim/gz-rendering/
Expand Down

0 comments on commit 39495c7

Please sign in to comment.