Commit Graph

36 Commits

Author SHA1 Message Date
Kenneth Moreland
8b133288ce Fix deprecation warnings
There was an error that caused deprecation warnings in VTK-m to be
suppressed, which meant that many uses of deprecated features went
unnoticed. This fixes those deprecation warnings.

The majority of the warnings were caused by the use of the deprecated
`Cast`, `CopyTo`, and `ResetTypes` methods of `UnknownArrayHandle` (or
`VariantArrayHandle`). Both `Cast` and `CopyTo` have been subsumed by
`AsArrayHandle` (to make the functionality more clear). `ResetTypes` now
requires a second template argument to define the storage types to try.

Also fixed some issues with `SerializableField` being deprecated.
This class is no longer necessary because `Field` can now be directly
serialized.
2021-01-26 07:56:39 -07:00
Li-Ta Lo
ca0ce4de7b Merge branch 'master' into hdf5_image_io 2021-01-14 14:08:00 -07:00
Kenneth Moreland
50ff9c22aa Add support of ArrayHandleSOA as a default storage type 2021-01-06 13:20:58 -07:00
Li-Ta Lo
fac489644f HDF5 unit tests
Move HDF5ImageWriter/Reader to its own unit test. Use user supplied
field name as HDF5 dataset name.
2021-01-04 10:01:49 -07:00
Li-Ta Lo
03cb5cb43c rename file names and add reference to the specification 2021-01-04 09:04:08 -07:00
Robert Maynard
90c607c999 Correct CMake checking for targets before creation 2020-12-30 12:42:51 -05:00
Robert Maynard
7897d23c39 Cleanup some minor CMake style issues 2020-12-28 10:36:00 -05:00
Li-Ta Lo
da7d6aaf19 Add HDF5 Image file support 2020-12-25 16:02:08 -07:00
nadavi
1818a885bf Generate and test regression-test images with io library updates 2020-12-02 16:24:07 +00:00
Nick Thompson
5d4c3f0c61 Less verbose logging. 2020-11-20 15:12:23 -05:00
Kenneth Moreland
f7cc03107d Fix deprecated warnings
Supress the deprecated class warnings for the implementation of
deprecated features.
2020-09-09 06:13:07 -06:00
Kenneth Moreland
63ef84ed78 Optionally remove all use of ArrayHandleVirtual
As we remove more and more virtual methods from VTK-m, I expect several
users will be interested in completely removing them from the build for
several reasons.

1. They may be compiling for hardware that does not support virtual
methods.
2. They may need to compile for CUDA but need shared libraries.
3. It should go a bit faster.

To enable this, a CMake option named `VTKm_NO_DEPRECATED_VIRTUAL` is
added. It defaults to `OFF`. But when it is `ON`, none of the code that
both uses virtuals and is deprecated will be built.

Currently, only `ArrayHandleVirtual` is deprecated, so the rest of the
virtual classes will still be built. As we move forward, more will be
removed until all virtual method functionality is removed.
2020-09-04 22:52:45 -06:00
Kenneth Moreland
52cecefba0 Fix crash when loading poly data with no cells 2020-09-01 14:20:11 -06:00
Kenneth Moreland
a8fa143351 Move UnitTestVTKDataSetReader files to git-lfs
The `UnitTestVTKDataSetReader` test reads in .vtk files of multiple
formats. The origins of this test predate the use of git-lfs and a data
directory, so the test defined in the source code several strings
containing the contents of the files.

That is no longer necessary. This change removes those strings from the
file and creates actual files in the data directory. This is easier to
manage as well as more convenient if you want to use the same data in a
different test or just take a look at the data in a different program
(such as VisIt or ParaView).
2020-08-25 07:23:13 -06:00
Kenneth Moreland
571aa9f3d7 Simplify getting test file names
The testing helper class provided a method named `GetTestDataBasePath`
that returned the base path to all the data files stored in the VTK-m
repo. This is fine, but it was a little cumbersome to build filenames.

