X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;ds=inline;f=source%2F3d%2Foverlay.cpp;h=ee9fea7892d465c8e439161cbf4bce17edd0c81f;hb=1ff06c5bc46a677fa389ef86c6b26664368f1653;hp=3f2d621d6b8aade208f8517488a0f3585f2117fc;hpb=bc8ac89bbe774bb133b758416182aa18e5e0a5a5;p=r2c2.git diff --git a/source/3d/overlay.cpp b/source/3d/overlay.cpp index 3f2d621..ee9fea7 100644 --- a/source/3d/overlay.cpp +++ b/source/3d/overlay.cpp @@ -1,6 +1,6 @@ /* $Id$ -This file is part of the MSP Märklin suite +This file is part of R²C² Copyright © 2010 Mikkosoft Productions, Mikko Rasa Distributed under the GPL */ @@ -18,7 +18,7 @@ Distributed under the GPL using namespace std; using namespace Msp; -namespace Marklin { +namespace R2C2 { Overlay3D::Overlay3D(const Graphics::Window &w, const GL::Camera &c, const GL::Font &f): window(w), @@ -98,6 +98,9 @@ void Overlay3D::render(const GL::Tag &tag) const for(map::const_iterator i=icons.begin(); i!=icons.end(); ++i) { + if(!i->first->is_visible()) + continue; + const Icon &icon = *i->second; Point node = i->first->get_node(); @@ -192,4 +195,4 @@ Overlay3D::Icon::Icon(): background((GL::COLOR4_UBYTE, GL::VERTEX2)) { } -} // namespace Marklin +} // namespace R2C2