1. 08 Mar, 2019 1 commit
    • jcfr's avatar
      COMP: Fix unused warnings related to use of vtkMRMLNodePropertyMacros · 29be7973
      jcfr authored
      These classes where using the macros vtkMRMLWriteXMLBeginMacro and
      vtkMRMLWriteXMLEndMacro but without any content printed or written
      between those calls.
      This commit fixes warnings like the following:
      Modules/Loadable/VolumeRendering/MRML/vtkMRMLGPURayCastVolumeRenderingDisplayNode.cxx: In member function ‘virtual void vtkMRMLGPURayCastVolumeRenderingDisplayNode::ReadXMLAttributes(const char**)’:
      Libs/MRML/Core/vtkMRMLNodePropertyMacros.h:148:15: warning: variable ‘xmlReadAttName’ set but not used [-Wunused-but-set-variable]
         const char* xmlReadAttName; \
      Modules/Loadable/VolumeRendering/MRML/vtkMRMLGPURayCastVolumeRenderingDisplayNode.cxx:48:3: note: in expansion of macro ‘vtkMRMLReadXMLBeginMacro’
      Modules/Loadable/VolumeRendering/MRML/vtkMRMLGPURayCastVolumeRenderingDisplayNode.cxx: In member function ‘virtual void vtkMRMLGPURayCastVolumeRenderingDisplayNode::WriteXML(std::ostream&, int)’:
      Libs/MRML/Core/vtkMRMLNodePropertyMacros.h:30:12: warning: unused variable ‘xmlWriteOutputStream’ [-Wunused-variable]
         ostream& xmlWriteOutputStream = of;
      Modules/Loadable/VolumeRendering/MRML/vtkMRMLGPURayCastVolumeRenderingDisplayNode.cxx:57:3: note: in expansion of macro ‘vtkMRMLWriteXMLBeginMacro’
      Modules/Loadable/VolumeRendering/MRML/vtkMRMLGPURayCastVolumeRenderingDisplayNode.cxx: In member function ‘virtual void vtkMRMLGPURayCastVolumeRenderingDisplayNode::PrintSelf(std::ostream&, vtkIndent)’:
      Libs/MRML/Core/vtkMRMLNodePropertyMacros.h:417:12: warning: unused variable ‘printOutputStream’ [-Wunused-variable]
         ostream& printOutputStream = os; \
      Modules/Loadable/VolumeRendering/MRML/vtkMRMLGPURayCastVolumeRenderingDisplayNode.cxx:78:3: note: in expansion of macro ‘vtkMRMLPrintBeginMacro’
         vtkMRMLPrintBeginMacro(os, indent);
      Libs/MRML/Core/vtkMRMLNodePropertyMacros.h:418:13: warning: variable ‘printOutputIndent’ set but not used [-Wunused-but-set-variable]
         vtkIndent printOutputIndent = indent;
      Modules/Loadable/VolumeRendering/MRML/vtkMRMLGPURayCastVolumeRenderingDisplayNode.cxx:78:3: note: in expansion of macro ‘vtkMRMLPrintBeginMacro’
         vtkMRMLPrintBeginMacro(os, indent);
      From: Pablo Hernandez-Cerdan <pablo.hernandez@kitware.com>
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27999 3bd1e089-480b-0410-8dfb-8563597acbee
  2. 15 Dec, 2018 2 commits
  3. 11 Dec, 2018 1 commit
  4. 08 Dec, 2018 1 commit
    • jcfr's avatar
      ENH: Speedup (from 2x to 10x faster) and simplify python tests · 783cf816
      jcfr authored
      * Run python self tests with a messageDelay of 100ms. Message delay is used
        in function "delayDisplay" to (1) let the event loop catch up to the state
        of the test and (2) to display a meaningful message when running test
        interactively from Slicer.
        When running tests on the dashboard, there is no need to wait too long
        before each test steps. This commit sets a default of 50ms when tests
        are executed from the module panel. It also provides a Slicer to change
        the value.
      * Refactor tests to use ScriptedLoadableModule base classes
      * Remove redundant test case AbdominalAtlasTest already coverted by
      * Remove duplicated implementation of functions like takeScreenshot.
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27617 3bd1e089-480b-0410-8dfb-8563597acbee
  5. 25 Nov, 2018 1 commit
  6. 13 Nov, 2018 1 commit
    • lassoan's avatar
      BUG: Fixed volume rendering ROI reset · 167e336f
      lassoan authored
      When volume rendered node's transform was changed, ROI was reset. This made it impossible to review clipped volume sequences or transform clipped volumes.
      ROI reset is not needed anyway, because if user would like to keep the volume fully displayed when it is transformed, then it can be achieved by setting the same parent transform for the ROI node as for the volume node.
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27544 3bd1e089-480b-0410-8dfb-8563597acbee
  7. 10 Nov, 2018 2 commits
  8. 27 Oct, 2018 1 commit
    • pieper's avatar
      COMP: fix macOS mojave build errors · 45994229
      pieper authored
      Add GetPointer to fix calls in mrml node tests.
      /Users/pieper/slicer/latest/Slicer/Libs/MRML/Core/Testing/vtkMRMLTableNodeTest1.cxx:38:18: error: no viable
            conversion from 'vtkNew<vtkMRMLTableNode>' to 'vtkMRMLNode *'
      /Users/pieper/slicer/latest/Slicer/Libs/MRML/Core/vtkMRMLScene.h:183:37: note: passing argument to parameter
            'nodeToAdd' here
        vtkMRMLNode* AddNode(vtkMRMLNode *nodeToAdd);
      From: Steve Pieper <pieper@isomics.com>
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27525 3bd1e089-480b-0410-8dfb-8563597acbee
  9. 25 Oct, 2018 1 commit
  10. 23 Oct, 2018 1 commit
    • cpinter's avatar
      BUG: Fix default display and storage node creation · 0f8704d1
      cpinter authored
      The CreateDefaultDisplayNodes and CreateDefaultStorageNode functions did not use the CreateNewNodeByClass infrastructure so default nodes were not considered. This has been fixed in all node classes using such functions.
      Tests also needed to be fixed accordingly. Null check for scene and raw ID setting has been removed from EXERCISE_ALL_BASIC_MRML_METHODS, and all failing tests have been changed so that the tested node is in a scene.
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27516 3bd1e089-480b-0410-8dfb-8563597acbee
  11. 22 Oct, 2018 1 commit
  12. 16 Oct, 2018 2 commits
    • lassoan's avatar
      ENH: Add CT-Air volume rendering preset · 119c2f08
      lassoan authored
      Users have often trouble with volume rendering "inverted" images - where dark regions should be visible and bright regions should be hidden (showing airways, blood vessels, ventricles, etc.), but so far all the volume rendering presets are showing bright regions and hiding dark regions. Creating an inverted transfer function requires a lot of clicking, so it is good to have at least one inverted preset, which can be used as a basis and shifted or slightly tuned as needed.
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27493 3bd1e089-480b-0410-8dfb-8563597acbee
    • lassoan's avatar
      ENH: Enable VR smooth clipping · f0329e5f
      lassoan authored
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27489 3bd1e089-480b-0410-8dfb-8563597acbee
  13. 13 Oct, 2018 2 commits
  14. 12 Oct, 2018 1 commit
  15. 04 Oct, 2018 1 commit
  16. 03 Oct, 2018 1 commit
  17. 25 Sep, 2018 1 commit
    • lassoan's avatar
      BUG: Fix py_ThresholdThreadingTest · 60f918d2
      lassoan authored
      Probably as a result of VTK Python wrapper updates, None is not accepted anymore as vtkMRMLSelectionNode::SetReferenceSecondaryVolumeID input.
      Since SetReferenceSecondaryVolumeID was just a workaround for fixing Python wrapping issues, there is no more reason to use it and we switch to SetSecondaryVolumeID.
      Changes are performed similarly for volume and label volume.
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27432 3bd1e089-480b-0410-8dfb-8563597acbee
  18. 12 Sep, 2018 1 commit
  19. 11 Sep, 2018 1 commit
  20. 26 Aug, 2018 1 commit
    • cpinter's avatar
      BUG: Fixed crash in volume rendering with multiple volumes and views · 468ad697
      cpinter authored
      With the NextActorPortIndex variable in the volume rendering displayable manager being static, it was common to all displayable managers (i.e. all views). Because of this, if 3 volumes were shown in 3 views, then NextActorPortIndex was already 12 (first one for each DM is for a dummy volume as a workaround to a VTK bug). Unfortunately, there is a hard limit of 10 input connections for the multi-volume mapper. Once this limit was crossed, Slicer crashed. Now NextActorPortIndex is per displayable manager, so this does not occur. I also added a check for the input connection limit.
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27369 3bd1e089-480b-0410-8dfb-8563597acbee
  21. 12 Aug, 2018 1 commit
    • jcfr's avatar
      COMP: Add missing header when using QVTKOpenGLWidget · 1751c87a
      jcfr authored
      Same fix than #987 but for all tests.
      Missing header when `Slicer_VTK_USE_QVTKOPENGLWIDGET` is defined.
      Tested using VTKv9 from this branch:
      Solve error:
      In file included from
      note: forward declaration of ‘class QSurfaceFormat’
       class QSurfaceFormat;
              error: incomplete type ‘QSurfaceFormat’ used in nested name
      From: Pablo Hernandez-Cerdan <pablo.hernandez@kitware.com>
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27346 3bd1e089-480b-0410-8dfb-8563597acbee
  22. 02 Aug, 2018 1 commit
  23. 19 Jul, 2018 1 commit
  24. 12 Jul, 2018 1 commit
  25. 02 Jul, 2018 1 commit
  26. 20 Jun, 2018 1 commit
  27. 13 Jun, 2018 1 commit
  28. 11 Jun, 2018 7 commits
    • cpinter's avatar
      ENH: Apply vol.ren. preset when re-selecting current preset · c5636f4c
      cpinter authored
      In order to reset the properties of the currently selected preset after adjusting shift, transfer functions, etc. was only possible by selecting another preset, and selecting the previous one again. With this change if the current preset is selected in the drop-down, it will be applied, so the extra two clicks are not necessary.
      Fixes https://issues.slicer.org/view.php?id=4410
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27246 3bd1e089-480b-0410-8dfb-8563597acbee
    • cpinter's avatar
      BUG: Fix issues with loading volume rendering default settings · 299bbafa
      cpinter authored
      Volume rendering default settings in Application settings are stored in the default 3D view node. But when the volume rendering logic is created, it does not have access to the scene yet. The previous solution, which set the defaults when the logic was modified resulted in a bug, namely that the default settings were applied when a new volume was shown. By applying the defaults when application startup completed, the issue is resolved.
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27245 3bd1e089-480b-0410-8dfb-8563597acbee
    • cpinter's avatar
      ENH: Add GPU memory combobox · edf5b767
      cpinter authored
      Added new widget to set GPU memory both in Application Settings and in Volume Rendering module.
      Note: Options to specify GPU memory as a percentage of the total memory have been added, but getting the GPU memory does not work. I asked for advice in this thread
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27242 3bd1e089-480b-0410-8dfb-8563597acbee
    • cpinter's avatar
      ENH: Add volume rendering options to Application Settings · 07ea3617
      cpinter authored
      In addition to the current rendering method and GPU memory size options, the following were added:
      - Default quality
      - Default interactive speed
      - Default surface smoothing
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27241 3bd1e089-480b-0410-8dfb-8563597acbee
    • cpinter's avatar
      ENH: Move volume rendering properties from display node to 3D view node · e565732e
      cpinter authored
      - Move properties from vol.ren. display node to view node: RaycastTechnique, ExpectedFPS, GPUMemorySize, EstimatedSampleDistance (renamed to VolumeRenderingOversamplingFactor, as the former name was misleading as it does not specify sample distance but an oversampling factor), PerformanceControl (renamed to VolumeRenderingQuality, as it is not directly related to performance, and even the enum was called Quality), SurfaceSmoothing (renamed to VolumeRenderingSurfaceSmoothing).
        1. Setting these options differently for volumes is not useful, however setting some of them per view could be useful
        2. The new multi volume rendering method has only one common mapper, and some properties cannot be set per volume
        3. It would be nice to expose these properties in Application Settings, to be able to define application defaults. For this, the view node is a better place
      Important note: this commit breaks backwards compatibility in terms of loading a scene containing special volume rendering settings, so those settings will not be loaded correctly. However Slicer 4.10 and soon after Slicer 5 is coming up, so this might be a good time to make this step.
      - Move GetSampleDistance function from displayable manager to vtkMRMLVolumeRenderingDisplayNode
      - Fix bugs related to multi-volume rendering
      - Fix vtkSlicerVolumeRenderingLogicTest and fix todo in vtkMRMLVolumeRenderingDisplayable by adding utility functions in the displayable manager
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27240 3bd1e089-480b-0410-8dfb-8563597acbee
    • cpinter's avatar
      STYLE: Fix indents and improve docstrings · 53f754bc
      cpinter authored
      Style related changes in view node and slice node classes to keep
      formatting consistent
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27239 3bd1e089-480b-0410-8dfb-8563597acbee
    • cpinter's avatar
      ENH: Add real MultiVolume volume rendering option · a192028f
      cpinter authored
      Add vtkMultiVolume driven volume rendering method as third option.
      Two blocking issues with vtkMultiVolume make it unusable in Slicer as is. Workarounds have been applied:
      1. vtk/vtk#17325: Added dummy single-voxel all-transparent volume so that all user transforms are correctly handled
      2. vtk/vtk#17302: Volume connections removed from actor and mapper so that it is actually hidden from the view when visibility checkbox is turned off
      git-svn-id: http://svn.slicer.org/Slicer4/trunk@27238 3bd1e089-480b-0410-8dfb-8563597acbee
  29. 14 May, 2018 1 commit
  30. 09 May, 2018 1 commit