ParticleAPI 3.0.0
Performant particle system API in C++ for interactive graphics
Public Member Functions | Public Attributes | List of all members
PDBlob Struct Reference

Gaussian blob. More...

#include <pDomain.h>

Inheritance diagram for PDBlob:
pDomain

Public Member Functions

 PDBlob (const pVec &Center, const float StandardDev)
 
void PDBlob_Cons (const pVec &Center, const float StandardDev)
 
bool Within (const pVec &pos) const
 Has a probability of returning true equal to the probability density at the specified point. More...
 
pVec Generate () const
 Returns a point with normal probability density. More...
 
float Size () const
 Returns the probability density integral, which is 1.0. More...
 
std::shared_ptr< pDomaincopy () const
 
virtual bool Within (const pVec &) const =0
 Returns true if the given point is within the domain. More...
 
virtual pVec Generate () const =0
 Returns a random point in the domain. More...
 
virtual float Size () const =0
 Returns the size of the domain (length, area, or volume). More...
 
virtual std::shared_ptr< pDomaincopy () const =0
 

Public Attributes

pVec ctr
 
float stdev
 
float Scale1
 
float Scale2
 
- Public Attributes inherited from pDomain
pDomainType_E Which
 

Detailed Description

Gaussian blob.

The point Center is the center of a normal probability density of standard deviation StandardDev. The density is radially symmetrical. The blob domain allows for some very natural-looking effects because there is no sharp, artificial-looking boundary at the edge of the domain.

Generate returns a point with normal probability density. Within has a probability of returning true equal to the probability density at the specified point.

Constructor & Destructor Documentation

◆ PDBlob()

PDBlob ( const pVec Center,
const float  StandardDev 
)
inline

Member Function Documentation

◆ copy()

std::shared_ptr< pDomain > copy ( ) const
inlinevirtual

Implements pDomain.

◆ Generate()

pVec Generate ( ) const
inlinevirtual

Returns a point with normal probability density.

Implements pDomain.

◆ PDBlob_Cons()

void PDBlob_Cons ( const pVec Center,
const float  StandardDev 
)
inline

◆ Size()

float Size ( ) const
inlinevirtual

Returns the probability density integral, which is 1.0.

Implements pDomain.

◆ Within()

bool Within ( const pVec pos) const
inlinevirtual

Has a probability of returning true equal to the probability density at the specified point.

Implements pDomain.

Member Data Documentation

◆ ctr

pVec ctr

◆ Scale1

float Scale1

◆ Scale2

float Scale2

◆ stdev

float stdev

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