View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0003993 | Slicer4 | Core: MRML | public | 2015-05-13 12:52 | 2017-06-10 08:51 |
Reporter | ktdiedrich | Assigned To | lassoan | ||
Priority | normal | Severity | minor | Reproducibility | always |
Status | closed | Resolution | fixed | ||
Product Version | Slicer 4.4.0 | ||||
Target Version | Fixed in Version | Slicer 4.5.0-1 | |||
Summary | 0003993: Registration Transform only applies transform 1 | ||||
Description | Nightly release 05-12-2015: From the Data module when dragging an image under a Transform (linear or BSpline) only Transform 1 and not Transform 2 is applied to the image. I tested the same transforms on stable Slicer 4.4.0 and both Transform 1 and Transform 2 are applied to an image. | ||||
Tags | No tags attached. | ||||
2015-05-20 10:22
|
SlicerTransformBugData.zip (1,183,101 bytes) |
Sample dta uploaded in ZIP file In the current Slicer 05-19-2015 Load transforms: Set intraoperative as background image and preoperative as foreground image in a viewer |
|
I'm trying the steps but I'm not understanding the issue. To start, the volumes do not overlap. Dragging preoperative under LT2 makes them overlap. Dragging the preoperative under AfBS2 makes them overlap and applies the BSpline. If you look at the AfBS2 Information in the transforms it includes both steps (linear and nonlinear). If you drag preoperative under LT2 and then drag LT2 under AfBS2 then the volumes do not overlap. I believe this behavior is correct and Slicer 4.4.0 was incorrect. I'm going to run this by Andras for his analysis. |
|
The volume don't overlap to start. AfBS2 was made with BRAINSfit affine and BSpline registration modes checked to transform preoperative onto intraoperative with 1 transform object (containing 2 transforms). We shouldn't need LT2. Slicer 4.4.0 does 2 transforms transforming preoperative on intraoperative. I made LT2 with only affine checked in BRAINSfit to test the linear transform separately from the BSpline transform. |
|
The transforms look good, they seem to be applied correctly. However, there seems to be an issue with the red slice viewer update: if the foreground volume is set before the transform is applied to the foreground volume then the red slice viewer does not show the foreground volume (the yellow and green slice viewers are OK). After I switch the foreground/background volume in the red slice viewer it starts to behave correctly. Diedrich, can you confirm that if you switch the foreground and background volume (intraop foreground, preop background) then it starts to work correctly? |
|
I wonder if this is related to the layout manager issue that came up recently. https://github.com/Slicer/Slicer/commit/2118883d08f404d5ec035c5271dbec1b7e83532b |
|
After several hours of debugging I've finally found the root cause of the issue: in int vtkImageReslice::RequestUpdateExtent() if this->ResliceTransform is not a vtkHomogeneousTransform then the hole input extent is updated and then the method returns. However, it does not touch the this->HitInputExtent flag. If the this->HitInputExtent was 0 before then the output of the filter remains always 0. Probably the simplest fix is to set the HitInputExtentFlag to 1 if the reslice transform is not homogeneous: VTKv6/Imaging/Core/vtkImageReslice.cxx: @@ -592,6 +592,7 @@ int vtkImageReslice::RequestUpdateExtent(
|
|
I've sent an email to David Gobbi to confirm that this is an issue in vtkImageReslice. |
|
Wow, amazing detective work Andras! Shall we put that in github.com:Slicer/VTK and propose it to kitware:VTK/VTK? |
|
I've sent a pull request to fix it in Slicer's VTK fork: I've checked the process for sending patches to VTK and it seems to be very long/difficult and I don't have any more time to spend with this issue. |
|
Understood - I merged the pull request and am testing on mac. If all is good I will update the version of VTK in slicer. |
|
Updated slicer/vtk superbuild hash in r24272 Thanks Andras! Karl, please test on your own build or tomorrow's nightly and close the issue if all is good. |
|
David has integrated the patch into VTK: |
|
Nice. Looks like it all worked as intended. |
|
Yes, it works with the fixed and moving images in both the foreground and background. |
|
Import 2017-06-07 23:51:09: master c560f575 2015-05-21 12:30:05 Details Diff |
BUG: 0003993 fix update of render window when transform changes Full credit to Andras Lasso for debugging this at the VTK level! Issue is described on the bug report: http://na-mic.org/Mantis/view.php?id=3993 git-svn-id: http://svn.slicer.org/Slicer4/trunk@24272 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - SuperBuild/External_VTKv6.cmake | Diff File |
Date Modified | Username | Field | Change |
---|---|---|---|
2015-05-13 12:52 | ktdiedrich | New Issue | |
2015-05-13 12:52 | ktdiedrich | Status | new => assigned |
2015-05-13 12:52 | ktdiedrich | Assigned To | => alexy |
2015-05-20 10:22 | ktdiedrich | File Added: SlicerTransformBugData.zip | |
2015-05-20 11:05 | ktdiedrich | Note Added: 0013077 | |
2015-05-20 11:21 | pieper | Note Added: 0013078 | |
2015-05-20 12:25 | ktdiedrich | Note Added: 0013079 | |
2015-05-20 14:04 | lassoan | Note Added: 0013080 | |
2015-05-20 14:19 | pieper | Note Added: 0013081 | |
2015-05-21 06:32 | lassoan | Note Added: 0013083 | |
2015-05-21 06:43 | lassoan | Note Added: 0013084 | |
2015-05-21 06:43 | pieper | Note Added: 0013085 | |
2015-05-21 08:15 | lassoan | Note Added: 0013087 | |
2015-05-21 08:39 | pieper | Note Added: 0013088 | |
2015-05-21 08:40 | pieper | Assigned To | alexy => lassoan |
2015-05-21 08:57 | pieper | Note Added: 0013089 | |
2015-05-21 08:57 | pieper | Status | assigned => resolved |
2015-05-21 08:57 | pieper | Fixed in Version | => Slicer 4.4.1 |
2015-05-21 08:57 | pieper | Resolution | open => fixed |
2015-05-21 10:16 | lassoan | Note Added: 0013090 | |
2015-05-21 11:15 | pieper | Note Added: 0013091 | |
2015-05-26 05:07 | ktdiedrich | Note Added: 0013100 | |
2015-05-26 05:42 | pieper | Status | resolved => closed |
2015-09-09 08:29 | jcfr | Fixed in Version | Slicer 4.4.1 => Slicer 4.5.0-1 |
2017-06-10 08:51 | pieper | Changeset attached | => Slicer master c560f575 |