Import 2017-06-07 23:51:09: master f6df62e8

Author Committer Branch Timestamp Parent
jcfr jcfr master 2017-05-05 23:53:44 master 50f6752f
Changeset

ENH: Ensure node loaded by volume logic respect default nodes

To that effect, this commit introduces the new method "vtkMRMLScene::AddNewNodeByClass()".
It allows to:

(1) easily create a node by className, optionally set its name
and then add it to the scene.

(2) ensure properties of loaded node are initialized considering
default nodes.

Suggested-by: Andras Lasso <lasso@queensu.ca>
Reviewed-by: Andras Lasso <lasso@queensu.ca>
Thanks: Andras Lasso <lasso@queensu.ca>

git-svn-id: http://svn.slicer.org/Slicer4/trunk@26001 3bd1e089-480b-0410-8dfb-8563597acbee

mod - Libs/MRML/Core/vtkMRMLScene.cxx Diff File
mod - Libs/MRML/Core/vtkMRMLScene.h Diff File
mod - Modules/Loadable/Volumes/Logic/vtkSlicerVolumesLogic.cxx Diff File
mod - Modules/Loadable/Volumes/Testing/Cxx/vtkSlicerVolumesLogicTest1.cxx Diff File