Skip to content

Commit

Permalink
BUG: SpatialObject writes object color
Browse files Browse the repository at this point in the history
The MetaSceneConverter code did not copy the SpatialObject's color
to the metaObject being written.

Color wasn't being copied from the SpatialObject to its Meta
representation for writing.
  • Loading branch information
aylward authored and thewtex committed Aug 2, 2021
1 parent 1c3c310 commit 3bf34f6
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions Modules/Core/SpatialObjects/include/itkMetaSceneConverter.hxx
Original file line number Diff line number Diff line change
Expand Up @@ -355,6 +355,11 @@ MetaSceneConverter<NDimensions, PixelType, TMeshTraits>::CreateMetaScene(Spatial
currentMeta->ParentID((*it)->GetParent()->GetId());
}
currentMeta->Name((*it)->GetProperty().GetName().c_str());
currentMeta->Color((*it)->GetProperty().GetRed(),
(*it)->GetProperty().GetGreen(),
(*it)->GetProperty().GetBlue(),
(*it)->GetProperty().GetAlpha());

this->SetTransform(currentMeta, (*it)->GetObjectToParentTransform());
metaScene->AddObject(currentMeta);
it++;
Expand Down

0 comments on commit 3bf34f6

Please sign in to comment.