Skip to content
Snippets Groups Projects
  1. May 04, 2017
    • Sean McBride's avatar
      Change bitwise to logical OR · 01ad8d5d
      Sean McBride authored
      Semantically, logical OR is what is desired here.
      I suspect the use of bitwise was a performance hack for old hardware.
      Logical OR can short circuit, giving the compiler an optimisation opportunity.
      01ad8d5d
  2. Apr 27, 2017
  3. Apr 02, 2017
    • David Gobbi's avatar
      Remove special characters from VTK source files. · 03647e64
      David Gobbi authored
      The source was searched with "grep -l [^ -~]" to find characters outside
      of the printable ASCII range 0x20 to 0x7e.  The worst offender is the
      en-dash character, which is visually indistinguishable from the minus
      character in most code editors.  Several tabs were also found, which
      is surprising since they should be blocked by the commit hooks.
      03647e64
  4. Mar 17, 2017
  5. Mar 14, 2017
  6. Feb 02, 2017
    • David Gobbi's avatar
      In vtkImageResliceToColors, call Build() on table · 198fd938
      David Gobbi authored
      This ensures that the table is up-to-date before it is applied to
      the image.  Note that is change is needed for the correct behavior
      of vtkImageResliceMapper.  Also note that the vtkImageMapToColors
      class correctly calls Build() on the table.
      198fd938
  7. Jan 22, 2017
    • Sean McBride's avatar
      const improvements to APIs and internal usage · 8b32854b
      Sean McBride authored
      - Made a few APIs' params const
      - Changed many usages of the evil GetBounds() to expect a const
        return value, even though it does not (yet?) return const
      - Slightly changed return values of vtkTextActor3D::GetBounds()
        to return its own ivar instead of its ImageActor's
      8b32854b
  8. Jan 20, 2017
    • David Gobbi's avatar
      Remove duplicate "OutputSpacing" member. · 03272ddd
      David Gobbi authored
      The class vtkImageResample declared a member called OutputSpacing, even
      though that member was already present in the superclass vtkImageReslice.
      In order to ensure that the SetOutputSpacing() method (in vtkImageReslice)
      can be used with vtkImageResample, it is necessary that vtkImageResample
      does not redeclare this member.
      
      Note that vtkImageResample uses a spacing of [0,0,0] as a signal that the
      spacing is "undefined", whereas vtkImageReslice does not (it uses a default
      spacing of [1,1,1] and a flag called ComputeOutputSpacing to indicate
      whether the filter should use these values or compute new ones).  This
      doesn't cause a bug since the OutputSpacing member only used in
      RequestInformation, and each class has its own RequestInformation
      implementation.
      03272ddd
  9. Jan 19, 2017
  10. Jan 16, 2017
  11. Jan 12, 2017
  12. Jan 05, 2017
  13. Dec 02, 2016
  14. Oct 29, 2016
  15. Oct 21, 2016
  16. Oct 07, 2016
  17. Oct 04, 2016
  18. Sep 26, 2016
  19. Sep 23, 2016
    • Kitware Robot's avatar
      Reindent using the reindentation script. · f830ff47
      Kitware Robot authored and David Gobbi's avatar David Gobbi committed
      This commit reindents the code with the following utility:
      Utilities/Maintenance/vtk-reindent-code.py
      
      This utility changes the positions of the braces so that they are no
      longer indented relative to the code block they reside in.
      
      The bash command line used was the following:
      
      for d in Charts Common Deprecated Domains Examples Filters GUISupport \
               Geovis IO Imaging Infovis Interaction Parallel Rendering \
               Testing Views Web Wrapping; do
        for e in cxx cxx.in txx txx.in hxx hxx.in h h.in c c.in; do
          find "${d}" -name "*.${e}" -exec \
            python Utilities/Maintenance/vtk_reindent_code.py {} +
        done
      done
      f830ff47
    • David DeMarle's avatar
      replace VTK's nonstandard Doxygen with standard markup · 6a7e5148
      David DeMarle authored
      generated via:
      cd $VTKSRC
      perl Utilities/Doxygen/doc_header2doxygen.pl --to ~/tmp/vtkheaders .
      cp -r ~/tmp/vtkheaders/* .
      6a7e5148
  20. Sep 16, 2016
  21. Sep 15, 2016
  22. Sep 14, 2016
    • David Gobbi's avatar
      Add vtkImageConnectivityFilter · 60d9d023
      David Gobbi authored
      This is the vtkImageData equivalent of vtkPolyDataConnectivityFilter.
      It performs connectivity checks on points with values within a specific
      scalar range (by default, it checks all points with values > 0).  Its
      output is a label image, where each connected region is assigned an
      integer label value.  Unlabeled points are assigned a value of zero.
      60d9d023
  23. Sep 12, 2016
    • Haocheng LIU's avatar
      Rewrite all public&private dependency in module.cmake file · 6e113ad4
      Haocheng LIU authored
      The current dependency relationship in vtk is unclear and misleading.
      This MR tries to rewrite them based on header files inclusion of headers
      and source files in each module. Corner cases are considered and
      modules are sorted in alphabetical order to facilitate future reference.
      See details in my gitlab python based script project. In future we can continue
      using this script to clean the VTK Dependency easily from
      time to time.
      6e113ad4
  24. Sep 07, 2016
    • David Gobbi's avatar
      16842: Fix reslice SplitMode, Stencil incompatibility · 8823c552
      David Gobbi authored
      This commit fixes #16842 for vtkImageReslice.  If GenerateStencilOutput
      is On, then stencil->InsertNextExtent() is called when vtkImageReslice's
      execute method completes a row, but if a row has been split among more
      than one piece, the stencil will be corrupted.  It's only when SplitMode
      is "Block" that this is likely to occur.  The fix used here is to detect
      when rows might be split, and to adjust the split mode so that it won't
      occur if GenerateStencilOutput is On.
      8823c552
  25. Sep 02, 2016
    • David Gobbi's avatar
      Simplify extern template declaration · ff7ce07d
      David Gobbi authored
      For C++11 (and for some pre-C++11 compilers via extensions) a template
      instantiation can be declared "extern" so that the compiler will avoid
      generating more than one copy of the code for that template.
      
      This commit is an attempt to simplify the use of extern template in VTK.
      ff7ce07d
  26. Aug 19, 2016
    • Bill Lorensen's avatar
      ENH: Introduce vtkMTimeType · 9333d9d1
      Bill Lorensen authored
      This is a fix for:
      #14310
      
      Windows applications that run for a long time report that rendered
      objects do not change. This is because the modified time on a Windows
      system is 32 bits. This causes overflows that defeat the modified time
      mechanism. This patch defines a new type, vtkMTimeType that is 64
      unsigned integer regardless of the architecture.
      
      A mechanism to provide backward compatibility is introduced. The
      preprocessor define "VTK_HAS_MTIME_TYPE" can be used in applications
      that must build against VTK versions that use the "unsigned long" type
      for MTime's.
      
      Methodology used to find MTime occurences:
      1) Identify files as follows:
         git grep "unsigned long" | grep ime | cut -d":" -f1,1 | sort | uniq
      2) Hand edit each of those files replacing "unsigned long" with
         "vtkMTimeType" where appropriate.
      3) Temporarily change typedef for vtkMTimeType to "double" to detect
         missing conversions
      9333d9d1
  27. Aug 03, 2016
  28. Jul 28, 2016
    • Seun Odutola's avatar
      slight perfomance improvement to vtkImageBlend · 5da6e11a
      Seun Odutola authored
      Added special case for RGB to RGB and RGBA to RGBA,
      where the loops are rewritten, transforming pointer arithmetic to indexing in order
      to allow auto-vectorization by clang.
      For the RGBA to RGBA case there was a noticeable gain of 3.2% in performance.
      5da6e11a
  29. Jul 26, 2016
  30. Jul 18, 2016
  31. Jul 16, 2016
    • David Gobbi's avatar
      Optimize the reslice nearest neighbor interpolation · 4cc6d511
      David Gobbi authored
      Use the efficient "setpixels" method for setting out-of-bounds regions
      to the background color.  Also, use a switch() to unroll the inner loop
      for common pixels sizes, this provides a performance boost of a few %.
      4cc6d511
  32. Jul 15, 2016
  33. Jul 13, 2016
    • Sean McBride's avatar
      Used clang-tidy's "modernize-use-override" to add some C++11 overrides · 753dcec5
      Sean McBride authored
      It doesn't seem to have got everything, but it's a start.
      
      Some resulting whitespace is suboptimal, but one day
      we can fix that with clang-format. :)
      
      Just ran this command:
      run-clang-tidy.py -checks=-*,modernize-use-override -fix
      
      (I actually had to build my own clang to make clang-tidy
      output "VTK_OVERRIDE" instead of "override".)
      753dcec5
Loading