Commit Graph

47 Commits

Author SHA1 Message Date
Li-Ta Lo
86e6c5c3e0 use lambda instead of functor, remove unused code 2023-04-20 13:34:58 -06:00
Kenneth Moreland
be7f06bbe7 CoordinateSystem data is VariantArrayHandle
`CoordinateSystem` differed from `Field` in that its `GetData`
method returned an `ArrayHandleVirtualCoordinates` instead of
a `VariantArrayHandle`. This is probably confusing since
`CoordianteSystem` inherits `Field` and has a pretty dramatic
difference in this behavior.

In preparation to deprecate `ArrayHandleVirtualCoordinates`, this
changes `CoordiantSystem` to be much more like `Field`. (In the
future, we may change the `CoordinateSystem` to point to a `Field`
rather than be a special `Field`.)

A method named `GetDataAsMultiplexer` has been added to
`CoordinateSystem`. This method allows you to get data from
`CoordinateSystem` as a single array type without worrying
about creating functors to handle different types and without
needing virtual methods.
2020-07-14 08:50:39 -06:00
Matt Larsen
1c63c7032a export symbols need by vtkh 2020-06-19 07:41:54 -07:00
Kenneth Moreland
0be50c119d Update VTK-m code to use new Vec aliases
Should make the code easier to read.
2019-07-31 12:55:40 -06:00
nadavi
fbcea82e78 conslidate the license statement 2019-04-17 10:57:13 -06:00
Allison Vacanti
93506d25e2 Change function signatures to use 'using' aliases.
Also cleaned up some lingering type typedefs.
2018-05-25 17:18:41 -04:00
Robert Maynard
944bc3c0d6 Introduce vtkm::cont::ColorTable replacing vtkm::rendering::ColorTable
The new and improved vtkm::cont::ColorTable provides a more feature complete
color table implementation that is modeled after
vtkDiscretizableColorTransferFunction. This class therefore supports different
color spaces ( rgb, lab, hsv, diverging ) and supports execution across all
device adapters.
2018-03-28 16:11:23 -04:00
Sujin Philip
70fcd1d1cc Update CoordinateSystem to use the Virtual Array 2018-01-10 10:19:19 -05:00
Kenneth Moreland
c3a3184d51 Update copyright for Sandia
Sandia National Laboratories recently changed management from the
Sandia Corporation to the National Technology & Engineering Solutions
of Sandia, LLC (NTESS). The copyright statements need to be updated
accordingly.
2017-09-20 15:33:44 -06:00
Matt Larsen
df185a67aa removing background colors from tracers. Background color is now the responsiblitiy of the canvas. 2017-08-12 17:22:47 -07:00
Matt Larsen
b1e3688bfd multi-canvas working for ray tracer + volume renderer 2017-08-05 19:11:28 -07:00
Matt Larsen
a2b3f80356 Cleaning up rendering headers and moving structured volume renderer into cxx file 2017-07-08 13:48:38 -07:00
Matt Larsen
95749ee223 connecting composite background from volume mapper to renderer 2017-07-03 11:00:54 -07:00
Matt Larsen
ce2c29105f removing debug variable 2017-07-02 17:02:39 -07:00
Matt Larsen
0498f48269 Fixing incorrect logic when sampling the upper edge of a cell that is on the data set boundry 2017-07-02 17:00:10 -07:00
Matt Larsen
630e871ea7 refactoring ray tracing and adding new renderer 2017-06-17 14:28:45 -07:00
Robert Maynard
5dd346007b Respect VTK-m convention of parameters all or nothing on a line
clang-format BinPack settings have been disabled to make sure that the
VTK-m style guideline is obeyed.
2017-05-26 13:53:28 -04:00
Kitware Robot
4ade5f5770 clang-format: apply to the entire tree 2017-05-25 07:51:37 -04:00
Kitware Robot
efbde1d54b clang-format: sort include directives 2017-05-18 12:59:33 -04:00
Matt Larsen
1d4cfc2a28 Fixing Min and Max calls not defined for non-floating point types 2017-03-13 21:12:02 -07:00
Matt Larsen
cfc252ad83 completed refactoring 2017-03-13 20:59:32 -07:00
mclarsen
2f9fb6eecb Almost finished refactoring 2017-03-13 17:03:37 -07:00
mclarsen
237df547ec Adding classes to reduce the ammount of redundant code 2017-03-13 11:49:29 -07:00
Matt Larsen
50ccedf828 Fixing the default behavior of the volume renderer 2017-02-22 11:17:22 -08:00
Matt Larsen
87e53d6c00 Fixing error in volume renderer 2017-02-10 14:00:02 -08:00
Matt Larsen
1f6ef23b98 adding the ability to turn off background compositing for volume renderer 2017-02-09 16:26:23 -08:00
Matt Larsen
bd845f01d6 Adding coordinate system include to the volume renderer 2017-02-09 13:00:08 -08:00
Matt Larsen
59020fe98f Adding several more includes to the volume renderer 2017-02-09 12:51:46 -08:00
Matt Larsen
9f074e4ad8 Removing typename from typdef declaration in the volume renderer 2017-02-09 12:47:02 -08:00
David C. Lonie
f601e38ba8 Simplify exception hierarchy.
Remove the ErrorControl class such that all subclasses now inherit from
error. Renamed all exception classes via s/ErrorControl/Error/.

