From 6a745cb2cc4c9658e6c75152e18056f6e0cbaf6d Mon Sep 17 00:00:00 2001 From: scrawl Date: Wed, 29 Mar 2017 07:10:41 +0200 Subject: [PATCH] Fix text colorMode (Bug #3815) and render bin --- apps/opencs/view/render/cellmarker.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/apps/opencs/view/render/cellmarker.cpp b/apps/opencs/view/render/cellmarker.cpp index abc337ce20..980ed305a6 100644 --- a/apps/opencs/view/render/cellmarker.cpp +++ b/apps/opencs/view/render/cellmarker.cpp @@ -3,6 +3,7 @@ #include #include +#include #include #include #include @@ -75,7 +76,10 @@ CSVRender::CellMarker::CellMarker( mMarkerNode->setAutoRotateMode(osg::AutoTransform::ROTATE_TO_SCREEN); mMarkerNode->setAutoScaleToScreen(true); mMarkerNode->getOrCreateStateSet()->setMode(GL_DEPTH_TEST, osg::StateAttribute::OFF); - mMarkerNode->getOrCreateStateSet()->setRenderBinDetails(osg::StateSet::TRANSPARENT_BIN + 1, "RenderBin"); + mMarkerNode->getOrCreateStateSet()->setRenderBinDetails(11, "RenderBin"); + osg::ref_ptr mat = new osg::Material; + mat->setColorMode(osg::Material::AMBIENT_AND_DIFFUSE); + mMarkerNode->getOrCreateStateSet()->setAttribute(mat); mMarkerNode->setUserData(new CellMarkerTag(this)); mMarkerNode->setNodeMask(Mask_CellMarker);