Commit Graph

655 Commits

Author SHA1 Message Date
Kenneth Moreland
eb9288cb1a Change vtkm::rendering::Window to View
The rendering classes do not actually manage windows, and window was not
descriptive of what this class was doing. We decided that the class was
mostly analogous to what we call a "view" in ParaView.
2016-06-02 15:43:40 -06:00
Kenneth Moreland
9fc86890eb Change vtkm::rendering::SceneRenderer* to Mapper*
This name was chosen to reflect the analogous name in VTK.
2016-06-02 13:41:14 -06:00
Kenneth Moreland
1934049df9 Change vtkm::rendering::View to Camera 2016-06-02 13:04:01 -06:00
Kenneth Moreland
a8169fbf61 Make sure all source files are declared in the examples
For header files, this only adds the file to IDE file lists, which is
convenient but not critical. However, the test did find a ligit error in
the hello_world example where the TBB build was actually using the
serial device adapter.
2016-06-02 10:24:21 -06:00
Jeremy Meredith
6c8045bdc3 unifying 2d and 3d scenes 2016-06-01 13:51:37 -04:00
Kenneth Moreland
507222c489 Change rendering classes to use Range and Bounds
In addition to this being necessary to be compatible with recent
changes, it makes for cleaner declaration of these values.
2016-05-29 18:49:37 -06:00
Kenneth Moreland
32efc36c1c Update Rendering example to latest rendering module changes 2016-05-25 15:34:57 -06:00
Dave Pugmire
dc31494b59 Merge branch 'master' into annot5 2016-05-20 10:04:37 -04:00
Dave Pugmire
389a4ca2f6 remove unused file. 2016-05-18 10:48:07 -04:00
Dave Pugmire
5f9403b881 Add trackball rotation, translate and zoom ot examples/rendering, and to the view classes. 2016-05-18 10:32:02 -04:00
Jeremy Meredith
9e53753c98 Merge branch 'master' into annot2 2016-05-16 16:54:45 -04:00
Jeremy Meredith
d560cf1d85 Merge branch 'master' into cellsetdim 2016-05-13 14:53:08 -04:00
Jeremy Meredith
514d32107a Merge branch 'master' into annot2 2016-05-13 14:39:04 -04:00
Jeremy Meredith
0c18278028 removing cell set dimensionality and splitting tetrahedralizer. 2016-05-13 14:26:59 -04:00
Kenneth Moreland
b446abba37 Update examples to filter interface changes. 2016-05-06 15:03:50 -06:00
Dave Pugmire
72673ed952 Add glut-based rendering example.
Added a GL-based render surface.
2016-05-05 13:26:39 -04:00
Robert Maynard
1ec3bc0e7a Rename the opengl folder / namespace to interop.
To clarify what functionality the classes inside provide.
2016-04-13 15:52:15 -04:00
Robert Maynard
4269e0070c Only build the rendering example if MESA has been found. 2016-04-07 20:07:22 -04:00
Robert Maynard
1edc465055 Add a demo for GTC2016 that covers io/filters/rendering. 2016-04-01 15:50:52 -04:00
Jeremy Meredith
5a0923c136 final (hopefully) references to Field::order removed. 2016-03-23 13:06:08 -04:00
Jeremy Meredith
d0c490dccb found more uses of field::order to remove. 2016-03-23 12:57:05 -04:00
Jeremy Meredith
0b0b3a6338 fixing another mention of field::order 2016-03-23 11:14:55 -04:00
Kenneth Moreland
f81e8c642f Fix example that was using the old interface to VTKDataSetWriter
As a bonus, fix a compiler warning about an unused typedef.
2016-03-17 09:13:25 -06:00
Robert Maynard
8e4a47ef57 Update IsosurfaceUniformGrid to use the marching cubes filter.
This way we have an example of how to use the filter code.
2016-03-14 08:39:17 -04:00
Robert Maynard
ad4f6c6485 All examples now use the proper CMake CUDA found variable. 2016-02-22 11:25:15 -05:00
Robert Maynard
ee368d0d68 Do not add c++ compiler optimizations to all compilers, but on a target basis.
As reported in Issue #54 the add_compile_options pollutes the global compile
flags. Instead we provided cmake flags for people to use.
2016-01-25 14:38:06 -05:00
Kenneth Moreland
ed43dad6ca Simplify and unify cast interface.
Previously, DynamicArrayHandle and DynamicCellSet had slightly different
interfaces to their CastTo feature. It was a bit confusing and not all
that easy to use.

