-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ENH: harden transformToWorld of exported models #15
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, this will be good, just please address the inline comment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, this will be good, I just added a few nitpicky comments.
You can make changes in Slicer using the web interface. A pull request is automatically created and tests are executed on it.
transformer.SetTransform(ras2lpsTransform) | ||
transformer.SetInputConnection(outputModelNode.GetPolyDataConnection()) | ||
transformOutputModelToWorldRAS = vtk.vtkGeneralTransform() | ||
transformOutputModelToWorldRAS.PostMultiply() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This needs to come after the slicer.vtkMRMLTransformNode.GetTransformBetweenNodes(inputModelNode.GetParentTransformNode() call.
transformOutputModelToWorldRAS.PostMultiply() | ||
slicer.vtkMRMLTransformNode.GetTransformBetweenNodes(inputModelNode.GetParentTransformNode(), None, transformOutputModelToWorldRAS) | ||
|
||
transformOutputModelToWorldLPS = transformOutputModelToWorldRAS |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This doesn't really explain things. You could create a new vtkGeneralTransform instead just assigning a new name but that would be a bit overcomplicated,l. Probably using just the transformOutputModelToWorldLPS name and a good comment would be sufficient.
Related #14