Commit 41f765b8 authored by Sebastien Barre's avatar Sebastien Barre
Browse files

ENH: fix computation of slice number/max

parent c6a6ac55
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
//---------------------------------------------------------------------------- //----------------------------------------------------------------------------
vtkStandardNewMacro(vtkCornerAnnotation); vtkStandardNewMacro(vtkCornerAnnotation);
vtkCxxRevisionMacro(vtkCornerAnnotation, "1.15"); vtkCxxRevisionMacro(vtkCornerAnnotation, "1.16");
vtkSetObjectImplementationMacro(vtkCornerAnnotation,ImageActor,vtkImageActor); vtkSetObjectImplementationMacro(vtkCornerAnnotation,ImageActor,vtkImageActor);
vtkSetObjectImplementationMacro(vtkCornerAnnotation,WindowLevel, vtkSetObjectImplementationMacro(vtkCornerAnnotation,WindowLevel,
...@@ -130,8 +130,8 @@ void vtkCornerAnnotation::TextReplace(vtkImageActor *ia, ...@@ -130,8 +130,8 @@ void vtkCornerAnnotation::TextReplace(vtkImageActor *ia,
} }
if (ia) if (ia)
{ {
slice = ia->GetSliceNumber() + 1; slice = ia->GetSliceNumber() - ia->GetSliceNumberMin() + 1;
slice_max = ia->GetSliceNumberMax() + 1; slice_max = ia->GetSliceNumberMax() - ia->GetSliceNumberMin() + 1;
ia_input = ia->GetInput(); ia_input = ia->GetInput();
if (!wl_input && ia_input) if (!wl_input && ia_input)
{ {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment