Go to the documentation of this file.
   10 #ifndef vtkm_rendering_raytracing_ChannelBuffer_h 
   11 #define vtkm_rendering_raytracing_ChannelBuffer_h 
   15 #include <vtkm/rendering/vtkm_rendering_export.h> 
   44 template <
typename Precision>
 
   74                                         Precision initValue = 1.f);
 
   78   void InitConst(
const Precision value);
 
   81   void SetName(
const std::string name);
 
   87   std::string GetName() 
const;
 
   92   template <
typename Device>
 
  100     this->NumChannels = numChannels;
 
  104     this->Buffer.
PrepareForOutput(this->Size * this->NumChannels, Device(), token);
 
  109   template <
typename Device>
 
  114       std::string msg = 
"ChannelBuffer SetNumChannels: numBins must be greater that 0";
 
  117     if (this->NumChannels == numChannels)
 
  120     this->NumChannels = numChannels;
 
  122     this->Buffer.
PrepareForOutput(this->Size * this->NumChannels, Device(), token);
 
  125   template <
typename Device>
 
  130     this->Size = newSize;
 
  
VTKM_CONT void Resize(const vtkm::Id newSize, Device device)
Definition: ChannelBuffer.h:126
 
Groups connected points that have the same field value.
Definition: Atomic.h:19
 
std::string Name
Definition: ChannelBuffer.h:50
 
VTKM_EXEC_CONT void Normalize(T &x)
Changes a vector to be normal.
Definition: VectorAnalysis.h:168
 
vtkm::Id Size
Definition: ChannelBuffer.h:49
 
Mananges a buffer that contains many channels per value (e.g., RGBA values).
Definition: ChannelBuffer.h:45
 
vtkm::Int32 Id
Represents an ID (index into arrays).
Definition: Types.h:191
 
A token to hold the scope of an ArrayHandle or other object.
Definition: Token.h:35
 
#define VTKM_CONT
Definition: ExportMacros.h:57
 
vtkm::cont::ArrayHandle< Precision > Buffer
Definition: ChannelBuffer.h:54
 
This class is thrown when a VTKm function or method encounters an invalid value that inhibits progres...
Definition: ErrorBadValue.h:25
 
VTKM_CONT WritePortalType PrepareForOutput(vtkm::Id numberOfValues, vtkm::cont::DeviceAdapterId device, vtkm::cont::Token &token) const
Prepares (allocates) this array to be used as an output from an operation in the execution environmen...
Definition: ArrayHandle.h:613
 
int32_t Int32
Definition: Types.h:160
 
VTKM_CONT ChannelBuffer(const vtkm::Int32 size, const vtkm::Int32 numChannels, Device)
Functions that are calleble within vtkm where the device is already known.
Definition: ChannelBuffer.h:93
 
VTKM_CONT void SetNumChannels(const vtkm::Int32 numChannels, Device)
Definition: ChannelBuffer.h:110
 
vtkm::Int32 NumChannels
Definition: ChannelBuffer.h:48
 
Definition: ChannelBufferOperations.h:93