To make things easier, there is now a new method named `DataPath` that
takes a string of the filename (or, rather, subpath) to the file in that
directory and automatically builds the path to it.
2020-08-25 06:17:59 -06:00
Kitware Robot
cf0cdcf7d1 clang-format: reformat the repository with clang-format-9 2020-08-24 14:01:08 -04:00
Vicente Adolfo Bolea Sanchez
ab0fecda7f VTKDataSetWriter: remove just_points argument
Signed-off-by: Vicente Adolfo Bolea Sanchez <vicente.bolea@kitware.com>
2020-07-24 15:54:13 -04:00
Kenneth Moreland
f6b13df513 Support coordinates of both float32 and float64
Previously there were issues if the coordinate system was using floating
point values that were not FloatDefault. This remedies that issue.
2020-07-14 08:53:01 -06:00
Kenneth Moreland
453e314044 Deprecate ArrayHandleVirtualCoordinates
We are in the process of deprecating virtual classes in VTK-m
(that run in the execution environment).
2020-07-14 08:51:47 -06:00
Kenneth Moreland
058927c82f Write uniform and rectilinear grids to legacy VTK files
As a programming convenience, all `vtkm::cont::DataSet` written by
`vtkm::io::VTKDataSetWriter` were written as a structured grid. Although
technically correct, it changed the structure of the data. This meant that
if you wanted to capture data to run elsewhere, it would run as a different
data type. This was particularly frustrating if the data of that structure
was causing problems and you wanted to debug it.

Now, `VTKDataSetWriter` checks the type of the `CoordinateSystem` to
determine whether the data should be written out as `STRUCTURED_POINTS`
(i.e. a uniform grid), `RECTILINEAR_GRID`, or `STRUCTURED_GRID`
(curvilinear).
2020-07-08 19:12:14 -06:00
dpugmire
4744730630 Merge branch 'master' of https://gitlab.kitware.com/vtk/vtk-m into betterParticleAdvectionDiffs2 2020-06-17 11:12:11 -04:00
dpugmire
447e8aff04 Merge branch 'master' of https://gitlab.kitware.com/vtk/vtk-m into betterParticleAdvectionDiffs2 2020-06-16 11:49:21 -04:00
NAThompson
0f0c465c1b Deprecate Camera::Activate() and Camera::Finish() 2020-06-14 11:04:06 -04:00
NAThompson
755137a822 Particle advection tests with file. 2020-06-13 10:58:45 -04:00
NAThompson
db8f3c9fc9 Remove Initialize() boilerplate. 2020-06-05 13:38:18 -04:00
Kenneth Moreland
6c97054b7f Update image writes to style and library
Updated the image writer classes to better follow VTK-m naming
convention (i.e. use `ImageWriterPNG` instead of `PNGWriter`). The
structure of the image writer class now also better matches the
interface for the VTK writer.

Also put the implementation of the image writers into the `vtkm_io`
library so that it only has to be compiled once.
2020-06-01 10:00:36 -06:00
Kenneth Moreland
1e91b32ace Update image readers to style and library
Updated the image reader classes to better follow VTK-m naming
convention (i.e. use `ImageReaderPNG` instead of `PNGReader`).
The structure of the image reader class now also better matches
the interface for the VTK reader.

Also put the implementation of the image readers into the `vtkm_io`
library so that it only has to be compiled once.
2020-06-01 10:00:18 -06:00
NAThompson
fe4f71ab92 Deprecate DataSetFieldAdd. 2020-05-27 15:27:47 -04:00
Kenneth Moreland
dce576bd11 Add BOVDataSetReader implementation to vtkm_io 2020-05-19 14:33:45 -06:00
Kenneth Moreland
0612be9c5b Move VTKDataSetReaderBase code to vtkm_io
Most of this code is not templated methods. Rather, it implements over
several types to call templated functions, which creates quite a bit of
code. Rather than have all code using a reader recompile the code, just
compile it once and put it in a library.
2020-05-19 12:27:01 -06:00
Nick Thompson
5d20506a5d Remove overly verbose log pring. 2020-05-18 22:25:29 -04:00
nadavi
24d022b02b Implement and test ImageReader and ImageWriter capabilities in the io library 2020-05-13 16:10:21 -06:00
NAThompson
2fc636c276 Test BOV reader. Fix slow WritePortal().Set(idx, val) loop. 2020-05-11 17:08:44 -04:00
NAThompson
697369fc14 Remove deprecation warnings throughout the project. 2020-04-30 08:12:04 -04:00
NAThompson
d610176aba First commit demos backwards compatibility and printing of warnings. 2020-04-30 07:37:55 -04:00
NAThompson
b82051746c Test that no warnings are generated and tests pass. 2020-04-29 11:30:18 -04:00