mantaflow  0.10
A framework for fluid simulation
Public Member Functions | Public Attributes | Protected Attributes | List of all members
Manta::ParticleDataImpl< T > Class Template Reference

#include <particle.h>

Inheritance diagram for Manta::ParticleDataImpl< T >:
Manta::ParticleDataBase

Public Member Functions

 PYTHON () ParticleDataImpl(FluidSolver *parent)
 
 ParticleDataImpl (FluidSolver *parent, ParticleDataImpl< T > *other)
 
T & get (IndexInt idx)
 access data
 
const T & get (IndexInt idx) const
 
T & operator[] (IndexInt idx)
 
const T & operator[] (IndexInt idx) const
 
 PYTHON () void clear()
 set all values to 0, note - different from particleSystem::clear! doesnt modify size of array (has to stay in sync with parent system)
 
 PYTHON () void setSource(Grid< T > *grid
 set grid from which to get data...
 
virtual IndexInt getSizeSlow () const
 particle data base interface
 
virtual void addEntry ()
 
virtual ParticleDataBaseclone ()
 
virtual PdataType getType () const
 
virtual void resize (IndexInt s)
 
virtual void copyValueSlow (IndexInt from, IndexInt to)
 
IndexInt size () const
 
void copyValue (IndexInt from, IndexInt to)
 fast inlined functions for per particle operations
 
void initNewValue (IndexInt idx, Vec3 pos)
 
 PYTHON () void setConst(T s)
 python interface (similar to grid data)
 
 PYTHON () void setConstRange(T s
 
 PYTHON () ParticleDataImpl< T > &copyFrom(const ParticleDataImpl< T > &a)
 
 PYTHON () void add(const ParticleDataImpl< T > &a)
 
 PYTHON () void sub(const ParticleDataImpl< T > &a)
 
 PYTHON () void addConst(T s)
 
 PYTHON () void addScaled(const ParticleDataImpl< T > &a
 
 PYTHON () void mult(const ParticleDataImpl< T > &a)
 
 PYTHON () void multConst(T s)
 
 PYTHON () void safeDiv(const ParticleDataImpl< T > &a)
 
 PYTHON () void clamp(Real min
 
 PYTHON () void clampMin(Real vmin)
 
 PYTHON () void clampMax(Real vmax)
 
 PYTHON () Real getMaxAbs()
 
 PYTHON () Real getMax()
 
 PYTHON () Real getMin()
 
 PYTHON () T sum(const ParticleDataImpl< int > *t
 
 PYTHON () Real sumSquare() const
 
 PYTHON () Real sumMagnitude() const
 
 PYTHON () void setConstIntFlag(T s
 special, set if int flag in t has "flag"
 
 PYTHON () void printPdata(IndexInt start
 
template<>
void initNewValue (IndexInt idx, Vec3 pos)
 
template<>
ParticleDataBase::PdataType getType () const
 
template<>
ParticleDataBase::PdataType getType () const
 
template<>
ParticleDataBase::PdataType getType () const
 
template<>
Real getMax ()
 
- Public Member Functions inherited from Manta::ParticleDataBase
 PYTHON () ParticleDataBase(FluidSolver *parent)
 
void setParticleSys (ParticleBase *set)
 set base pointer
 
void checkPartIndex (IndexInt idx) const
 debugging
 

Public Attributes

bool isMAC =false )
 
const int begin
 
const int const int end
 
const T & factor
 
Real max
 
const int itype =0) const
 
const ParticleDataImpl< int > & t
 
const ParticleDataImpl< int > const int flag
 
IndexInt stop =-1
 
IndexInt bool printIndex =false)
 

Protected Attributes

std::vector< T > mData
 file io More...
 
Grid< T > * mpGridSource
 optionally , we might have an associated grid from which to grab new data
 
bool mGridSourceMAC
 unfortunately , we need to distinguish mac vs regular vec3
 
- Protected Attributes inherited from Manta::ParticleDataBase
ParticleBasempParticleSys
 

Additional Inherited Members

- Public Types inherited from Manta::ParticleDataBase
enum  PdataType { TypeNone = 0, TypeReal = 1, TypeInt = 2, TypeVec3 = 4 }
 data type IDs, in line with those for grids
 

Detailed Description

template<class T>
class Manta::ParticleDataImpl< T >

abstract interface for particle data

Member Data Documentation

◆ mData

template<class T>
std::vector<T> Manta::ParticleDataImpl< T >::mData
protected

file io

data storage


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