VR-Forces 4.10 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Static Public Member Functions | Protected Attributes | Static Protected Attributes | Private Member Functions
makVrv::DtDropParticle Class Referenceabstract

Local class for a single drop particle on the screen. More...

Inheritance diagram for makVrv::DtDropParticle:
Inheritance graph
[legend]

Public Member Functions

 DtDropParticle (float px, float py, float pMass, double time, DtGridCell grid[][GRID_DIMENSION])
 constructor More...
 
virtual ~DtDropParticle ()
 destructor More...
 
virtual void setParent (DtDropParticle *drop)
 If this drop was left behind from wetting from another drop, keep track of the parent drop. More...
 
virtual DtDropParticleparent () const
 
virtual float mass () const
 set/get the mass More...
 
virtual void setMass (float m)
 
virtual const Vector2_32velocity () const
 get the velocity More...
 
virtual void affectedCells (std::vector< DtVector2< short > > &cells) const
 Gets all screen grid cells covered by this drop. More...
 
virtual void computeRadius (double waterOnScreenSize)
 compute radius More...
 
virtual void update (double time, double elapsedTime, DtGridCell grid[][GRID_DIMENSION], bool &destroyFlag)=0
 Update the particle. More...
 
virtual void gridPosition (int &gx, int &gy) const
 get the grid position More...
 
virtual bool mergeable () const
 can this be merged with another particle? More...
 
virtual float x () const
 get x More...
 
virtual float y () const
 get y More...
 
virtual float radius () const
 get radius More...
 
virtual int type () const
 type (0) More...
 
virtual float intensity (void) const
 intensity (1) More...
 

Static Public Member Functions

static void precomputeDropletNormalsIfNeeded ()
 Precompute a normal map for a drop. More...
 
static const void * precomputedDropletNormalsDataPointer (void)
 accesss the grid of precomputed normals as a void* pointer (so that they can be copied into a gpu buffer for example) More...
 

Protected Attributes

float myX
 
float myY
 
float myRadius
 
float myMass
 
float myV0
 
double myT0
 
float myAcceleration
 
DtDropParticlemyParent
 
Vector2_32 myDirection
 
Vector2_32 myVelocity
 
int myLastGridX
 
int myLastGridY
 
bool myMergeable
 

Static Protected Attributes

static DtVector4< unsigned intthePrecomputedDropletNormals [PRECOMPUTED_DIM][PRECOMPUTED_DIM]
 
static bool myDropletInitialized
 

Private Member Functions

 DtDropParticle ()=delete
 private default constructor. not allowed. More...
 
 DtDropParticle (const DtDropParticle &)=delete
 prevent copy-construction More...
 
DtDropParticleoperator= (const DtDropParticle &)=delete
 prevent assignment More...
 

Detailed Description

Local class for a single drop particle on the screen.

Constructor & Destructor Documentation

makVrv::DtDropParticle::DtDropParticle ( float  px,
float  py,
float  pMass,
double  time,
DtGridCell  grid[][GRID_DIMENSION] 
)

constructor

virtual makVrv::DtDropParticle::~DtDropParticle ( )
virtual

destructor

makVrv::DtDropParticle::DtDropParticle ( )
privatedelete

private default constructor. not allowed.

makVrv::DtDropParticle::DtDropParticle ( const DtDropParticle )
privatedelete

prevent copy-construction

Member Function Documentation

DtDropParticle& makVrv::DtDropParticle::operator= ( const DtDropParticle )
privatedelete

prevent assignment

virtual void makVrv::DtDropParticle::setParent ( DtDropParticle drop)
virtual

If this drop was left behind from wetting from another drop, keep track of the parent drop.

virtual DtDropParticle* makVrv::DtDropParticle::parent ( ) const
virtual
virtual float makVrv::DtDropParticle::mass ( ) const
virtual

set/get the mass

virtual void makVrv::DtDropParticle::setMass ( float  m)
virtual
virtual const Vector2_32& makVrv::DtDropParticle::velocity ( ) const
virtual

get the velocity

virtual void makVrv::DtDropParticle::affectedCells ( std::vector< DtVector2< short > > &  cells) const
virtual

Gets all screen grid cells covered by this drop.

virtual void makVrv::DtDropParticle::computeRadius ( double  waterOnScreenSize)
virtual

compute radius

virtual void makVrv::DtDropParticle::update ( double  time,
double  elapsedTime,
DtGridCell  grid[][GRID_DIMENSION],
bool destroyFlag 
)
pure virtual

Update the particle.

Implemented in makVrv::DtSplashParticle, and makVrv::DtRaindropParticle.

virtual void makVrv::DtDropParticle::gridPosition ( int gx,
int gy 
) const
virtual

get the grid position

virtual bool makVrv::DtDropParticle::mergeable ( ) const
virtual

can this be merged with another particle?

virtual float makVrv::DtDropParticle::x ( ) const
virtual

get x

virtual float makVrv::DtDropParticle::y ( ) const
virtual

get y

virtual float makVrv::DtDropParticle::radius ( ) const
virtual

get radius

virtual int makVrv::DtDropParticle::type ( ) const
virtual

type (0)

Reimplemented in makVrv::DtSplashParticle.

virtual float makVrv::DtDropParticle::intensity ( void  ) const
virtual

intensity (1)

Reimplemented in makVrv::DtSplashParticle.

static void makVrv::DtDropParticle::precomputeDropletNormalsIfNeeded ( )
static

Precompute a normal map for a drop.

static const void* makVrv::DtDropParticle::precomputedDropletNormalsDataPointer ( void  )
static

accesss the grid of precomputed normals as a void* pointer (so that they can be copied into a gpu buffer for example)

Member Data Documentation

float makVrv::DtDropParticle::myX
protected
float makVrv::DtDropParticle::myY
protected
float makVrv::DtDropParticle::myRadius
protected
float makVrv::DtDropParticle::myMass
protected
float makVrv::DtDropParticle::myV0
protected
double makVrv::DtDropParticle::myT0
protected
float makVrv::DtDropParticle::myAcceleration
protected
DtDropParticle* makVrv::DtDropParticle::myParent
protected
Vector2_32 makVrv::DtDropParticle::myDirection
protected
Vector2_32 makVrv::DtDropParticle::myVelocity
protected
int makVrv::DtDropParticle::myLastGridX
protected
int makVrv::DtDropParticle::myLastGridY
protected
bool makVrv::DtDropParticle::myMergeable
protected
DtVector4<unsigned int> makVrv::DtDropParticle::thePrecomputedDropletNormals[PRECOMPUTED_DIM][PRECOMPUTED_DIM]
staticprotected
bool makVrv::DtDropParticle::myDropletInitialized
staticprotected

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

Document ID: Generated on Tue Sep 21 17:42:52 EDT 2021 from SVN revision 234861
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)