Nebula
Loading...
Searching...
No Matches
Models::ParticleSystemNode Class Reference

#include <particlesystemnode.h>

Inherits Models::ShaderStateNode.

Public Member Functions

 ParticleSystemNode ()
 constructor
 
virtual ~ParticleSystemNode ()
 destructor
 
virtual void UpdateMeshResource (const Resources::ResourceName &msh)
 change a mesh during runtime
 
IndexT GetPrimitiveGroupIndex () const
 get the primitive group index in the emitter mesh
 
void SetEmitterAttrs (const Particles::EmitterAttrs &attrs)
 set emitter attributes
 
const Particles::EmitterAttrsGetEmitterAttrs () const
 get emitter attributes
 
const Particles::EmitterMeshGetEmitterMesh () const
 get emitter mesh
 
const Particles::EnvelopeSampleBufferGetSampleBuffer () const
 get emitter sample buffer
 
- Public Member Functions inherited from Models::ShaderStateNode
 ShaderStateNode ()
 constructor
 
virtual ~ShaderStateNode ()
 destructor
 
const Materials::MaterialId GetMaterial () const
 get surface
 
- Public Member Functions inherited from Models::TransformNode
 TransformNode ()
 constructor
 
virtual ~TransformNode ()
 destructor
 
void GetLODDistances (float &minDistance, float &maxDistance)
 Get LOD distances.
 
- Public Member Functions inherited from Models::ModelNode
 ModelNode ()
 constructor
 
virtual ~ModelNode ()
 destructor
 
const Util::Array< ModelNode * > & GetChildren () const
 return constant reference to children
 
const NodeType GetType () const
 get type of node
 
const NodeBits GetBits () const
 get feature bits of node
 
virtual bool GetImplicitHierarchyActivation () const
 return true if all children should create hierarchies upon calling CreateInstance
 
const Util::StringAtomGetName () const
 return name
 
const uint32_t HashCode () const
 get hash
 
virtual std::function< void(const CoreGraphics::CmdBufferId)> GetApplyFunction ()
 Get function to apply node.
 
virtual std::function< const CoreGraphics::PrimitiveGroup()> GetPrimitiveGroupFunction ()
 Get function to fetch primitive group.
 

Static Public Member Functions

static Util::FixedArray< CoreGraphics::ResourceTableIdCreateResourceTables ()
 Create resource table.
 
- Static Public Member Functions inherited from Models::ShaderStateNode
static Util::FixedArray< CoreGraphics::ResourceTableIdCreateResourceTables ()
 Create resource table.
 

Protected Member Functions

virtual void OnFinishedLoading (ModelStreamingData *streamingData) override
 called once when all pending resource have been loaded
 
virtual bool Load (const Util::FourCC &fourcc, const Util::StringAtom &tag, const Ptr< IO::BinaryReader > &reader, bool immediate) override
 parse data tag (called by loader code)
 
- Protected Member Functions inherited from Models::ShaderStateNode
bool Load (const Util::FourCC &fourcc, const Util::StringAtom &tag, const Ptr< IO::BinaryReader > &reader, bool immediate) override
 load shader state
 
virtual void Unload () override
 unload data
 
- Protected Member Functions inherited from Models::ModelNode
virtual void Discard ()
 discard node
 

Protected Attributes

Particles::EnvelopeSampleBuffer sampleBuffer
 
Particles::EmitterAttrs emitterAttrs
 
Particles::EmitterMesh emitterMesh
 
Resources::ResourceName meshResId
 
Util::StringAtom tag
 
IndexT primGroupIndex
 
Resources::ResourceId meshResource
 
CoreGraphics::MeshId mesh
 
- Protected Attributes inherited from Models::ShaderStateNode
Resources::ResourceId materialRes
 
Materials::MaterialId material
 
Resources::ResourceName materialName
 
Util::FixedArray< CoreGraphics::ResourceTableIdresourceTables
 
- Protected Attributes inherited from Models::TransformNode
Math::vec3 position
 
Math::quat rotate
 
Math::vec3 scale
 
Math::vec3 rotatePivot
 
Math::vec3 scalePivot
 
bool isInViewSpace
 
float minDistance
 
float maxDistance
 
bool useLodDistances
 
bool lockedToViewer
 
- Protected Attributes inherited from Models::ModelNode
Util::StringAtom name
 
NodeType type
 
