1. 01 Aug, 2013 1 commit
    • Sean McBride's avatar
      Conservative elimination of !null checks before 'delete' · 8812203b
      Sean McBride authored
      C++ guarantees that delete 0 and delete [] 0 do nothing.
      Older buggy compilers that didn't honour this are no longer
      supported by VTK.  Conservatively removed many "if (!ptr)"
      checks before using delete in /Common.
      
      Change-Id: I451f353ba57487432904487d61107cf7bb818b8e
      8812203b
  2. 31 Jul, 2013 1 commit
    • Sean McBride's avatar
      Removed a bunch of empty destructors · 9e42e0e1
      Sean McBride authored
      Their declaration violates the 'rule of 3' and was
      causing compiler warnings with clang's -Wdeprecated
      in C++11.
      
      Change-Id: I959d582deea4ceccc69684be32dccd3521f54807
      9e42e0e1
  3. 30 Jul, 2013 1 commit
  4. 26 Jul, 2013 1 commit
  5. 25 Jul, 2013 3 commits
    • Utkarsh Ayachit's avatar
      Cleanup logic for indexed colors. · 16543376
      Utkarsh Ayachit authored
      vtkDiscretizableColorTransferFunction used control points to map indexed colors.
      To make applications simpler, added a new API to add indexed colors which are
      used when present when in IndexedLookup mode. If no IndexedColors are specified,
      the vtkDiscretizableColorTransferFunction reverts to the previous behaviour for
      backwards compatibility.
      
      Change-Id: If5b6791baccf2ee0022fd1b1098093d226ef64c3
      16543376
    • Utkarsh Ayachit's avatar
      Release graphics resources properly. · 37a10c60
      Utkarsh Ayachit authored
      vtkScalarBarActor wasn't releasing graphics resources for internal texture. This
      fixes the problem.
      
      Change-Id: I5f01c7d8ad0f78c25b4ab8f21bc8b4e66ae91c5f
      37a10c60
    • Utkarsh Ayachit's avatar
      Cleaning up transfer function widgets. · 1509669d
      Utkarsh Ayachit authored
      Cleaning up issues with the context-items related to tranfer function editor.
      
      + Added support for log-mapped color-transfer function. We ensure that when
        using log-scale, the color transfer function widget also enter log-space.
      
      + vtkPiecewiseControlPointsItem had a bug resulting it deleting of end points
        even when told otherwise. Fixed that.
      
      + Added new event vtkControlPointsItem::PointsModifiedEvent which if fired when
        control points are changed making it easier for application to do something
        when the points are changed.
      
      + Improved the usability by adding ability to label control points.
      
      Change-Id: If02bc1139f6ccb3d7c2198b07d10491f902bafda
      1509669d
  6. 24 Jul, 2013 2 commits
    • Burlen Loring's avatar
      Make "graphic error" api legacy · c544585c
      Burlen Loring authored
      Decorated vtkRenderWindow "graphic error" methods with legacy.
      These were superceded by vtkOpenGL{Check/Clear}ErrorMacro's.
      
      Change-Id: I2b3fbbbb1125b7611d4553e6ea1640b3f74121f6
      c544585c
    • Burlen Loring's avatar
      OpenGL driver version detection and OS Mesa features · 4d5cbfb6
      Burlen Loring authored
      Added support to vtkOpenGLExtensionManager for fine grained
      OpenGL driver version detection. Added a flag to enable/disable
      features with known driver specific bugs for testing new
      driver releases. This mostly to test future Mesa releases to
      determine if bugs have been fixed. Used the new feature to
      see if some long standing Mesa bugs have been fixed in newer
      Mesa releases for the OS Mesa renderer.
      
      * NPOT texture support used by vtkOpenGLContextDevice2D and
      vtkOpenGL2ContextDevice2D fixed in Mesa >= 8
      
      * reset glReadBuffer to quiet incomplete FBO error report in
      vtkOpenGLVolumeGPURayCastMapper
      
      * vtkOpenGLVolumeGPURayCastMapper tests pass in Mesa >= 9
      except TestGPURayCastCompositeShadeMask. Explicitly disabled
      the test for OS Mesa.
      
      * disable FBO for Mesa < 8 because of TestBlurAndSobelPasses
      TestSobelGradientMagnitudePass test failures
      
      * disable vtkOpenGLHAVSVolumeMapper for OS Mesa without
      Gallium llvmpipe renderer
      
      * vtkCompositeRGBAPass needs GL_ARB_texture_float. Mesa
      may or may not be built with it enabled due to patent
      restrictions and a bug in 8-9 releases.
      
      * Disable FBO for Mesa drivers reporting OpenGL version 1.4
      because of incomplete/buggy GL_ARB_draw_buffers.
      
      * Although associated ctests run and pass, disable
      vtkOpenGLVolumeTextureMapper3D for OS Mesa < 9 because of
      false OpenGL invalid enum report.
      
      Change-Id: Ic82aeb4747137aead53251026744baa61ced66d0
      4d5cbfb6
  7. 23 Jul, 2013 1 commit
    • Utkarsh Ayachit's avatar
      Fixed regression introduced by a6fa3e37. · f7f82536
      Utkarsh Ayachit authored
      a6fa3e37 changed the logic in vtkWin32OpenGLRenderWindow::CleanUpRenderers().
      That method was used when swithcing from offscreen to onscreen. That resulted in
      the renderers not having correct references to render window after switching
      from offscreen to onscreen context causing dashboard failures on ParaView
      dashboards. This fixes that issue.
      
      Since the a6fa3e37 changed the logic in CreateOffScreenDC() by not using
      CleanUpRenderers() to reset renderers, it makes sence to change the logic in
      ResumeScreenRendering() to not use CleanUpRenderers() for resetting renderers as
      well.
      
      Change-Id: I32e58854fa8720c99212cee5d7a2652f11dc9b21
      f7f82536
  8. 19 Jul, 2013 1 commit
    • Sean McBride's avatar
      Fixed typo in include guard define · fe579828
      Sean McBride authored
      Found by a cool new warning in clang:
      
      VTK/Rendering/FreeType/vtkMathTextUtilities.h:21:9: warning: '__vtkMathTextUtilities_h' is used as a header guard here, followed by #define of a different macro [-Wheader-guard]
      
              ^~~~~~~~~~~~~~~~~~~~~~~~
      VTK/Rendering/FreeType/vtkMathTextUtilities.h:22:9: note: '__vtkMathTypeUtilities_h' is defined here; did you mean '__vtkMathTextUtilities_h'?
      
              ^~~~~~~~~~~~~~~~~~~~~~~~
              __vtkMathTextUtilities_h
      
      Change-Id: I0ed048fcdfa69f6c47308987c8901eb0e56459a1
      fe579828
  9. 17 Jul, 2013 1 commit
  10. 16 Jul, 2013 1 commit
    • Utkarsh Ayachit's avatar
      Increasing timeout for test. · 4b20f9b1
      Utkarsh Ayachit authored
      With additional OpenGL checks, vtkRenderingOpenGLCxx-TestTextureSize  now takes
      longer than 90s on certain machines (dash3). Increasing the timeout to 300s
      which is typical for dashboards.
      
      Change-Id: Iac4f5ff3f9eb22d3af1caf7507a162c7fa6cce05
      4b20f9b1
  11. 12 Jul, 2013 1 commit
    • Burlen Loring's avatar
      OpenGL error hunt -- dashboard cleanup · 6455c581
      Burlen Loring authored
      Use static version of vtkOpenGLCheckErrorMacro in helper class
      that's not a vtkObject in vtkPistonMapper. Don't check for OpenGL
      errors in vtkGL2PSExporter::Write it doesn't use OpenGL directly.
      Fix warning about narrowing cast. Use vtkOpenGLCheckErrorMacro
      before return in vtkOpenGLImageSliceMapper::TextureSizeOK.
      
      Change-Id: Ia05575d571c230b68b2035e8a866f0ec7519d887
      6455c581
  12. 11 Jul, 2013 1 commit
    • Burlen Loring's avatar
      OpenGL error hunt -- dashboard cleanup · 0994d6ca
      Burlen Loring authored
      Test for context in vtkFrameBufferObject when Get'ing
      FBO attributes. This prevents driver segfault in
      TestSetGet.tcl on Apple.
      
      Change-Id: If093750770a5a55ac3cd69eaa0a7d8115e2d3771
      0994d6ca
  13. 08 Jul, 2013 1 commit
    • Burlen Loring's avatar
      OpenGL error hunt · a6fa3e37
      Burlen Loring authored
      This patch implements OpenGL error checking in VTK.
      
      OpenGL's error handling implementation error is designed such
      that internal error flags remain set with the first error that
      occurred until they are explicitly checked. With this design
      it's important to check and clear the error flags regularly
      else they become unusable as code checking for errors ends
      up reporting earlier undetected unrelated errors.
      
      This patch takes the following approach:
      
      1) at public entry points into code that uses OpenGL clear the
      error flags without reporting errors. This guards against
      reportinig unrealted errors, such as those caused by code
      outside of VTK. See vtkOpenGLClearErrorMacro
      
      2) before returning from functions that made OpenGL calls check
      for and report OpenGL errors. This detects Open GL errors in the
      function/method where they occurred facilitating debugging and it
      clears error flags so that user code doesn't detect errors caused
      by VTK. See vtkOpenGLCheckErrorMacro
      
      This patch cleans up a number of bugs that were detected by
      the new error checking and reporting.
      
      This patch also contains improvements for OpenGL pixel buffers, a
      renderbuffer object, and fast paths through framebuffer objects,
      and texture objects, and fast path for setting uniform variables,
      all of which are needed in vtkSurfaceLICPainter and
      vtkLineIntegralConvolution2D GPGPU code.
      
      Change-Id: I4ecefe9a444a74128bf73ef2ddfd5d4acea387ec
      a6fa3e37
  14. 05 Jul, 2013 1 commit
  15. 01 Jul, 2013 1 commit
  16. 28 Jun, 2013 5 commits
  17. 27 Jun, 2013 1 commit
  18. 25 Jun, 2013 1 commit
  19. 18 Jun, 2013 1 commit
    • David C. Lonie's avatar
      Move scalar bar GL2PS special case handler from PV to VTK. · 9f33a74f
      David C. Lonie authored
      This patch moves the special handler code for scalar bars from paraview
      into VTK. The code was originally in PV as the PVScalarBar differed
      significantly from vtkScalarBar, but now that they share more of their
      implementations VTK can handle the export.
      
      Change-Id: Icf37d51f46ba2569db86da1125c5c0c4f247747f
      9f33a74f
  20. 11 Jun, 2013 1 commit
  21. 07 Jun, 2013 1 commit
  22. 04 Jun, 2013 2 commits
    • Brad King's avatar
      Convert VTKData test inputs to ExternalData content links · 3797f83d
      Brad King authored
      Add to the Testing/Data directory ExternalData content links mirroring
      the content and layout we use from the VTKData/Data directory.
      
      Add a CMake/vtkLegacyData.cmake module, included from CMakeLists.txt and
      Testing/External/CMakeLists.txt, to call ExternalData_Expand_Arguments
      for all data directories added from VTKData/Data.  This will bulk-fetch
      all test input data currently used by tests of any module, enabled or
      not.  We can make the DATA{} references more granular later.
      
      Add a VTK_TEST_DATA_DIR variable to refer to the directory we tell the
      ExternalData module to populate the real data files.  Replace references
      to VTK_DATA_ROOT in test command lines (after -D) with references to
      VTK_TEST_DATA_DIR.  Drop the VTK_DATA_ROOT CMake option and stop using
      the VTKData repository.
      
      Remove the TESTING_DATA option from the vtk_add_test_cxx API and remove
      the VTK_DATA_ROOT option from the vtk_add_test_mpi API since all test
      input data are now handled through ExternalData and Testing/Data content
      links.
      
      Change-Id: Id02490b76ea2e161b9038188264a4830485039d8
      3797f83d
    • David Thompson's avatar
      Use the font scaling provided by vtkTextActor. · 47b6fa6e
      David Thompson authored
      This will increase the size of fonts used on displays
      with high pixel densities.
      
      Also, this changes the signature of vtkTextActor::GetBoundingBox()
      to take a vtkViewport. Since this is a new method for VTK6, it is
      better to fix it now; having it pass a NULL viewport pointer
      internally was causing crashes.
      
      Finally, vtkTextActor::SetConstrainedFontSize() should take font
      scaling into account.
      
      Change-Id: I3cc99f99798da96f5c8e9249538ba269216e302a
      47b6fa6e
  23. 31 May, 2013 1 commit
  24. 28 May, 2013 2 commits
    • David Thompson's avatar
      Update the scalar bar build time. · 155b7f30
      David Thompson authored
      The BuildTime member is not being updated when the
      scalar bar layout is recalculated, causing layouts
      to be recomputed every time the bar is rendered.
      
      Change-Id: Ib5f8e69573383d2c7cf04ca9cfb18b70fbc40dcb
      155b7f30
    • David Thompson's avatar
      Update the scalar bar build time. · 118aa20a
      David Thompson authored
      The BuildTime member is not being updated when the
      scalar bar layout is recalculated, causing layouts
      to be recomputed every time the bar is rendered.
      
      Change-Id: I79615dfee885cf13b64370bd53dd6bc9485980cd
      118aa20a
  25. 27 May, 2013 1 commit
    • Jean-Christophe Fillion-Robin's avatar
      COMP 12945: Allow VTK to build against Qt5 · 384636ec
      Jean-Christophe Fillion-Robin authored
      Since VTK build system has been updated to make use of CMake macros
      specific to Qt5, the support has to explicitly enabled configuring VTK
      with -DVTK_QT_VERSION:STRING="5"
      
      Additionally, in case Qt5 is not installed in a standard location,
      a custom prefix for "find_package" should be passed.
      For example:
        -DCMAKE_PREFIX_PATH:STRING=/home/jchris/Qt5.0.2/5.0.2/gcc_64/
      
      
      Finally, this commit also resolves the build errors reported below.
      
      Fix missing header build error by including Qt headers directly without
      specifying the intermediate directory.
      
      * Fix build error changing QString::toAscii into  QString::toLatin
      The method "toAscii" has been deprecated and is not available in
      default Qt5 distribution.
      See http://qt-project.org/doc/qt-5.0/qtcore/qstring.html#toAscii
      
      * Fix build error changing Qt::WFlags into Qt::WindowFlags
      See http://qt-project.org/doc/qt-5.0/qtcore/qt-obsolete.html
      
      * Fix build error changing QAbstractItemModel::reset() into
      combo QAbstractItemModel::beginResetModel()/QAbstractItemModel::endResetModel()
      The method "reset" has been deprecated and is not available in
      default Qt5 distribution.
      See http://qt-project.org/doc/qt-5.0/qtcore/qabstractitemmodel-compat.html#reset
      
      * Fix build error by including "vtkObjectBase.h":
      /home/jchris/Projects/Qt5.0.2/5.0.2/gcc_64/include/QtCore/qmetatype.h:464: error: invalid application of ‘sizeof’ to incomplete type ‘QStaticAssertFailure<false>’
      
      * Fix "no matching function for call to ‘QPixmap::grabWidget(QWidget*)’" by using
      "QWidget::grab"
      See http://qt-project.org/doc/qt-5.0/qtwidgets/qwidget.html#grab
      
      * Fix missing QHttpHeader/QHttpRequestHeader headers by removing them.
      They have been removed from Qt5 and were not used in the code.
      
      * Fix error: ‘qInstallMsgHandler’ was not declared in this scope
      by using "qInstallMessageHandler"
      See http://qt-project.org/doc/qt-5.0/qtdoc/sourcebreaks.html
      
      * Fix Q4VTKWidgetPlugin.cxx:147: error: invalid application of
      ‘sizeof’ to incomplete type ‘QStaticAssertFailure<false>’ by
      using "Q_PLUGIN_METADATA" macro instead of Q_EXPORT_PLUGIN
      or Q_EXPORT_PLUGIN2.
      See http://qt-project.org/wiki/Transition_from_Qt_4.x_to_Qt5#7ec1b8f08d7f31ebcb53188f0bd15ed5
      
      Change-Id: Ie7123e5990e3a8afb4d7d2efa0fda5bd7b98c1e3
      384636ec
  26. 23 May, 2013 3 commits
    • Brad King's avatar
      Search for Ghostscript only when needed · fb82c67a
      Brad King authored
      Move the search for the Ghostscript executable added by commit 870dd114
      (Add new GL2PS testing system using ghostscript, 2012-10-01) into a
      dedicated vtkGhostscript module.  Include it from CMakeLists.txt that
      need VTK_GHOSTSCRIPT_EXECUTABLE.  This avoids keeping module-specific
      code in the top-level CMakeLists.txt file and enables the corresponding
      tests in the Testing/External build.
      
      Change-Id: I410737f16c653aaaa60799ce1471cb1798707079
      fb82c67a
    • Brad King's avatar
      Remove references to old VTKData/Baseline directories · fc5d874c
      Brad King authored
      The VTKData repository no longer holds Baseline directories so drop
      references to such directories from the VTK source tree:
      
      * Replace the default -V in CMake/vtkTestingRenderingDriver.cmake with a
        value that will fail but indicate what to do.  All current uses of
        this module have an explicit -V so the default should never be used.
      
      * Drop a few leftover Baseline directory references from comments in
        "*/*/Testing/*/CMakeLists.txt".
      
      * Remove boilerplate duplicate test command-line examples (that
        reference Baseline directories) from *.py tests and leave an updated
        example in "Wrapping/Python/README.txt".  The command-line example
        convention was added long before the modern CTest infrastructure
        and is no longer needed anyway.
      
      Change-Id: I3001e99b3cc8c2717107e61b3b7f988caeb49cab
      fc5d874c
    • Brad King's avatar
      Use vtk_test_cxx_executable in Rendering/GL2PS/Testing/Cxx · 57569cc9
      Brad King authored
      Replace the last use of vtkTestingObjectFactory.cmake and remove it.
      CMake modules that have immediate inline effects are hard to follow, so
      drop this one.
      
      Change-Id: I813644b0c31c1eecd3415f11e57e703d035940fd
      57569cc9
  27. 21 May, 2013 1 commit
  28. 20 May, 2013 1 commit
    • Andrew Maclean's avatar
      Make some color methods consistent. · 293e5386
      Andrew Maclean authored
      In order to use functions like SetTableValue(2, "Blue") in a lookup table
        or other SetColors in derived classes in the same manner,
        these methods should be virtual.
      This commit just makes the relevant Set methods virtual.
      In the case of vtkProperty, the definition of SetColor(double a[3]) has
        been moved into vtkProperty.cxx, the rationale is that, in VTK classes,
        definitions occur in the implementation file not the header file.
      
      Change-Id: I89fee8eb4902e0847114b068374c3bff0bf10b9d
      293e5386
  29. 17 May, 2013 1 commit