Skip to content

Commit

Permalink
#2460 Tensor vectors: Move cvf::ref of scaler mapper out to avoid nul…
Browse files Browse the repository at this point in the history
…lptr exception
  • Loading branch information
Rebecca Cox committed Feb 20, 2018
1 parent 2c26ca4 commit 0366361
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -334,10 +334,10 @@ cvf::ref<cvf::Part> RivTensorResultPartMgr::createPart(const std::vector<TensorV

cvf::ScalarMapper* activeScalerMapper = nullptr;

cvf::ref<cvf::ScalarMapperDiscreteLinear> discreteScalarMapper = new cvf::ScalarMapperDiscreteLinear;
auto vectorColors = m_rimReservoirView->tensorResults()->vectorColors();
if (vectorColors == RimTensorResults::MAGENTA_BROWN_BLACK || vectorColors == RimTensorResults::WHITE_GRAY_BLACK)
{
cvf::ref<cvf::ScalarMapperDiscreteLinear> discreteScalarMapper = new cvf::ScalarMapperDiscreteLinear;

activeScalerMapper = discreteScalarMapper.p();

Expand Down

0 comments on commit 0366361

Please sign in to comment.