VISR  0.11.8
Versatile Interactive Scene Renderer
visr::pml::VectorParameter< ElementType > Class Template Reference

#include <vector_parameter.hpp>

Inheritance diagram for visr::pml::VectorParameter< ElementType >:
visr::efl::BasicVector< ElementType > visr::TypedParameterBase< VectorParameter< ElementType >, VectorParameterConfig, VectorParameterType< ElementType >::ptype() > visr::ParameterBase

Public Member Functions

 VectorParameter (VectorParameter< ElementType > const &rhs)
 
 VectorParameter (ParameterConfigBase const &config)
 
 VectorParameter (VectorParameterConfig const &config)
 
virtual ~VectorParameter () override
 
- Public Member Functions inherited from visr::efl::BasicVector< ElementType >
 BasicVector (std::size_t alignmentElements=0)
 
 BasicVector (std::size_t size, std::size_t alignmentElements)
 
 BasicVector (std::initializer_list< ElementType > const &initialValues, std::size_t alignmentElements=0)
 
 BasicVector (BasicVector< ElementType > &&rhs)=default
 
BasicVector< ElementType > & operator= (BasicVector< ElementType > &&rhs)=default
 
 ~BasicVector ()
 
void resize (std::size_t newSize)
 
void assign (const BasicVector< ElementType > &rhs)
 
void zeroFill ()
 
void fillValue (ElementType val)
 
void swap (BasicVector< ElementType > &rhs)
 
void copy (BasicVector< ElementType > const &rhs)
 
std::size_t alignmentElements () const
 
std::size_t size () const
 
ElementType & operator[] (std::size_t idx)
 
ElementType const & operator[] (std::size_t idx) const
 
ElementType & at (std::size_t idx)
 
ElementType const & at (std::size_t idx) const
 
ElementType * data ()
 
ElementType const * data () const
 
- Public Member Functions inherited from visr::TypedParameterBase< VectorParameter< ElementType >, VectorParameterConfig, VectorParameterType< ElementType >::ptype() >
 TypedParameterBase ()=default
 
virtual ~TypedParameterBase ()=default
 
ParameterType type () final
 
std::unique_ptr< ParameterBaseclone () const final
 
void assign (ParameterBase const &rhs) override
 
- Public Member Functions inherited from visr::ParameterBase
 ParameterBase ()
 
 ParameterBase (const ParameterBase &)
 
ParameterBaseoperator= (const ParameterBase &)
 
virtual ~ParameterBase ()
 

Static Public Member Functions

static VectorParameter fromString (std::string const &initString, std::size_t alignment=0)
 
static VectorParameter fromStream (std::istream &stream, std::size_t alignment=0)
 
static VectorParameter fromAudioFile (std::string const &fileName, std::size_t alignment=0)
 
static VectorParameter fromTextFile (std::string const &fileName, std::size_t alignment=0)
 
- Static Public Member Functions inherited from visr::TypedParameterBase< VectorParameter< ElementType >, VectorParameterConfig, VectorParameterType< ElementType >::ptype() >
static const constexpr ParameterType staticType ()
 

Additional Inherited Members

- Public Types inherited from visr::TypedParameterBase< VectorParameter< ElementType >, VectorParameterConfig, VectorParameterType< ElementType >::ptype() >
using ParameterConfigType = VectorParameterConfig
 

Detailed Description

template<typename ElementType>
class visr::pml::VectorParameter< ElementType >

A type for passing vectors between processing components. The template class is explicitly instantiated for the element types float and double.

Template Parameters
ElementTypeThe data type of the elements of the matrix.

Constructor & Destructor Documentation

◆ VectorParameter() [1/3]

template<typename ElementType >
visr::pml::VectorParameter< ElementType >::VectorParameter ( VectorParameter< ElementType > const &  rhs)

◆ VectorParameter() [2/3]

template<typename ElementType >
visr::pml::VectorParameter< ElementType >::VectorParameter ( ParameterConfigBase const &  config)
explicit

◆ VectorParameter() [3/3]

template<typename ElementType >
visr::pml::VectorParameter< ElementType >::VectorParameter ( VectorParameterConfig const &  config)
explicit

◆ ~VectorParameter()

template<typename ElementType >
visr::pml::VectorParameter< ElementType >::~VectorParameter ( )
overridevirtualdefault

Destructor (virtual)

Member Function Documentation

◆ fromAudioFile()

template<typename ElementType >
VectorParameter< ElementType > visr::pml::VectorParameter< ElementType >::fromAudioFile ( std::string const &  fileName,
std::size_t  alignment = 0 
)
static

Create a VectorParameter from an audio file (e.g., a WAV file). The file must contain a single audio channel.

◆ fromStream()

template<typename ElementType >
VectorParameter< ElementType > visr::pml::VectorParameter< ElementType >::fromStream ( std::istream &  stream,
std::size_t  alignment = 0 
)
static

Create a VectorParameter from a stream containing a textual representation of the string.

See also
fromString for the format.

◆ fromString()

template<typename ElementType >
VectorParameter< ElementType > visr::pml::VectorParameter< ElementType >::fromString ( std::string const &  initString,
std::size_t  alignment = 0 
)
static

Named constructors to create and initialise vectors from various representations. Create a VectorParameter from a string containing a list of numbers separated by a space or a comma plus arbitray amounts of whitespace

◆ fromTextFile()

template<typename ElementType >
VectorParameter< ElementType > visr::pml::VectorParameter< ElementType >::fromTextFile ( std::string const &  fileName,
std::size_t  alignment = 0 
)
static

Create a VectorParameter from a file containing a list of values.

See also
fromStream for a description of the text format.

The documentation for this class was generated from the following files: