#1114 Use "Disable Lighting" on well communication lines also.

This commit is contained in:
Jacob Støren 2017-03-15 10:53:25 +01:00
parent c7207afcc2
commit 983db61402

View File

@ -104,9 +104,11 @@ void RivWellConnectionsPartMgr::appendDynamicGeometryPartsToModel(cvf::ModelBasi
double maxAbsFlux = flowResults->maxAbsPairFlux(static_cast<int>(frameIndex));
if (maxAbsFlux != 0.0) fluxWidthScale = characteristicCellSize / maxAbsFlux;
}
RimEclipseWellCollection* wellColl = m_rimReservoirView->wellCollection();
bool enableLighting = !m_rimReservoirView->isLightingDisabled();
RimEclipseWellCollection* wellColl = m_rimReservoirView->wellCollection();
for ( RimEclipseWell * otherWell: wellColl->wells )
{
@ -148,6 +150,8 @@ void RivWellConnectionsPartMgr::appendDynamicGeometryPartsToModel(cvf::ModelBasi
part->setDrawable(geo.p());
caf::SurfaceEffectGenerator surfaceGen(cvf::Color4f(otherWell->wellPipeColor()), caf::PO_1);
surfaceGen.enableLighting(enableLighting);
cvf::ref<cvf::Effect> eff = surfaceGen.generateCachedEffect();
part->setEffect(eff.p());