This change simplifies and unifies them by making each class have a single
CopyTo method that takes a reference to a cast object (an ArrayHandle or
CellSet, respectively) and fills that object with the data contained if
the cast is successfull. This interface gets around having to declare
strange types.

Each object also has a Cast method that has to have a template parameter
specified and returns a reference of that type (if possible).

In addition, the old behavior is preserved for DynamicArrayHandle (but
not DynamicCellSet). To avoid confusion, the name of that cast method is
CastToTypeStorage. However, the method was chaned to not take parameters
to make it consistent with the other Cast method.

Also, the IsType methods have been modified to reflect changes in
cast/copy. IsType now no longer takes arguments. However, an alternate
IsSameType does the same thing but does take an argument.
2016-01-18 15:58:04 -07:00
Robert Maynard
4bb3cce016 Use the DataSetBuilderExplicitIterative helper where it is useful. 2016-01-18 16:19:48 -05:00
Robert Maynard
e7456fa120 Update vtkm tests and examples to use DataSetBuilders. 2016-01-15 15:44:56 -05:00
Robert Maynard
f5f9939f26 Update all of vtkm to understand it can only identify as one compiler. 2016-01-12 11:05:40 -05:00
Robert Maynard
c70da5fc23 Extend vtkm::DeviceAdapterTraits to include a unique numeric identifier.
Previously each device adapter only had a unique string name. This was
not the best when it came to developing data structures to track the status
of a given device at runtime.

This adds in a unique numeric identifier to each device adapter. This will
allow classes to easily create bitmasks / lookup tables for the validity of
devices.
2015-12-16 11:18:52 -05:00
Robert Maynard
a7127f0fc3 Adding vtkm::cont::RuntimeDeviceInformation.
The RuntimeDeviceInformation class allows developers to check if a given
device is supported on a machine at runtime. This allows developers to properly
check for CUDA support before running any worklets.
2015-12-15 17:25:27 -05:00
Robert Maynard
7d249e8996 Move DeviceAdapterTraits into vtkm::cont as they are user API.
When writing multiple backend code users of vtkm need to use the
DeviceAdapterTraits classes, so therefore we should move them to vtkm::cont
to signify this.
2015-12-11 09:52:18 -05:00
T.J. Corona
e14dba7ed4 Use vtkm::Float32 with OpenGL, not vtkm::FloatDefault.
When vtkm is built with VTKm_USE_DOUBLE_PRECISION, the IsosurfaceUniformGrid
example would not compile. Now it does.
2015-12-03 15:02:41 -05:00
T.J. Corona
baa73eaad8 Merge topic 'marching-cubes'
33b0d1bf Move marching cubes edge table out of the worklet.
a5ae4127 Remove IsosurfaceUniformGrid.
35355382 Generalize IsosurfaceUniformGrid to Accept explicit cell sets.

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <kmorel@sandia.gov>
Merge-request: !272
2015-12-03 14:54:02 -05:00
T.J. Corona
a5ae4127e0 Remove IsosurfaceUniformGrid. 2015-12-02 15:11:56 -05:00
Kenneth Moreland
0d0294d4b2 Fix conversion warnings in streamline example.
vtkm::Id is a signed integer whereas size_t used by standard C++
functions is unsigned. It doesn't matter, but compilers like to complain
about it. Make any such conversions explicit.
2015-11-30 14:14:07 -07:00
Patricia Kroll Fasel - 090207
6c4fb856df Add example data file for streamline. 2015-11-23 17:00:22 -07:00
Patricia Kroll Fasel - 090207
3946b0c462 Add unit test, pass all args in Run() 2015-11-23 16:19:26 -07:00
Patricia Kroll Fasel - 090207
09e4377891 Merge branch 'master' of gitlab.kitware.com:Fasel/vtk-m into streamline 2015-11-23 12:56:27 -07:00
Patricia Kroll Fasel - 090207
02f84a1992 StreamLine filter outputs dataset. Add example. 2015-11-23 12:54:12 -07:00
Patricia Kroll Fasel - 090207
34cc971969 StreamLine particle tracing returns output dataset. 2015-11-23 12:50:13 -07:00
Kenneth Moreland
b5803a5f05 Merge branch 'improve-cmake-module' into 'master'
Improve CMake module