NodeBits bits
 
Models::ModelNodeparent
 
Util::Array< Models::ModelNode * > children
 
Math::bbox boundingBox
 
Util::StringAtom tag
 
IndexT uniqueId
 

Private Member Functions

Particles::EnvelopeCurve ParseEnvelopeCurveData (const Ptr< IO::BinaryReader > &reader) const
 helper function to parse an EnvelopeCurve from a data stream
 

Friends

class Particles::ParticleContext
 
class Models::ModelContext
 

Additional Inherited Members

- Static Public Attributes inherited from Models::ShaderStateNode
static const uint NumTables = 1
 
static const uint NumMaxOffsets = 4
 
- Static Protected Attributes inherited from Models::ModelNode
static IndexT ModelNodeUniqueIdCounter = 0
 

Constructor & Destructor Documentation

◆ ParticleSystemNode()

Models::ParticleSystemNode::ParticleSystemNode ( )

constructor

◆ ~ParticleSystemNode()

Models::ParticleSystemNode::~ParticleSystemNode ( )
virtual

destructor

Member Function Documentation

◆ CreateResourceTables()

Util::FixedArray< CoreGraphics::ResourceTableId > Models::ParticleSystemNode::CreateResourceTables ( )
static

Create resource table.

◆ GetEmitterAttrs()

const Particles::EmitterAttrs & Models::ParticleSystemNode::GetEmitterAttrs ( ) const
inline

get emitter attributes

◆ GetEmitterMesh()

const Particles::EmitterMesh & Models::ParticleSystemNode::GetEmitterMesh ( ) const
inline

get emitter mesh

◆ GetPrimitiveGroupIndex()

IndexT Models::ParticleSystemNode::GetPrimitiveGroupIndex ( ) const
inline

get the primitive group index in the emitter mesh

◆ GetSampleBuffer()

const Particles::EnvelopeSampleBuffer & Models::ParticleSystemNode::GetSampleBuffer ( ) const
inline

get emitter sample buffer

◆ Load()

bool Models::ParticleSystemNode::Load ( const Util::FourCC & fourcc,
const Util::StringAtom & tag,
const Ptr< IO::BinaryReader > & reader,
bool immediate )
overrideprotectedvirtual

parse data tag (called by loader code)

Reimplemented from Models::TransformNode.

◆ OnFinishedLoading()

void Models::ParticleSystemNode::OnFinishedLoading ( ModelStreamingData * streamingData)
overrideprotectedvirtual

called once when all pending resource have been loaded

Reimplemented from Models::ShaderStateNode.

◆ ParseEnvelopeCurveData()

Particles::EnvelopeCurve Models::ParticleSystemNode::ParseEnvelopeCurveData ( const Ptr< IO::BinaryReader > & reader) const
private

helper function to parse an EnvelopeCurve from a data stream

Helper function for ParseDataTag, parses the data elements of an EnvelopeCurve from the data stream and returns an EnvelopeCurve object.

◆ SetEmitterAttrs()

void Models::ParticleSystemNode::SetEmitterAttrs ( const Particles::EmitterAttrs & attrs)
inline

set emitter attributes

◆ UpdateMeshResource()

void Models::ParticleSystemNode::UpdateMeshResource ( const Resources::ResourceName & msh)
virtual

change a mesh during runtime

Friends And Related Symbol Documentation

◆ Models::ModelContext

friend class Models::ModelContext
friend

◆ Particles::ParticleContext

friend class Particles::ParticleContext
friend

Member Data Documentation

◆ emitterAttrs

Particles::EmitterAttrs Models::ParticleSystemNode::emitterAttrs
protected

◆ emitterMesh

Particles::EmitterMesh Models::ParticleSystemNode::emitterMesh
protected

◆ mesh

CoreGraphics::MeshId Models::ParticleSystemNode::mesh
protected

◆ meshResId

Resources::ResourceName Models::ParticleSystemNode::meshResId
protected

◆ meshResource

Resources::ResourceId Models::ParticleSystemNode::meshResource
protected

◆ primGroupIndex

IndexT Models::ParticleSystemNode::primGroupIndex
protected

◆ sampleBuffer

Particles::EnvelopeSampleBuffer Models::ParticleSystemNode::sampleBuffer
protected

◆ tag

Util::StringAtom Models::ParticleSystemNode::tag
protected

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