2bfbf0a9 Transfer of virtuals to the CUDA device now properly uses streams
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Sujin Philip <sujin.philip@kitware.com>
Merge-request: !1114
Due to recent changes to remove static arrays that are not supported on
some devices, the function to return all the local point indices on a
face was removed. That left no way to get the structure of cell faces
short of pulling an internal data structure.
This change resurrects a function to get point indices for a face. The
interface for this method has necessarily changed, so I also changed the
corresponding function for getting edge indices.
86f6ecbf Add some convenience methods for Filter::SetFieldsToPass
f8237a9d Make selection of fields to pass a field member variable
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Utkarsh Ayachit <utkarsh.ayachit@kitware.com>
Merge-request: !1118
The first convenience method takes a FieldSelection and a mode. The mode
given will override the mode in the FieldSelection. The intention is to
make it easy to give the constructor argument for FieldSelection and the
mode. For example, if you wanted to pass all variables _except_
"stopfield", you could say
field.SetFieldsToPass("stopfield",
vtkm::filter::FieldSelection::MODE_EXCLUDE);
I also added a convenience method that takes the name of a field and an
association.
field.SetFieldsToPass("pointfield",
vtkm::cont::Field::ASSOC_POINTS);
Granted, you could get the same effect by wrapping this arguments in
initializer braces, but this is a bit more clear.
Previously you passed a FieldSelection to Filter::Execute to specify
which fields to pass from input to output. There is no real reason for
this as other information about input and output fields are member
variables to Filter. This moves field selection as a member variable as
well. (This should also help confusion when updating old code to new to
prevent users from mistaking field passing with input fields.
Also added a few convenience constructors to FieldSelection so that you
can call Field::SetFieldsToPass() with just the string of what you want
to pass.
d74b96ba Support FieldSelection initialization with vtkm::Pair initializer list
8e312f81 Add MODE_EXCLUDE to FieldSelection
9c51de8d Add MODE_NONE to FieldSelection
a4aa42c0 Avoid "weird" arrays in fields
6a6ac7cd Change filter to pass all fields by default
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1116
This allows you to turn off the selection of fields rather than turn
them on. It could be helpful, for example, if you were isosurfacing on a
single isovalue and didn't want to pass the field you are contouring on
(because it's all the same value).
This mode forces the selection to be empty. Although there is no
practical difference between having MODE_NONE and having MODE_SELECTED
with nothing selected (which is the default), this is a semantically
nicer way to say you don't want any fields.
Since we have changed the default behavior of Filter::Execute to be
MODE_ALL, this is a nice addition so that you can clearly specify you
don't want to pass any fields by adding
vtkm::filter::FieldSelection::MODE_NONE as the second argument. (Making
it MODE_SELECTED is not clear that you want none.)
In some of the tests there was a field that was using a counting array.
This uses an integer as the value type and has a special implicit
storage type. Currently, this is likely to cause problems whenever it
runs into a cast and call of a dynamic array. For now, let's avoid
these.
In the near future we should have expanded virtual method capabilities
that will make it possible to support these atypical arrays.
Several MultiBlock methods take references as arguments. Generally that
is good as some of the arguments take larger data structures like
DataSet and std::vector that can be passed much faster as a reference.
However, the references were not declared const, which means that you
could not use rvalues. This is now fixed.
e3961b9c update examples after filter API changes.
9cf5be2f Make `Result` constructor as `explicit`.
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1112
This avoid accidental conversions from DataSet to Result in return
values. This exposed several issues with filters and their tests. Fixed
those as well.
cbadd3e6 Make CoordinateSystem not fail on CUDA
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <kmorel@sandia.gov>
Acked-by: Matt Larsen <mlarsen@cs.uoregon.edu>
Merge-request: !1108
86bd81de streamline: handle different storage types for fields.
de4e840e enhance filter API
c255c0eb add `vtkm::cont::ConditionalCastAndCall`
54c2d234 Make it easier to iterator over blocks.
d1a59aad Fixes for CrossProduct and DotProduct.
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Robert Maynard <robert.maynard@kitware.com>
Merge-request: !1100
By pruning the invalid combinations first we reduce the amount of work
the compiler has to do. Additionally it makes for smaller callstacks when
the compiler errors out during a CastAndCall.
Filters now support executing on a dataset to produce a result dataset
with automatic mapping of fields to the output dataset. Fields to map
can be selected using `vtkm::filter::FieldSelection` class, which provides
constructors to map all or no fields, along with a selection of fields.
This updates all tests to use the new filter API.
a75c6ae4 Automatically disable assert for CUDA 7.5 as they don't work in device code
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Matt Larsen <mlarsen@cs.uoregon.edu>
Merge-request: !1105