Some improvements to VTKmConfig.cmake and the device configuration scripts to better support CMake projects using VTK-m.

See merge request !271
2015-11-12 18:09:01 -05:00
Kenneth Moreland
fac5d79a52 Remove direct use of TBB_LIBRARIES and TBB_INCLUDE_DIRS
Instead, use VTKm_LIBRARIES and VTKm_INCLUDE_DIRS where the configuration
stores all necessary libraries and include directories.
2015-11-12 14:34:31 -07:00
Sujin Philip
70b2eff85e Update clipping example to use the new io framework 2015-11-12 10:29:30 -05:00
T.J. Corona
9414120b6a Replace ArrayHandleCastForInput with the more versatile ArrayHandleCast. 2015-11-11 17:13:04 -05:00
Kenneth Moreland
1a538ca196 Merge branch 'scatter-worklets' into 'master'
Scatter in worklets

Add the functionality to perform a scatter operation from input to output in a worklet invocation. This allows you to, for example, specify a variable amount of outputs generated for each input.

See merge request !221
2015-11-11 13:09:47 -05:00
Robert Maynard
88a605549e Merge topic 'more_efficient_opengl_interop'
4d270187 Update the opengl interop code to be significantly faster with cuda.

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !261
2015-11-11 09:40:07 -05:00
T.J. Corona
af32a21b2e Add support for bidirectional array transforms.
Array transforms can now be created with an inverse functor, allowing for
casts back into the native array type. As a result, array transforms with
both a functor and inverse functor defined can perform read and write
operations. As an example, ArrayHandleCast now supports this operation. The
original implementation of ArrayHandleCast (i.e. read only) has been renamed
'ArrayHandleCastForInput'.
2015-11-10 15:13:02 -05:00
Kenneth Moreland
58aa46df74 Fix spacing in Isosurface test code.
The original isosurface code was not treating the origin and spacing of
the point coordinates correctly. Instead, it was ignoring the origin and
spacing and instead scaling all point coordinates to be in the unit cube
in world space (except there was also an off-by-one error in that). This
change recompensates by adjusting the origin and spacing to make the
correct position where the geometry was previously errantly placed.
2015-11-06 18:05:20 -07:00
Robert Maynard
4d270187c7 Update the opengl interop code to be significantly faster with cuda.
Now that we hold the state information about the transferring of an array,
we can do a far more efficient transferring.
2015-11-05 13:50:35 -05:00
Sujin Philip
1b8fe17f1b Fix for several warnings 2015-11-03 09:11:38 -05:00
Sujin Philip
fd244c4142 Fix errors and warnings caused by recent changes to device adapter tag logic 2015-11-03 09:11:38 -05:00
Robert Maynard
160f0099e5 Merge topic 'cleanup_cmake_logic'
7a356b2c By default do not export all symbols in vtk-m.
91a09c8b Remove unneeded cmake code from the examples.
e24bdfb6 Bump the minimum cmake version to 2.8.11
05ea81d3 Teach vtk-m CMake about new policies from CMake 3.X.X

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !243
2015-10-22 12:19:04 -04:00
Robert Maynard
91a09c8ba2 Remove unneeded cmake code from the examples.
This is needed as it allows the policies specified in the root of
vtk-m to propagate properly to the examples. When CMake
sees a cmake_minimum_required command it resets all policy flags.
2015-10-21 10:27:21 -04:00
Kenneth Moreland
4f8f76f3f7 Fix line endings.
There were a couple of files checked into the git repository with DOS
line endings. Most git implementations really expect there to be Unix
line endings and should do the appropriate conversions as necessary.
This commit should change the line endings to the appropriate Unix endings.
2015-10-20 12:32:29 -06:00
Patricia Kroll Fasel - 090207
65c9de08bd Merge branch 'master' of gitlab.kitware.com:Fasel/vtk-m into tetra_explicit 2015-10-08 16:07:18 -06:00
Patricia Kroll Fasel - 090207
5f6a552a26 Compiler warnings 2015-10-08 12:12:49 -06:00
Patricia Kroll Fasel - 090207
c94dca791b Compiler warnings 2015-10-08 12:07:13 -06:00
Patricia Kroll Fasel - 090207
b74737125c Compiler warnings GL deprecated 2015-10-08 11:45:50 -06:00
Patricia Kroll Fasel - 090207
2b43e52516 Compiler warnings 2015-10-08 11:38:56 -06:00
Patricia Kroll Fasel - 090207
2f532bf379 Compiler warnings 2015-10-08 11:11:08 -06:00
Patricia Kroll Fasel - 090207
cba29a1e67 Fix compiler warnings 2015-10-08 10:52:34 -06:00
Patricia Kroll Fasel - 090207
0b9cffe4f4 Merge branch 'master' of gitlab.kitware.com:Fasel/vtk-m into tetra_explicit 2015-10-08 09:56:44 -06:00
Patricia Kroll Fasel - 090207
5569d8c1b1 Merge branch 'master' of gitlab.kitware.com:Fasel/vtk-m into tetra_uniform 2015-10-08 09:35:10 -06:00
Patricia Kroll Fasel - 090207
5a7b3668ee Correct for gcc and pgi compilers and CastTo. Add CellSetSingleType for output. 2015-09-29 11:20:05 -06:00
Kenneth Moreland
7404f4edda Wrap boost include.
Wrap VTKM_THIRDPARTY_PRE_INCLUDE and VTKM_THIRDPARTY_POST_INCLUDE around
a boost include. This suppresses some warnings.
2015-09-29 10:25:27 -04:00
Patricia Kroll Fasel - 090207
deceb79edc Fix to work with gcc and pgi compilers. Change to use CellSetSingleType. 2015-09-28 16:23:03 -06:00
Patricia Kroll Fasel - 090207
78239c5571 Minor corrections for Allocate of shapes, numindices. 2015-09-24 16:17:50 -06:00
Patricia Kroll Fasel - 090207
a821310b6f Changes in CellSetExplicit for shape and numindices types. Made one Run() method
by getting point dimensions from the dataset.
2015-09-24 16:07:45 -06:00
Patricia Kroll Fasel - 090207
3e4ca9ae8f Merge branch 'master' of gitlab.kitware.com:Fasel/vtk-m into tetra_uniform 2015-09-24 11:55:33 -06:00
Patricia Kroll Fasel - 090207
3e94b4295b Types for shapes and numindices changed in CellSetExplicit. 2015-09-24 11:52:38 -06:00
Patricia Kroll Fasel - 090207
c7234eedf7 Merge branch 'master' of gitlab.kitware.com:Fasel/vtk-m into tetra_explicit 2015-09-24 11:10:20 -06:00
Patricia Kroll Fasel - 090207
a7f7b46169 Add 3D tetrahedralize of explicit cell set. 2015-09-24 10:56:03 -06:00
Robert Maynard
45ad63c770 Merge topic 'update_cell_connectivity_types'
19cebccf Correct issues that buildbot brought up in the code.
c6dbc0f2 GetNumberOfPointsInCell consistently returns a vtkm::IdComponent
25ff1e94 CellSetExplicit storage tags are now easier to override.
935b3fd6 CellSetExplicit uses UInt8 for shape, and IdComponent for numIndices.

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !210
2015-09-24 11:23:54 -04:00
Patricia Kroll Fasel - 090207
4e92cd3f33 Tetrahedralize 2D explicit dataset first version with opengl example 2015-09-23 14:43:27 -06:00
Robert Maynard
c6dbc0f20e GetNumberOfPointsInCell consistently returns a vtkm::IdComponent 2015-09-23 15:47:41 -04:00
Robert Maynard
dda098e80f Suppress Deprecation warnings about glut in the examples. 2015-09-23 09:00:51 -04:00
Patricia Kroll Fasel - 090207
1c19a15f51 Triangulate a 2D data set extension 2015-09-22 11:40:01 -06:00
Patricia Kroll Fasel - 090207
efb7775cf4 Use CUDA and TBB if available 2015-09-21 15:23:14 -06:00
Robert Maynard
46dc67c336 Suppress warnings from examples. 2015-09-21 14:17:25 -04:00
Patricia Kroll Fasel - 090207
99231afbaf Supply files to run cuda and tbb. Use quaternion from isosurface. 2015-09-21 10:45:06 -06:00
Robert Maynard
c6fa4aa326 Remove unused variables. 2015-09-18 11:40:32 -04:00
Patricia Kroll Fasel - 090207
d57393d142 Fix merge problems with CMakeList files 2015-09-17 13:49:47 -06:00
Patricia Kroll Fasel - 090207
1acd09610e Merge branch 'master' of gitlab.kitware.com:Fasel/vtk-m into tetra_uniform 2015-09-17 13:27:45 -06:00
Patricia Kroll Fasel - 090207
02d2eefe22 3d uniform grid to tetrahedra now includes getting actual vertex points. 2015-09-17 13:10:22 -06:00
Robert Maynard
83f164daaa Update isosurface to know about ArrayHandleCounting step parameter. 2015-09-17 14:19:18 -04:00
Robert Maynard
319303564c Correct warnings in the isosurface example. 2015-09-17 14:19:18 -04:00
Sujin Philip
2519dd7ef2 Merge topic 'update-clip'
54c30cbc Select step 4 implementation method
6617596f Add a clipping example
7f017c11 Release ArrayHandle resources sooner to avoid OOM
bab41d21 Workaround thrust scan bug
b5e74682 Add support for more cell types
002e5b6c Fix lowerbounds implementation and collect timing information

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Robert Maynard <robert.maynard@kitware.com>
Merge-request: !197
2015-09-17 10:28:43 -04:00
Robert Maynard
9b877ef49b Merge topic 'multiple_backend_example'
fd685210 Always install all device headers even when device isn't enabled.
b1663b24 Add an example of using multiple backends from a single translation unit.
fc0ff69d Methods with try/catch need to be host only.
4d635d64 DeviceAdapter Tags now always exist, and contain if the device is valid.
cf32b430 Teach Configure.h to store if TBB and CUDA are enabled.

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <kmorel@sandia.gov>
Merge-request: !198
2015-09-17 09:49:49 -04:00
Robert Maynard
b1663b24b7 Add an example of using multiple backends from a single translation unit. 2015-09-17 09:28:21 -04:00
Patricia Kroll Fasel - 090207
6683c32a9f OpenGL example working for 3d tet uniform, serial and cuda. 2015-09-16 11:52:41 -06:00
Robert Maynard
9c3ff00b6e Switch over to a simpler way to specify the vtkm backend. 2015-09-16 13:16:25 -04:00
Sujin Philip
6617596f3b Add a clipping example 2015-09-16 10:07:25 -04:00
Robert Maynard
86ef09acd9 Update Isosurface Example to properly use the correct device adapter. 2015-09-15 14:18:36 -04:00
Robert Maynard
5ce3e1f3d0 Update HelloWorld Example to properly use the correct device adapter. 2015-09-15 14:15:56 -04:00
Patricia Kroll Fasel - 090207
22c95f102a Update tetrahedralize to output dataset 2015-09-14 14:45:59 -06:00
Patricia Kroll Fasel - 090207
d602ec3aad OpenGL example of tetrahedralize uniform grid 2015-09-14 14:35:54 -06:00
Robert Maynard
628c2acaa1 Remove memory leaks and automatically quit the hello world demo. 2015-09-07 11:32:12 -04:00
Robert Maynard
c75facf940 Add a HelloWorld example that uses opengl interop.
Based on the work of Tyson Neuroth and Huu Tan Nguyen at the VTK-m code
sprint.

Shows how to invoke a simple worklet to generate coordinates and colors,
and than use opengl interop to display it to the screen.
2015-09-04 09:38:07 -04:00
Robert Maynard
5e5e307939 Move IsoSurface example to its own directory. 2015-09-03 16:05:21 -04:00
Christopher Meyer Sewell - 188584
a10d1fc237 Removing unnecessary cell fields from isosurface test and example, and adding a few comments 2015-09-02 12:03:49 -06:00
Christopher Meyer Sewell - 188584
70c49b14c0 Changing translation for isosurface example 2015-09-01 18:22:40 -06:00
Christopher Meyer Sewell - 188584
a96da4e053 Moving viewpoint for IsosurfaceUniformGrid example 2015-09-01 18:09:15 -06:00
Christopher Meyer Sewell - 188584
30100e2ae8 Adding examples directory with isosurface rendering example 2015-09-01 17:09:36 -06:00