See issue #57.
2017-02-07 15:42:38 -05:00
Kenneth Moreland
02e37f4bc5 Fix an issue with casting a float to an int too soon
There was a case of bad casting where a Float32 that should be in the
range between 0 and 1 was cast to an Id and then multiplied by the size
of an array. The intention is to get a proportional index into the
array, but because the float was cast to an int first, you get either
the first or last index.

Instead, first cast the size of the array to a Float32, multiply it by
the fraction, and then cast back to an Id. That should give the desired
effect.
2016-11-22 15:34:56 -07:00
Kenneth Moreland
fdaccc22db Remove exports for header-only functions/methods
Change the VTKM_CONT_EXPORT to VTKM_CONT. (Likewise for EXEC and
EXEC_CONT.) Remove the inline from these macros so that they can be
applied to everything, including implementations in a library.

Because inline is not declared in these modifies, you have to add the
keyword to functions and methods where the implementation is not inlined
in the class.
2016-11-15 22:22:13 -07:00
Dave Pugmire
80eb8621e2 more uninitialized compiler warnings... 2016-11-07 15:24:38 -05:00
Dave Pugmire
2975b03a53 Remove 'uninitialized variable' warning. 2016-11-07 15:07:03 -05:00
Dave Pugmire
f413bac78c Fix compiler warnings. 2016-11-04 11:43:30 -04:00
Robert Maynard
6d9dd7d233 Correct conversion warning in VolumeRendererStructured 2016-10-31 15:27:45 -04:00
Kenneth Moreland
4b83826345 Fix uninitialized variable warning in structured volume renderer
One of the dashboard was complaining that the bottomLeft variable might
have been used uninitialized because it got set in a condition above it.
In fact, that condition is always true the first during the first
iteration, but it is not worth fighting the compiler over it. Instead,
just initialize the value of bottomLeft when it is constructed.
2016-09-22 09:52:12 -06:00
Kenneth Moreland
893f3115f2 Fix precision warnings when FloatDefault is 64 bit
When VTKm_USE_DOUBLE_PRECISION is on (not the default), then
vtkm::FloatDefault is set to 64 bit values. There was some code that was
coded for 32 bit and never checked for 64 bit (on all compilers).
2016-08-26 09:33:37 -06:00
Robert Maynard
31138293f9 Pass Fields and CoordinateSystems to Dispatcher::Invoke
Now that we can handle scheduling Fields and CoordinateSystems, do
2016-08-05 15:26:17 -04:00
Kenneth Moreland
e30607f134 Hide internal std::vector in Scene
Generally we try not to expose the implementation details of how things
are stored in objects.

Also changed some arguments that should have been declared const to
actually be const.
2016-06-09 12:07:53 -06:00
Kenneth Moreland
8834458238 Fix use of uninitialized invSpacing value
The SamplerRect worklet had an error where it was possible that the
invSpacing stack-local values could be used uninitialized. On the first
iteration of the loop in the SamplerRect operation, it calls LocateCell,
which is supposed to set invSpacing. Under most conditions it does, but
if one of the ray directions is 0 (which can happen with axis-aligned
views), one of the invSpacing dimensions was skipped, leaving the value
to whatever garbage happened to be on the stack. Later, the invSpacing
value was used to interpolate a scalar, which under some circumstances
could cause an array index error when looking up a color in the color
map.

This fix changes the condition for when the ray direction is 0 to still
initialize invSpacing.
2016-06-07 09:36:56 -06:00
Kenneth Moreland
fa3e43fbaa Change vtkm::rendering::RenderSurface to Canvas
The word surface is more often used for something like a polygonal mesh,
so this name is quite confusing. Canvas is consistent with a
conventional name in GUI widget APIs.
2016-06-02 16:04:13 -06: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
1736a117ba Fix warnings about out of order member initialization
There are a lot of VTK-m coding style issues I would also like to clean
up (such as variable names and using "this->" before member variables),
but it is late and I want to go home.
2016-05-19 17:27:16 -06:00
Kenneth Moreland
68c18b2e38 Fix multiple warnings about unused params and precision loss 2016-05-19 17:15:06 -06:00
Matt Larsen
e6a4570b6d Added copyright statement to VolumeRendererStructured.h 2016-05-18 20:51:04 -04:00
mclarsen
6ada07ea31 Added structured 2016-05-18 16:30:07 -07:00