Fix typo when generating light NNC colors

This commit is contained in:
Magne Sjaastad 2018-03-24 14:42:30 +01:00
parent a55740a376
commit bffc50b826
2 changed files with 6 additions and 1 deletions

View File

@ -705,8 +705,9 @@ void RivFaultPartMgr::updateNNCColors(size_t timeStepIndex, RimEclipseCellColors
cvf::Color3f nncColor = m_defaultColor;
nncColor.r() += (1.0 - nncColor.r()) * 0.2;
nncColor.g() += (1.0 - nncColor.g()) * 0.2;
nncColor.g() += (1.0 - nncColor.b()) * 0.2;
nncColor.b() += (1.0 - nncColor.b()) * 0.2;
CVF_ASSERT(nncColor.isValid());
cvf::ref<cvf::Effect> nncEffect;
if (m_rimFaultCollection->showFaultFaces || m_rimFaultCollection->showOppositeFaultFaces)

View File

@ -259,6 +259,8 @@ void EffectGenerator::releaseUnreferencedEffects()
//--------------------------------------------------------------------------------------------------
SurfaceEffectGenerator::SurfaceEffectGenerator(const cvf::Color4f& color, PolygonOffset polygonOffset)
{
CVF_ASSERT(color.isValid());
m_color = color;
m_polygonOffset = polygonOffset;
m_cullBackfaces = FC_NONE;
@ -271,6 +273,8 @@ SurfaceEffectGenerator::SurfaceEffectGenerator(const cvf::Color4f& color, Polygo
//--------------------------------------------------------------------------------------------------
SurfaceEffectGenerator::SurfaceEffectGenerator(const cvf::Color3f& color, PolygonOffset polygonOffset)
{
CVF_ASSERT(color.isValid());
m_color = cvf::Color4f(color, 1.0f);
m_polygonOffset = polygonOffset;
m_cullBackfaces = FC_NONE;