Checked in osgParticle, writtten by Marco Jez.
This commit is contained in:
3
AUTHORS
3
AUTHORS
@@ -45,6 +45,9 @@ Ben Discoe <ben@vterrain.org>
|
||||
- png plugin.
|
||||
- fixes to OBJ plugin.
|
||||
|
||||
Maroc Jez <marco.jez@arsenal.it>
|
||||
- osgParticle
|
||||
|
||||
Byan Woods <byran@tapestrysolutions.com>
|
||||
- Port to MacOS, various code changes to support this.
|
||||
- Metrowerks CodeWarrior makefiles.
|
||||
|
||||
@@ -11,6 +11,7 @@ SRC_DIRS = \
|
||||
osgUtil\
|
||||
osgDB\
|
||||
osgGA\
|
||||
osgParticle\
|
||||
osgGLUT\
|
||||
osgPlugins\
|
||||
osgText\
|
||||
@@ -74,6 +75,7 @@ DEMOS_DIRS = \
|
||||
osgcube\
|
||||
osghud\
|
||||
osgimpostor\
|
||||
osgparticle\
|
||||
osgreflect\
|
||||
osgscribe\
|
||||
osgstereoimage\
|
||||
|
||||
95
VisualStudio/Demos/osgparticle/osgparticle.dsp
Normal file
95
VisualStudio/Demos/osgparticle/osgparticle.dsp
Normal file
@@ -0,0 +1,95 @@
|
||||
# Microsoft Developer Studio Project File - Name="Demo osgparticle" - Package Owner=<4>
|
||||
# Microsoft Developer Studio Generated Build File, Format Version 6.00
|
||||
# ** DO NOT EDIT **
|
||||
|
||||
# TARGTYPE "Win32 (x86) Console Application" 0x0103
|
||||
|
||||
CFG=Demo osgparticle - Win32 Release
|
||||
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
|
||||
!MESSAGE use the Export Makefile command and run
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "osgparticle.mak".
|
||||
!MESSAGE
|
||||
!MESSAGE You can specify a configuration when running NMAKE
|
||||
!MESSAGE by defining the macro CFG on the command line. For example:
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "osgparticle.mak" CFG="Demo osgparticle - Win32 Release"
|
||||
!MESSAGE
|
||||
!MESSAGE Possible choices for configuration are:
|
||||
!MESSAGE
|
||||
!MESSAGE "Demo osgparticle - Win32 Release" (based on "Win32 (x86) Console Application")
|
||||
!MESSAGE "Demo osgparticle - Win32 Debug" (based on "Win32 (x86) Console Application")
|
||||
!MESSAGE
|
||||
|
||||
# Begin Project
|
||||
# PROP AllowPerConfigDependencies 0
|
||||
# PROP Scc_ProjName ""
|
||||
# PROP Scc_LocalPath ""
|
||||
CPP=cl.exe
|
||||
RSC=rc.exe
|
||||
|
||||
!IF "$(CFG)" == "Demo osgparticle - Win32 Release"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Use_Debug_Libraries 0
|
||||
# PROP BASE Output_Dir "Release"
|
||||
# PROP BASE Intermediate_Dir "Release"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Use_Debug_Libraries 0
|
||||
# PROP Output_Dir "Release"
|
||||
# PROP Intermediate_Dir "Release"
|
||||
# PROP Ignore_Export_Lib 0
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
|
||||
# ADD CPP /nologo /MD /W3 /GR /GX /O2 /I "../../../include" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
|
||||
# ADD BASE RSC /l 0x809 /d "NDEBUG"
|
||||
# ADD RSC /l 0x809 /d "NDEBUG"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LINK32=link.exe
|
||||
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
|
||||
# ADD LINK32 /nologo /subsystem:console /pdb:none /machine:I386 /out:"../../../bin/osgparticle.exe" /libpath:"../../../lib"
|
||||
|
||||
!ELSEIF "$(CFG)" == "Demo osgparticle - Win32 Debug"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Use_Debug_Libraries 1
|
||||
# PROP BASE Output_Dir "Debug"
|
||||
# PROP BASE Intermediate_Dir "Debug"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Use_Debug_Libraries 1
|
||||
# PROP Output_Dir "Debug"
|
||||
# PROP Intermediate_Dir "Debug"
|
||||
# PROP Ignore_Export_Lib 0
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
|
||||
# ADD CPP /nologo /MDd /W3 /Gm /vd0 /GR /GX /Zi /Od /I "../../../include" /D "_CONSOLE" /D "_MBCS" /D "FL_DLL" /D "WIN32" /D "_DEBUG" /FR /YX /FD /c
|
||||
# ADD BASE RSC /l 0x809 /d "_DEBUG"
|
||||
# ADD RSC /l 0x809 /d "_DEBUG"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LINK32=link.exe
|
||||
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
|
||||
# ADD LINK32 glut32.lib glu32.lib opengl32.lib /nologo /subsystem:console /debug /machine:I386 /nodefaultlib:"libcmt" /out:"../../../bin/osgparticled.exe" /pdbtype:sept /libpath:"../../../lib"
|
||||
# SUBTRACT LINK32 /incremental:no
|
||||
|
||||
!ENDIF
|
||||
|
||||
# Begin Target
|
||||
|
||||
# Name "Demo osgparticle - Win32 Release"
|
||||
# Name "Demo osgparticle - Win32 Debug"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\..\src\Demos\osgparticle\osgparticle.cpp
|
||||
# End Source File
|
||||
# End Target
|
||||
# Begin Group "Resource Files"
|
||||
|
||||
# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
|
||||
# End Group
|
||||
# End Project
|
||||
@@ -182,6 +182,42 @@ Package=<4>
|
||||
|
||||
|
||||
|
||||
Project: "Core osgParticle"=.\osgParticle\osgParticle.dsp - Package Owner=<4>
|
||||
|
||||
|
||||
|
||||
Package=<5>
|
||||
|
||||
{{{
|
||||
|
||||
}}}
|
||||
|
||||
|
||||
|
||||
Package=<4>
|
||||
|
||||
{{{
|
||||
|
||||
Begin Project Dependency
|
||||
|
||||
Project_Dep_Name Core osg
|
||||
|
||||
End Project Dependency
|
||||
|
||||
Begin Project Dependency
|
||||
|
||||
Project_Dep_Name Core osgDB
|
||||
|
||||
End Project Dependency
|
||||
|
||||
}}}
|
||||
|
||||
|
||||
|
||||
###############################################################################
|
||||
|
||||
|
||||
|
||||
Project: "Core osgUtil"=.\osgUtil\osgUtil.dsp - Package Owner=<4>
|
||||
|
||||
|
||||
@@ -1106,6 +1142,66 @@ Package=<4>
|
||||
|
||||
|
||||
|
||||
Project: "Demo sgv"=.\Demos\sgv\sgv.dsp - Package Owner=<4>
|
||||
|
||||
|
||||
|
||||
Package=<5>
|
||||
|
||||
{{{
|
||||
|
||||
}}}
|
||||
|
||||
|
||||
|
||||
Package=<4>
|
||||
|
||||
{{{
|
||||
|
||||
Begin Project Dependency
|
||||
|
||||
Project_Dep_Name Core osg
|
||||
|
||||
End Project Dependency
|
||||
|
||||
Begin Project Dependency
|
||||
|
||||
Project_Dep_Name Core osgDB
|
||||
|
||||
End Project Dependency
|
||||
|
||||
Begin Project Dependency
|
||||
|
||||
Project_Dep_Name Core osgGA
|
||||
|
||||
End Project Dependency
|
||||
|
||||
Begin Project Dependency
|
||||
|
||||
Project_Dep_Name Core osgParticle
|
||||
|
||||
End Project Dependency
|
||||
|
||||
Begin Project Dependency
|
||||
|
||||
Project_Dep_Name Core osgGLUT
|
||||
|
||||
End Project Dependency
|
||||
|
||||
Begin Project Dependency
|
||||
|
||||
Project_Dep_Name Core osgUtil
|
||||
|
||||
End Project Dependency
|
||||
|
||||
}}}
|
||||
|
||||
|
||||
|
||||
###############################################################################
|
||||
|
||||
|
||||
|
||||
Project: "osgPlugin 3ds"=.\osgPlugins\lib3ds\lib3ds.dsp - Package Owner=<4>
|
||||
|
||||
|
||||
|
||||
680
VisualStudio/osgParticle/osgParticle.dsp
Normal file
680
VisualStudio/osgParticle/osgParticle.dsp
Normal file
@@ -0,0 +1,680 @@
|
||||
# Microsoft Developer Studio Project File - Name="Core osgParticle" - Package Owner=<4>
|
||||
|
||||
# Microsoft Developer Studio Generated Build File, Format Version 6.00
|
||||
|
||||
# ** DO NOT EDIT **
|
||||
|
||||
|
||||
|
||||
# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
|
||||
|
||||
|
||||
|
||||
CFG=Core osgParticle - Win32 Release
|
||||
|
||||
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
|
||||
|
||||
!MESSAGE use the Export Makefile command and run
|
||||
|
||||
!MESSAGE
|
||||
|
||||
!MESSAGE NMAKE /f "osgParticle.mak".
|
||||
|
||||
!MESSAGE
|
||||
|
||||
!MESSAGE You can specify a configuration when running NMAKE
|
||||
|
||||
!MESSAGE by defining the macro CFG on the command line. For example:
|
||||
|
||||
!MESSAGE
|
||||
|
||||
!MESSAGE NMAKE /f "osgParticle.mak" CFG="Core osgParticle - Win32 Release"
|
||||
|
||||
!MESSAGE
|
||||
|
||||
!MESSAGE Possible choices for configuration are:
|
||||
|
||||
!MESSAGE
|
||||
|
||||
!MESSAGE "Core osgParticle - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
|
||||
|
||||
!MESSAGE "Core osgParticle - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
|
||||
|
||||
!MESSAGE
|
||||
|
||||
|
||||
|
||||
# Begin Project
|
||||
|
||||
# PROP AllowPerConfigDependencies 0
|
||||
|
||||
# PROP Scc_ProjName ""
|
||||
|
||||
# PROP Scc_LocalPath ""
|
||||
|
||||
CPP=cl.exe
|
||||
|
||||
MTL=midl.exe
|
||||
|
||||
RSC=rc.exe
|
||||
|
||||
|
||||
|
||||
!IF "$(CFG)" == "Core osgParticle - Win32 Release"
|
||||
|
||||
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
|
||||
# PROP BASE Use_Debug_Libraries 0
|
||||
|
||||
# PROP BASE Output_Dir "../../lib"
|
||||
|
||||
# PROP BASE Intermediate_Dir "Release"
|
||||
|
||||
# PROP BASE Target_Dir ""
|
||||
|
||||
# PROP Use_MFC 0
|
||||
|
||||
# PROP Use_Debug_Libraries 0
|
||||
|
||||
# PROP Output_Dir "../../lib"
|
||||
|
||||
# PROP Intermediate_Dir "Release"
|
||||
|
||||
# PROP Ignore_Export_Lib 0
|
||||
|
||||
# PROP Target_Dir ""
|
||||
|
||||
# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "FTGL_LIBRARY_STATIC" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /YX /FD /c
|
||||
|
||||
# ADD CPP /nologo /MD /W3 /GR /GX /O2 /I "../../include" /D "NDEBUG" /D "_MBCS" /D "_USRDLL" /D "osgParticle_LIBRARY" /D "FTGL_LIBRARY_STATIC" /D "WIN32" /D "_WINDOWS" /YX /FD /c
|
||||
|
||||
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
|
||||
|
||||
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
|
||||
|
||||
# ADD BASE RSC /l 0x809 /d "NDEBUG"
|
||||
|
||||
# ADD RSC /l 0x809 /d "NDEBUG"
|
||||
|
||||
BSC32=bscmake.exe
|
||||
|
||||
# ADD BASE BSC32 /nologo
|
||||
|
||||
# ADD BSC32 /nologo
|
||||
|
||||
LINK32=link.exe
|
||||
|
||||
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
|
||||
|
||||
# ADD LINK32 glu32.lib opengl32.lib /nologo /dll /pdb:none /machine:I386 /out:"../../bin/osgParticle.dll" /libpath:"../../lib"
|
||||
|
||||
|
||||
|
||||
!ELSEIF "$(CFG)" == "Core osgParticle - Win32 Debug"
|
||||
|
||||
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
|
||||
# PROP BASE Use_Debug_Libraries 1
|
||||
|
||||
# PROP BASE Output_Dir "Debug"
|
||||
|
||||
# PROP BASE Intermediate_Dir "Debug"
|
||||
|
||||
# PROP BASE Target_Dir ""
|
||||
|
||||
# PROP Use_MFC 0
|
||||
|
||||
# PROP Use_Debug_Libraries 1
|
||||
|
||||
# PROP Output_Dir "../../lib"
|
||||
|
||||
# PROP Intermediate_Dir "Debug"
|
||||
|
||||
# PROP Ignore_Export_Lib 0
|
||||
|
||||
# PROP Target_Dir ""
|
||||
|
||||
# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "FTGL_LIBRARY_STATIC" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /YX /FD /GZ /c
|
||||
|
||||
# ADD CPP /nologo /MDd /W3 /Gm /vmg /vd0 /GR /GX /Zi /Od /I "../../include" /D "osgParticle_LIBRARY" /D "FTGL_LIBRARY_STATIC" /D "_WINDOWS" /D "WIN32" /D "_DEBUG" /YX /FD /GZ /c
|
||||
|
||||
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
|
||||
|
||||
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
|
||||
|
||||
# ADD BASE RSC /l 0x809 /d "_DEBUG"
|
||||
|
||||
# ADD RSC /l 0x809 /d "_DEBUG"
|
||||
|
||||
BSC32=bscmake.exe
|
||||
|
||||
# ADD BASE BSC32 /nologo
|
||||
|
||||
# ADD BSC32 /nologo
|
||||
|
||||
LINK32=link.exe
|
||||
|
||||
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
|
||||
|
||||
# ADD LINK32 glu32.lib opengl32.lib /nologo /dll /debug /machine:I386 /out:"../../bin/osgParticled.dll" /pdbtype:sept /libpath:"../../lib"
|
||||
|
||||
# SUBTRACT LINK32 /pdb:none
|
||||
|
||||
|
||||
|
||||
!ENDIF
|
||||
|
||||
|
||||
|
||||
# Begin Target
|
||||
|
||||
|
||||
|
||||
# Name "Core osgParticle - Win32 Release"
|
||||
|
||||
# Name "Core osgParticle - Win32 Debug"
|
||||
|
||||
# Begin Group "Source Files"
|
||||
|
||||
|
||||
|
||||
# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\Emitter.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\FluidFrictionOperator.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_AccelOperator.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_CenteredPlacer.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_Emitter.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_FluidFrictionOperator.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_ForceOperator.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_LinearInterpolator.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_ModularEmitter.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_ModularProgram.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_MultiSegmentPlacer.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_Particle.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_ParticleProcessor.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_ParticleSystem.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_ParticleSystemUpdater.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_PointPlacer.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_Program.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_RadialShooter.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_RandomRateCounter.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_SectorPlacer.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_SegmentPlacer.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\IO_VariableRateCounter.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\ModularEmitter.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\ModularProgram.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\MultiSegmentPlacer.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\Particle.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\ParticleProcessor.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\ParticleSystem.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\ParticleSystemUpdater.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\Program.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\src\osgParticle\Version.cpp
|
||||
|
||||
# End Source File
|
||||
|
||||
# End Group
|
||||
|
||||
# Begin Group "Header Files"
|
||||
|
||||
|
||||
|
||||
# PROP Default_Filter ";h;hpp;hxx;hm;inl"
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\AccelOperator
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\CenteredPlacer
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\Counter
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\Emitter
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\Export
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\FluidFrictionOperator
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\ForceOperator
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\Interpolator
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\LinearInterpolator
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\ModularEmitter
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\ModularProgram
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\MultiSegmentPlacer
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\Operator
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\Particle
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\ParticleProcessor
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\ParticleSystem
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\ParticleSystemUpdater
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\Placer
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\PointPlacer
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\Program
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\RadialShooter
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\RandomRateCounter
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\SectorPlacer
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\SegmentPlacer
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\Shooter
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\VariableRateCounter
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\Version
|
||||
|
||||
# End Source File
|
||||
|
||||
# Begin Source File
|
||||
|
||||
|
||||
|
||||
SOURCE=..\..\include\osgParticle\range
|
||||
|
||||
# End Source File
|
||||
|
||||
# End Group
|
||||
|
||||
# Begin Group "Resource Files"
|
||||
|
||||
|
||||
|
||||
# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
|
||||
|
||||
# End Group
|
||||
|
||||
# End Target
|
||||
|
||||
# End Project
|
||||
|
||||
132
doc/doc++/osgParticle/AccelOperator.html
Normal file
132
doc/doc++/osgParticle/AccelOperator.html
Normal file
@@ -0,0 +1,132 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::AccelOperator</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::AccelOperator</A></H2></H2><BLOCKQUOTE>An operator class that applies a constant acceleration to the particles</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=95>
|
||||
<param name=classes value="Mosg::Object,M,COperator,MOperator.html,CAccelOperator,MAccelOperator.html">
|
||||
<param name=before value="M,M,M">
|
||||
<param name=after value="Md_SP,Md_,M">
|
||||
<param name=indent value="0,1,2">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.1.1">META_Object</A></B>(<!1><A HREF="AccelOperator.html">AccelOperator</A>)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.1.6">AccelOperator</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.1.7">AccelOperator</A></B>(const <!1><A HREF="AccelOperator.html#DOC.2.1.7">AccelOperator</A> &copy, const osg::CopyOp &copyop)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const osg::Vec3& <B><A HREF="#DOC.2.1.8">getAcceleration</A></B>() const
|
||||
<DD><I>Get the acceleration vector</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.1.9">setAcceleration</A></B>(const osg::Vec3 &v)
|
||||
<DD><I>Set the acceleration vector</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.1.10">setToGravity</A></B>(float scale)
|
||||
<DD><I>Quickly set the acceleration vector to the gravity on earth (0, 0, -981).</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.1.11">operate</A></B>(<!1><A HREF="Particle.html">Particle</A>* P, double dt)
|
||||
<DD><I>Apply the acceleration to a particle.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.1.12">beginOperate</A></B>(<!1><A HREF="Program.html">Program</A>* prg)
|
||||
<DD><I>Perform some initializations.</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.1.2">~AccelOperator</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="AccelOperator.html">AccelOperator</A>& <B><A HREF="#DOC.2.1.3">operator=</A></B>(const <!1><A HREF="AccelOperator.html">AccelOperator</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="Operator.html">Operator</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual const char* <B>className</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual bool <B>isSameKindAs</B>(const osg::Object* obj) const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual void <B>endOperate</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline bool <B>isEnabled</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setEnabled</B>(bool v)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>An operator class that applies a constant acceleration to the particles</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="META_Object"></A>
|
||||
<A NAME="DOC.2.1.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> META_Object(<!1><A HREF="AccelOperator.html">AccelOperator</A>)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~AccelOperator"></A>
|
||||
<A NAME="DOC.2.1.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~AccelOperator()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.1.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="AccelOperator.html">AccelOperator</A>& operator=(const <!1><A HREF="AccelOperator.html">AccelOperator</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="AccelOperator"></A>
|
||||
<A NAME="DOC.2.1.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline AccelOperator()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="AccelOperator"></A>
|
||||
<A NAME="DOC.2.1.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline AccelOperator(const <!1><A HREF="AccelOperator.html#DOC.2.1.7">AccelOperator</A> &copy, const osg::CopyOp &copyop)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getAcceleration"></A>
|
||||
<A NAME="DOC.2.1.8"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const osg::Vec3& getAcceleration() const </B></TT>
|
||||
<DD>Get the acceleration vector
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setAcceleration"></A>
|
||||
<A NAME="DOC.2.1.9"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setAcceleration(const osg::Vec3 &v)</B></TT>
|
||||
<DD>Set the acceleration vector
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setToGravity"></A>
|
||||
<A NAME="DOC.2.1.10"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setToGravity(float scale)</B></TT>
|
||||
<DD>Quickly set the acceleration vector to the gravity on earth (0, 0, -981).
|
||||
The acceleration will be multiplied by the <CODE>scale</CODE> parameter.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operate"></A>
|
||||
<A NAME="DOC.2.1.11"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void operate(<!1><A HREF="Particle.html">Particle</A>* P, double dt)</B></TT>
|
||||
<DD>Apply the acceleration to a particle. Do not call this method manually.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="beginOperate"></A>
|
||||
<A NAME="DOC.2.1.12"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void beginOperate(<!1><A HREF="Program.html">Program</A>* prg)</B></TT>
|
||||
<DD>Perform some initializations. Do not call this method manually.
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
115
doc/doc++/osgParticle/CenteredPlacer.html
Normal file
115
doc/doc++/osgParticle/CenteredPlacer.html
Normal file
@@ -0,0 +1,115 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::CenteredPlacer</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::CenteredPlacer</A></H2></H2><BLOCKQUOTE>An abstract placer base class for placers which need a <I>center point</I></BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=155>
|
||||
<param name=classes value="Mosg::Object,M,CPlacer,MPlacer.html,CCenteredPlacer,MCenteredPlacer.html,CSectorPlacer,MSectorPlacer.html,CPointPlacer,MPointPlacer.html">
|
||||
<param name=before value="M,M,M,M|_,Mr_">
|
||||
<param name=after value="Md_SP,Md_,M,M,M">
|
||||
<param name=indent value="0,1,2,2,2">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual const char* <B><A HREF="#DOC.2.2.1">className</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual bool <B><A HREF="#DOC.2.2.2">isSameKindAs</A></B>(const osg::Object* obj) const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.2.5">CenteredPlacer</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.2.6">CenteredPlacer</A></B>(const <!1><A HREF="CenteredPlacer.html#DOC.2.2.6">CenteredPlacer</A> &copy, const osg::CopyOp &copyop)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const osg::Vec3& <B><A HREF="#DOC.2.2.7">getCenter</A></B>() const
|
||||
<DD><I>Get the center point</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.2.8">setCenter</A></B>(const osg::Vec3 &v)
|
||||
<DD><I>Set the center point</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.2.9">setCenter</A></B>(float x, float y, float z)
|
||||
<DD><I>Set the center point</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.2.3">~CenteredPlacer</A></B>()
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="Placer.html">Placer</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual void <B>place</B>(<!1><A HREF="Particle.html">Particle</A>* P) const
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif><!1><A HREF="Placer.html">Placer</A>& <B>operator=</B>(const <!1><A HREF="Placer.html">Placer</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>An abstract placer base class for placers which need a <I>center point</I></BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="className"></A>
|
||||
<A NAME="DOC.2.2.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual const char* className() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="isSameKindAs"></A>
|
||||
<A NAME="DOC.2.2.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual bool isSameKindAs(const osg::Object* obj) const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~CenteredPlacer"></A>
|
||||
<A NAME="DOC.2.2.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~CenteredPlacer()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="CenteredPlacer"></A>
|
||||
<A NAME="DOC.2.2.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline CenteredPlacer()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="CenteredPlacer"></A>
|
||||
<A NAME="DOC.2.2.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline CenteredPlacer(const <!1><A HREF="CenteredPlacer.html#DOC.2.2.6">CenteredPlacer</A> &copy, const osg::CopyOp &copyop)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getCenter"></A>
|
||||
<A NAME="DOC.2.2.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const osg::Vec3& getCenter() const </B></TT>
|
||||
<DD>Get the center point
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setCenter"></A>
|
||||
<A NAME="DOC.2.2.8"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setCenter(const osg::Vec3 &v)</B></TT>
|
||||
<DD>Set the center point
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setCenter"></A>
|
||||
<A NAME="DOC.2.2.9"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setCenter(float x, float y, float z)</B></TT>
|
||||
<DD>Set the center point
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
<HR>
|
||||
<DL><DT><B>Direct child classes:
|
||||
</B><DD><A HREF="SectorPlacer.html">SectorPlacer</A><BR>
|
||||
<A HREF="PointPlacer.html">PointPlacer</A><BR>
|
||||
</DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
BIN
doc/doc++/osgParticle/ClassGraph.class
Normal file
BIN
doc/doc++/osgParticle/ClassGraph.class
Normal file
Binary file not shown.
BIN
doc/doc++/osgParticle/ClassGraphPanel.class
Normal file
BIN
doc/doc++/osgParticle/ClassGraphPanel.class
Normal file
Binary file not shown.
BIN
doc/doc++/osgParticle/ClassLayout.class
Normal file
BIN
doc/doc++/osgParticle/ClassLayout.class
Normal file
Binary file not shown.
87
doc/doc++/osgParticle/Counter.html
Normal file
87
doc/doc++/osgParticle/Counter.html
Normal file
@@ -0,0 +1,87 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::Counter</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::Counter</A></H2></H2><HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=95>
|
||||
<param name=classes value="Mosg::Object,M,CCounter,MCounter.html,CVariableRateCounter,MVariableRateCounter.html">
|
||||
<param name=before value="M,M,M^_">
|
||||
<param name=after value="Md_,M,M">
|
||||
<param name=indent value="0,1,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual const char* <B><A HREF="#DOC.2.3.1">className</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual bool <B><A HREF="#DOC.2.3.2">isSameKindAs</A></B>(const osg::Object* obj) const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual int <B><A HREF="#DOC.2.3.3">numParticlesToCreate</A></B>(double dt) const = 0
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.3.6">Counter</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.3.7">Counter</A></B>(const <!1><A HREF="Counter.html#DOC.2.3.7">Counter</A> &copy, const osg::CopyOp &copyop)
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.3.4">~Counter</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="Counter.html">Counter</A>& <B><A HREF="#DOC.2.3.5">operator=</A></B>(const <!1><A HREF="Counter.html">Counter</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<DL>
|
||||
|
||||
<A NAME="className"></A>
|
||||
<A NAME="DOC.2.3.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual const char* className() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="isSameKindAs"></A>
|
||||
<A NAME="DOC.2.3.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual bool isSameKindAs(const osg::Object* obj) const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="numParticlesToCreate"></A>
|
||||
<A NAME="DOC.2.3.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual int numParticlesToCreate(double dt) const = 0</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~Counter"></A>
|
||||
<A NAME="DOC.2.3.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> ~Counter()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.3.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="Counter.html">Counter</A>& operator=(const <!1><A HREF="Counter.html">Counter</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="Counter"></A>
|
||||
<A NAME="DOC.2.3.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline Counter()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="Counter"></A>
|
||||
<A NAME="DOC.2.3.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline Counter(const <!1><A HREF="Counter.html#DOC.2.3.7">Counter</A> &copy, const osg::CopyOp &copyop)</B></TT>
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
<HR>
|
||||
<DL><DT><B>Direct child classes:
|
||||
</B><DD><A HREF="VariableRateCounter.html">VariableRateCounter</A><BR>
|
||||
</DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
181
doc/doc++/osgParticle/Emitter.html
Normal file
181
doc/doc++/osgParticle/Emitter.html
Normal file
@@ -0,0 +1,181 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class OSGPARTICLE_EXPORT osgParticle::Emitter</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class OSGPARTICLE_EXPORT <A HREF="#DOC.DOCU">osgParticle::Emitter</A></H2></H2><BLOCKQUOTE>An abstract base class for particle emitters.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=125>
|
||||
<param name=classes value="Mosg::Node,M,CParticleProcessor,MParticleProcessor.html,CEmitter,MEmitter.html,CModularEmitter,MModularEmitter.html">
|
||||
<param name=before value="M,M,M,M^_">
|
||||
<param name=after value="Md_SP,Md_,M,M">
|
||||
<param name=indent value="0,1,2,2">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.4.1">Emitter</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.4.2">Emitter</A></B>(const <!1><A HREF="Emitter.html#DOC.2.4.2">Emitter</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual const char* <B><A HREF="#DOC.2.4.3">className</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual bool <B><A HREF="#DOC.2.4.4">isSameKindAs</A></B>(const osg::Object* obj)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual void <B><A HREF="#DOC.2.4.5">accept</A></B>(osg::NodeVisitor& nv)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="Particle.html">Particle</A>& <B><A HREF="#DOC.2.4.11">getParticleTemplate</A></B>() const
|
||||
<DD><I>Get the particle template</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.4.12">setParticleTemplate</A></B>(const <!1><A HREF="Particle.html">Particle</A> &p)
|
||||
<DD><I>Set the particle template (particle is copied)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline bool <B><A HREF="#DOC.2.4.13">getUseDefaultTemplate</A></B>() const
|
||||
<DD><I>Return whether the particle system's default template should be used</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.4.14">setUseDefaultTemplate</A></B>(bool v)
|
||||
<DD><I>Set whether the default particle template should be used.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.4.15">process</A></B>(double dt)
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.4.6">~Emitter</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="Emitter.html">Emitter</A>& <B><A HREF="#DOC.2.4.7">operator=</A></B>(const <!1><A HREF="Emitter.html">Emitter</A> &)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual void <B><A HREF="#DOC.2.4.8">emit</A></B>(double dt) = 0
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="ParticleProcessor.html">ParticleProcessor</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline <!1><A HREF="ParticleProcessor.html#DOC.2.14.1">ReferenceFrame</A> <B>getReferenceFrame</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>void <B>traverse</B>(osg::NodeVisitor &nv)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline ParticleProcessor::ReferenceFrame <B>getReferenceFrame</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setReferenceFrame</B>(<!1><A HREF="ParticleProcessor.html#DOC.2.14.1">ReferenceFrame</A> rf)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline bool <B>isEnabled</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setEnabled</B>(bool v)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* <B>getParticleSystem</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* <B>getParticleSystem</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setParticleSystem</B>(<!1><A HREF="ParticleSystem.html">ParticleSystem</A>* ps)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const bool <B>computeBound</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const osg::Matrix& <B>getLocalToWorldMatrix</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const osg::Matrix& <B>getWorldToLocalMatrix</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>transformLocalToWorld</B>(const osg::Vec3 &P)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>transformWorldToLocal</B>(const osg::Vec3 &P)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>rotateLocalToWorld</B>(const osg::Vec3 &P)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>rotateWorldToLocal</B>(const osg::Vec3 &P)
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Public Members</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>enum <B>ReferenceFrame</B>
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>An abstract base class for particle emitters.
|
||||
Descendant classes must override the <CODE>emit()</CODE> method to generate new particles by
|
||||
calling the <CODE>ParticleSystem::createParticle()</CODE> method on the particle system associated
|
||||
to the emitter.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="Emitter"></A>
|
||||
<A NAME="DOC.2.4.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> Emitter()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="Emitter"></A>
|
||||
<A NAME="DOC.2.4.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> Emitter(const <!1><A HREF="Emitter.html#DOC.2.4.2">Emitter</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="className"></A>
|
||||
<A NAME="DOC.2.4.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual const char* className() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="isSameKindAs"></A>
|
||||
<A NAME="DOC.2.4.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual bool isSameKindAs(const osg::Object* obj)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="accept"></A>
|
||||
<A NAME="DOC.2.4.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual void accept(osg::NodeVisitor& nv)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~Emitter"></A>
|
||||
<A NAME="DOC.2.4.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~Emitter()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.4.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="Emitter.html">Emitter</A>& operator=(const <!1><A HREF="Emitter.html">Emitter</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="emit"></A>
|
||||
<A NAME="DOC.2.4.8"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual void emit(double dt) = 0</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getParticleTemplate"></A>
|
||||
<A NAME="DOC.2.4.11"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="Particle.html">Particle</A>& getParticleTemplate() const </B></TT>
|
||||
<DD>Get the particle template
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setParticleTemplate"></A>
|
||||
<A NAME="DOC.2.4.12"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setParticleTemplate(const <!1><A HREF="Particle.html">Particle</A> &p)</B></TT>
|
||||
<DD>Set the particle template (particle is copied)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getUseDefaultTemplate"></A>
|
||||
<A NAME="DOC.2.4.13"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline bool getUseDefaultTemplate() const </B></TT>
|
||||
<DD>Return whether the particle system's default template should be used
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setUseDefaultTemplate"></A>
|
||||
<A NAME="DOC.2.4.14"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setUseDefaultTemplate(bool v)</B></TT>
|
||||
<DD>Set whether the default particle template should be used.
|
||||
When this flag is true, the particle template is ignored, and the
|
||||
particle system's default template is used instead.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="process"></A>
|
||||
<A NAME="DOC.2.4.15"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void process(double dt)</B></TT>
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
<HR>
|
||||
<DL><DT><B>Direct child classes:
|
||||
</B><DD><A HREF="ModularEmitter.html">ModularEmitter</A><BR>
|
||||
</DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
175
doc/doc++/osgParticle/FluidFrictionOperator.html
Normal file
175
doc/doc++/osgParticle/FluidFrictionOperator.html
Normal file
@@ -0,0 +1,175 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class OSGPARTICLE_EXPORT osgParticle::FluidFrictionOperator</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class OSGPARTICLE_EXPORT <A HREF="#DOC.DOCU">osgParticle::FluidFrictionOperator</A></H2></H2><BLOCKQUOTE>An operator that simulates the friction of a fluid.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=95>
|
||||
<param name=classes value="Mosg::Object,M,COperator,MOperator.html,CFluidFrictionOperator,MFluidFrictionOperator.html">
|
||||
<param name=before value="M,M,M">
|
||||
<param name=after value="Md_SP,Md_,M">
|
||||
<param name=indent value="0,1,2">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.5.1">FluidFrictionOperator</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.5.2">FluidFrictionOperator</A></B>(const <!1><A HREF="FluidFrictionOperator.html#DOC.2.5.2">FluidFrictionOperator</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.5.3">META_Object</A></B>(<!1><A HREF="FluidFrictionOperator.html">FluidFrictionOperator</A>)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>void <B><A HREF="#DOC.2.5.4">operate</A></B>(<!1><A HREF="Particle.html">Particle</A>* P, double dt)
|
||||
<DD><I>Apply the friction forces to a particle.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline float <B><A HREF="#DOC.2.5.13">getFluidDensity</A></B>() const
|
||||
<DD><I>Get the density of the fluid</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline float <B><A HREF="#DOC.2.5.14">getFluidViscosity</A></B>() const
|
||||
<DD><I>Get the viscosity of the fluid</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.5.15">setFluidDensity</A></B>(float d)
|
||||
<DD><I>Set the density of the fluid</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.5.16">setFluidViscosity</A></B>(float v)
|
||||
<DD><I>Set the viscosity of the fluid</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.5.17">setFluidToAir</A></B>()
|
||||
<DD><I>Set the fluid parameters as for air (20<32>C temperature)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.5.18">setFluidToWater</A></B>()
|
||||
<DD><I>Set the fluid parameters as for pure water (20<32>C temperature)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline float <B><A HREF="#DOC.2.5.19">getOverrideRadius</A></B>() const
|
||||
<DD><I>Get the overriden radius value</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.5.20">setOverrideRadius</A></B>(float r)
|
||||
<DD><I>Set the overriden radius value (pass 0 if you want to use particle's radius)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.5.21">beginOperate</A></B>(<!1><A HREF="Program.html">Program</A>* prg)
|
||||
<DD><I>Perform some initializations.</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.5.5">~FluidFrictionOperator</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="FluidFrictionOperator.html">FluidFrictionOperator</A>& <B><A HREF="#DOC.2.5.6">operator=</A></B>(const <!1><A HREF="FluidFrictionOperator.html">FluidFrictionOperator</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="Operator.html">Operator</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual const char* <B>className</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual bool <B>isSameKindAs</B>(const osg::Object* obj) const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual void <B>endOperate</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline bool <B>isEnabled</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setEnabled</B>(bool v)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>An operator that simulates the friction of a fluid.
|
||||
By using this operator you can let the particles move in a fluid of a given <I>density</I>
|
||||
and <I>viscosity</I>. There are two functions to quickly setup the parameters for pure water
|
||||
and air. You can decide whether to compute the forces using the particle's physical
|
||||
radius or another value, by calling the <CODE>setOverrideRadius()</CODE> method.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="FluidFrictionOperator"></A>
|
||||
<A NAME="DOC.2.5.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> FluidFrictionOperator()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="FluidFrictionOperator"></A>
|
||||
<A NAME="DOC.2.5.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> FluidFrictionOperator(const <!1><A HREF="FluidFrictionOperator.html#DOC.2.5.2">FluidFrictionOperator</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="META_Object"></A>
|
||||
<A NAME="DOC.2.5.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> META_Object(<!1><A HREF="FluidFrictionOperator.html">FluidFrictionOperator</A>)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operate"></A>
|
||||
<A NAME="DOC.2.5.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>void operate(<!1><A HREF="Particle.html">Particle</A>* P, double dt)</B></TT>
|
||||
<DD>Apply the friction forces to a particle. Do not call this method manually.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~FluidFrictionOperator"></A>
|
||||
<A NAME="DOC.2.5.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~FluidFrictionOperator()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.5.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="FluidFrictionOperator.html">FluidFrictionOperator</A>& operator=(const <!1><A HREF="FluidFrictionOperator.html">FluidFrictionOperator</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getFluidDensity"></A>
|
||||
<A NAME="DOC.2.5.13"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline float getFluidDensity() const </B></TT>
|
||||
<DD>Get the density of the fluid
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getFluidViscosity"></A>
|
||||
<A NAME="DOC.2.5.14"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline float getFluidViscosity() const </B></TT>
|
||||
<DD>Get the viscosity of the fluid
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setFluidDensity"></A>
|
||||
<A NAME="DOC.2.5.15"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setFluidDensity(float d)</B></TT>
|
||||
<DD>Set the density of the fluid
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setFluidViscosity"></A>
|
||||
<A NAME="DOC.2.5.16"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setFluidViscosity(float v)</B></TT>
|
||||
<DD>Set the viscosity of the fluid
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setFluidToAir"></A>
|
||||
<A NAME="DOC.2.5.17"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setFluidToAir()</B></TT>
|
||||
<DD>Set the fluid parameters as for air (20<32>C temperature)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setFluidToWater"></A>
|
||||
<A NAME="DOC.2.5.18"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setFluidToWater()</B></TT>
|
||||
<DD>Set the fluid parameters as for pure water (20<32>C temperature)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getOverrideRadius"></A>
|
||||
<A NAME="DOC.2.5.19"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline float getOverrideRadius() const </B></TT>
|
||||
<DD>Get the overriden radius value
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setOverrideRadius"></A>
|
||||
<A NAME="DOC.2.5.20"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setOverrideRadius(float r)</B></TT>
|
||||
<DD>Set the overriden radius value (pass 0 if you want to use particle's radius)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="beginOperate"></A>
|
||||
<A NAME="DOC.2.5.21"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void beginOperate(<!1><A HREF="Program.html">Program</A>* prg)</B></TT>
|
||||
<DD>Perform some initializations. Do not call this method manually.
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
125
doc/doc++/osgParticle/ForceOperator.html
Normal file
125
doc/doc++/osgParticle/ForceOperator.html
Normal file
@@ -0,0 +1,125 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::ForceOperator</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::ForceOperator</A></H2></H2><BLOCKQUOTE>An operator that applies a constant force to the particles.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=95>
|
||||
<param name=classes value="Mosg::Object,M,COperator,MOperator.html,CForceOperator,MForceOperator.html">
|
||||
<param name=before value="M,M,M">
|
||||
<param name=after value="Md_SP,Md_,M">
|
||||
<param name=indent value="0,1,2">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.6.1">META_Object</A></B>(<!1><A HREF="ForceOperator.html">ForceOperator</A>)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.6.6">ForceOperator</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.6.7">ForceOperator</A></B>(const <!1><A HREF="ForceOperator.html#DOC.2.6.7">ForceOperator</A> &copy, const osg::CopyOp &copyop)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const osg::Vec3& <B><A HREF="#DOC.2.6.8">getForce</A></B>() const
|
||||
<DD><I>Get the force vector</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.6.9">setForce</A></B>(const osg::Vec3 &v)
|
||||
<DD><I>Set the force vector</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.6.10">operate</A></B>(<!1><A HREF="Particle.html">Particle</A>* P, double dt)
|
||||
<DD><I>Apply the force to a particle.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.6.11">beginOperate</A></B>(<!1><A HREF="Program.html">Program</A>* prg)
|
||||
<DD><I>Perform some initialization.</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.6.2">~ForceOperator</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="ForceOperator.html">ForceOperator</A>& <B><A HREF="#DOC.2.6.3">operator=</A></B>(const <!1><A HREF="ForceOperator.html">ForceOperator</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="Operator.html">Operator</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual const char* <B>className</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual bool <B>isSameKindAs</B>(const osg::Object* obj) const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual void <B>endOperate</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline bool <B>isEnabled</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setEnabled</B>(bool v)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>An operator that applies a constant force to the particles.
|
||||
Remember that if the mass of particles is expressed in <U>kg</U> and the lengths are
|
||||
expressed in <U>meters</U>, then the force should be expressed in <U>Newtons</U>.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="META_Object"></A>
|
||||
<A NAME="DOC.2.6.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> META_Object(<!1><A HREF="ForceOperator.html">ForceOperator</A>)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~ForceOperator"></A>
|
||||
<A NAME="DOC.2.6.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~ForceOperator()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.6.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="ForceOperator.html">ForceOperator</A>& operator=(const <!1><A HREF="ForceOperator.html">ForceOperator</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="ForceOperator"></A>
|
||||
<A NAME="DOC.2.6.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline ForceOperator()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="ForceOperator"></A>
|
||||
<A NAME="DOC.2.6.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline ForceOperator(const <!1><A HREF="ForceOperator.html#DOC.2.6.7">ForceOperator</A> &copy, const osg::CopyOp &copyop)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getForce"></A>
|
||||
<A NAME="DOC.2.6.8"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const osg::Vec3& getForce() const </B></TT>
|
||||
<DD>Get the force vector
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setForce"></A>
|
||||
<A NAME="DOC.2.6.9"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setForce(const osg::Vec3 &v)</B></TT>
|
||||
<DD>Set the force vector
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operate"></A>
|
||||
<A NAME="DOC.2.6.10"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void operate(<!1><A HREF="Particle.html">Particle</A>* P, double dt)</B></TT>
|
||||
<DD>Apply the force to a particle. Do not call this method manually.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="beginOperate"></A>
|
||||
<A NAME="DOC.2.6.11"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void beginOperate(<!1><A HREF="Program.html">Program</A>* prg)</B></TT>
|
||||
<DD>Perform some initialization. Do not call this method manually.
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
112
doc/doc++/osgParticle/General.html
Normal file
112
doc/doc++/osgParticle/General.html
Normal file
@@ -0,0 +1,112 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>General Bits</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<DL>
|
||||
<DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_ACCELOPERATOR_"></A>
|
||||
<B>OSGPARTICLE_ACCELOPERATOR_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_CENTEREDPLACER_"></A>
|
||||
<B>OSGPARTICLE_CENTEREDPLACER_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_COUNTER_"></A>
|
||||
<B>OSGPARTICLE_COUNTER_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_EMITTER_"></A>
|
||||
<B>OSGPARTICLE_EMITTER_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_EXPORT_"></A>
|
||||
<B>OSGPARTICLE_EXPORT_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_EXPORT"></A>
|
||||
<B>OSGPARTICLE_EXPORT</B>(dllexport)<DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_EXPORT"></A>
|
||||
<B>OSGPARTICLE_EXPORT</B>(dllimport)<DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_EXPORT"></A>
|
||||
<B>OSGPARTICLE_EXPORT</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_FLUIDFRICTIONOPERATOR_"></A>
|
||||
<B>OSGPARTICLE_FLUIDFRICTIONOPERATOR_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_FORCEOPERATOR_"></A>
|
||||
<B>OSGPARTICLE_FORCEOPERATOR_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_INTERPOLATOR_"></A>
|
||||
<B>OSGPARTICLE_INTERPOLATOR_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_LINEARINTERPOLATOR_"></A>
|
||||
<B>OSGPARTICLE_LINEARINTERPOLATOR_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_MODULAREMITTER_"></A>
|
||||
<B>OSGPARTICLE_MODULAREMITTER_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_MODULARPROGRAM_"></A>
|
||||
<B>OSGPARTICLE_MODULARPROGRAM_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_MULTISEGMENTPLACER_"></A>
|
||||
<B>OSGPARTICLE_MULTISEGMENTPLACER_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_OPERATOR_"></A>
|
||||
<B>OSGPARTICLE_OPERATOR_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_PARTICLE_"></A>
|
||||
<B>OSGPARTICLE_PARTICLE_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_PARTICLEPROCESSOR_"></A>
|
||||
<B>OSGPARTICLE_PARTICLEPROCESSOR_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_PARTICLESYSTEM_"></A>
|
||||
<B>OSGPARTICLE_PARTICLESYSTEM_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_PARTICLESYSTEMUPDATER_"></A>
|
||||
<B>OSGPARTICLE_PARTICLESYSTEMUPDATER_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_PLACER_"></A>
|
||||
<B>OSGPARTICLE_PLACER_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_POINTPLACER_"></A>
|
||||
<B>OSGPARTICLE_POINTPLACER_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_PROGRAM_"></A>
|
||||
<B>OSGPARTICLE_PROGRAM_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_RADIALSHOOTER_"></A>
|
||||
<B>OSGPARTICLE_RADIALSHOOTER_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_RANDOMRATECOUNTER_"></A>
|
||||
<B>OSGPARTICLE_RANDOMRATECOUNTER_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_RANGE_"></A>
|
||||
<B>OSGPARTICLE_RANGE_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_SEGMENTPLACER_"></A>
|
||||
<B>OSGPARTICLE_SEGMENTPLACER_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_SHOOTER_"></A>
|
||||
<B>OSGPARTICLE_SHOOTER_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_VARIABLERATECOUNTER_"></A>
|
||||
<B>OSGPARTICLE_VARIABLERATECOUNTER_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>#define<A NAME="OSGPARTICLE_VERSION_"></A>
|
||||
<B>OSGPARTICLE_VERSION_</B><DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>OSGPARTICLE_EXPORT const char*<A NAME="osgParticleGetVersion"></A>
|
||||
<B>osgParticleGetVersion</B>()<DT>
|
||||
|
||||
<IMG ALT="o" BORDER=0 SRC=icon1.gif>OSGPARTICLE_EXPORT const char*<A NAME="osgParticleGetLibraryName"></A>
|
||||
<B>osgParticleGetLibraryName</B>()</DL>
|
||||
<P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">Hierarchy of classes</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
61
doc/doc++/osgParticle/HIER.html
Normal file
61
doc/doc++/osgParticle/HIER.html
Normal file
@@ -0,0 +1,61 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>Hierarchy of Classes</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
<H1>Hierarchy of Classes</H1>
|
||||
<UL>
|
||||
|
||||
<LI><A HREF="Counter.html">osgParticle::Counter</A><UL>
|
||||
|
||||
<LI><A HREF="VariableRateCounter.html">osgParticle::VariableRateCounter</A><UL>
|
||||
|
||||
<LI><A HREF="RandomRateCounter.html">osgParticle::RandomRateCounter</A></UL>
|
||||
</UL>
|
||||
|
||||
<LI><A HREF="Interpolator.html">osgParticle::Interpolator</A><UL>
|
||||
|
||||
<LI><A HREF="LinearInterpolator.html">osgParticle::LinearInterpolator</A></UL>
|
||||
|
||||
<LI><A HREF="Operator.html">osgParticle::Operator</A><UL>
|
||||
|
||||
<LI><A HREF="AccelOperator.html">osgParticle::AccelOperator</A>
|
||||
<LI><A HREF="FluidFrictionOperator.html">osgParticle::FluidFrictionOperator</A>
|
||||
<LI><A HREF="ForceOperator.html">osgParticle::ForceOperator</A></UL>
|
||||
|
||||
<LI><A HREF="Particle.html">osgParticle::Particle</A>
|
||||
<LI><A HREF="ParticleProcessor.html">osgParticle::ParticleProcessor</A><UL>
|
||||
|
||||
<LI><A HREF="Emitter.html">osgParticle::Emitter</A><UL>
|
||||
|
||||
<LI><A HREF="ModularEmitter.html">osgParticle::ModularEmitter</A></UL>
|
||||
|
||||
<LI><A HREF="Program.html">osgParticle::Program</A><UL>
|
||||
|
||||
<LI><A HREF="ModularProgram.html">osgParticle::ModularProgram</A></UL>
|
||||
</UL>
|
||||
|
||||
<LI><A HREF="ParticleSystem.html">osgParticle::ParticleSystem</A>
|
||||
<LI><A HREF="ParticleSystemUpdater.html">osgParticle::ParticleSystemUpdater</A>
|
||||
<LI><A HREF="Placer.html">osgParticle::Placer</A><UL>
|
||||
|
||||
<LI><A HREF="CenteredPlacer.html">osgParticle::CenteredPlacer</A><UL>
|
||||
|
||||
<LI><A HREF="PointPlacer.html">osgParticle::PointPlacer</A>
|
||||
<LI><A HREF="SectorPlacer.html">osgParticle::SectorPlacer</A></UL>
|
||||
|
||||
<LI><A HREF="MultiSegmentPlacer.html">osgParticle::MultiSegmentPlacer</A>
|
||||
<LI><A HREF="SegmentPlacer.html">osgParticle::SegmentPlacer</A></UL>
|
||||
|
||||
<LI><A HREF="Shooter.html">osgParticle::Shooter</A><UL>
|
||||
|
||||
<LI><A HREF="RadialShooter.html">osgParticle::RadialShooter</A></UL>
|
||||
</UL>
|
||||
<P><I><A HREF="index.html">Alphabetic index</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
79
doc/doc++/osgParticle/HIERjava.html
Normal file
79
doc/doc++/osgParticle/HIERjava.html
Normal file
@@ -0,0 +1,79 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>Hierarchy of Classes</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
<H1>Hierarchy of classes</H1>
|
||||
<UL>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=125>
|
||||
<param name=classes value="Mosg::Object,M,CCounter,MCounter.html,CVariableRateCounter,MVariableRateCounter.html,CRandomRateCounter,MRandomRateCounter.html">
|
||||
<param name=before value="M,M,M^_,MSP^_">
|
||||
<param name=after value="Md_,M,M,M">
|
||||
<param name=indent value="0,1,1,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=95>
|
||||
<param name=classes value="Mosg::Object,M,CInterpolator,MInterpolator.html,CLinearInterpolator,MLinearInterpolator.html">
|
||||
<param name=before value="M,M,M^_">
|
||||
<param name=after value="Md_,M,M">
|
||||
<param name=indent value="0,1,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=155>
|
||||
<param name=classes value="Mosg::Object,M,COperator,MOperator.html,CForceOperator,MForceOperator.html,CFluidFrictionOperator,MFluidFrictionOperator.html,CAccelOperator,MAccelOperator.html">
|
||||
<param name=before value="M,M,M|_,MR_,Mr_">
|
||||
<param name=after value="Md_,M,M,M,M">
|
||||
<param name=indent value="0,1,1,1,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=35>
|
||||
<param name=classes value="CParticle,MParticle.html">
|
||||
<param name=before value="M">
|
||||
<param name=after value="M">
|
||||
<param name=indent value="0">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=185>
|
||||
<param name=classes value="Mosg::Node,M,CParticleProcessor,MParticleProcessor.html,CProgram,MProgram.html,CModularProgram,MModularProgram.html,CEmitter,MEmitter.html,CModularEmitter,MModularEmitter.html">
|
||||
<param name=before value="M,M,M|_,M||^_,Mr_,MSP^_">
|
||||
<param name=after value="Md_,M,M,M,M,M">
|
||||
<param name=indent value="0,1,1,1,1,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=65>
|
||||
<param name=classes value="Mosg::Drawable,M,CParticleSystem,MParticleSystem.html">
|
||||
<param name=before value="M,M">
|
||||
<param name=after value="Md_,M">
|
||||
<param name=indent value="0,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=65>
|
||||
<param name=classes value="Mosg::Node,M,CParticleSystemUpdater,MParticleSystemUpdater.html">
|
||||
<param name=before value="M,M">
|
||||
<param name=after value="Md_,M">
|
||||
<param name=indent value="0,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=215>
|
||||
<param name=classes value="Mosg::Object,M,CPlacer,MPlacer.html,CSegmentPlacer,MSegmentPlacer.html,CMultiSegmentPlacer,MMultiSegmentPlacer.html,CCenteredPlacer,MCenteredPlacer.html,CSectorPlacer,MSectorPlacer.html,CPointPlacer,MPointPlacer.html">
|
||||
<param name=before value="M,M,M|_,MR_,Mr_,MSP|_,MSPr_">
|
||||
<param name=after value="Md_,M,M,M,M,M,M">
|
||||
<param name=indent value="0,1,1,1,1,1,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=95>
|
||||
<param name=classes value="Mosg::Object,M,CShooter,MShooter.html,CRadialShooter,MRadialShooter.html">
|
||||
<param name=before value="M,M,M^_">
|
||||
<param name=after value="Md_,M,M">
|
||||
<param name=indent value="0,1,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
</UL>
|
||||
<I><A HREF="index.html"> alphabetic index</A></I><P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
115
doc/doc++/osgParticle/Interpolator.html
Normal file
115
doc/doc++/osgParticle/Interpolator.html
Normal file
@@ -0,0 +1,115 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::Interpolator</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::Interpolator</A></H2></H2><BLOCKQUOTE>An abstract base class for implementing interpolators</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=95>
|
||||
<param name=classes value="Mosg::Object,M,CInterpolator,MInterpolator.html,CLinearInterpolator,MLinearInterpolator.html">
|
||||
<param name=before value="M,M,M^_">
|
||||
<param name=after value="Md_,M,M">
|
||||
<param name=indent value="0,1,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.7.1">Interpolator</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.7.2">Interpolator</A></B>(const <!1><A HREF="Interpolator.html#DOC.2.7.2">Interpolator</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual const char* <B><A HREF="#DOC.2.7.3">className</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual bool <B><A HREF="#DOC.2.7.4">isSameKindAs</A></B>(const osg::Object* obj) const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual float <B><A HREF="#DOC.2.7.5">interpolate</A></B>(float t, float y1, float y2) const = 0
|
||||
<DD><I>Interpolate between floats.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual osg::Vec2 <B><A HREF="#DOC.2.7.6">interpolate</A></B>(float t, const osg::Vec2 &y1, const osg::Vec2 &y2) const
|
||||
<DD><I>Interpolate between 2-dimensional vectors.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual osg::Vec3 <B><A HREF="#DOC.2.7.7">interpolate</A></B>(float t, const osg::Vec3 &y1, const osg::Vec3 &y2) const
|
||||
<DD><I>Interpolate between 3-dimensional vectors.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual osg::Vec4 <B><A HREF="#DOC.2.7.8">interpolate</A></B>(float t, const osg::Vec4 &y1, const osg::Vec4 &y2) const
|
||||
<DD><I>Interpolate between 4-dimensional vectors.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>template<class T_> T_ <B><A HREF="#DOC.2.7.9">interpolate</A></B>(float t, const <!1><A HREF="range.html">range</A><T_> &r) const
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.7.10">~Interpolator</A></B>()
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>An abstract base class for implementing interpolators</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="Interpolator"></A>
|
||||
<A NAME="DOC.2.7.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> Interpolator()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="Interpolator"></A>
|
||||
<A NAME="DOC.2.7.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> Interpolator(const <!1><A HREF="Interpolator.html#DOC.2.7.2">Interpolator</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="className"></A>
|
||||
<A NAME="DOC.2.7.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual const char* className() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="isSameKindAs"></A>
|
||||
<A NAME="DOC.2.7.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual bool isSameKindAs(const osg::Object* obj) const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="interpolate"></A>
|
||||
<A NAME="DOC.2.7.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual float interpolate(float t, float y1, float y2) const = 0</B></TT>
|
||||
<DD>Interpolate between floats. Must be overriden in descendant classes.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="interpolate"></A>
|
||||
<A NAME="DOC.2.7.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual osg::Vec2 interpolate(float t, const osg::Vec2 &y1, const osg::Vec2 &y2) const </B></TT>
|
||||
<DD>Interpolate between 2-dimensional vectors. Default behavior is to interpolate each component separately.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="interpolate"></A>
|
||||
<A NAME="DOC.2.7.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual osg::Vec3 interpolate(float t, const osg::Vec3 &y1, const osg::Vec3 &y2) const </B></TT>
|
||||
<DD>Interpolate between 3-dimensional vectors. Default behavior is to interpolate each component separately.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="interpolate"></A>
|
||||
<A NAME="DOC.2.7.8"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual osg::Vec4 interpolate(float t, const osg::Vec4 &y1, const osg::Vec4 &y2) const </B></TT>
|
||||
<DD>Interpolate between 4-dimensional vectors. Default behavior is to interpolate each component separately.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="interpolate"></A>
|
||||
<A NAME="DOC.2.7.9"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>template<class T_> T_ interpolate(float t, const <!1><A HREF="range.html">range</A><T_> &r) const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~Interpolator"></A>
|
||||
<A NAME="DOC.2.7.10"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~Interpolator()</B></TT>
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
<HR>
|
||||
<DL><DT><B>Direct child classes:
|
||||
</B><DD><A HREF="LinearInterpolator.html">LinearInterpolator</A><BR>
|
||||
</DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
85
doc/doc++/osgParticle/LinearInterpolator.html
Normal file
85
doc/doc++/osgParticle/LinearInterpolator.html
Normal file
@@ -0,0 +1,85 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::LinearInterpolator</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::LinearInterpolator</A></H2></H2><BLOCKQUOTE>A linear interpolator</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=95>
|
||||
<param name=classes value="Mosg::Object,M,CInterpolator,MInterpolator.html,CLinearInterpolator,MLinearInterpolator.html">
|
||||
<param name=before value="M,M,M">
|
||||
<param name=after value="Md_SP,Md_,M">
|
||||
<param name=indent value="0,1,2">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.8.1">LinearInterpolator</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.8.2">LinearInterpolator</A></B>(const <!1><A HREF="LinearInterpolator.html#DOC.2.8.2">LinearInterpolator</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.8.3">META_Object</A></B>(<!1><A HREF="LinearInterpolator.html">LinearInterpolator</A>)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual float <B><A HREF="#DOC.2.8.4">interpolate</A></B>(float t, float y1, float y2) const
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.8.5">~LinearInterpolator</A></B>()
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="Interpolator.html">Interpolator</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual const char* <B>className</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual bool <B>isSameKindAs</B>(const osg::Object* obj) const
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>A linear interpolator</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="LinearInterpolator"></A>
|
||||
<A NAME="DOC.2.8.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> LinearInterpolator()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="LinearInterpolator"></A>
|
||||
<A NAME="DOC.2.8.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> LinearInterpolator(const <!1><A HREF="LinearInterpolator.html#DOC.2.8.2">LinearInterpolator</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="META_Object"></A>
|
||||
<A NAME="DOC.2.8.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> META_Object(<!1><A HREF="LinearInterpolator.html">LinearInterpolator</A>)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="interpolate"></A>
|
||||
<A NAME="DOC.2.8.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual float interpolate(float t, float y1, float y2) const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~LinearInterpolator"></A>
|
||||
<A NAME="DOC.2.8.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~LinearInterpolator()</B></TT>
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
223
doc/doc++/osgParticle/ModularEmitter.html
Normal file
223
doc/doc++/osgParticle/ModularEmitter.html
Normal file
@@ -0,0 +1,223 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class OSGPARTICLE_EXPORT osgParticle::ModularEmitter</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class OSGPARTICLE_EXPORT <A HREF="#DOC.DOCU">osgParticle::ModularEmitter</A></H2></H2><BLOCKQUOTE>An emitter class that holds three objects to control the creation of particles.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=125>
|
||||
<param name=classes value="Mosg::Node,M,CParticleProcessor,MParticleProcessor.html,CEmitter,MEmitter.html,CModularEmitter,MModularEmitter.html">
|
||||
<param name=before value="M,M,M,M">
|
||||
<param name=after value="Md_SPSP,Md_SP,Md_,M">
|
||||
<param name=indent value="0,1,2,3">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.9.1">ModularEmitter</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.9.2">ModularEmitter</A></B>(const <!1><A HREF="ModularEmitter.html#DOC.2.9.2">ModularEmitter</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.9.3">META_Node</A></B>(<!1><A HREF="ModularEmitter.html">ModularEmitter</A>)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <!1><A HREF="Counter.html">Counter</A>* <B><A HREF="#DOC.2.9.10">getCounter</A></B>()
|
||||
<DD><I>Get the counter object</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="Counter.html">Counter</A>* <B><A HREF="#DOC.2.9.11">getCounter</A></B>() const
|
||||
<DD><I>Get the const Counter object</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.9.12">setCounter</A></B>(<!1><A HREF="Counter.html">Counter</A>* c)
|
||||
<DD><I>Set the Counter object</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <!1><A HREF="Placer.html">Placer</A>* <B><A HREF="#DOC.2.9.13">getPlacer</A></B>()
|
||||
<DD><I>Get the Placer object</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="Placer.html">Placer</A>* <B><A HREF="#DOC.2.9.14">getPlacer</A></B>() const
|
||||
<DD><I>Get the const Placer object.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.9.15">setPlacer</A></B>(<!1><A HREF="Placer.html">Placer</A>* p)
|
||||
<DD><I>Set the Placer object</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <!1><A HREF="Shooter.html">Shooter</A>* <B><A HREF="#DOC.2.9.16">getShooter</A></B>()
|
||||
<DD><I>Get the Shooter object</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="Shooter.html">Shooter</A>* <B><A HREF="#DOC.2.9.17">getShooter</A></B>() const
|
||||
<DD><I>Get the const Shooter object</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.9.18">setShooter</A></B>(<!1><A HREF="Shooter.html">Shooter</A>* s)
|
||||
<DD><I>Set the Shooter object</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.9.4">~ModularEmitter</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="ModularEmitter.html">ModularEmitter</A>& <B><A HREF="#DOC.2.9.5">operator=</A></B>(const <!1><A HREF="ModularEmitter.html">ModularEmitter</A> &)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>void <B><A HREF="#DOC.2.9.6">emit</A></B>(double dt)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="Emitter.html">Emitter</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual const char* <B>className</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual bool <B>isSameKindAs</B>(const osg::Object* obj)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual void <B>accept</B>(osg::NodeVisitor& nv)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const <!1><A HREF="Particle.html">Particle</A>& <B>getParticleTemplate</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setParticleTemplate</B>(const <!1><A HREF="Particle.html">Particle</A> &p)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline bool <B>getUseDefaultTemplate</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setUseDefaultTemplate</B>(bool v)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>process</B>(double dt)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="ParticleProcessor.html">ParticleProcessor</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline <!1><A HREF="ParticleProcessor.html#DOC.2.14.1">ReferenceFrame</A> <B>getReferenceFrame</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>void <B>traverse</B>(osg::NodeVisitor &nv)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline ParticleProcessor::ReferenceFrame <B>getReferenceFrame</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setReferenceFrame</B>(<!1><A HREF="ParticleProcessor.html#DOC.2.14.1">ReferenceFrame</A> rf)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline bool <B>isEnabled</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setEnabled</B>(bool v)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* <B>getParticleSystem</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* <B>getParticleSystem</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setParticleSystem</B>(<!1><A HREF="ParticleSystem.html">ParticleSystem</A>* ps)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const bool <B>computeBound</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const osg::Matrix& <B>getLocalToWorldMatrix</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const osg::Matrix& <B>getWorldToLocalMatrix</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>transformLocalToWorld</B>(const osg::Vec3 &P)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>transformWorldToLocal</B>(const osg::Vec3 &P)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>rotateLocalToWorld</B>(const osg::Vec3 &P)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>rotateWorldToLocal</B>(const osg::Vec3 &P)
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Public Members</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>enum <B>ReferenceFrame</B>
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>An emitter class that holds three objects to control the creation of particles.
|
||||
These objects are a <I>counter</I>, a <I>placer</I> and a <I>shooter</I>.
|
||||
The counter controls the number of particles to be emitted at each frame;
|
||||
the placer must initialize the particle's position vector, while the shooter initializes
|
||||
its velocity vector.
|
||||
You can use the predefined counter/placer/shooter classes, or you can create your own.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="ModularEmitter"></A>
|
||||
<A NAME="DOC.2.9.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> ModularEmitter()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="ModularEmitter"></A>
|
||||
<A NAME="DOC.2.9.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> ModularEmitter(const <!1><A HREF="ModularEmitter.html#DOC.2.9.2">ModularEmitter</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="META_Node"></A>
|
||||
<A NAME="DOC.2.9.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> META_Node(<!1><A HREF="ModularEmitter.html">ModularEmitter</A>)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~ModularEmitter"></A>
|
||||
<A NAME="DOC.2.9.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~ModularEmitter()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.9.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="ModularEmitter.html">ModularEmitter</A>& operator=(const <!1><A HREF="ModularEmitter.html">ModularEmitter</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="emit"></A>
|
||||
<A NAME="DOC.2.9.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>void emit(double dt)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getCounter"></A>
|
||||
<A NAME="DOC.2.9.10"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline <!1><A HREF="Counter.html">Counter</A>* getCounter()</B></TT>
|
||||
<DD>Get the counter object
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getCounter"></A>
|
||||
<A NAME="DOC.2.9.11"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="Counter.html">Counter</A>* getCounter() const </B></TT>
|
||||
<DD>Get the const Counter object
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setCounter"></A>
|
||||
<A NAME="DOC.2.9.12"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setCounter(<!1><A HREF="Counter.html">Counter</A>* c)</B></TT>
|
||||
<DD>Set the Counter object
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getPlacer"></A>
|
||||
<A NAME="DOC.2.9.13"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline <!1><A HREF="Placer.html">Placer</A>* getPlacer()</B></TT>
|
||||
<DD>Get the Placer object
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getPlacer"></A>
|
||||
<A NAME="DOC.2.9.14"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="Placer.html">Placer</A>* getPlacer() const </B></TT>
|
||||
<DD>Get the const Placer object.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setPlacer"></A>
|
||||
<A NAME="DOC.2.9.15"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setPlacer(<!1><A HREF="Placer.html">Placer</A>* p)</B></TT>
|
||||
<DD>Set the Placer object
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getShooter"></A>
|
||||
<A NAME="DOC.2.9.16"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline <!1><A HREF="Shooter.html">Shooter</A>* getShooter()</B></TT>
|
||||
<DD>Get the Shooter object
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getShooter"></A>
|
||||
<A NAME="DOC.2.9.17"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="Shooter.html">Shooter</A>* getShooter() const </B></TT>
|
||||
<DD>Get the const Shooter object
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setShooter"></A>
|
||||
<A NAME="DOC.2.9.18"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setShooter(<!1><A HREF="Shooter.html">Shooter</A>* s)</B></TT>
|
||||
<DD>Set the Shooter object
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
181
doc/doc++/osgParticle/ModularProgram.html
Normal file
181
doc/doc++/osgParticle/ModularProgram.html
Normal file
@@ -0,0 +1,181 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class OSGPARTICLE_EXPORT osgParticle::ModularProgram</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class OSGPARTICLE_EXPORT <A HREF="#DOC.DOCU">osgParticle::ModularProgram</A></H2></H2><BLOCKQUOTE>A program class for performing operations on particles using a sequence of <I>operators</I>.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=125>
|
||||
<param name=classes value="Mosg::Node,M,CParticleProcessor,MParticleProcessor.html,CProgram,MProgram.html,CModularProgram,MModularProgram.html">
|
||||
<param name=before value="M,M,M,M">
|
||||
<param name=after value="Md_SPSP,Md_SP,Md_,M">
|
||||
<param name=indent value="0,1,2,3">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.10.1">ModularProgram</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.10.2">ModularProgram</A></B>(const <!1><A HREF="ModularProgram.html#DOC.2.10.2">ModularProgram</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.10.3">META_Node</A></B>(<!1><A HREF="ModularProgram.html">ModularProgram</A>)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline int <B><A HREF="#DOC.2.10.8">numOperators</A></B>() const
|
||||
<DD><I>Get the number of operators</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.10.9">addOperator</A></B>(<!1><A HREF="Operator.html">Operator</A>* o)
|
||||
<DD><I>Add an operator to the list.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <!1><A HREF="Operator.html">Operator</A>* <B><A HREF="#DOC.2.10.10">getOperator</A></B>(int i)
|
||||
<DD><I>Get a pointer to an operator in the list</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="Operator.html">Operator</A>* <B><A HREF="#DOC.2.10.11">getOperator</A></B>(int i) const
|
||||
<DD><I>Get a const pointer to an operator in the list</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.10.12">removeOperator</A></B>(int i)
|
||||
<DD><I>Remove an operator from the list</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.10.4">~ModularProgram</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="ModularProgram.html">ModularProgram</A>& <B><A HREF="#DOC.2.10.5">operator=</A></B>(const <!1><A HREF="ModularProgram.html">ModularProgram</A> &)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>void <B><A HREF="#DOC.2.10.6">execute</A></B>(double dt)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="Program.html">Program</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual const char* <B>className</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual bool <B>isSameKindAs</B>(const osg::Object* obj)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual void <B>accept</B>(osg::NodeVisitor& nv)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>process</B>(double dt)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="ParticleProcessor.html">ParticleProcessor</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline <!1><A HREF="ParticleProcessor.html#DOC.2.14.1">ReferenceFrame</A> <B>getReferenceFrame</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>void <B>traverse</B>(osg::NodeVisitor &nv)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline ParticleProcessor::ReferenceFrame <B>getReferenceFrame</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setReferenceFrame</B>(<!1><A HREF="ParticleProcessor.html#DOC.2.14.1">ReferenceFrame</A> rf)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline bool <B>isEnabled</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setEnabled</B>(bool v)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* <B>getParticleSystem</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* <B>getParticleSystem</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setParticleSystem</B>(<!1><A HREF="ParticleSystem.html">ParticleSystem</A>* ps)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const bool <B>computeBound</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const osg::Matrix& <B>getLocalToWorldMatrix</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const osg::Matrix& <B>getWorldToLocalMatrix</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>transformLocalToWorld</B>(const osg::Vec3 &P)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>transformWorldToLocal</B>(const osg::Vec3 &P)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>rotateLocalToWorld</B>(const osg::Vec3 &P)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>rotateWorldToLocal</B>(const osg::Vec3 &P)
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Public Members</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>enum <B>ReferenceFrame</B>
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>A program class for performing operations on particles using a sequence of <I>operators</I>.
|
||||
To use a <CODE>ModularProgram</CODE> you have to create some <CODE>Operator</CODE> objects and
|
||||
add them to the program.
|
||||
All operators will be applied to each particle in the same order they've been added to the program.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="ModularProgram"></A>
|
||||
<A NAME="DOC.2.10.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> ModularProgram()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="ModularProgram"></A>
|
||||
<A NAME="DOC.2.10.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> ModularProgram(const <!1><A HREF="ModularProgram.html#DOC.2.10.2">ModularProgram</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="META_Node"></A>
|
||||
<A NAME="DOC.2.10.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> META_Node(<!1><A HREF="ModularProgram.html">ModularProgram</A>)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~ModularProgram"></A>
|
||||
<A NAME="DOC.2.10.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~ModularProgram()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.10.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="ModularProgram.html">ModularProgram</A>& operator=(const <!1><A HREF="ModularProgram.html">ModularProgram</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="execute"></A>
|
||||
<A NAME="DOC.2.10.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>void execute(double dt)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="numOperators"></A>
|
||||
<A NAME="DOC.2.10.8"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline int numOperators() const </B></TT>
|
||||
<DD>Get the number of operators
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="addOperator"></A>
|
||||
<A NAME="DOC.2.10.9"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void addOperator(<!1><A HREF="Operator.html">Operator</A>* o)</B></TT>
|
||||
<DD>Add an operator to the list.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getOperator"></A>
|
||||
<A NAME="DOC.2.10.10"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline <!1><A HREF="Operator.html">Operator</A>* getOperator(int i)</B></TT>
|
||||
<DD>Get a pointer to an operator in the list
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getOperator"></A>
|
||||
<A NAME="DOC.2.10.11"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="Operator.html">Operator</A>* getOperator(int i) const </B></TT>
|
||||
<DD>Get a const pointer to an operator in the list
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="removeOperator"></A>
|
||||
<A NAME="DOC.2.10.12"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void removeOperator(int i)</B></TT>
|
||||
<DD>Remove an operator from the list
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
151
doc/doc++/osgParticle/MultiSegmentPlacer.html
Normal file
151
doc/doc++/osgParticle/MultiSegmentPlacer.html
Normal file
@@ -0,0 +1,151 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class OSGPARTICLE_EXPORT osgParticle::MultiSegmentPlacer</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class OSGPARTICLE_EXPORT <A HREF="#DOC.DOCU">osgParticle::MultiSegmentPlacer</A></H2></H2><BLOCKQUOTE>A polyline-shaped particle placer.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=95>
|
||||
<param name=classes value="Mosg::Object,M,CPlacer,MPlacer.html,CMultiSegmentPlacer,MMultiSegmentPlacer.html">
|
||||
<param name=before value="M,M,M">
|
||||
<param name=after value="Md_SP,Md_,M">
|
||||
<param name=indent value="0,1,2">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.11.1">MultiSegmentPlacer</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.11.2">MultiSegmentPlacer</A></B>(const <!1><A HREF="MultiSegmentPlacer.html#DOC.2.11.2">MultiSegmentPlacer</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.11.3">META_Object</A></B>(<!1><A HREF="MultiSegmentPlacer.html">MultiSegmentPlacer</A>)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>void <B><A HREF="#DOC.2.11.4">place</A></B>(<!1><A HREF="Particle.html">Particle</A>* P) const
|
||||
<DD><I>Place a partice.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline int <B><A HREF="#DOC.2.11.10">numVertices</A></B>() const
|
||||
<DD><I>Get the number of vertices which define the segments</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const osg::Vec3& <B><A HREF="#DOC.2.11.11">getVertex</A></B>(int i) const
|
||||
<DD><I>Get a vertex</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.11.12">setVertex</A></B>(int i, const osg::Vec3 &v)
|
||||
<DD><I>Set a vertex</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.11.13">setVertex</A></B>(int i, float x, float y, float z)
|
||||
<DD><I>Set a vertex</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.11.14">addVertex</A></B>(const osg::Vec3 &v)
|
||||
<DD><I>Add a vertex</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.11.15">addVertex</A></B>(float x, float y, float z)
|
||||
<DD><I>Add a vertex</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.11.16">removeVertex</A></B>(int i)
|
||||
<DD><I>Remove a vertex</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.11.5">~MultiSegmentPlacer</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="MultiSegmentPlacer.html">MultiSegmentPlacer</A>& <B><A HREF="#DOC.2.11.6">operator=</A></B>(const <!1><A HREF="MultiSegmentPlacer.html">MultiSegmentPlacer</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="Placer.html">Placer</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual const char* <B>className</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual bool <B>isSameKindAs</B>(const osg::Object* obj) const
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>A polyline-shaped particle placer.
|
||||
This placer class sets the position of incoming particles by choosing a random point on the
|
||||
specified sequence of connected segments.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="MultiSegmentPlacer"></A>
|
||||
<A NAME="DOC.2.11.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> MultiSegmentPlacer()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="MultiSegmentPlacer"></A>
|
||||
<A NAME="DOC.2.11.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> MultiSegmentPlacer(const <!1><A HREF="MultiSegmentPlacer.html#DOC.2.11.2">MultiSegmentPlacer</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="META_Object"></A>
|
||||
<A NAME="DOC.2.11.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> META_Object(<!1><A HREF="MultiSegmentPlacer.html">MultiSegmentPlacer</A>)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="place"></A>
|
||||
<A NAME="DOC.2.11.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>void place(<!1><A HREF="Particle.html">Particle</A>* P) const </B></TT>
|
||||
<DD>Place a partice. Called automatically by <CODE>ModularEmitter</CODE>, do not call this method manually.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~MultiSegmentPlacer"></A>
|
||||
<A NAME="DOC.2.11.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~MultiSegmentPlacer()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.11.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="MultiSegmentPlacer.html">MultiSegmentPlacer</A>& operator=(const <!1><A HREF="MultiSegmentPlacer.html">MultiSegmentPlacer</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="numVertices"></A>
|
||||
<A NAME="DOC.2.11.10"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline int numVertices() const </B></TT>
|
||||
<DD>Get the number of vertices which define the segments
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getVertex"></A>
|
||||
<A NAME="DOC.2.11.11"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const osg::Vec3& getVertex(int i) const </B></TT>
|
||||
<DD>Get a vertex
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setVertex"></A>
|
||||
<A NAME="DOC.2.11.12"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setVertex(int i, const osg::Vec3 &v)</B></TT>
|
||||
<DD>Set a vertex
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setVertex"></A>
|
||||
<A NAME="DOC.2.11.13"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setVertex(int i, float x, float y, float z)</B></TT>
|
||||
<DD>Set a vertex
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="addVertex"></A>
|
||||
<A NAME="DOC.2.11.14"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void addVertex(const osg::Vec3 &v)</B></TT>
|
||||
<DD>Add a vertex
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="addVertex"></A>
|
||||
<A NAME="DOC.2.11.15"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void addVertex(float x, float y, float z)</B></TT>
|
||||
<DD>Add a vertex
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="removeVertex"></A>
|
||||
<A NAME="DOC.2.11.16"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void removeVertex(int i)</B></TT>
|
||||
<DD>Remove a vertex
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
BIN
doc/doc++/osgParticle/NavigatorButton.class
Normal file
BIN
doc/doc++/osgParticle/NavigatorButton.class
Normal file
Binary file not shown.
20
doc/doc++/osgParticle/OSGPARTICLE_SECTORPLACER_.html
Normal file
20
doc/doc++/osgParticle/OSGPARTICLE_SECTORPLACER_.html
Normal file
@@ -0,0 +1,20 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>#define OSGPARTICLE_SECTORPLACER_</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>#define <A HREF="#DOC.DOCU">OSGPARTICLE_SECTORPLACER_</A></H2></H2><BLOCKQUOTE>Range of osg::Vec4s</BLOCKQUOTE>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>Range of osg::Vec4s</BLOCKQUOTE>
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
135
doc/doc++/osgParticle/Operator.html
Normal file
135
doc/doc++/osgParticle/Operator.html
Normal file
@@ -0,0 +1,135 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::Operator</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::Operator</A></H2></H2><BLOCKQUOTE>An abstract base class used by <CODE>ModularProgram</CODE> to perform operations on particles before they are updated.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=155>
|
||||
<param name=classes value="Mosg::Object,M,COperator,MOperator.html,CForceOperator,MForceOperator.html,CFluidFrictionOperator,MFluidFrictionOperator.html,CAccelOperator,MAccelOperator.html">
|
||||
<param name=before value="M,M,M|_,MR_,Mr_">
|
||||
<param name=after value="Md_,M,M,M,M">
|
||||
<param name=indent value="0,1,1,1,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual const char* <B><A HREF="#DOC.2.12.1">className</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual bool <B><A HREF="#DOC.2.12.2">isSameKindAs</A></B>(const osg::Object* obj) const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual void <B><A HREF="#DOC.2.12.3">operate</A></B>(<!1><A HREF="Particle.html">Particle</A>* P, double dt) = 0
|
||||
<DD><I>Do something on a particle.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual void <B><A HREF="#DOC.2.12.4">beginOperate</A></B>(<!1><A HREF="Program.html">Program</A>* )
|
||||
<DD><I>Do something before processing particles via the <CODE>operate()</CODE> method.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual void <B><A HREF="#DOC.2.12.5">endOperate</A></B>()
|
||||
<DD><I>Do something after all particles have been processed</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.12.9">Operator</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.12.10">Operator</A></B>(const <!1><A HREF="Operator.html#DOC.2.12.10">Operator</A> &copy, const osg::CopyOp &copyop)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline bool <B><A HREF="#DOC.2.12.11">isEnabled</A></B>() const
|
||||
<DD><I>Get whether this operator is enabled</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.12.12">setEnabled</A></B>(bool v)
|
||||
<DD><I>Enable or disable this operator</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.12.6">~Operator</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="Operator.html">Operator</A>& <B><A HREF="#DOC.2.12.7">operator=</A></B>(const <!1><A HREF="Operator.html">Operator</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>An abstract base class used by <CODE>ModularProgram</CODE> to perform operations on particles before they are updated.
|
||||
To implement a new operator, derive from this class and override the <CODE>operate()</CODE> method.
|
||||
You should also override the <CODE>beginOperate()</CODE> method to query the calling program for the reference frame
|
||||
used, and initialize the right transformations if needed.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="className"></A>
|
||||
<A NAME="DOC.2.12.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual const char* className() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="isSameKindAs"></A>
|
||||
<A NAME="DOC.2.12.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual bool isSameKindAs(const osg::Object* obj) const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operate"></A>
|
||||
<A NAME="DOC.2.12.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual void operate(<!1><A HREF="Particle.html">Particle</A>* P, double dt) = 0</B></TT>
|
||||
<DD>Do something on a particle.
|
||||
This method is called by <CODE>ModularProgram</CODE> objects to perform some operations
|
||||
on the particles. You must override it in descendant classes. Common operations
|
||||
consist of modifying the particle's velocity vector. The <CODE>dt</CODE> parameter is
|
||||
the time elapsed from last operation.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="beginOperate"></A>
|
||||
<A NAME="DOC.2.12.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual void beginOperate(<!1><A HREF="Program.html">Program</A>* )</B></TT>
|
||||
<DD>Do something before processing particles via the <CODE>operate()</CODE> method.
|
||||
Overriding this method could be necessary to query the calling <CODE>Program</CODE> object
|
||||
for the current reference frame. If the reference frame is RELATIVE_TO_PARENTS, then your
|
||||
class should prepare itself to do all operations in local coordinates.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="endOperate"></A>
|
||||
<A NAME="DOC.2.12.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual void endOperate()</B></TT>
|
||||
<DD>Do something after all particles have been processed
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~Operator"></A>
|
||||
<A NAME="DOC.2.12.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~Operator()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.12.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="Operator.html">Operator</A>& operator=(const <!1><A HREF="Operator.html">Operator</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="Operator"></A>
|
||||
<A NAME="DOC.2.12.9"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline Operator()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="Operator"></A>
|
||||
<A NAME="DOC.2.12.10"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline Operator(const <!1><A HREF="Operator.html#DOC.2.12.10">Operator</A> &copy, const osg::CopyOp &copyop)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="isEnabled"></A>
|
||||
<A NAME="DOC.2.12.11"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline bool isEnabled() const </B></TT>
|
||||
<DD>Get whether this operator is enabled
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setEnabled"></A>
|
||||
<A NAME="DOC.2.12.12"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setEnabled(bool v)</B></TT>
|
||||
<DD>Enable or disable this operator
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
<HR>
|
||||
<DL><DT><B>Direct child classes:
|
||||
</B><DD><A HREF="ForceOperator.html">ForceOperator</A><BR>
|
||||
<A HREF="FluidFrictionOperator.html">FluidFrictionOperator</A><BR>
|
||||
<A HREF="AccelOperator.html">AccelOperator</A><BR>
|
||||
</DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
377
doc/doc++/osgParticle/Particle.html
Normal file
377
doc/doc++/osgParticle/Particle.html
Normal file
@@ -0,0 +1,377 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class OSGPARTICLE_EXPORT osgParticle::Particle</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class OSGPARTICLE_EXPORT <A HREF="#DOC.DOCU">osgParticle::Particle</A></H2></H2><BLOCKQUOTE>Implementation of a <B>particle</B>.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.13.2">Particle</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <!1><A HREF="Particle.html#DOC.2.13.1">Shape</A> <B><A HREF="#DOC.2.13.3">getShape</A></B>() const
|
||||
<DD><I>Get the shape of the particle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>bool <B><A HREF="#DOC.2.13.4">update</A></B>(double dt)
|
||||
<DD><I>Update the particle (don't call this method manually).</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>void <B><A HREF="#DOC.2.13.5">render</A></B>(const osg::Matrix &modelview, float scale = 1.0f) const
|
||||
<DD><I>Render the particle.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline Particle::Shape <B><A HREF="#DOC.2.13.26">getShape</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.27">setShape</A></B>(<!1><A HREF="Particle.html#DOC.2.13.1">Shape</A> s)
|
||||
<DD><I>Set the shape of the particle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline bool <B><A HREF="#DOC.2.13.28">isAlive</A></B>() const
|
||||
<DD><I>Get whether the particle is still alive</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline double <B><A HREF="#DOC.2.13.29">getLifeTime</A></B>() const
|
||||
<DD><I>Get the life time of the particle (in seconds)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline double <B><A HREF="#DOC.2.13.30">getAge</A></B>() const
|
||||
<DD><I>Get the age of the particle (in seconds)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline float <B><A HREF="#DOC.2.13.31">getRadius</A></B>() const
|
||||
<DD><I>Get the physical radius of the particle.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.32">setRadius</A></B>(float r)
|
||||
<DD><I>Set the physical radius of the particle.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="rangef.html">rangef</A>& <B><A HREF="#DOC.2.13.33">getSizeRange</A></B>() const
|
||||
<DD><I>Get the minimum and maximum values for polygon size</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="rangef.html">rangef</A>& <B><A HREF="#DOC.2.13.34">getAlphaRange</A></B>() const
|
||||
<DD><I>Get the minimum and maximum values for alpha</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const rangev4& <B><A HREF="#DOC.2.13.35">getColorRange</A></B>() const
|
||||
<DD><I>Get the minimum and maximum values for color</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="Interpolator.html">Interpolator</A>* <B><A HREF="#DOC.2.13.36">getSizeInterpolator</A></B>() const
|
||||
<DD><I>Get the interpolator for computing the size of polygons</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="Interpolator.html">Interpolator</A>* <B><A HREF="#DOC.2.13.37">getAlphaInterpolator</A></B>() const
|
||||
<DD><I>Get the interpolator for computing alpha values</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="Interpolator.html">Interpolator</A>* <B><A HREF="#DOC.2.13.38">getColorInterpolator</A></B>() const
|
||||
<DD><I>Get the interpolator for computing color values</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const osg::Vec3& <B><A HREF="#DOC.2.13.39">getPosition</A></B>() const
|
||||
<DD><I>Get the position vector</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const osg::Vec3& <B><A HREF="#DOC.2.13.40">getVelocity</A></B>() const
|
||||
<DD><I>Get the velocity vector.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const osg::Vec3& <B><A HREF="#DOC.2.13.41">getPreviousPosition</A></B>() const
|
||||
<DD><I>Get the previous position (the position before last update)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.42">kill</A></B>()
|
||||
<DD><I>Kill the particle on next update NOTE: after calling this function, the <CODE>isAlive()</CODE> method will still return true until the particle is updated again</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.43">setLifeTime</A></B>(double t)
|
||||
<DD><I>Set the life time of the particle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.44">setSizeRange</A></B>(const <!1><A HREF="rangef.html">rangef</A> &r)
|
||||
<DD><I>Set the minimum and maximum values for polygon size</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.45">setAlphaRange</A></B>(const <!1><A HREF="rangef.html">rangef</A> &r)
|
||||
<DD><I>Set the minimum and maximum values for alpha</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.46">setColorRange</A></B>(const rangev4 &r)
|
||||
<DD><I>Set the minimum and maximum values for color</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.47">setSizeInterpolator</A></B>(<!1><A HREF="Interpolator.html">Interpolator</A>* ri)
|
||||
<DD><I>Set the interpolator for computing size values</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.48">setAlphaInterpolator</A></B>(<!1><A HREF="Interpolator.html">Interpolator</A>* ai)
|
||||
<DD><I>Set the interpolator for computing alpha values.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.49">setColorInterpolator</A></B>(<!1><A HREF="Interpolator.html">Interpolator</A>* ci)
|
||||
<DD><I>Set the interpolator for computing color values</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.50">setPosition</A></B>(const osg::Vec3 &p)
|
||||
<DD><I>Set the position vector.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.51">setVelocity</A></B>(const osg::Vec3 &v)
|
||||
<DD><I>Set the velocity vector.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.52">addVelocity</A></B>(const osg::Vec3 &v)
|
||||
<DD><I>Add a vector to the velocity vector</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.53">transformPositionVelocity</A></B>(const osg::Matrix &xform)
|
||||
<DD><I>Transform position and velocity vectors by a matrix</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline float <B><A HREF="#DOC.2.13.54">getMass</A></B>() const
|
||||
<DD><I>Get the mass of the particle.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline float <B><A HREF="#DOC.2.13.55">getMassInv</A></B>() const
|
||||
<DD><I>Get <CODE>1 / getMass()</CODE></I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.56">setMass</A></B>(float m)
|
||||
<DD><I>Set the mass of the particle.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.57">beginRender</A></B>()
|
||||
<DD><I>Perform some pre-rendering tasks.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.13.58">endRender</A></B>()
|
||||
<DD><I>Perform some post-rendering tasks.</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Public Members</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>enum <B><A HREF="#DOC.2.13.1">Shape</A></B>
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>Implementation of a <B>particle</B>.
|
||||
Objects of this class are particles, they have some graphical properties
|
||||
and some physical properties. Particles are created by emitters and then placed
|
||||
into Particle Systems, where they live and get updated at each frame.
|
||||
Particles can either live forever (lifeTime < 0), or die after a specified
|
||||
time (lifeTime >= 0). For each property which is defined as a range of values, a
|
||||
"current" value will be evaluated at each frame by interpolating the <I>min</I>
|
||||
and <I>max</I> values so that <I>curr_value = min</I> when <I>t == 0</I>, and
|
||||
<I>curr_value = max</I> when <I>t == lifeTime</I>.
|
||||
You may customize the interpolator objects to achieve any kind of transition.
|
||||
If you want the particle to live forever, set its lifetime to any value <= 0;
|
||||
in that case, no interpolation is done to compute real-time properties, and only
|
||||
minimum values are used.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="Shape"></A>
|
||||
<A NAME="DOC.2.13.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>enum Shape</B></TT>
|
||||
<DL><DT><DD></DL><P><DL>
|
||||
|
||||
<A NAME="POINT"></A>
|
||||
<A NAME="DOC.2.13.1.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> POINT</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="QUAD"></A>
|
||||
<A NAME="DOC.2.13.1.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> QUAD</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="QUAD_TRIANGLESTRIP"></A>
|
||||
<A NAME="DOC.2.13.1.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> QUAD_TRIANGLESTRIP</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="HEXAGON"></A>
|
||||
<A NAME="DOC.2.13.1.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> HEXAGON</B></TT>
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<A NAME="Particle"></A>
|
||||
<A NAME="DOC.2.13.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> Particle()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getShape"></A>
|
||||
<A NAME="DOC.2.13.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline <!1><A HREF="Particle.html#DOC.2.13.1">Shape</A> getShape() const </B></TT>
|
||||
<DD>Get the shape of the particle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="update"></A>
|
||||
<A NAME="DOC.2.13.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>bool update(double dt)</B></TT>
|
||||
<DD>Update the particle (don't call this method manually).
|
||||
This method is called automatically by <CODE>ParticleSystem::update()</CODE>; it
|
||||
updates the graphical properties of the particle for the current time,
|
||||
checks whether the particle is still alive, and then updates its position
|
||||
by computing <I>P = P + V * dt</I> (where <I>P</I> is the position and <I>V</I> is the velocity).
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="render"></A>
|
||||
<A NAME="DOC.2.13.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>void render(const osg::Matrix &modelview, float scale = 1.0f) const </B></TT>
|
||||
<DD>Render the particle. Called automatically by particle systems.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getShape"></A>
|
||||
<A NAME="DOC.2.13.26"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline Particle::Shape getShape() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setShape"></A>
|
||||
<A NAME="DOC.2.13.27"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setShape(<!1><A HREF="Particle.html#DOC.2.13.1">Shape</A> s)</B></TT>
|
||||
<DD>Set the shape of the particle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="isAlive"></A>
|
||||
<A NAME="DOC.2.13.28"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline bool isAlive() const </B></TT>
|
||||
<DD>Get whether the particle is still alive
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getLifeTime"></A>
|
||||
<A NAME="DOC.2.13.29"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline double getLifeTime() const </B></TT>
|
||||
<DD>Get the life time of the particle (in seconds)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getAge"></A>
|
||||
<A NAME="DOC.2.13.30"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline double getAge() const </B></TT>
|
||||
<DD>Get the age of the particle (in seconds)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getRadius"></A>
|
||||
<A NAME="DOC.2.13.31"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline float getRadius() const </B></TT>
|
||||
<DD>Get the physical radius of the particle.
|
||||
For built-in operators to work correctly, lengths must be expressed in meters.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setRadius"></A>
|
||||
<A NAME="DOC.2.13.32"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setRadius(float r)</B></TT>
|
||||
<DD>Set the physical radius of the particle.
|
||||
For built-in operators to work correctly, lengths must be expressed in meters.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getSizeRange"></A>
|
||||
<A NAME="DOC.2.13.33"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="rangef.html">rangef</A>& getSizeRange() const </B></TT>
|
||||
<DD>Get the minimum and maximum values for polygon size
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getAlphaRange"></A>
|
||||
<A NAME="DOC.2.13.34"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="rangef.html">rangef</A>& getAlphaRange() const </B></TT>
|
||||
<DD>Get the minimum and maximum values for alpha
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getColorRange"></A>
|
||||
<A NAME="DOC.2.13.35"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const rangev4& getColorRange() const </B></TT>
|
||||
<DD>Get the minimum and maximum values for color
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getSizeInterpolator"></A>
|
||||
<A NAME="DOC.2.13.36"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="Interpolator.html">Interpolator</A>* getSizeInterpolator() const </B></TT>
|
||||
<DD>Get the interpolator for computing the size of polygons
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getAlphaInterpolator"></A>
|
||||
<A NAME="DOC.2.13.37"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="Interpolator.html">Interpolator</A>* getAlphaInterpolator() const </B></TT>
|
||||
<DD>Get the interpolator for computing alpha values
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getColorInterpolator"></A>
|
||||
<A NAME="DOC.2.13.38"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="Interpolator.html">Interpolator</A>* getColorInterpolator() const </B></TT>
|
||||
<DD>Get the interpolator for computing color values
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getPosition"></A>
|
||||
<A NAME="DOC.2.13.39"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const osg::Vec3& getPosition() const </B></TT>
|
||||
<DD>Get the position vector
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getVelocity"></A>
|
||||
<A NAME="DOC.2.13.40"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const osg::Vec3& getVelocity() const </B></TT>
|
||||
<DD>Get the velocity vector.
|
||||
For built-in operators to work correctly, remember that velocity components are expressed
|
||||
in meters per second.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getPreviousPosition"></A>
|
||||
<A NAME="DOC.2.13.41"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const osg::Vec3& getPreviousPosition() const </B></TT>
|
||||
<DD>Get the previous position (the position before last update)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="kill"></A>
|
||||
<A NAME="DOC.2.13.42"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void kill()</B></TT>
|
||||
<DD>Kill the particle on next update
|
||||
NOTE: after calling this function, the <CODE>isAlive()</CODE> method will still
|
||||
return true until the particle is updated again
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setLifeTime"></A>
|
||||
<A NAME="DOC.2.13.43"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setLifeTime(double t)</B></TT>
|
||||
<DD>Set the life time of the particle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setSizeRange"></A>
|
||||
<A NAME="DOC.2.13.44"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setSizeRange(const <!1><A HREF="rangef.html">rangef</A> &r)</B></TT>
|
||||
<DD>Set the minimum and maximum values for polygon size
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setAlphaRange"></A>
|
||||
<A NAME="DOC.2.13.45"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setAlphaRange(const <!1><A HREF="rangef.html">rangef</A> &r)</B></TT>
|
||||
<DD>Set the minimum and maximum values for alpha
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setColorRange"></A>
|
||||
<A NAME="DOC.2.13.46"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setColorRange(const rangev4 &r)</B></TT>
|
||||
<DD>Set the minimum and maximum values for color
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setSizeInterpolator"></A>
|
||||
<A NAME="DOC.2.13.47"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setSizeInterpolator(<!1><A HREF="Interpolator.html">Interpolator</A>* ri)</B></TT>
|
||||
<DD>Set the interpolator for computing size values
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setAlphaInterpolator"></A>
|
||||
<A NAME="DOC.2.13.48"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setAlphaInterpolator(<!1><A HREF="Interpolator.html">Interpolator</A>* ai)</B></TT>
|
||||
<DD>Set the interpolator for computing alpha values.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setColorInterpolator"></A>
|
||||
<A NAME="DOC.2.13.49"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setColorInterpolator(<!1><A HREF="Interpolator.html">Interpolator</A>* ci)</B></TT>
|
||||
<DD>Set the interpolator for computing color values
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setPosition"></A>
|
||||
<A NAME="DOC.2.13.50"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setPosition(const osg::Vec3 &p)</B></TT>
|
||||
<DD>Set the position vector.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setVelocity"></A>
|
||||
<A NAME="DOC.2.13.51"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setVelocity(const osg::Vec3 &v)</B></TT>
|
||||
<DD>Set the velocity vector.
|
||||
For built-in operators to work correctly, remember that velocity components are expressed
|
||||
in meters per second.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="addVelocity"></A>
|
||||
<A NAME="DOC.2.13.52"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void addVelocity(const osg::Vec3 &v)</B></TT>
|
||||
<DD>Add a vector to the velocity vector
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="transformPositionVelocity"></A>
|
||||
<A NAME="DOC.2.13.53"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void transformPositionVelocity(const osg::Matrix &xform)</B></TT>
|
||||
<DD>Transform position and velocity vectors by a matrix
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getMass"></A>
|
||||
<A NAME="DOC.2.13.54"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline float getMass() const </B></TT>
|
||||
<DD>Get the mass of the particle.
|
||||
For built-in operators to work correctly, remember that the mass is expressed in kg.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getMassInv"></A>
|
||||
<A NAME="DOC.2.13.55"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline float getMassInv() const </B></TT>
|
||||
<DD>Get <CODE>1 / getMass()</CODE>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setMass"></A>
|
||||
<A NAME="DOC.2.13.56"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setMass(float m)</B></TT>
|
||||
<DD>Set the mass of the particle.
|
||||
For built-in operators to work correctly, remember that the mass is expressed in kg.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="beginRender"></A>
|
||||
<A NAME="DOC.2.13.57"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void beginRender()</B></TT>
|
||||
<DD>Perform some pre-rendering tasks. Called automatically by particle systems.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="endRender"></A>
|
||||
<A NAME="DOC.2.13.58"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void endRender()</B></TT>
|
||||
<DD>Perform some post-rendering tasks. Called automatically by particle systems.
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
241
doc/doc++/osgParticle/ParticleProcessor.html
Normal file
241
doc/doc++/osgParticle/ParticleProcessor.html
Normal file
@@ -0,0 +1,241 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class OSGPARTICLE_EXPORT osgParticle::ParticleProcessor</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class OSGPARTICLE_EXPORT <A HREF="#DOC.DOCU">osgParticle::ParticleProcessor</A></H2></H2><BLOCKQUOTE>A common base interface for those classes which need to do something on particles.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=125>
|
||||
<param name=classes value="Mosg::Node,M,CParticleProcessor,MParticleProcessor.html,CProgram,MProgram.html,CEmitter,MEmitter.html">
|
||||
<param name=before value="M,M,M|_,Mr_">
|
||||
<param name=after value="Md_,M,M,M">
|
||||
<param name=indent value="0,1,1,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.14.2">ParticleProcessor</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.14.3">ParticleProcessor</A></B>(const <!1><A HREF="ParticleProcessor.html#DOC.2.14.3">ParticleProcessor</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual const char* <B><A HREF="#DOC.2.14.4">className</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual bool <B><A HREF="#DOC.2.14.5">isSameKindAs</A></B>(const osg::Object* obj)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual void <B><A HREF="#DOC.2.14.6">accept</A></B>(osg::NodeVisitor& nv)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <!1><A HREF="ParticleProcessor.html#DOC.2.14.1">ReferenceFrame</A> <B><A HREF="#DOC.2.14.7">getReferenceFrame</A></B>() const
|
||||
<DD><I>Get the reference frame</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>void <B><A HREF="#DOC.2.14.8">traverse</A></B>(osg::NodeVisitor &nv)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline ParticleProcessor::ReferenceFrame <B><A HREF="#DOC.2.14.21">getReferenceFrame</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.14.22">setReferenceFrame</A></B>(<!1><A HREF="ParticleProcessor.html#DOC.2.14.1">ReferenceFrame</A> rf)
|
||||
<DD><I>Set the reference frame</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline bool <B><A HREF="#DOC.2.14.23">isEnabled</A></B>() const
|
||||
<DD><I>Get whether this processor is enabled or not</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.14.24">setEnabled</A></B>(bool v)
|
||||
<DD><I>Set whether this processor is enabled or not</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* <B><A HREF="#DOC.2.14.25">getParticleSystem</A></B>()
|
||||
<DD><I>Get a pointer to the destination particle system</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* <B><A HREF="#DOC.2.14.26">getParticleSystem</A></B>() const
|
||||
<DD><I>Get a const pointer to the destination particle system</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.14.27">setParticleSystem</A></B>(<!1><A HREF="ParticleSystem.html">ParticleSystem</A>* ps)
|
||||
<DD><I>Set the destination particle system</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const bool <B><A HREF="#DOC.2.14.28">computeBound</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const osg::Matrix& <B><A HREF="#DOC.2.14.29">getLocalToWorldMatrix</A></B>()
|
||||
<DD><I>Get the current local-to-world transformation matrix (valid only during cull traversal)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const osg::Matrix& <B><A HREF="#DOC.2.14.30">getWorldToLocalMatrix</A></B>()
|
||||
<DD><I>Get the current world-to-local transformation matrix (valid only during cull traversal)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline osg::Vec3 <B><A HREF="#DOC.2.14.31">transformLocalToWorld</A></B>(const osg::Vec3 &P)
|
||||
<DD><I>Transform a point from local to world coordinates (valid only during cull traversal)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline osg::Vec3 <B><A HREF="#DOC.2.14.32">transformWorldToLocal</A></B>(const osg::Vec3 &P)
|
||||
<DD><I>Transform a point from world to local coordinates (valid only during cull traversal)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline osg::Vec3 <B><A HREF="#DOC.2.14.33">rotateLocalToWorld</A></B>(const osg::Vec3 &P)
|
||||
<DD><I>Transform a vector from local to world coordinates, discarding translation (valid only during cull traversal)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline osg::Vec3 <B><A HREF="#DOC.2.14.34">rotateWorldToLocal</A></B>(const osg::Vec3 &P)
|
||||
<DD><I>Transform a vector from world to local coordinates, discarding translation (valid only during cull traversal)</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Public Members</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>enum <B><A HREF="#DOC.2.14.1">ReferenceFrame</A></B>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.14.9">~ParticleProcessor</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="ParticleProcessor.html">ParticleProcessor</A>& <B><A HREF="#DOC.2.14.10">operator=</A></B>(const <!1><A HREF="ParticleProcessor.html">ParticleProcessor</A> &)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual void <B><A HREF="#DOC.2.14.11">process</A></B>(double dt) = 0
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>A common base interface for those classes which need to do something on particles. Such classes
|
||||
are, for example, <CODE>Emitter</CODE> (particle generation) and <CODE>Program</CODE> (particle animation).
|
||||
This class holds some properties, like a <I>reference frame</I> and a reference to a <CODE>ParticleSystem<CODE>;
|
||||
descendant classes should process the particles taking into account the reference frame, computing the right
|
||||
transformations when needed.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="ReferenceFrame"></A>
|
||||
<A NAME="DOC.2.14.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>enum ReferenceFrame</B></TT>
|
||||
<DL><DT><DD></DL><P><DL>
|
||||
|
||||
<A NAME="RELATIVE_TO_PARENTS"></A>
|
||||
<A NAME="DOC.2.14.1.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> RELATIVE_TO_PARENTS</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="RELATIVE_TO_ABSOLUTE"></A>
|
||||
<A NAME="DOC.2.14.1.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> RELATIVE_TO_ABSOLUTE</B></TT>
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<A NAME="ParticleProcessor"></A>
|
||||
<A NAME="DOC.2.14.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> ParticleProcessor()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="ParticleProcessor"></A>
|
||||
<A NAME="DOC.2.14.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> ParticleProcessor(const <!1><A HREF="ParticleProcessor.html#DOC.2.14.3">ParticleProcessor</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="className"></A>
|
||||
<A NAME="DOC.2.14.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual const char* className() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="isSameKindAs"></A>
|
||||
<A NAME="DOC.2.14.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual bool isSameKindAs(const osg::Object* obj)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="accept"></A>
|
||||
<A NAME="DOC.2.14.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual void accept(osg::NodeVisitor& nv)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getReferenceFrame"></A>
|
||||
<A NAME="DOC.2.14.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline <!1><A HREF="ParticleProcessor.html#DOC.2.14.1">ReferenceFrame</A> getReferenceFrame() const </B></TT>
|
||||
<DD>Get the reference frame
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="traverse"></A>
|
||||
<A NAME="DOC.2.14.8"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>void traverse(osg::NodeVisitor &nv)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~ParticleProcessor"></A>
|
||||
<A NAME="DOC.2.14.9"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~ParticleProcessor()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.14.10"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="ParticleProcessor.html">ParticleProcessor</A>& operator=(const <!1><A HREF="ParticleProcessor.html">ParticleProcessor</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="process"></A>
|
||||
<A NAME="DOC.2.14.11"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual void process(double dt) = 0</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getReferenceFrame"></A>
|
||||
<A NAME="DOC.2.14.21"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline ParticleProcessor::ReferenceFrame getReferenceFrame() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setReferenceFrame"></A>
|
||||
<A NAME="DOC.2.14.22"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setReferenceFrame(<!1><A HREF="ParticleProcessor.html#DOC.2.14.1">ReferenceFrame</A> rf)</B></TT>
|
||||
<DD>Set the reference frame
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="isEnabled"></A>
|
||||
<A NAME="DOC.2.14.23"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline bool isEnabled() const </B></TT>
|
||||
<DD>Get whether this processor is enabled or not
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setEnabled"></A>
|
||||
<A NAME="DOC.2.14.24"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setEnabled(bool v)</B></TT>
|
||||
<DD>Set whether this processor is enabled or not
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getParticleSystem"></A>
|
||||
<A NAME="DOC.2.14.25"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* getParticleSystem()</B></TT>
|
||||
<DD>Get a pointer to the destination particle system
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getParticleSystem"></A>
|
||||
<A NAME="DOC.2.14.26"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* getParticleSystem() const </B></TT>
|
||||
<DD>Get a const pointer to the destination particle system
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setParticleSystem"></A>
|
||||
<A NAME="DOC.2.14.27"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setParticleSystem(<!1><A HREF="ParticleSystem.html">ParticleSystem</A>* ps)</B></TT>
|
||||
<DD>Set the destination particle system
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="computeBound"></A>
|
||||
<A NAME="DOC.2.14.28"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const bool computeBound() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getLocalToWorldMatrix"></A>
|
||||
<A NAME="DOC.2.14.29"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const osg::Matrix& getLocalToWorldMatrix()</B></TT>
|
||||
<DD>Get the current local-to-world transformation matrix (valid only during cull traversal)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getWorldToLocalMatrix"></A>
|
||||
<A NAME="DOC.2.14.30"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const osg::Matrix& getWorldToLocalMatrix()</B></TT>
|
||||
<DD>Get the current world-to-local transformation matrix (valid only during cull traversal)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="transformLocalToWorld"></A>
|
||||
<A NAME="DOC.2.14.31"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline osg::Vec3 transformLocalToWorld(const osg::Vec3 &P)</B></TT>
|
||||
<DD>Transform a point from local to world coordinates (valid only during cull traversal)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="transformWorldToLocal"></A>
|
||||
<A NAME="DOC.2.14.32"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline osg::Vec3 transformWorldToLocal(const osg::Vec3 &P)</B></TT>
|
||||
<DD>Transform a point from world to local coordinates (valid only during cull traversal)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="rotateLocalToWorld"></A>
|
||||
<A NAME="DOC.2.14.33"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline osg::Vec3 rotateLocalToWorld(const osg::Vec3 &P)</B></TT>
|
||||
<DD>Transform a vector from local to world coordinates, discarding translation (valid only during cull traversal)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="rotateWorldToLocal"></A>
|
||||
<A NAME="DOC.2.14.34"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline osg::Vec3 rotateWorldToLocal(const osg::Vec3 &P)</B></TT>
|
||||
<DD>Transform a vector from world to local coordinates, discarding translation (valid only during cull traversal)
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
<HR>
|
||||
<DL><DT><B>Direct child classes:
|
||||
</B><DD><A HREF="Program.html">Program</A><BR>
|
||||
<A HREF="Emitter.html">Emitter</A><BR>
|
||||
</DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
311
doc/doc++/osgParticle/ParticleSystem.html
Normal file
311
doc/doc++/osgParticle/ParticleSystem.html
Normal file
@@ -0,0 +1,311 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class OSGPARTICLE_EXPORT osgParticle::ParticleSystem</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class OSGPARTICLE_EXPORT <A HREF="#DOC.DOCU">osgParticle::ParticleSystem</A></H2></H2><BLOCKQUOTE>The heart of this class library; its purpose is to hold a set of particles and manage particle creation, update, rendering and destruction.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=65>
|
||||
<param name=classes value="Mosg::Drawable,M,CParticleSystem,MParticleSystem.html">
|
||||
<param name=before value="M,M">
|
||||
<param name=after value="Md_,M">
|
||||
<param name=indent value="0,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.15.1">ParticleSystem</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.15.2">ParticleSystem</A></B>(const <!1><A HREF="ParticleSystem.html#DOC.2.15.2">ParticleSystem</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.15.3">META_Object</A></B>(<!1><A HREF="ParticleSystem.html">ParticleSystem</A>)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline virtual <!1><A HREF="Particle.html">Particle</A>* <B><A HREF="#DOC.2.15.4">createParticle</A></B>(const <!1><A HREF="Particle.html">Particle</A>* ptemplate)
|
||||
<DD><I>Create a new particle from the specified template (or the default one if <CODE>ptemplate</CODE> is null)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline virtual void <B><A HREF="#DOC.2.15.5">destroyParticle</A></B>(int i)
|
||||
<DD><I>Destroy the i-th particle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>void <B><A HREF="#DOC.2.15.6">setDefaultAttributes</A></B>(const std::string &texturefile = "", bool emissive_particles = true, bool lighting = false)
|
||||
<DD><I>A useful method to set the most common <CODE>StateAttribute</CODE>'s in one call.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual void <B><A HREF="#DOC.2.15.7">update</A></B>(double dt)
|
||||
<DD><I>Update the particles.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline virtual bool <B><A HREF="#DOC.2.15.8">getStats</A></B>(osg::Statistics &stats)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline bool <B><A HREF="#DOC.2.15.29">isFrozen</A></B>() const
|
||||
<DD><I>Return true if the particle system is frozen</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.15.30">setFrozen</A></B>(bool v)
|
||||
<DD><I>Set or reset the <I>frozen</I> state.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const osg::BoundingBox& <B><A HREF="#DOC.2.15.31">getDefaultBoundingBox</A></B>() const
|
||||
<DD><I>Get the default bounding box</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.15.32">setDefaultBoundingBox</A></B>(const osg::BoundingBox &bbox)
|
||||
<DD><I>Set the default bounding box.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline bool <B><A HREF="#DOC.2.15.33">getDoublePassRendering</A></B>() const
|
||||
<DD><I>Get the double pass rendering flag</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.15.34">setDoublePassRendering</A></B>(bool v)
|
||||
<DD><I>Set the double pass rendering flag.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline int <B><A HREF="#DOC.2.15.35">numParticles</A></B>() const
|
||||
<DD><I>Get the number of allocated particles (alive + dead)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline int <B><A HREF="#DOC.2.15.36">numDeadParticles</A></B>() const
|
||||
<DD><I>Get the number of dead particles</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <!1><A HREF="Particle.html">Particle</A>* <B><A HREF="#DOC.2.15.37">getParticle</A></B>(int i)
|
||||
<DD><I>Get a pointer to the i-th particle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="Particle.html">Particle</A>* <B><A HREF="#DOC.2.15.38">getParticle</A></B>(int i) const
|
||||
<DD><I>Get a const pointer to the i-th particle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.15.39">destroyParticle</A></B>(int i)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline int <B><A HREF="#DOC.2.15.40">getLastFrameNumber</A></B>() const
|
||||
<DD><I>Get the last frame number</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const bool <B><A HREF="#DOC.2.15.41">computeBound</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline bool <B><A HREF="#DOC.2.15.42">getStats</A></B>(osg::Statistics &stats)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.15.43">update_bounds</A></B>(const osg::Vec3 &p)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="Particle.html">Particle</A>& <B><A HREF="#DOC.2.15.44">getDefaultParticleTemplate</A></B>() const
|
||||
<DD><I>Get a reference to the default particle template</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.15.45">setDefaultParticleTemplate</A></B>(const <!1><A HREF="Particle.html">Particle</A> &p)
|
||||
<DD><I>Set the default particle template (particle is copied)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline bool <B><A HREF="#DOC.2.15.46">getFreezeOnCull</A></B>() const
|
||||
<DD><I>Get whether the particle system can freeze when culled</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.15.47">setFreezeOnCull</A></B>(bool v)
|
||||
<DD><I>Set whether the particle system can freeze when culled (default is true)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline int <B><A HREF="#DOC.2.15.48">getLevelOfDetail</A></B>() const
|
||||
<DD><I>(<B>EXPERIMENTAL</B>) Get the level of detail</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.15.49">setLevelOfDetail</A></B>(int v)
|
||||
<DD><I>(<B>EXPERIMENTAL</B>) Set the level of detail.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <!1><A HREF="Particle.html">Particle</A>* <B><A HREF="#DOC.2.15.50">createParticle</A></B>(const <!1><A HREF="Particle.html">Particle</A>* ptemplate)
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.15.9">~ParticleSystem</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="ParticleSystem.html">ParticleSystem</A>& <B><A HREF="#DOC.2.15.10">operator=</A></B>(const <!1><A HREF="ParticleSystem.html">ParticleSystem</A> &)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline virtual const bool <B><A HREF="#DOC.2.15.11">computeBound</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual void <B><A HREF="#DOC.2.15.12">drawImmediateMode</A></B>(osg::State &state)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>void <B><A HREF="#DOC.2.15.13">single_pass_render</A></B>(const osg::Matrix &modelview)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>The heart of this class library; its purpose is to hold a set of particles and manage particle creation, update, rendering and destruction.
|
||||
You can add this drawable to any <CODE>Geode</CODE> as you usually do with other
|
||||
<CODE>Drawable</CODE> classes. Each instance of <CODE>ParticleSystem</CODE> is a separate set of
|
||||
particles; it provides the interface for creating particles and iterating
|
||||
through them (see the <CODE>Emitter</CODE> and <CODE>Program</CODE> classes).</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="ParticleSystem"></A>
|
||||
<A NAME="DOC.2.15.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> ParticleSystem()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="ParticleSystem"></A>
|
||||
<A NAME="DOC.2.15.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> ParticleSystem(const <!1><A HREF="ParticleSystem.html#DOC.2.15.2">ParticleSystem</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="META_Object"></A>
|
||||
<A NAME="DOC.2.15.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> META_Object(<!1><A HREF="ParticleSystem.html">ParticleSystem</A>)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="createParticle"></A>
|
||||
<A NAME="DOC.2.15.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline virtual <!1><A HREF="Particle.html">Particle</A>* createParticle(const <!1><A HREF="Particle.html">Particle</A>* ptemplate)</B></TT>
|
||||
<DD>Create a new particle from the specified template (or the default one if <CODE>ptemplate</CODE> is null)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="destroyParticle"></A>
|
||||
<A NAME="DOC.2.15.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline virtual void destroyParticle(int i)</B></TT>
|
||||
<DD>Destroy the i-th particle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setDefaultAttributes"></A>
|
||||
<A NAME="DOC.2.15.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>void setDefaultAttributes(const std::string &texturefile = "", bool emissive_particles = true, bool lighting = false)</B></TT>
|
||||
<DD>A useful method to set the most common <CODE>StateAttribute</CODE>'s in one call.
|
||||
If <CODE>texturefile</CODE> is empty, then texturing is turned off.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="update"></A>
|
||||
<A NAME="DOC.2.15.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual void update(double dt)</B></TT>
|
||||
<DD>Update the particles. Don't call this directly, use a <CODE>ParticleSystemUpdater</CODE> instead.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getStats"></A>
|
||||
<A NAME="DOC.2.15.8"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline virtual bool getStats(osg::Statistics &stats)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~ParticleSystem"></A>
|
||||
<A NAME="DOC.2.15.9"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~ParticleSystem()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.15.10"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="ParticleSystem.html">ParticleSystem</A>& operator=(const <!1><A HREF="ParticleSystem.html">ParticleSystem</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="computeBound"></A>
|
||||
<A NAME="DOC.2.15.11"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline virtual const bool computeBound() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="drawImmediateMode"></A>
|
||||
<A NAME="DOC.2.15.12"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual void drawImmediateMode(osg::State &state)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="single_pass_render"></A>
|
||||
<A NAME="DOC.2.15.13"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>void single_pass_render(const osg::Matrix &modelview)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="isFrozen"></A>
|
||||
<A NAME="DOC.2.15.29"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline bool isFrozen() const </B></TT>
|
||||
<DD>Return true if the particle system is frozen
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setFrozen"></A>
|
||||
<A NAME="DOC.2.15.30"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setFrozen(bool v)</B></TT>
|
||||
<DD>Set or reset the <I>frozen</I> state.
|
||||
When the particle system is frozen, emitters and programs won't do anything on it.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getDefaultBoundingBox"></A>
|
||||
<A NAME="DOC.2.15.31"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const osg::BoundingBox& getDefaultBoundingBox() const </B></TT>
|
||||
<DD>Get the default bounding box
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setDefaultBoundingBox"></A>
|
||||
<A NAME="DOC.2.15.32"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setDefaultBoundingBox(const osg::BoundingBox &bbox)</B></TT>
|
||||
<DD>Set the default bounding box.
|
||||
The default bounding box is used when a real bounding box cannot be computed, for example
|
||||
because no particles has been updated yet.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getDoublePassRendering"></A>
|
||||
<A NAME="DOC.2.15.33"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline bool getDoublePassRendering() const </B></TT>
|
||||
<DD>Get the double pass rendering flag
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setDoublePassRendering"></A>
|
||||
<A NAME="DOC.2.15.34"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setDoublePassRendering(bool v)</B></TT>
|
||||
<DD>Set the double pass rendering flag.
|
||||
Double pass rendering avoids overdraw problems between particle systems
|
||||
and other opaque objects. If you can render all the particle systems <U>after</U>
|
||||
the opaque objects, then double pass is not necessary and can be turned off (best choice).
|
||||
If you set the default attributes with <CODE>setDefaultAttributes</CODE>, then the particle
|
||||
system will fall into a transparent bin.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="numParticles"></A>
|
||||
<A NAME="DOC.2.15.35"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline int numParticles() const </B></TT>
|
||||
<DD>Get the number of allocated particles (alive + dead)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="numDeadParticles"></A>
|
||||
<A NAME="DOC.2.15.36"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline int numDeadParticles() const </B></TT>
|
||||
<DD>Get the number of dead particles
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getParticle"></A>
|
||||
<A NAME="DOC.2.15.37"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline <!1><A HREF="Particle.html">Particle</A>* getParticle(int i)</B></TT>
|
||||
<DD>Get a pointer to the i-th particle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getParticle"></A>
|
||||
<A NAME="DOC.2.15.38"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="Particle.html">Particle</A>* getParticle(int i) const </B></TT>
|
||||
<DD>Get a const pointer to the i-th particle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="destroyParticle"></A>
|
||||
<A NAME="DOC.2.15.39"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void destroyParticle(int i)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getLastFrameNumber"></A>
|
||||
<A NAME="DOC.2.15.40"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline int getLastFrameNumber() const </B></TT>
|
||||
<DD>Get the last frame number
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="computeBound"></A>
|
||||
<A NAME="DOC.2.15.41"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const bool computeBound() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getStats"></A>
|
||||
<A NAME="DOC.2.15.42"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline bool getStats(osg::Statistics &stats)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="update_bounds"></A>
|
||||
<A NAME="DOC.2.15.43"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void update_bounds(const osg::Vec3 &p)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getDefaultParticleTemplate"></A>
|
||||
<A NAME="DOC.2.15.44"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="Particle.html">Particle</A>& getDefaultParticleTemplate() const </B></TT>
|
||||
<DD>Get a reference to the default particle template
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setDefaultParticleTemplate"></A>
|
||||
<A NAME="DOC.2.15.45"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setDefaultParticleTemplate(const <!1><A HREF="Particle.html">Particle</A> &p)</B></TT>
|
||||
<DD>Set the default particle template (particle is copied)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getFreezeOnCull"></A>
|
||||
<A NAME="DOC.2.15.46"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline bool getFreezeOnCull() const </B></TT>
|
||||
<DD>Get whether the particle system can freeze when culled
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setFreezeOnCull"></A>
|
||||
<A NAME="DOC.2.15.47"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setFreezeOnCull(bool v)</B></TT>
|
||||
<DD>Set whether the particle system can freeze when culled (default is true)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getLevelOfDetail"></A>
|
||||
<A NAME="DOC.2.15.48"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline int getLevelOfDetail() const </B></TT>
|
||||
<DD>(<B>EXPERIMENTAL</B>) Get the level of detail
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setLevelOfDetail"></A>
|
||||
<A NAME="DOC.2.15.49"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setLevelOfDetail(int v)</B></TT>
|
||||
<DD>(<B>EXPERIMENTAL</B>) Set the level of detail. The total number of particles is divided by the detail value to
|
||||
get the actual number of particles to be drawn. This value must be greater than zero.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="createParticle"></A>
|
||||
<A NAME="DOC.2.15.50"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline <!1><A HREF="Particle.html">Particle</A>* createParticle(const <!1><A HREF="Particle.html">Particle</A>* ptemplate)</B></TT>
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
152
doc/doc++/osgParticle/ParticleSystemUpdater.html
Normal file
152
doc/doc++/osgParticle/ParticleSystemUpdater.html
Normal file
@@ -0,0 +1,152 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class OSGPARTICLE_EXPORT osgParticle::ParticleSystemUpdater</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class OSGPARTICLE_EXPORT <A HREF="#DOC.DOCU">osgParticle::ParticleSystemUpdater</A></H2></H2><BLOCKQUOTE>A useful node class for updating particle systems automatically.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=65>
|
||||
<param name=classes value="Mosg::Node,M,CParticleSystemUpdater,MParticleSystemUpdater.html">
|
||||
<param name=before value="M,M">
|
||||
<param name=after value="Md_,M">
|
||||
<param name=indent value="0,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.16.1">ParticleSystemUpdater</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.16.2">ParticleSystemUpdater</A></B>(const <!1><A HREF="ParticleSystemUpdater.html#DOC.2.16.2">ParticleSystemUpdater</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.16.3">META_Node</A></B>(<!1><A HREF="ParticleSystemUpdater.html">ParticleSystemUpdater</A>)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual void <B><A HREF="#DOC.2.16.4">traverse</A></B>(osg::NodeVisitor &nv)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const bool <B><A HREF="#DOC.2.16.10">computeBound</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline int <B><A HREF="#DOC.2.16.11">numParticleSystems</A></B>() const
|
||||
<DD><I>Return the number of particle systems on the list</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.16.12">addParticleSystem</A></B>(<!1><A HREF="ParticleSystem.html">ParticleSystem</A>* ps)
|
||||
<DD><I>Add a particle system to the list</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* <B><A HREF="#DOC.2.16.13">getParticleSystem</A></B>(int i) const
|
||||
<DD><I>Get a const particle system from the list</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* <B><A HREF="#DOC.2.16.14">getParticleSystem</A></B>(int i)
|
||||
<DD><I>Get a particle system from the list</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.16.15">removeParticleSystem</A></B>(int i)
|
||||
<DD><I>Remove a particle system from the list (by index)</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline int <B><A HREF="#DOC.2.16.16">findParticleSystem</A></B>(<!1><A HREF="ParticleSystem.html">ParticleSystem</A>* ps) const
|
||||
<DD><I>Find a particle system</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline bool <B><A HREF="#DOC.2.16.17">removeParticleSystem</A></B>(<!1><A HREF="ParticleSystem.html">ParticleSystem</A>* ps)
|
||||
<DD><I>Remove a particle system from the list (by pointer)</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.16.5">~ParticleSystemUpdater</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="ParticleSystemUpdater.html">ParticleSystemUpdater</A>& <B><A HREF="#DOC.2.16.6">operator=</A></B>(const <!1><A HREF="ParticleSystemUpdater.html">ParticleSystemUpdater</A> &)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline virtual const bool <B><A HREF="#DOC.2.16.7">computeBound</A></B>() const
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>A useful node class for updating particle systems automatically.
|
||||
When a <CODE>ParticleSystemUpdater</CODE> is traversed by a cull visitor, it calls the
|
||||
<CODE>update()</CODE> method on the specified particle systems. You should place this updater
|
||||
<U>AFTER</U> other nodes like emitters and programs.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="ParticleSystemUpdater"></A>
|
||||
<A NAME="DOC.2.16.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> ParticleSystemUpdater()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="ParticleSystemUpdater"></A>
|
||||
<A NAME="DOC.2.16.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> ParticleSystemUpdater(const <!1><A HREF="ParticleSystemUpdater.html#DOC.2.16.2">ParticleSystemUpdater</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="META_Node"></A>
|
||||
<A NAME="DOC.2.16.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> META_Node(<!1><A HREF="ParticleSystemUpdater.html">ParticleSystemUpdater</A>)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="traverse"></A>
|
||||
<A NAME="DOC.2.16.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual void traverse(osg::NodeVisitor &nv)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~ParticleSystemUpdater"></A>
|
||||
<A NAME="DOC.2.16.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~ParticleSystemUpdater()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.16.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="ParticleSystemUpdater.html">ParticleSystemUpdater</A>& operator=(const <!1><A HREF="ParticleSystemUpdater.html">ParticleSystemUpdater</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="computeBound"></A>
|
||||
<A NAME="DOC.2.16.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline virtual const bool computeBound() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="computeBound"></A>
|
||||
<A NAME="DOC.2.16.10"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const bool computeBound() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="numParticleSystems"></A>
|
||||
<A NAME="DOC.2.16.11"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline int numParticleSystems() const </B></TT>
|
||||
<DD>Return the number of particle systems on the list
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="addParticleSystem"></A>
|
||||
<A NAME="DOC.2.16.12"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void addParticleSystem(<!1><A HREF="ParticleSystem.html">ParticleSystem</A>* ps)</B></TT>
|
||||
<DD>Add a particle system to the list
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getParticleSystem"></A>
|
||||
<A NAME="DOC.2.16.13"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* getParticleSystem(int i) const </B></TT>
|
||||
<DD>Get a const particle system from the list
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getParticleSystem"></A>
|
||||
<A NAME="DOC.2.16.14"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* getParticleSystem(int i)</B></TT>
|
||||
<DD>Get a particle system from the list
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="removeParticleSystem"></A>
|
||||
<A NAME="DOC.2.16.15"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void removeParticleSystem(int i)</B></TT>
|
||||
<DD>Remove a particle system from the list (by index)
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="findParticleSystem"></A>
|
||||
<A NAME="DOC.2.16.16"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline int findParticleSystem(<!1><A HREF="ParticleSystem.html">ParticleSystem</A>* ps) const </B></TT>
|
||||
<DD>Find a particle system
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="removeParticleSystem"></A>
|
||||
<A NAME="DOC.2.16.17"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline bool removeParticleSystem(<!1><A HREF="ParticleSystem.html">ParticleSystem</A>* ps)</B></TT>
|
||||
<DD>Remove a particle system from the list (by pointer)
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
95
doc/doc++/osgParticle/Placer.html
Normal file
95
doc/doc++/osgParticle/Placer.html
Normal file
@@ -0,0 +1,95 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::Placer</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::Placer</A></H2></H2><BLOCKQUOTE>An abstract base class for implementing <I>particle placers</I>.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=155>
|
||||
<param name=classes value="Mosg::Object,M,CPlacer,MPlacer.html,CSegmentPlacer,MSegmentPlacer.html,CMultiSegmentPlacer,MMultiSegmentPlacer.html,CCenteredPlacer,MCenteredPlacer.html">
|
||||
<param name=before value="M,M,M|_,MR_,Mr_">
|
||||
<param name=after value="Md_,M,M,M,M">
|
||||
<param name=indent value="0,1,1,1,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual const char* <B><A HREF="#DOC.2.17.1">className</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual bool <B><A HREF="#DOC.2.17.2">isSameKindAs</A></B>(const osg::Object* obj) const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual void <B><A HREF="#DOC.2.17.3">place</A></B>(<!1><A HREF="Particle.html">Particle</A>* P) const = 0
|
||||
<DD><I>Place a particle.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.17.6">Placer</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.17.7">Placer</A></B>(const <!1><A HREF="Placer.html#DOC.2.17.7">Placer</A> &copy, const osg::CopyOp &copyop)
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.17.4">~Placer</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="Placer.html">Placer</A>& <B><A HREF="#DOC.2.17.5">operator=</A></B>(const <!1><A HREF="Placer.html">Placer</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>An abstract base class for implementing <I>particle placers</I>. A placer is an object which take
|
||||
a particle as input, and places it somewhere by setting its position vector. Placer objects are
|
||||
used by the <CODE>ModularEmitter</CODE> class as part of the particle emission process.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="className"></A>
|
||||
<A NAME="DOC.2.17.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual const char* className() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="isSameKindAs"></A>
|
||||
<A NAME="DOC.2.17.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual bool isSameKindAs(const osg::Object* obj) const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="place"></A>
|
||||
<A NAME="DOC.2.17.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual void place(<!1><A HREF="Particle.html">Particle</A>* P) const = 0</B></TT>
|
||||
<DD>Place a particle. Must be implemented in descendant classes.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~Placer"></A>
|
||||
<A NAME="DOC.2.17.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> ~Placer()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.17.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="Placer.html">Placer</A>& operator=(const <!1><A HREF="Placer.html">Placer</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="Placer"></A>
|
||||
<A NAME="DOC.2.17.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline Placer()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="Placer"></A>
|
||||
<A NAME="DOC.2.17.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline Placer(const <!1><A HREF="Placer.html#DOC.2.17.7">Placer</A> &copy, const osg::CopyOp &copyop)</B></TT>
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
<HR>
|
||||
<DL><DT><B>Direct child classes:
|
||||
</B><DD><A HREF="SegmentPlacer.html">SegmentPlacer</A><BR>
|
||||
<A HREF="MultiSegmentPlacer.html">MultiSegmentPlacer</A><BR>
|
||||
<A HREF="CenteredPlacer.html">CenteredPlacer</A><BR>
|
||||
</DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
106
doc/doc++/osgParticle/PointPlacer.html
Normal file
106
doc/doc++/osgParticle/PointPlacer.html
Normal file
@@ -0,0 +1,106 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::PointPlacer</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::PointPlacer</A></H2></H2><BLOCKQUOTE>A point-shaped particle placer.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=125>
|
||||
<param name=classes value="Mosg::Object,M,CPlacer,MPlacer.html,CCenteredPlacer,MCenteredPlacer.html,CPointPlacer,MPointPlacer.html">
|
||||
<param name=before value="M,M,M,M">
|
||||
<param name=after value="Md_SPSP,Md_SP,Md_,M">
|
||||
<param name=indent value="0,1,2,3">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.18.1">META_Object</A></B>(<!1><A HREF="PointPlacer.html">PointPlacer</A>)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.18.4">PointPlacer</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.18.5">PointPlacer</A></B>(const <!1><A HREF="PointPlacer.html#DOC.2.18.5">PointPlacer</A> &copy, const osg::CopyOp &copyop)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.18.6">place</A></B>(<!1><A HREF="Particle.html">Particle</A>* P) const
|
||||
<DD><I>Place a particle.</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.18.2">~PointPlacer</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="PointPlacer.html">PointPlacer</A>& <B><A HREF="#DOC.2.18.3">operator=</A></B>(const <!1><A HREF="PointPlacer.html">PointPlacer</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="CenteredPlacer.html">CenteredPlacer</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual const char* <B>className</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual bool <B>isSameKindAs</B>(const osg::Object* obj) const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const osg::Vec3& <B>getCenter</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setCenter</B>(const osg::Vec3 &v)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setCenter</B>(float x, float y, float z)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="Placer.html">Placer</A>:</H3>
|
||||
<DL>
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>A point-shaped particle placer.
|
||||
This placer class uses the center point defined in its base class <CODE>CenteredPlacer</CODE>
|
||||
to place there all incoming particles.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="META_Object"></A>
|
||||
<A NAME="DOC.2.18.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> META_Object(<!1><A HREF="PointPlacer.html">PointPlacer</A>)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~PointPlacer"></A>
|
||||
<A NAME="DOC.2.18.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~PointPlacer()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.18.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="PointPlacer.html">PointPlacer</A>& operator=(const <!1><A HREF="PointPlacer.html">PointPlacer</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="PointPlacer"></A>
|
||||
<A NAME="DOC.2.18.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline PointPlacer()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="PointPlacer"></A>
|
||||
<A NAME="DOC.2.18.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline PointPlacer(const <!1><A HREF="PointPlacer.html#DOC.2.18.5">PointPlacer</A> &copy, const osg::CopyOp &copyop)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="place"></A>
|
||||
<A NAME="DOC.2.18.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void place(<!1><A HREF="Particle.html">Particle</A>* P) const </B></TT>
|
||||
<DD>Place a particle.
|
||||
This method is called automatically by <CODE>ModularEmitter</CODE> and should not be called
|
||||
manually.
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
152
doc/doc++/osgParticle/Program.html
Normal file
152
doc/doc++/osgParticle/Program.html
Normal file
@@ -0,0 +1,152 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class OSGPARTICLE_EXPORT osgParticle::Program</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class OSGPARTICLE_EXPORT <A HREF="#DOC.DOCU">osgParticle::Program</A></H2></H2><BLOCKQUOTE>An abstract <CODE>ParticleProcessor</CODE> descendant for modifying particles "on the fly" during the cull traversal.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=125>
|
||||
<param name=classes value="Mosg::Node,M,CParticleProcessor,MParticleProcessor.html,CProgram,MProgram.html,CModularProgram,MModularProgram.html">
|
||||
<param name=before value="M,M,M,M^_">
|
||||
<param name=after value="Md_SP,Md_,M,M">
|
||||
<param name=indent value="0,1,2,2">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.19.1">Program</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.19.2">Program</A></B>(const <!1><A HREF="Program.html#DOC.2.19.2">Program</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual const char* <B><A HREF="#DOC.2.19.3">className</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual bool <B><A HREF="#DOC.2.19.4">isSameKindAs</A></B>(const osg::Object* obj)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual void <B><A HREF="#DOC.2.19.5">accept</A></B>(osg::NodeVisitor& nv)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.19.9">process</A></B>(double dt)
|
||||
<DD><I>Implementation of <CODE>ParticleProcessor::process()</CODE>.</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.19.6">~Program</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="Program.html">Program</A>& <B><A HREF="#DOC.2.19.7">operator=</A></B>(const <!1><A HREF="Program.html">Program</A> &)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual void <B><A HREF="#DOC.2.19.8">execute</A></B>(double dt) = 0
|
||||
<DD><I>Execute the program on the particle system.</I>
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="ParticleProcessor.html">ParticleProcessor</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline <!1><A HREF="ParticleProcessor.html#DOC.2.14.1">ReferenceFrame</A> <B>getReferenceFrame</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>void <B>traverse</B>(osg::NodeVisitor &nv)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline ParticleProcessor::ReferenceFrame <B>getReferenceFrame</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setReferenceFrame</B>(<!1><A HREF="ParticleProcessor.html#DOC.2.14.1">ReferenceFrame</A> rf)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline bool <B>isEnabled</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setEnabled</B>(bool v)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* <B>getParticleSystem</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const <!1><A HREF="ParticleSystem.html">ParticleSystem</A>* <B>getParticleSystem</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setParticleSystem</B>(<!1><A HREF="ParticleSystem.html">ParticleSystem</A>* ps)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const bool <B>computeBound</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const osg::Matrix& <B>getLocalToWorldMatrix</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const osg::Matrix& <B>getWorldToLocalMatrix</B>()
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>transformLocalToWorld</B>(const osg::Vec3 &P)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>transformWorldToLocal</B>(const osg::Vec3 &P)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>rotateLocalToWorld</B>(const osg::Vec3 &P)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline osg::Vec3 <B>rotateWorldToLocal</B>(const osg::Vec3 &P)
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Public Members</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>enum <B>ReferenceFrame</B>
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>An abstract <CODE>ParticleProcessor</CODE> descendant for modifying particles "on the fly"
|
||||
during the cull traversal.
|
||||
Descendants of this class must implement the <CODE>execute()</CODE> method, which should iterate
|
||||
through all particles in the linked particle system and modify them somehow
|
||||
(usually updating their velocity vector).</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="Program"></A>
|
||||
<A NAME="DOC.2.19.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> Program()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="Program"></A>
|
||||
<A NAME="DOC.2.19.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> Program(const <!1><A HREF="Program.html#DOC.2.19.2">Program</A> &copy, const osg::CopyOp &copyop = osg::CopyOp::SHALLOW_COPY)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="className"></A>
|
||||
<A NAME="DOC.2.19.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual const char* className() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="isSameKindAs"></A>
|
||||
<A NAME="DOC.2.19.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual bool isSameKindAs(const osg::Object* obj)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="accept"></A>
|
||||
<A NAME="DOC.2.19.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual void accept(osg::NodeVisitor& nv)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~Program"></A>
|
||||
<A NAME="DOC.2.19.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~Program()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.19.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="Program.html">Program</A>& operator=(const <!1><A HREF="Program.html">Program</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="execute"></A>
|
||||
<A NAME="DOC.2.19.8"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual void execute(double dt) = 0</B></TT>
|
||||
<DD>Execute the program on the particle system. Must be overriden in descendant classes.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="process"></A>
|
||||
<A NAME="DOC.2.19.9"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void process(double dt)</B></TT>
|
||||
<DD>Implementation of <CODE>ParticleProcessor::process()</CODE>. Do not call this method by yourself.
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
<HR>
|
||||
<DL><DT><B>Direct child classes:
|
||||
</B><DD><A HREF="ModularProgram.html">ModularProgram</A><BR>
|
||||
</DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
170
doc/doc++/osgParticle/RadialShooter.html
Normal file
170
doc/doc++/osgParticle/RadialShooter.html
Normal file
@@ -0,0 +1,170 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::RadialShooter</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::RadialShooter</A></H2></H2><BLOCKQUOTE>A shooter class that shoots particles radially.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=95>
|
||||
<param name=classes value="Mosg::Object,M,CShooter,MShooter.html,CRadialShooter,MRadialShooter.html">
|
||||
<param name=before value="M,M,M">
|
||||
<param name=after value="Md_SP,Md_,M">
|
||||
<param name=indent value="0,1,2">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.20.1">META_Object</A></B>(<!1><A HREF="RadialShooter.html">RadialShooter</A>)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.20.7">RadialShooter</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.20.8">RadialShooter</A></B>(const <!1><A HREF="RadialShooter.html#DOC.2.20.8">RadialShooter</A> &copy, const osg::CopyOp &copyop)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="rangef.html">rangef</A>& <B><A HREF="#DOC.2.20.9">getThetaRange</A></B>() const
|
||||
<DD><I>Get the range of possible values for <B>theta</B> angle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="rangef.html">rangef</A>& <B><A HREF="#DOC.2.20.10">getPhiRange</A></B>() const
|
||||
<DD><I>Get the range of possible values for <B>phi</B> angle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="rangef.html">rangef</A>& <B><A HREF="#DOC.2.20.11">getInitialSpeedRange</A></B>() const
|
||||
<DD><I>Get the range of possible values for initial speed of particles</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.20.12">setThetaRange</A></B>(const <!1><A HREF="rangef.html">rangef</A> &r)
|
||||
<DD><I>Set the range of possible values for <B>theta</B> angle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.20.13">setThetaRange</A></B>(float r1, float r2)
|
||||
<DD><I>Set the range of possible values for <B>theta</B> angle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.20.14">setPhiRange</A></B>(const <!1><A HREF="rangef.html">rangef</A> &r)
|
||||
<DD><I>Set the range of possible values for <B>phi</B> angle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.20.15">setPhiRange</A></B>(float r1, float r2)
|
||||
<DD><I>Set the range of possible values for <B>phi</B> angle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.20.16">setInitialSpeedRange</A></B>(const <!1><A HREF="rangef.html">rangef</A> &r)
|
||||
<DD><I>Set the range of possible values for initial speed of particles</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.20.17">setInitialSpeedRange</A></B>(float r1, float r2)
|
||||
<DD><I>Set the range of possible values for initial speed of particles</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.20.18">shoot</A></B>(<!1><A HREF="Particle.html">Particle</A>* P) const
|
||||
<DD><I>Shoot a particle.</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.20.2">~RadialShooter</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="RadialShooter.html">RadialShooter</A>& <B><A HREF="#DOC.2.20.3">operator=</A></B>(const <!1><A HREF="RadialShooter.html">RadialShooter</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="Shooter.html">Shooter</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual const char* <B>className</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual bool <B>isSameKindAs</B>(const osg::Object* obj) const
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>A shooter class that shoots particles radially.
|
||||
This shooter computes the velocity vector of incoming particles by choosing a
|
||||
random direction and a random speed. Both direction and speed are chosen within
|
||||
specified ranges. The direction is defined by two angles: <B>theta</B>, which
|
||||
is the angle between the velocity vector and the Z axis, and <B>phi</B>, which is
|
||||
the angle between the X axis and the velocity vector projected onto the X-Y plane.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="META_Object"></A>
|
||||
<A NAME="DOC.2.20.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> META_Object(<!1><A HREF="RadialShooter.html">RadialShooter</A>)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~RadialShooter"></A>
|
||||
<A NAME="DOC.2.20.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~RadialShooter()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.20.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="RadialShooter.html">RadialShooter</A>& operator=(const <!1><A HREF="RadialShooter.html">RadialShooter</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="RadialShooter"></A>
|
||||
<A NAME="DOC.2.20.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline RadialShooter()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="RadialShooter"></A>
|
||||
<A NAME="DOC.2.20.8"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline RadialShooter(const <!1><A HREF="RadialShooter.html#DOC.2.20.8">RadialShooter</A> &copy, const osg::CopyOp &copyop)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getThetaRange"></A>
|
||||
<A NAME="DOC.2.20.9"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="rangef.html">rangef</A>& getThetaRange() const </B></TT>
|
||||
<DD>Get the range of possible values for <B>theta</B> angle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getPhiRange"></A>
|
||||
<A NAME="DOC.2.20.10"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="rangef.html">rangef</A>& getPhiRange() const </B></TT>
|
||||
<DD>Get the range of possible values for <B>phi</B> angle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getInitialSpeedRange"></A>
|
||||
<A NAME="DOC.2.20.11"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="rangef.html">rangef</A>& getInitialSpeedRange() const </B></TT>
|
||||
<DD>Get the range of possible values for initial speed of particles
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setThetaRange"></A>
|
||||
<A NAME="DOC.2.20.12"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setThetaRange(const <!1><A HREF="rangef.html">rangef</A> &r)</B></TT>
|
||||
<DD>Set the range of possible values for <B>theta</B> angle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setThetaRange"></A>
|
||||
<A NAME="DOC.2.20.13"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setThetaRange(float r1, float r2)</B></TT>
|
||||
<DD>Set the range of possible values for <B>theta</B> angle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setPhiRange"></A>
|
||||
<A NAME="DOC.2.20.14"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setPhiRange(const <!1><A HREF="rangef.html">rangef</A> &r)</B></TT>
|
||||
<DD>Set the range of possible values for <B>phi</B> angle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setPhiRange"></A>
|
||||
<A NAME="DOC.2.20.15"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setPhiRange(float r1, float r2)</B></TT>
|
||||
<DD>Set the range of possible values for <B>phi</B> angle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setInitialSpeedRange"></A>
|
||||
<A NAME="DOC.2.20.16"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setInitialSpeedRange(const <!1><A HREF="rangef.html">rangef</A> &r)</B></TT>
|
||||
<DD>Set the range of possible values for initial speed of particles
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setInitialSpeedRange"></A>
|
||||
<A NAME="DOC.2.20.17"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setInitialSpeedRange(float r1, float r2)</B></TT>
|
||||
<DD>Set the range of possible values for initial speed of particles
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="shoot"></A>
|
||||
<A NAME="DOC.2.20.18"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void shoot(<!1><A HREF="Particle.html">Particle</A>* P) const </B></TT>
|
||||
<DD>Shoot a particle. Do not call this method manually.
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
99
doc/doc++/osgParticle/RandomRateCounter.html
Normal file
99
doc/doc++/osgParticle/RandomRateCounter.html
Normal file
@@ -0,0 +1,99 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::RandomRateCounter</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::RandomRateCounter</A></H2></H2><HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=125>
|
||||
<param name=classes value="Mosg::Object,M,CCounter,MCounter.html,CVariableRateCounter,MVariableRateCounter.html,CRandomRateCounter,MRandomRateCounter.html">
|
||||
<param name=before value="M,M,M,M">
|
||||
<param name=after value="Md_SPSP,Md_SP,Md_,M">
|
||||
<param name=indent value="0,1,2,3">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.21.1">META_Object</A></B>(<!1><A HREF="RandomRateCounter.html">RandomRateCounter</A>)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.21.4">RandomRateCounter</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.21.5">RandomRateCounter</A></B>(const <!1><A HREF="RandomRateCounter.html#DOC.2.21.5">RandomRateCounter</A> &copy, const osg::CopyOp &copyop)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline int <B><A HREF="#DOC.2.21.6">numParticlesToCreate</A></B>(double dt) const
|
||||
<DD><I>Return the number of particles to be created in this frame</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.21.2">~RandomRateCounter</A></B>()
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="VariableRateCounter.html">VariableRateCounter</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual const char* <B>className</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual bool <B>isSameKindAs</B>(const osg::Object* obj) const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const <!1><A HREF="rangef.html">rangef</A>& <B>getRateRange</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setRateRange</B>(const <!1><A HREF="rangef.html">rangef</A> &r)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setRateRange</B>(float minrange, float maxrange)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="Counter.html">Counter</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif><!1><A HREF="Counter.html">Counter</A>& <B>operator=</B>(const <!1><A HREF="Counter.html">Counter</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<DL>
|
||||
|
||||
<A NAME="META_Object"></A>
|
||||
<A NAME="DOC.2.21.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> META_Object(<!1><A HREF="RandomRateCounter.html">RandomRateCounter</A>)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~RandomRateCounter"></A>
|
||||
<A NAME="DOC.2.21.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~RandomRateCounter()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="RandomRateCounter"></A>
|
||||
<A NAME="DOC.2.21.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline RandomRateCounter()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="RandomRateCounter"></A>
|
||||
<A NAME="DOC.2.21.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline RandomRateCounter(const <!1><A HREF="RandomRateCounter.html#DOC.2.21.5">RandomRateCounter</A> &copy, const osg::CopyOp &copyop)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="numParticlesToCreate"></A>
|
||||
<A NAME="DOC.2.21.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline int numParticlesToCreate(double dt) const </B></TT>
|
||||
<DD>Return the number of particles to be created in this frame
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
154
doc/doc++/osgParticle/SectorPlacer.html
Normal file
154
doc/doc++/osgParticle/SectorPlacer.html
Normal file
@@ -0,0 +1,154 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::SectorPlacer</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::SectorPlacer</A></H2></H2><BLOCKQUOTE>A sector-shaped particle placer.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=125>
|
||||
<param name=classes value="Mosg::Object,M,CPlacer,MPlacer.html,CCenteredPlacer,MCenteredPlacer.html,CSectorPlacer,MSectorPlacer.html">
|
||||
<param name=before value="M,M,M,M">
|
||||
<param name=after value="Md_SPSP,Md_SP,Md_,M">
|
||||
<param name=indent value="0,1,2,3">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.26.1">META_Object</A></B>(<!1><A HREF="SectorPlacer.html">SectorPlacer</A>)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.26.6">SectorPlacer</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.26.7">SectorPlacer</A></B>(const <!1><A HREF="SectorPlacer.html#DOC.2.26.7">SectorPlacer</A> &copy, const osg::CopyOp &copyop)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="rangef.html">rangef</A>& <B><A HREF="#DOC.2.26.8">getRadiusRange</A></B>() const
|
||||
<DD><I>Get the range of possible values for radius</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="rangef.html">rangef</A>& <B><A HREF="#DOC.2.26.9">getPhiRange</A></B>() const
|
||||
<DD><I>Get the range of possible values for the central angle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.26.10">setRadiusRange</A></B>(const <!1><A HREF="rangef.html">rangef</A> &r)
|
||||
<DD><I>Set the range of possible values for radius</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.26.11">setRadiusRange</A></B>(float r1, float r2)
|
||||
<DD><I>Set the range of possible values for radius</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.26.12">setPhiRange</A></B>(const <!1><A HREF="rangef.html">rangef</A> &r)
|
||||
<DD><I>Set the range of possible values for the central angle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.26.13">setPhiRange</A></B>(float r1, float r2)
|
||||
<DD><I>Set the range of possible values for the central angle</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.26.14">place</A></B>(<!1><A HREF="Particle.html">Particle</A>* P) const
|
||||
<DD><I>Place a particle.</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.26.2">~SectorPlacer</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="SectorPlacer.html">SectorPlacer</A>& <B><A HREF="#DOC.2.26.3">operator=</A></B>(const <!1><A HREF="SectorPlacer.html">SectorPlacer</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="CenteredPlacer.html">CenteredPlacer</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual const char* <B>className</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual bool <B>isSameKindAs</B>(const osg::Object* obj) const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline const osg::Vec3& <B>getCenter</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setCenter</B>(const osg::Vec3 &v)
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>inline void <B>setCenter</B>(float x, float y, float z)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="Placer.html">Placer</A>:</H3>
|
||||
<DL>
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>A sector-shaped particle placer.
|
||||
This placer sets the initial position of incoming particle by choosing a random position
|
||||
within a circular sector; this sector is defined by three parameters: a <I>center point</I>,
|
||||
which is inherited directly from <CODE>osgParticle::CenteredPlacer</CODE>, a range of values
|
||||
for <I>radius</I>, and a range of values for the <I>central angle</I> (sometimes called <B>phi</B>). </BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="META_Object"></A>
|
||||
<A NAME="DOC.2.26.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> META_Object(<!1><A HREF="SectorPlacer.html">SectorPlacer</A>)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~SectorPlacer"></A>
|
||||
<A NAME="DOC.2.26.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~SectorPlacer()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.26.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="SectorPlacer.html">SectorPlacer</A>& operator=(const <!1><A HREF="SectorPlacer.html">SectorPlacer</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="SectorPlacer"></A>
|
||||
<A NAME="DOC.2.26.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline SectorPlacer()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="SectorPlacer"></A>
|
||||
<A NAME="DOC.2.26.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline SectorPlacer(const <!1><A HREF="SectorPlacer.html#DOC.2.26.7">SectorPlacer</A> &copy, const osg::CopyOp &copyop)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getRadiusRange"></A>
|
||||
<A NAME="DOC.2.26.8"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="rangef.html">rangef</A>& getRadiusRange() const </B></TT>
|
||||
<DD>Get the range of possible values for radius
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getPhiRange"></A>
|
||||
<A NAME="DOC.2.26.9"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="rangef.html">rangef</A>& getPhiRange() const </B></TT>
|
||||
<DD>Get the range of possible values for the central angle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setRadiusRange"></A>
|
||||
<A NAME="DOC.2.26.10"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setRadiusRange(const <!1><A HREF="rangef.html">rangef</A> &r)</B></TT>
|
||||
<DD>Set the range of possible values for radius
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setRadiusRange"></A>
|
||||
<A NAME="DOC.2.26.11"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setRadiusRange(float r1, float r2)</B></TT>
|
||||
<DD>Set the range of possible values for radius
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setPhiRange"></A>
|
||||
<A NAME="DOC.2.26.12"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setPhiRange(const <!1><A HREF="rangef.html">rangef</A> &r)</B></TT>
|
||||
<DD>Set the range of possible values for the central angle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setPhiRange"></A>
|
||||
<A NAME="DOC.2.26.13"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setPhiRange(float r1, float r2)</B></TT>
|
||||
<DD>Set the range of possible values for the central angle
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="place"></A>
|
||||
<A NAME="DOC.2.26.14"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void place(<!1><A HREF="Particle.html">Particle</A>* P) const </B></TT>
|
||||
<DD>Place a particle. Do not call it manually.
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
152
doc/doc++/osgParticle/SegmentPlacer.html
Normal file
152
doc/doc++/osgParticle/SegmentPlacer.html
Normal file
@@ -0,0 +1,152 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::SegmentPlacer</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::SegmentPlacer</A></H2></H2><BLOCKQUOTE>A segment-shaped particle placer.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=95>
|
||||
<param name=classes value="Mosg::Object,M,CPlacer,MPlacer.html,CSegmentPlacer,MSegmentPlacer.html">
|
||||
<param name=before value="M,M,M">
|
||||
<param name=after value="Md_SP,Md_,M">
|
||||
<param name=indent value="0,1,2">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.27.1">META_Object</A></B>(<!1><A HREF="SegmentPlacer.html">SegmentPlacer</A>)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.27.6">SegmentPlacer</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.27.7">SegmentPlacer</A></B>(const <!1><A HREF="SegmentPlacer.html#DOC.2.27.7">SegmentPlacer</A> &copy, const osg::CopyOp &copyop)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const osg::Vec3& <B><A HREF="#DOC.2.27.8">getVertexA</A></B>() const
|
||||
<DD><I>get vertex <B>A</B></I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const osg::Vec3& <B><A HREF="#DOC.2.27.9">getVertexB</A></B>() const
|
||||
<DD><I>get vertex <B>B</B></I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.27.10">setSegment</A></B>(const osg::Vec3 &A, const osg::Vec3 &B)
|
||||
<DD><I>Set both vertices</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.27.11">place</A></B>(<!1><A HREF="Particle.html">Particle</A>* P) const
|
||||
<DD><I>Place a particle.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.27.12">setVertexA</A></B>(const osg::Vec3 &v)
|
||||
<DD><I>Set vertex <B>A</B> of the segment as a vector</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.27.13">setVertexA</A></B>(float x, float y, float z)
|
||||
<DD><I>Set vertex <B>A</B> of the segment as three floats</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.27.14">setVertexB</A></B>(const osg::Vec3 &v)
|
||||
<DD><I>Set vertex <B>B</B> of the segment as a vector</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.27.15">setVertexB</A></B>(float x, float y, float z)
|
||||
<DD><I>Set vertex <B>B</B> of the segment as three floats</I>
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.27.2">~SegmentPlacer</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="SegmentPlacer.html">SegmentPlacer</A>& <B><A HREF="#DOC.2.27.3">operator=</A></B>(const <!1><A HREF="SegmentPlacer.html">SegmentPlacer</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="Placer.html">Placer</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual const char* <B>className</B>() const
|
||||
<DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual bool <B>isSameKindAs</B>(const osg::Object* obj) const
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>A segment-shaped particle placer.
|
||||
To use this placer you have to define a segment, by setting its two vertices (<B>A</B> and <B>B</B>);
|
||||
when an emitter requests a <CODE>SegmentPlacer</CODE> to place a particle, the position is chosen randomly
|
||||
within that segment.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="META_Object"></A>
|
||||
<A NAME="DOC.2.27.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> META_Object(<!1><A HREF="SegmentPlacer.html">SegmentPlacer</A>)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~SegmentPlacer"></A>
|
||||
<A NAME="DOC.2.27.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~SegmentPlacer()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.27.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="SegmentPlacer.html">SegmentPlacer</A>& operator=(const <!1><A HREF="SegmentPlacer.html">SegmentPlacer</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="SegmentPlacer"></A>
|
||||
<A NAME="DOC.2.27.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline SegmentPlacer()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="SegmentPlacer"></A>
|
||||
<A NAME="DOC.2.27.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline SegmentPlacer(const <!1><A HREF="SegmentPlacer.html#DOC.2.27.7">SegmentPlacer</A> &copy, const osg::CopyOp &copyop)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getVertexA"></A>
|
||||
<A NAME="DOC.2.27.8"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const osg::Vec3& getVertexA() const </B></TT>
|
||||
<DD>get vertex <B>A</B>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getVertexB"></A>
|
||||
<A NAME="DOC.2.27.9"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const osg::Vec3& getVertexB() const </B></TT>
|
||||
<DD>get vertex <B>B</B>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setSegment"></A>
|
||||
<A NAME="DOC.2.27.10"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setSegment(const osg::Vec3 &A, const osg::Vec3 &B)</B></TT>
|
||||
<DD>Set both vertices
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="place"></A>
|
||||
<A NAME="DOC.2.27.11"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void place(<!1><A HREF="Particle.html">Particle</A>* P) const </B></TT>
|
||||
<DD>Place a particle. This method is called by <CODE>ModularEmitter</CODE>, do not call it manually.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setVertexA"></A>
|
||||
<A NAME="DOC.2.27.12"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setVertexA(const osg::Vec3 &v)</B></TT>
|
||||
<DD>Set vertex <B>A</B> of the segment as a vector
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setVertexA"></A>
|
||||
<A NAME="DOC.2.27.13"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setVertexA(float x, float y, float z)</B></TT>
|
||||
<DD>Set vertex <B>A</B> of the segment as three floats
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setVertexB"></A>
|
||||
<A NAME="DOC.2.27.14"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setVertexB(const osg::Vec3 &v)</B></TT>
|
||||
<DD>Set vertex <B>B</B> of the segment as a vector
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setVertexB"></A>
|
||||
<A NAME="DOC.2.27.15"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setVertexB(float x, float y, float z)</B></TT>
|
||||
<DD>Set vertex <B>B</B> of the segment as three floats
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
|
||||
<HR><DL><DT><B>This class has no child classes.</B></DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
94
doc/doc++/osgParticle/Shooter.html
Normal file
94
doc/doc++/osgParticle/Shooter.html
Normal file
@@ -0,0 +1,94 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::Shooter</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::Shooter</A></H2></H2><BLOCKQUOTE>An abstract base class used by ModularEmitter to "shoot" the particles after they have been placed.</BLOCKQUOTE>
|
||||
<HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=95>
|
||||
<param name=classes value="Mosg::Object,M,CShooter,MShooter.html,CRadialShooter,MRadialShooter.html">
|
||||
<param name=before value="M,M,M^_">
|
||||
<param name=after value="Md_,M,M">
|
||||
<param name=indent value="0,1,1">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual const char* <B><A HREF="#DOC.2.28.1">className</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual bool <B><A HREF="#DOC.2.28.2">isSameKindAs</A></B>(const osg::Object* obj) const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual void <B><A HREF="#DOC.2.28.3">shoot</A></B>(<!1><A HREF="Particle.html">Particle</A>* P) const = 0
|
||||
<DD><I>Shoot a particle.</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.28.6">Shooter</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.28.7">Shooter</A></B>(const <!1><A HREF="Shooter.html#DOC.2.28.7">Shooter</A> &copy, const osg::CopyOp &copyop)
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.28.4">~Shooter</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif><!1><A HREF="Shooter.html">Shooter</A>& <B><A HREF="#DOC.2.28.5">operator=</A></B>(const <!1><A HREF="Shooter.html">Shooter</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>An abstract base class used by ModularEmitter to "shoot" the particles after they have been placed.
|
||||
Descendants of this class must override the <CODE>shoot()</CODE> method.</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="className"></A>
|
||||
<A NAME="DOC.2.28.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual const char* className() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="isSameKindAs"></A>
|
||||
<A NAME="DOC.2.28.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual bool isSameKindAs(const osg::Object* obj) const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="shoot"></A>
|
||||
<A NAME="DOC.2.28.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual void shoot(<!1><A HREF="Particle.html">Particle</A>* P) const = 0</B></TT>
|
||||
<DD>Shoot a particle. Must be overriden by descendants.
|
||||
This method should only set the velocity vector of particle <CODE>P</CODE>, leaving other
|
||||
attributes unchanged.
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~Shooter"></A>
|
||||
<A NAME="DOC.2.28.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~Shooter()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="operator="></A>
|
||||
<A NAME="DOC.2.28.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B><!1><A HREF="Shooter.html">Shooter</A>& operator=(const <!1><A HREF="Shooter.html">Shooter</A> &)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="Shooter"></A>
|
||||
<A NAME="DOC.2.28.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline Shooter()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="Shooter"></A>
|
||||
<A NAME="DOC.2.28.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline Shooter(const <!1><A HREF="Shooter.html#DOC.2.28.7">Shooter</A> &copy, const osg::CopyOp &copyop)</B></TT>
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
<HR>
|
||||
<DL><DT><B>Direct child classes:
|
||||
</B><DD><A HREF="RadialShooter.html">RadialShooter</A><BR>
|
||||
</DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
106
doc/doc++/osgParticle/VariableRateCounter.html
Normal file
106
doc/doc++/osgParticle/VariableRateCounter.html
Normal file
@@ -0,0 +1,106 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>class osgParticle::VariableRateCounter</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>class <A HREF="#DOC.DOCU">osgParticle::VariableRateCounter</A></H2></H2><HR>
|
||||
|
||||
<H2>Inheritance:</H2>
|
||||
<APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=125>
|
||||
<param name=classes value="Mosg::Object,M,CCounter,MCounter.html,CVariableRateCounter,MVariableRateCounter.html,CRandomRateCounter,MRandomRateCounter.html">
|
||||
<param name=before value="M,M,M,M^_">
|
||||
<param name=after value="Md_SP,Md_,M,M">
|
||||
<param name=indent value="0,1,2,2">
|
||||
<param name=arrowdir value="down">
|
||||
</APPLET>
|
||||
<HR>
|
||||
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual const char* <B><A HREF="#DOC.2.29.1">className</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual bool <B><A HREF="#DOC.2.29.2">isSameKindAs</A></B>(const osg::Object* obj) const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.29.5">VariableRateCounter</A></B>()
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline <B><A HREF="#DOC.2.29.6">VariableRateCounter</A></B>(const <!1><A HREF="VariableRateCounter.html#DOC.2.29.6">VariableRateCounter</A> &copy, const osg::CopyOp &copyop)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline const <!1><A HREF="rangef.html">rangef</A>& <B><A HREF="#DOC.2.29.7">getRateRange</A></B>() const
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.29.8">setRateRange</A></B>(const <!1><A HREF="rangef.html">rangef</A> &r)
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>inline void <B><A HREF="#DOC.2.29.9">setRateRange</A></B>(float minrange, float maxrange)
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>virtual <B><A HREF="#DOC.2.29.3">~VariableRateCounter</A></B>()
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
<HR><H3>Inherited from <A HREF="Counter.html">Counter</A>:</H3>
|
||||
<DL>
|
||||
<P><DL>
|
||||
<DT><H3>Public Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif>virtual int <B>numParticlesToCreate</B>(double dt) const
|
||||
</DL></P>
|
||||
|
||||
<P><DL>
|
||||
<DT><H3>Protected Methods</H3><DD><DT>
|
||||
<IMG ALT="o" SRC=icon2.gif><!1><A HREF="Counter.html">Counter</A>& <B>operator=</B>(const <!1><A HREF="Counter.html">Counter</A> &)
|
||||
</DL></P>
|
||||
|
||||
</DL>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<DL>
|
||||
|
||||
<A NAME="className"></A>
|
||||
<A NAME="DOC.2.29.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual const char* className() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="isSameKindAs"></A>
|
||||
<A NAME="DOC.2.29.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual bool isSameKindAs(const osg::Object* obj) const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="~VariableRateCounter"></A>
|
||||
<A NAME="DOC.2.29.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>virtual ~VariableRateCounter()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="VariableRateCounter"></A>
|
||||
<A NAME="DOC.2.29.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline VariableRateCounter()</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="VariableRateCounter"></A>
|
||||
<A NAME="DOC.2.29.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline VariableRateCounter(const <!1><A HREF="VariableRateCounter.html#DOC.2.29.6">VariableRateCounter</A> &copy, const osg::CopyOp &copyop)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="getRateRange"></A>
|
||||
<A NAME="DOC.2.29.7"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline const <!1><A HREF="rangef.html">rangef</A>& getRateRange() const </B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setRateRange"></A>
|
||||
<A NAME="DOC.2.29.8"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setRateRange(const <!1><A HREF="rangef.html">rangef</A> &r)</B></TT>
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="setRateRange"></A>
|
||||
<A NAME="DOC.2.29.9"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>inline void setRateRange(float minrange, float maxrange)</B></TT>
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
<HR>
|
||||
<DL><DT><B>Direct child classes:
|
||||
</B><DD><A HREF="RandomRateCounter.html">RandomRateCounter</A><BR>
|
||||
</DL>
|
||||
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
BIN
doc/doc++/osgParticle/icon1.gif
Normal file
BIN
doc/doc++/osgParticle/icon1.gif
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 326 B |
BIN
doc/doc++/osgParticle/icon2.gif
Normal file
BIN
doc/doc++/osgParticle/icon2.gif
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 326 B |
61
doc/doc++/osgParticle/index.html
Normal file
61
doc/doc++/osgParticle/index.html
Normal file
@@ -0,0 +1,61 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>Table of Contents</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H1>Table of Contents</H1>
|
||||
<H2>Namespaces</H2>
|
||||
<UL>
|
||||
<LI><A HREF="osgParticle.html">osgParticle</A>
|
||||
</UL>
|
||||
<H2>Functions</H2>
|
||||
<UL>
|
||||
<LI><A HREF="General.html#osgParticleGetLibraryName">osgParticleGetLibraryName</A>
|
||||
<LI><A HREF="General.html#osgParticleGetVersion">osgParticleGetVersion</A>
|
||||
</UL>
|
||||
<H2>Macros</H2>
|
||||
<UL>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_ACCELOPERATOR_">OSGPARTICLE_ACCELOPERATOR_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_CENTEREDPLACER_">OSGPARTICLE_CENTEREDPLACER_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_COUNTER_">OSGPARTICLE_COUNTER_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_EMITTER_">OSGPARTICLE_EMITTER_</A>
|
||||
<LI><B>OSGPARTICLE_EXPORT:</B>
|
||||
<UL>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_EXPORT">OSGPARTICLE_EXPORT</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_EXPORT">OSGPARTICLE_EXPORT</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_EXPORT">OSGPARTICLE_EXPORT</A>
|
||||
</UL>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_EXPORT_">OSGPARTICLE_EXPORT_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_FLUIDFRICTIONOPERATOR_">OSGPARTICLE_FLUIDFRICTIONOPERATOR_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_FORCEOPERATOR_">OSGPARTICLE_FORCEOPERATOR_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_INTERPOLATOR_">OSGPARTICLE_INTERPOLATOR_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_LINEARINTERPOLATOR_">OSGPARTICLE_LINEARINTERPOLATOR_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_MODULAREMITTER_">OSGPARTICLE_MODULAREMITTER_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_MODULARPROGRAM_">OSGPARTICLE_MODULARPROGRAM_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_MULTISEGMENTPLACER_">OSGPARTICLE_MULTISEGMENTPLACER_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_OPERATOR_">OSGPARTICLE_OPERATOR_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_PARTICLEPROCESSOR_">OSGPARTICLE_PARTICLEPROCESSOR_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_PARTICLESYSTEMUPDATER_">OSGPARTICLE_PARTICLESYSTEMUPDATER_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_PARTICLESYSTEM_">OSGPARTICLE_PARTICLESYSTEM_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_PARTICLE_">OSGPARTICLE_PARTICLE_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_PLACER_">OSGPARTICLE_PLACER_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_POINTPLACER_">OSGPARTICLE_POINTPLACER_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_PROGRAM_">OSGPARTICLE_PROGRAM_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_RADIALSHOOTER_">OSGPARTICLE_RADIALSHOOTER_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_RANDOMRATECOUNTER_">OSGPARTICLE_RANDOMRATECOUNTER_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_RANGE_">OSGPARTICLE_RANGE_</A>
|
||||
<LI><A HREF="OSGPARTICLE_SECTORPLACER_.html">OSGPARTICLE_SECTORPLACER_</A> <I>Range of osg::Vec4s</I>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_SEGMENTPLACER_">OSGPARTICLE_SEGMENTPLACER_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_SHOOTER_">OSGPARTICLE_SHOOTER_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_VARIABLERATECOUNTER_">OSGPARTICLE_VARIABLERATECOUNTER_</A>
|
||||
<LI><A HREF="General.html#OSGPARTICLE_VERSION_">OSGPARTICLE_VERSION_</A>
|
||||
</UL>
|
||||
<P><I><A HREF="HIER.html">Hierarchy of classes</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
109
doc/doc++/osgParticle/osgParticle.html
Normal file
109
doc/doc++/osgParticle/osgParticle.html
Normal file
@@ -0,0 +1,109 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>namespace osgParticle</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>namespace <A HREF="#DOC.DOCU">osgParticle</A></H2></H2>
|
||||
<HR>
|
||||
<P><DL>
|
||||
<DT>
|
||||
class <B><A HREF="AccelOperator.html">AccelOperator</A></B>: public <!1><A HREF="Operator.html">Operator</A>
|
||||
<DD><I>An operator class that applies a constant acceleration to the particles</I>
|
||||
<DT>
|
||||
class <B><A HREF="CenteredPlacer.html">CenteredPlacer</A></B>: public <!1><A HREF="Placer.html">Placer</A>
|
||||
<DD><I>An abstract placer base class for placers which need a <I>center point</I></I>
|
||||
<DT>
|
||||
class <B><A HREF="Counter.html">Counter</A></B>: public osg::Object
|
||||
<DT>
|
||||
class OSGPARTICLE_EXPORT <B><A HREF="Emitter.html">Emitter</A></B>: public <!1><A HREF="ParticleProcessor.html">ParticleProcessor</A>
|
||||
<DD><I>An abstract base class for particle emitters.</I>
|
||||
<DT>
|
||||
class OSGPARTICLE_EXPORT <B><A HREF="FluidFrictionOperator.html">FluidFrictionOperator</A></B>: public <!1><A HREF="Operator.html">Operator</A>
|
||||
<DD><I>An operator that simulates the friction of a fluid.</I>
|
||||
<DT>
|
||||
class <B><A HREF="ForceOperator.html">ForceOperator</A></B>: public <!1><A HREF="Operator.html">Operator</A>
|
||||
<DD><I>An operator that applies a constant force to the particles.</I>
|
||||
<DT>
|
||||
class <B><A HREF="Interpolator.html">Interpolator</A></B>: public osg::Object
|
||||
<DD><I>An abstract base class for implementing interpolators</I>
|
||||
<DT>
|
||||
class <B><A HREF="LinearInterpolator.html">LinearInterpolator</A></B>: public <!1><A HREF="Interpolator.html">Interpolator</A>
|
||||
<DD><I>A linear interpolator</I>
|
||||
<DT>
|
||||
class OSGPARTICLE_EXPORT <B><A HREF="ModularEmitter.html">ModularEmitter</A></B>: public <!1><A HREF="Emitter.html">Emitter</A>
|
||||
<DD><I>An emitter class that holds three objects to control the creation of particles.</I>
|
||||
<DT>
|
||||
class OSGPARTICLE_EXPORT <B><A HREF="ModularProgram.html">ModularProgram</A></B>: public <!1><A HREF="Program.html">Program</A>
|
||||
<DD><I>A program class for performing operations on particles using a sequence of <I>operators</I>.</I>
|
||||
<DT>
|
||||
class OSGPARTICLE_EXPORT <B><A HREF="MultiSegmentPlacer.html">MultiSegmentPlacer</A></B>: public <!1><A HREF="Placer.html">Placer</A>
|
||||
<DD><I>A polyline-shaped particle placer.</I>
|
||||
<DT>
|
||||
class <B><A HREF="Operator.html">Operator</A></B>: public osg::Object
|
||||
<DD><I>An abstract base class used by <CODE>ModularProgram</CODE> to perform operations on particles before they are updated.</I>
|
||||
<DT>
|
||||
class OSGPARTICLE_EXPORT <B><A HREF="Particle.html">Particle</A></B>
|
||||
<DD><I>Implementation of a <B>particle</B>.</I>
|
||||
<DT>
|
||||
class OSGPARTICLE_EXPORT <B><A HREF="ParticleProcessor.html">ParticleProcessor</A></B>: public osg::Node
|
||||
<DD><I>A common base interface for those classes which need to do something on particles.</I>
|
||||
<DT>
|
||||
class OSGPARTICLE_EXPORT <B><A HREF="ParticleSystem.html">ParticleSystem</A></B>: public osg::Drawable
|
||||
<DD><I>The heart of this class library; its purpose is to hold a set of particles and manage particle creation, update, rendering and destruction.</I>
|
||||
<DT>
|
||||
class OSGPARTICLE_EXPORT <B><A HREF="ParticleSystemUpdater.html">ParticleSystemUpdater</A></B>: public osg::Node
|
||||
<DD><I>A useful node class for updating particle systems automatically.</I>
|
||||
<DT>
|
||||
class <B><A HREF="Placer.html">Placer</A></B>: public osg::Object
|
||||
<DD><I>An abstract base class for implementing <I>particle placers</I>.</I>
|
||||
<DT>
|
||||
class <B><A HREF="PointPlacer.html">PointPlacer</A></B>: public <!1><A HREF="CenteredPlacer.html">CenteredPlacer</A>
|
||||
<DD><I>A point-shaped particle placer.</I>
|
||||
<DT>
|
||||
class OSGPARTICLE_EXPORT <B><A HREF="Program.html">Program</A></B>: public <!1><A HREF="ParticleProcessor.html">ParticleProcessor</A>
|
||||
<DD><I>An abstract <CODE>ParticleProcessor</CODE> descendant for modifying particles "on the fly" during the cull traversal.</I>
|
||||
<DT>
|
||||
class <B><A HREF="RadialShooter.html">RadialShooter</A></B>: public <!1><A HREF="Shooter.html">Shooter</A>
|
||||
<DD><I>A shooter class that shoots particles radially.</I>
|
||||
<DT>
|
||||
class <B><A HREF="RandomRateCounter.html">RandomRateCounter</A></B>: public <!1><A HREF="VariableRateCounter.html">VariableRateCounter</A>
|
||||
<DT>
|
||||
template<class T_> struct <B><A HREF="range.html">range</A></B>
|
||||
<DD><I> A simple struct template useful to store ranges of values as min/max pairs.</I>
|
||||
<DT>
|
||||
typedef <!1><A HREF="range.html">range</A><float> <B><A HREF="rangef.html">rangef</A></B>
|
||||
<DD><I>Range of floats</I>
|
||||
<DT>
|
||||
typedef <!1><A HREF="range.html">range</A><osg::Vec2> <B><A HREF="rangev2.html">rangev2</A></B>
|
||||
<DD><I>Range of osg::Vec2s</I>
|
||||
<DT>
|
||||
typedef <!1><A HREF="range.html">range</A><osg::Vec3> <B><A HREF="rangev3.html">rangev3</A></B>
|
||||
<DD><I>Range of osg::Vec3s</I>
|
||||
<DT>
|
||||
class <B><A HREF="SectorPlacer.html">SectorPlacer</A></B>: public <!1><A HREF="CenteredPlacer.html">CenteredPlacer</A>
|
||||
<DD><I>A sector-shaped particle placer.</I>
|
||||
<DT>
|
||||
class <B><A HREF="SegmentPlacer.html">SegmentPlacer</A></B>: public <!1><A HREF="Placer.html">Placer</A>
|
||||
<DD><I>A segment-shaped particle placer.</I>
|
||||
<DT>
|
||||
class <B><A HREF="Shooter.html">Shooter</A></B>: public osg::Object
|
||||
<DD><I>An abstract base class used by ModularEmitter to "shoot" the particles after they have been placed.</I>
|
||||
<DT>
|
||||
class <B><A HREF="VariableRateCounter.html">VariableRateCounter</A></B>: public <!1><A HREF="Counter.html">Counter</A>
|
||||
</DL></P>
|
||||
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<DL>
|
||||
</DL>
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
81
doc/doc++/osgParticle/range.html
Normal file
81
doc/doc++/osgParticle/range.html
Normal file
@@ -0,0 +1,81 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>template<class T_> struct osgParticle::range</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>template<class T_> struct <A HREF="#DOC.DOCU">osgParticle::range</A></H2></H2><BLOCKQUOTE> A simple struct template useful to store ranges of values as min/max pairs.</BLOCKQUOTE>
|
||||
|
||||
<HR>
|
||||
<P><DL>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>T_ <B><A HREF="#DOC.2.22.1">min</A></B>
|
||||
<DD><I>Lower bound</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>T_ <B><A HREF="#DOC.2.22.2">max</A></B>
|
||||
<DD><I>Higher bound</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.22.3">range</A></B>()
|
||||
<DD><I>Construct the object by calling default constructors for min and max</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif> <B><A HREF="#DOC.2.22.4">range</A></B>(const T_ &mn, const T_ &mx)
|
||||
<DD><I>Construct and initialize min and max directly</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>void <B><A HREF="#DOC.2.22.5">set</A></B>(const T_ &mn, const T_ &mx)
|
||||
<DD><I>Set min and max</I>
|
||||
<DT>
|
||||
<IMG ALT="[more]" BORDER=0 SRC=icon1.gif>T_ <B><A HREF="#DOC.2.22.6">get_random</A></B>() const
|
||||
<DD><I>Get a random value between min and max</I>
|
||||
</DL></P>
|
||||
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>
|
||||
A simple struct template useful to store ranges of values as min/max pairs.
|
||||
This struct template helps storing min/max ranges for values of any kind; class <CODE>T_</CODE> is
|
||||
the type of values to be stored, and it must support operations <CODE>T_ + T_</CODE>, <CODE>T_ - T_</CODE>,
|
||||
and <CODE>T_ * float</CODE>, otherwise the <CODE>get_random()</CODE> method will not compile.
|
||||
This struct could be extended to customize the random number generator (now it uses only
|
||||
<CODE>std::rand()</CODE>).</BLOCKQUOTE>
|
||||
<DL>
|
||||
|
||||
<A NAME="min"></A>
|
||||
<A NAME="DOC.2.22.1"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>T_ min</B></TT>
|
||||
<DD>Lower bound
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="max"></A>
|
||||
<A NAME="DOC.2.22.2"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>T_ max</B></TT>
|
||||
<DD>Higher bound
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="range"></A>
|
||||
<A NAME="DOC.2.22.3"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> range()</B></TT>
|
||||
<DD>Construct the object by calling default constructors for min and max
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="range"></A>
|
||||
<A NAME="DOC.2.22.4"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B> range(const T_ &mn, const T_ &mx)</B></TT>
|
||||
<DD>Construct and initialize min and max directly
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="set"></A>
|
||||
<A NAME="DOC.2.22.5"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>void set(const T_ &mn, const T_ &mx)</B></TT>
|
||||
<DD>Set min and max
|
||||
<DL><DT><DD></DL><P>
|
||||
<A NAME="get_random"></A>
|
||||
<A NAME="DOC.2.22.6"></A>
|
||||
<DT><IMG ALT="o" BORDER=0 SRC=icon2.gif><TT><B>T_ get_random() const </B></TT>
|
||||
<DD>Get a random value between min and max
|
||||
<DL><DT><DD></DL><P></DL>
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
20
doc/doc++/osgParticle/rangef.html
Normal file
20
doc/doc++/osgParticle/rangef.html
Normal file
@@ -0,0 +1,20 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>typedef range<float> osgParticle::rangef</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>typedef <!1><A HREF="range.html">range</A><float> <A HREF="#DOC.DOCU">osgParticle::rangef</A></H2></H2><BLOCKQUOTE>Range of floats</BLOCKQUOTE>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>Range of floats</BLOCKQUOTE>
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
20
doc/doc++/osgParticle/rangev2.html
Normal file
20
doc/doc++/osgParticle/rangev2.html
Normal file
@@ -0,0 +1,20 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>typedef range<osg::Vec2> osgParticle::rangev2</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>typedef <!1><A HREF="range.html">range</A><osg::Vec2> <A HREF="#DOC.DOCU">osgParticle::rangev2</A></H2></H2><BLOCKQUOTE>Range of osg::Vec2s</BLOCKQUOTE>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>Range of osg::Vec2s</BLOCKQUOTE>
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
20
doc/doc++/osgParticle/rangev3.html
Normal file
20
doc/doc++/osgParticle/rangev3.html
Normal file
@@ -0,0 +1,20 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>typedef range<osg::Vec3> osgParticle::rangev3</TITLE>
|
||||
<META NAME="GENERATOR" CONTENT="DOC++ 3.4.8">
|
||||
</HEAD>
|
||||
<BODY BGCOLOR="#ffffff">
|
||||
|
||||
<H2>typedef <!1><A HREF="range.html">range</A><osg::Vec3> <A HREF="#DOC.DOCU">osgParticle::rangev3</A></H2></H2><BLOCKQUOTE>Range of osg::Vec3s</BLOCKQUOTE>
|
||||
|
||||
<A NAME="DOC.DOCU"></A>
|
||||
<HR>
|
||||
<H2>Documentation</H2>
|
||||
<BLOCKQUOTE>Range of osg::Vec3s</BLOCKQUOTE>
|
||||
<DL><DT><DD></DL><P><P><I><A HREF="index.html">Alphabetic index</A></I> <I><A HREF="HIER.html">HTML hierarchy of classes</A> or <A HREF="HIERjava.html">Java</A></I></P><HR>
|
||||
<BR>
|
||||
This page was generated with the help of <A HREF="http://docpp.sourceforge.net">DOC++</A>.
|
||||
</BODY>
|
||||
</HTML>
|
||||
@@ -38,6 +38,8 @@ core scene graph reference guide.
|
||||
scene graph utilities reference guide.
|
||||
<br><a href="doc++/osgDB/HIER.html">osgDB/</a>
|
||||
scene graph database utilities reference guide.
|
||||
<br><a href="doc++/osgParticle/HIER.html">osgParticle/</a>
|
||||
scene graph particle reference guide.
|
||||
<br><a href="doc++/osgText/HIER.html">osgText/</a>
|
||||
scene graph text reference guide.
|
||||
<br><a href="doc++/osgGLUT/HIER.html">osgGLUT/</a>
|
||||
|
||||
99
include/osgParticle/AccelOperator
Normal file
99
include/osgParticle/AccelOperator
Normal file
@@ -0,0 +1,99 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_ACCELOPERATOR_
|
||||
#define OSGPARTICLE_ACCELOPERATOR_ 1
|
||||
|
||||
#include <osgParticle/ModularProgram>
|
||||
#include <osgParticle/Operator>
|
||||
#include <osgParticle/Particle>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
#include <osg/Vec3>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/** An operator class that applies a constant acceleration to the particles.
|
||||
*/
|
||||
class AccelOperator: public Operator {
|
||||
public:
|
||||
inline AccelOperator();
|
||||
inline AccelOperator(const AccelOperator ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
META_Object(AccelOperator);
|
||||
|
||||
/// Get the acceleration vector.
|
||||
inline const osg::Vec3 &getAcceleration() const;
|
||||
|
||||
/// Set the acceleration vector.
|
||||
inline void setAcceleration(const osg::Vec3 &v);
|
||||
|
||||
/** Quickly set the acceleration vector to the gravity on earth (0, 0, -9.81).
|
||||
The acceleration will be multiplied by the <CODE>scale</CODE> parameter.
|
||||
*/
|
||||
inline void setToGravity(float scale = 1);
|
||||
|
||||
/// Apply the acceleration to a particle. Do not call this method manually.
|
||||
inline void operate(Particle *P, double dt);
|
||||
|
||||
/// Perform some initializations. Do not call this method manually.
|
||||
inline void beginOperate(Program *prg);
|
||||
|
||||
protected:
|
||||
virtual ~AccelOperator() {}
|
||||
AccelOperator &operator=(const AccelOperator &) { return *this; }
|
||||
|
||||
private:
|
||||
osg::Vec3 accel_;
|
||||
osg::Vec3 xf_accel_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline AccelOperator::AccelOperator()
|
||||
: Operator(), accel_(0, 0, 0)
|
||||
{
|
||||
}
|
||||
|
||||
inline AccelOperator::AccelOperator(const AccelOperator ©, const osg::CopyOp ©op)
|
||||
: Operator(copy, copyop), accel_(copy.accel_)
|
||||
{
|
||||
}
|
||||
|
||||
inline const osg::Vec3 &AccelOperator::getAcceleration() const
|
||||
{
|
||||
return accel_;
|
||||
}
|
||||
|
||||
inline void AccelOperator::setAcceleration(const osg::Vec3 &v)
|
||||
{
|
||||
accel_ = v;
|
||||
}
|
||||
|
||||
inline void AccelOperator::setToGravity(float scale)
|
||||
{
|
||||
accel_.set(0, 0, -9.80665f * scale);
|
||||
}
|
||||
|
||||
inline void AccelOperator::operate(Particle *P, double dt)
|
||||
{
|
||||
P->addVelocity(xf_accel_ * dt);
|
||||
}
|
||||
|
||||
inline void AccelOperator::beginOperate(Program *prg)
|
||||
{
|
||||
if (prg->getReferenceFrame() == ModularProgram::RELATIVE_TO_PARENTS) {
|
||||
xf_accel_ = prg->rotateLocalToWorld(accel_);
|
||||
} else {
|
||||
xf_accel_ = accel_;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
74
include/osgParticle/CenteredPlacer
Normal file
74
include/osgParticle/CenteredPlacer
Normal file
@@ -0,0 +1,74 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_CENTEREDPLACER_
|
||||
#define OSGPARTICLE_CENTEREDPLACER_ 1
|
||||
|
||||
#include <osgParticle/Placer>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
#include <osg/Vec3>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/** An abstract placer base class for placers which need a <I>center point</I>.
|
||||
*/
|
||||
class CenteredPlacer: public Placer {
|
||||
public:
|
||||
inline CenteredPlacer();
|
||||
inline CenteredPlacer(const CenteredPlacer ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
virtual const char *className() const { return "CenteredPlacer"; }
|
||||
virtual bool isSameKindAs(const osg::Object *obj) const { return dynamic_cast<const Placer *>(obj) != 0; }
|
||||
|
||||
/// Get the center point.
|
||||
inline const osg::Vec3 &getCenter() const;
|
||||
|
||||
/// Set the center point.
|
||||
inline void setCenter(const osg::Vec3 &v);
|
||||
|
||||
/// Set the center point.
|
||||
inline void setCenter(float x, float y, float z);
|
||||
|
||||
protected:
|
||||
virtual ~CenteredPlacer() {}
|
||||
|
||||
private:
|
||||
osg::Vec3 center_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline CenteredPlacer::CenteredPlacer()
|
||||
: Placer(), center_(0, 0, 0)
|
||||
{
|
||||
}
|
||||
|
||||
inline CenteredPlacer::CenteredPlacer(const CenteredPlacer ©, const osg::CopyOp ©op)
|
||||
: Placer(copy, copyop), center_(copy.center_)
|
||||
{
|
||||
}
|
||||
|
||||
inline const osg::Vec3 &CenteredPlacer::getCenter() const
|
||||
{
|
||||
return center_;
|
||||
}
|
||||
|
||||
inline void CenteredPlacer::setCenter(const osg::Vec3 &v)
|
||||
{
|
||||
center_ = v;
|
||||
}
|
||||
|
||||
inline void CenteredPlacer::setCenter(float x, float y, float z)
|
||||
{
|
||||
center_.set(x, y, z);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
44
include/osgParticle/Counter
Normal file
44
include/osgParticle/Counter
Normal file
@@ -0,0 +1,44 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_COUNTER_
|
||||
#define OSGPARTICLE_COUNTER_ 1
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
class Counter: public osg::Object {
|
||||
public:
|
||||
inline Counter();
|
||||
inline Counter(const Counter ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
virtual const char *className() const { return "Counter"; }
|
||||
virtual bool isSameKindAs(const osg::Object *obj) const { return dynamic_cast<const Counter *>(obj) != 0; }
|
||||
|
||||
virtual int numParticlesToCreate(double dt) const = 0;
|
||||
|
||||
protected:
|
||||
~Counter() {}
|
||||
Counter &operator=(const Counter &) { return *this; }
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline Counter::Counter()
|
||||
: osg::Object()
|
||||
{
|
||||
}
|
||||
|
||||
inline Counter::Counter(const Counter ©, const osg::CopyOp ©op)
|
||||
: osg::Object(copy, copyop)
|
||||
{
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
96
include/osgParticle/Emitter
Normal file
96
include/osgParticle/Emitter
Normal file
@@ -0,0 +1,96 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_EMITTER_
|
||||
#define OSGPARTICLE_EMITTER_ 1
|
||||
|
||||
#include <osgParticle/Export>
|
||||
#include <osgParticle/ParticleProcessor>
|
||||
#include <osgParticle/Particle>
|
||||
|
||||
#include <osg/Object>
|
||||
#include <osg/Node>
|
||||
#include <osg/NodeVisitor>
|
||||
#include <osg/CopyOp>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/** An abstract base class for particle emitters.
|
||||
Descendant classes must override the <CODE>emit()</CODE> method to generate new particles by
|
||||
calling the <CODE>ParticleSystem::createParticle()</CODE> method on the particle system associated
|
||||
to the emitter.
|
||||
*/
|
||||
class OSGPARTICLE_EXPORT Emitter: public ParticleProcessor {
|
||||
public:
|
||||
Emitter();
|
||||
Emitter(const Emitter ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
virtual const char *className() const { return "Emitter"; }
|
||||
virtual bool isSameKindAs(const osg::Object *obj) { return dynamic_cast<const Emitter*>(obj) != 0; }
|
||||
virtual void accept(osg::NodeVisitor& nv) { if (nv.validNodeMask(*this)) { nv.pushOntoNodePath(this); nv.apply(*this); nv.popFromNodePath(); } }
|
||||
|
||||
/// Get the particle template.
|
||||
inline const Particle &getParticleTemplate() const;
|
||||
|
||||
/// Set the particle template (particle is copied).
|
||||
inline void setParticleTemplate(const Particle &p);
|
||||
|
||||
/// Return whether the particle system's default template should be used.
|
||||
inline bool getUseDefaultTemplate() const;
|
||||
|
||||
/** Set whether the default particle template should be used.
|
||||
When this flag is true, the particle template is ignored, and the
|
||||
particle system's default template is used instead.
|
||||
*/
|
||||
inline void setUseDefaultTemplate(bool v);
|
||||
|
||||
protected:
|
||||
virtual ~Emitter() {}
|
||||
Emitter &operator=(const Emitter &) { return *this; }
|
||||
|
||||
inline void process(double dt);
|
||||
|
||||
virtual void emit(double dt) = 0;
|
||||
|
||||
private:
|
||||
bool usedeftemp_;
|
||||
Particle ptemp_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline const Particle &Emitter::getParticleTemplate() const
|
||||
{
|
||||
return ptemp_;
|
||||
}
|
||||
|
||||
inline void Emitter::setParticleTemplate(const Particle &p)
|
||||
{
|
||||
ptemp_ = p;
|
||||
usedeftemp_ = false;
|
||||
}
|
||||
|
||||
inline bool Emitter::getUseDefaultTemplate() const
|
||||
{
|
||||
return usedeftemp_;
|
||||
}
|
||||
|
||||
inline void Emitter::setUseDefaultTemplate(bool v)
|
||||
{
|
||||
usedeftemp_ = v;
|
||||
}
|
||||
|
||||
inline void Emitter::process(double dt)
|
||||
{
|
||||
emit(dt);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
30
include/osgParticle/Export
Normal file
30
include/osgParticle/Export
Normal file
@@ -0,0 +1,30 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_EXPORT_
|
||||
#define OSGPARTICLE_EXPORT_ 1
|
||||
|
||||
#if defined(WIN32) && !(defined(__CYGWIN__) || defined(__MINGW32__))
|
||||
#pragma warning( disable : 4244 )
|
||||
#pragma warning( disable : 4251 )
|
||||
#pragma warning( disable : 4275 )
|
||||
#pragma warning( disable : 4786 )
|
||||
#pragma warning( disable : 4290 )
|
||||
#endif
|
||||
|
||||
|
||||
#if defined(_MSC_VER) || defined(__CYGWIN__) || defined(__MINGW32__) || defined( __BCPLUSPLUS__) || defined( __MWERKS__)
|
||||
# ifdef OSGPARTICLE_LIBRARY
|
||||
# define OSGPARTICLE_EXPORT __declspec(dllexport)
|
||||
# else
|
||||
# define OSGPARTICLE_EXPORT __declspec(dllimport)
|
||||
# endif /* OSGPARTICLE_LIBRARY */
|
||||
#else
|
||||
# define OSGPARTICLE_EXPORT
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
132
include/osgParticle/FluidFrictionOperator
Normal file
132
include/osgParticle/FluidFrictionOperator
Normal file
@@ -0,0 +1,132 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_FLUIDFRICTIONOPERATOR_
|
||||
#define OSGPARTICLE_FLUIDFRICTIONOPERATOR_ 1
|
||||
|
||||
#include <osgParticle/Export>
|
||||
#include <osgParticle/Operator>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
#include <osg/Math>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
class Particle;
|
||||
|
||||
/** An operator that simulates the friction of a fluid.
|
||||
By using this operator you can let the particles move in a fluid of a given <I>density</I>
|
||||
and <I>viscosity</I>. There are two functions to quickly setup the parameters for pure water
|
||||
and air. You can decide whether to compute the forces using the particle's physical
|
||||
radius or another value, by calling the <CODE>setOverrideRadius()</CODE> method.
|
||||
*/
|
||||
class OSGPARTICLE_EXPORT FluidFrictionOperator: public Operator {
|
||||
public:
|
||||
|
||||
FluidFrictionOperator();
|
||||
FluidFrictionOperator(const FluidFrictionOperator ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
META_Object(FluidFrictionOperator);
|
||||
|
||||
/// Get the density of the fluid.
|
||||
inline float getFluidDensity() const;
|
||||
|
||||
/// Set the density of the fluid.
|
||||
inline void setFluidDensity(float d);
|
||||
|
||||
/// Get the viscosity of the fluid.
|
||||
inline float getFluidViscosity() const;
|
||||
|
||||
/// Set the viscosity of the fluid.
|
||||
inline void setFluidViscosity(float v);
|
||||
|
||||
/// Get the overriden radius value.
|
||||
inline float getOverrideRadius() const;
|
||||
|
||||
/// Set the overriden radius value (pass 0 if you want to use particle's radius).
|
||||
inline void setOverrideRadius(float r);
|
||||
|
||||
/// Set the fluid parameters as for air (20<32>C temperature).
|
||||
inline void setFluidToAir();
|
||||
|
||||
/// Set the fluid parameters as for pure water (20<32>C temperature).
|
||||
inline void setFluidToWater();
|
||||
|
||||
/// Apply the friction forces to a particle. Do not call this method manually.
|
||||
void operate(Particle *P, double dt);
|
||||
|
||||
/// Perform some initializations. Do not call this method manually.
|
||||
inline void beginOperate(Program *prg);
|
||||
|
||||
protected:
|
||||
virtual ~FluidFrictionOperator() {}
|
||||
FluidFrictionOperator &operator=(const FluidFrictionOperator &) { return *this; }
|
||||
|
||||
private:
|
||||
float A_;
|
||||
float B_;
|
||||
float density_;
|
||||
float viscosity_;
|
||||
float ovr_rad_;
|
||||
Program *current_program_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline float FluidFrictionOperator::getFluidDensity() const
|
||||
{
|
||||
return density_;
|
||||
}
|
||||
|
||||
inline float FluidFrictionOperator::getFluidViscosity() const
|
||||
{
|
||||
return viscosity_;
|
||||
}
|
||||
|
||||
inline void FluidFrictionOperator::setFluidDensity(float d)
|
||||
{
|
||||
density_ = d;
|
||||
B_ = 0.2f * osg::PI * density_;
|
||||
}
|
||||
|
||||
inline void FluidFrictionOperator::setFluidViscosity(float v)
|
||||
{
|
||||
viscosity_ = v;
|
||||
A_ = 6 * osg::PI * viscosity_;
|
||||
}
|
||||
|
||||
inline void FluidFrictionOperator::setFluidToAir()
|
||||
{
|
||||
setFluidViscosity(1.8e-5f);
|
||||
setFluidDensity(1.2929f);
|
||||
}
|
||||
|
||||
inline void FluidFrictionOperator::setFluidToWater()
|
||||
{
|
||||
setFluidViscosity(1.002e-3f);
|
||||
setFluidDensity(1.0f);
|
||||
}
|
||||
|
||||
inline float FluidFrictionOperator::getOverrideRadius() const
|
||||
{
|
||||
return ovr_rad_;
|
||||
}
|
||||
|
||||
inline void FluidFrictionOperator::setOverrideRadius(float r)
|
||||
{
|
||||
ovr_rad_ = r;
|
||||
}
|
||||
|
||||
inline void FluidFrictionOperator::beginOperate(Program *prg)
|
||||
{
|
||||
current_program_ = prg;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
89
include/osgParticle/ForceOperator
Normal file
89
include/osgParticle/ForceOperator
Normal file
@@ -0,0 +1,89 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_FORCEOPERATOR_
|
||||
#define OSGPARTICLE_FORCEOPERATOR_ 1
|
||||
|
||||
#include <osgParticle/ModularProgram>
|
||||
#include <osgParticle/Operator>
|
||||
#include <osgParticle/Particle>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
#include <osg/Vec3>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/** An operator that applies a constant force to the particles.
|
||||
Remember that if the mass of particles is expressed in <U>kg</U> and the lengths are
|
||||
expressed in <U>meters</U>, then the force should be expressed in <U>Newtons</U>.
|
||||
*/
|
||||
class ForceOperator: public Operator {
|
||||
public:
|
||||
inline ForceOperator();
|
||||
inline ForceOperator(const ForceOperator ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
META_Object(ForceOperator);
|
||||
|
||||
/// Get the force vector.
|
||||
inline const osg::Vec3 &getForce() const;
|
||||
|
||||
/// Set the force vector.
|
||||
inline void setForce(const osg::Vec3 &f);
|
||||
|
||||
/// Apply the force to a particle. Do not call this method manually.
|
||||
inline void operate(Particle *P, double dt);
|
||||
|
||||
/// Perform some initialization. Do not call this method manually.
|
||||
inline void beginOperate(Program *prg);
|
||||
|
||||
protected:
|
||||
virtual ~ForceOperator() {};
|
||||
ForceOperator &operator=(const ForceOperator &) { return *this; }
|
||||
|
||||
private:
|
||||
osg::Vec3 force_;
|
||||
osg::Vec3 xf_force_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline ForceOperator::ForceOperator()
|
||||
: Operator(), force_(0, 0, 0)
|
||||
{
|
||||
}
|
||||
|
||||
inline ForceOperator::ForceOperator(const ForceOperator ©, const osg::CopyOp ©op)
|
||||
: Operator(copy, copyop), force_(copy.force_)
|
||||
{
|
||||
}
|
||||
|
||||
inline const osg::Vec3 &ForceOperator::getForce() const
|
||||
{
|
||||
return force_;
|
||||
}
|
||||
|
||||
inline void ForceOperator::setForce(const osg::Vec3 &v)
|
||||
{
|
||||
force_ = v;
|
||||
}
|
||||
|
||||
inline void ForceOperator::operate(Particle *P, double dt)
|
||||
{
|
||||
P->addVelocity(xf_force_ * (P->getMassInv() * dt));
|
||||
}
|
||||
|
||||
inline void ForceOperator::beginOperate(Program *prg)
|
||||
{
|
||||
if (prg->getReferenceFrame() == ModularProgram::RELATIVE_TO_PARENTS) {
|
||||
xf_force_ = prg->rotateLocalToWorld(force_);
|
||||
} else {
|
||||
xf_force_ = force_;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
77
include/osgParticle/Interpolator
Normal file
77
include/osgParticle/Interpolator
Normal file
@@ -0,0 +1,77 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_INTERPOLATOR_
|
||||
#define OSGPARTICLE_INTERPOLATOR_
|
||||
|
||||
#include <osgParticle/range>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
#include <osg/Vec2>
|
||||
#include <osg/Vec3>
|
||||
#include <osg/Vec4>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/// An abstract base class for implementing interpolators.
|
||||
class Interpolator : public osg::Object {
|
||||
public:
|
||||
Interpolator()
|
||||
: osg::Object() {}
|
||||
|
||||
Interpolator(const Interpolator ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY)
|
||||
: osg::Object(copy, copyop) {}
|
||||
|
||||
virtual const char *className() const { return "Interpolator"; }
|
||||
virtual bool isSameKindAs(const osg::Object *obj) const { return dynamic_cast<const Interpolator *>(obj) != 0; }
|
||||
|
||||
/// Interpolate between floats. Must be overriden in descendant classes.
|
||||
virtual float interpolate(float t, float y1, float y2) const = 0;
|
||||
|
||||
/// Interpolate between 2-dimensional vectors. Default behavior is to interpolate each component separately.
|
||||
virtual osg::Vec2 interpolate(float t, const osg::Vec2 &y1, const osg::Vec2 &y2) const
|
||||
{
|
||||
return osg::Vec2(
|
||||
interpolate(t, y1.x(), y2.x()),
|
||||
interpolate(t, y1.y(), y2.y())
|
||||
);
|
||||
}
|
||||
|
||||
/// Interpolate between 3-dimensional vectors. Default behavior is to interpolate each component separately.
|
||||
virtual osg::Vec3 interpolate(float t, const osg::Vec3 &y1, const osg::Vec3 &y2) const
|
||||
{
|
||||
return osg::Vec3(
|
||||
interpolate(t, y1.x(), y2.x()),
|
||||
interpolate(t, y1.y(), y2.y()),
|
||||
interpolate(t, y1.z(), y2.z())
|
||||
);
|
||||
}
|
||||
|
||||
/// Interpolate between 4-dimensional vectors. Default behavior is to interpolate each component separately.
|
||||
virtual osg::Vec4 interpolate(float t, const osg::Vec4 &y1, const osg::Vec4 &y2) const
|
||||
{
|
||||
return osg::Vec4(
|
||||
interpolate(t, y1.x(), y2.x()),
|
||||
interpolate(t, y1.y(), y2.y()),
|
||||
interpolate(t, y1.z(), y2.z()),
|
||||
interpolate(t, y1.w(), y2.w())
|
||||
);
|
||||
}
|
||||
|
||||
template<class T_>
|
||||
T_ interpolate(float t, const range<T_> &r) const
|
||||
{
|
||||
return interpolate(t, r.min, r.max);
|
||||
}
|
||||
|
||||
protected:
|
||||
virtual ~Interpolator() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
41
include/osgParticle/LinearInterpolator
Normal file
41
include/osgParticle/LinearInterpolator
Normal file
@@ -0,0 +1,41 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_LINEARINTERPOLATOR_
|
||||
#define OSGPARTICLE_LINEARINTERPOLATOR_
|
||||
|
||||
#include <osgParticle/Interpolator>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
#include <osg/Vec3>
|
||||
#include <osg/Vec4>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/// A linear interpolator.
|
||||
class LinearInterpolator: public Interpolator {
|
||||
public:
|
||||
LinearInterpolator()
|
||||
: Interpolator() {}
|
||||
|
||||
LinearInterpolator(const LinearInterpolator ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY)
|
||||
: Interpolator(copy, copyop) {}
|
||||
|
||||
META_Object(LinearInterpolator);
|
||||
|
||||
virtual float interpolate(float t, float y1, float y2) const
|
||||
{
|
||||
return y1 + (y2 - y1) * t;
|
||||
}
|
||||
|
||||
protected:
|
||||
virtual ~LinearInterpolator() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
130
include/osgParticle/ModularEmitter
Normal file
130
include/osgParticle/ModularEmitter
Normal file
@@ -0,0 +1,130 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_MODULAREMITTER_
|
||||
#define OSGPARTICLE_MODULAREMITTER_ 1
|
||||
|
||||
#include <osgParticle/Export>
|
||||
#include <osgParticle/Emitter>
|
||||
#include <osgParticle/Particle>
|
||||
#include <osgParticle/RandomRateCounter>
|
||||
#include <osgParticle/Placer>
|
||||
#include <osgParticle/PointPlacer>
|
||||
#include <osgParticle/Shooter>
|
||||
#include <osgParticle/RadialShooter>
|
||||
#include <osgParticle/ParticleSystem>
|
||||
|
||||
#include <osg/ref_ptr>
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
#include <osg/Node>
|
||||
#include <osg/NodeVisitor>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/** An emitter class that holds three objects to control the creation of particles.
|
||||
These objects are a <I>counter</I>, a <I>placer</I> and a <I>shooter</I>.
|
||||
The counter controls the number of particles to be emitted at each frame;
|
||||
the placer must initialize the particle's position vector, while the shooter initializes
|
||||
its velocity vector.
|
||||
You can use the predefined counter/placer/shooter classes, or you can create your own.
|
||||
*/
|
||||
class OSGPARTICLE_EXPORT ModularEmitter: public Emitter {
|
||||
public:
|
||||
ModularEmitter();
|
||||
ModularEmitter(const ModularEmitter ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
META_Node(ModularEmitter);
|
||||
|
||||
/// Get the counter object.
|
||||
inline Counter *getCounter();
|
||||
|
||||
/// Get the const Counter object.
|
||||
inline const Counter *getCounter() const;
|
||||
|
||||
/// Set the Counter object.
|
||||
inline void setCounter(Counter *c);
|
||||
|
||||
/// Get the Placer object.
|
||||
inline Placer *getPlacer();
|
||||
|
||||
/// Get the const Placer object.
|
||||
inline const Placer *getPlacer() const;
|
||||
|
||||
/// Set the Placer object.
|
||||
inline void setPlacer(Placer *p);
|
||||
|
||||
/// Get the Shooter object.
|
||||
inline Shooter *getShooter();
|
||||
|
||||
/// Get the const Shooter object.
|
||||
inline const Shooter *getShooter() const;
|
||||
|
||||
/// Set the Shooter object.
|
||||
inline void setShooter(Shooter *s);
|
||||
|
||||
protected:
|
||||
virtual ~ModularEmitter() {}
|
||||
ModularEmitter &operator=(const ModularEmitter &) { return *this; }
|
||||
|
||||
void emit(double dt);
|
||||
|
||||
private:
|
||||
osg::ref_ptr<Counter> counter_;
|
||||
osg::ref_ptr<Placer> placer_;
|
||||
osg::ref_ptr<Shooter> shooter_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline Counter *ModularEmitter::getCounter()
|
||||
{
|
||||
return counter_.get();
|
||||
}
|
||||
|
||||
inline const Counter *ModularEmitter::getCounter() const
|
||||
{
|
||||
return counter_.get();
|
||||
}
|
||||
|
||||
inline void ModularEmitter::setCounter(Counter *c)
|
||||
{
|
||||
counter_ = c;
|
||||
}
|
||||
|
||||
inline Placer *ModularEmitter::getPlacer()
|
||||
{
|
||||
return placer_.get();
|
||||
}
|
||||
|
||||
inline const Placer *ModularEmitter::getPlacer() const
|
||||
{
|
||||
return placer_.get();
|
||||
}
|
||||
|
||||
inline void ModularEmitter::setPlacer(Placer *p)
|
||||
{
|
||||
placer_ = p;
|
||||
}
|
||||
|
||||
inline Shooter *ModularEmitter::getShooter()
|
||||
{
|
||||
return shooter_.get();
|
||||
}
|
||||
|
||||
inline const Shooter *ModularEmitter::getShooter() const
|
||||
{
|
||||
return shooter_.get();
|
||||
}
|
||||
|
||||
inline void ModularEmitter::setShooter(Shooter *s)
|
||||
{
|
||||
shooter_ = s;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
90
include/osgParticle/ModularProgram
Normal file
90
include/osgParticle/ModularProgram
Normal file
@@ -0,0 +1,90 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_MODULARPROGRAM_
|
||||
#define OSGPARTICLE_MODULARPROGRAM_ 1
|
||||
|
||||
#include <osgParticle/Export>
|
||||
#include <osgParticle/Program>
|
||||
#include <osgParticle/Operator>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
#include <osg/Node>
|
||||
#include <osg/NodeVisitor>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/** A program class for performing operations on particles using a sequence of <I>operators</I>.
|
||||
To use a <CODE>ModularProgram</CODE> you have to create some <CODE>Operator</CODE> objects and
|
||||
add them to the program.
|
||||
All operators will be applied to each particle in the same order they've been added to the program.
|
||||
*/
|
||||
class OSGPARTICLE_EXPORT ModularProgram: public Program {
|
||||
public:
|
||||
ModularProgram();
|
||||
ModularProgram(const ModularProgram ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
META_Node(ModularProgram);
|
||||
|
||||
/// Get the number of operators.
|
||||
inline int numOperators() const;
|
||||
|
||||
/// Add an operator to the list.
|
||||
inline void addOperator(Operator *o);
|
||||
|
||||
/// Get a pointer to an operator in the list.
|
||||
inline Operator *getOperator(int i);
|
||||
|
||||
/// Get a const pointer to an operator in the list.
|
||||
inline const Operator *getOperator(int i) const;
|
||||
|
||||
/// Remove an operator from the list.
|
||||
inline void removeOperator(int i);
|
||||
|
||||
protected:
|
||||
virtual ~ModularProgram() {}
|
||||
ModularProgram &operator=(const ModularProgram &) { return *this; }
|
||||
|
||||
void execute(double dt);
|
||||
|
||||
private:
|
||||
typedef std::vector<osg::ref_ptr<Operator> > Operator_vector;
|
||||
|
||||
Operator_vector operators_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline int ModularProgram::numOperators() const
|
||||
{
|
||||
return static_cast<int>(operators_.size());
|
||||
}
|
||||
|
||||
inline void ModularProgram::addOperator(Operator *o)
|
||||
{
|
||||
operators_.push_back(o);
|
||||
}
|
||||
|
||||
inline Operator *ModularProgram::getOperator(int i)
|
||||
{
|
||||
return operators_[i].get();
|
||||
}
|
||||
|
||||
inline const Operator *ModularProgram::getOperator(int i) const
|
||||
{
|
||||
return operators_[i].get();
|
||||
}
|
||||
|
||||
inline void ModularProgram::removeOperator(int i)
|
||||
{
|
||||
operators_.erase(operators_.begin()+i);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
119
include/osgParticle/MultiSegmentPlacer
Normal file
119
include/osgParticle/MultiSegmentPlacer
Normal file
@@ -0,0 +1,119 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_MULTISEGMENTPLACER_
|
||||
#define OSGPARTICLE_MULTISEGMENTPLACER_ 1
|
||||
|
||||
#include <osgParticle/Export>
|
||||
#include <osgParticle/Placer>
|
||||
#include <osgParticle/Particle>
|
||||
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
|
||||
#include <osg/Notify>
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
#include <osg/Vec3>
|
||||
|
||||
namespace osgParticle {
|
||||
|
||||
/** A polyline-shaped particle placer.
|
||||
This placer class sets the position of incoming particles by choosing a random point on the
|
||||
specified sequence of connected segments.
|
||||
*/
|
||||
class OSGPARTICLE_EXPORT MultiSegmentPlacer: public Placer {
|
||||
public:
|
||||
MultiSegmentPlacer();
|
||||
MultiSegmentPlacer(const MultiSegmentPlacer ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
META_Object(MultiSegmentPlacer);
|
||||
|
||||
/// Get the number of vertices which define the segments.
|
||||
inline int numVertices() const;
|
||||
|
||||
/// Get a vertex.
|
||||
inline const osg::Vec3 &getVertex(int i) const;
|
||||
|
||||
/// Set a vertex.
|
||||
inline void setVertex(int i, const osg::Vec3 &v);
|
||||
|
||||
/// Set a vertex.
|
||||
inline void setVertex(int i, float x, float y, float z);
|
||||
|
||||
/// Add a vertex.
|
||||
inline void addVertex(const osg::Vec3 &v);
|
||||
|
||||
/// Add a vertex.
|
||||
inline void addVertex(float x, float y, float z);
|
||||
|
||||
/// Remove a vertex.
|
||||
inline void removeVertex(int i);
|
||||
|
||||
/// Place a partice. Called automatically by <CODE>ModularEmitter</CODE>, do not call this method manually.
|
||||
void place(Particle *P) const;
|
||||
|
||||
protected:
|
||||
virtual ~MultiSegmentPlacer() {}
|
||||
MultiSegmentPlacer &operator=(const MultiSegmentPlacer &) { return *this; }
|
||||
|
||||
private:
|
||||
typedef std::pair<osg::Vec3, float> Vertex_data;
|
||||
typedef std::vector<Vertex_data> Vertex_vector;
|
||||
|
||||
Vertex_vector vx_;
|
||||
float total_length_;
|
||||
|
||||
void recompute_length();
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
|
||||
inline int MultiSegmentPlacer::numVertices() const
|
||||
{
|
||||
return static_cast<int>(vx_.size());
|
||||
}
|
||||
|
||||
inline const osg::Vec3 &MultiSegmentPlacer::getVertex(int i) const
|
||||
{
|
||||
return vx_[i].first;
|
||||
}
|
||||
|
||||
inline void MultiSegmentPlacer::setVertex(int i, const osg::Vec3 &v)
|
||||
{
|
||||
vx_[i].first = v;
|
||||
recompute_length();
|
||||
}
|
||||
|
||||
inline void MultiSegmentPlacer::setVertex(int i, float x, float y, float z)
|
||||
{
|
||||
vx_[i].first.set(x, y, z);
|
||||
recompute_length();
|
||||
}
|
||||
|
||||
inline void MultiSegmentPlacer::addVertex(const osg::Vec3 &v)
|
||||
{
|
||||
float l = 0;
|
||||
if (vx_.size() > 0) {
|
||||
l = (v - vx_.back().first).length();
|
||||
}
|
||||
total_length_ += l;
|
||||
vx_.push_back(std::make_pair(v, total_length_));
|
||||
}
|
||||
|
||||
inline void MultiSegmentPlacer::addVertex(float x, float y, float z)
|
||||
{
|
||||
addVertex(osg::Vec3(x, y, z));
|
||||
}
|
||||
|
||||
inline void MultiSegmentPlacer::removeVertex(int i)
|
||||
{
|
||||
vx_.erase(vx_.begin()+i);
|
||||
recompute_length();
|
||||
}
|
||||
|
||||
}
|
||||
#endif
|
||||
91
include/osgParticle/Operator
Normal file
91
include/osgParticle/Operator
Normal file
@@ -0,0 +1,91 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_OPERATOR_
|
||||
#define OSGPARTICLE_OPERATOR_ 1
|
||||
|
||||
#include <osgParticle/Program>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
#include <osg/Matrix>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
// forward declaration to avoid including the whole header file
|
||||
class Particle;
|
||||
|
||||
/** An abstract base class used by <CODE>ModularProgram</CODE> to perform operations on particles before they are updated.
|
||||
To implement a new operator, derive from this class and override the <CODE>operate()</CODE> method.
|
||||
You should also override the <CODE>beginOperate()</CODE> method to query the calling program for the reference frame
|
||||
used, and initialize the right transformations if needed.
|
||||
*/
|
||||
class Operator: public osg::Object {
|
||||
public:
|
||||
inline Operator();
|
||||
inline Operator(const Operator ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
virtual const char *className() const { return "Operator"; }
|
||||
virtual bool isSameKindAs(const osg::Object *obj) const { return dynamic_cast<const Operator *>(obj) != 0; }
|
||||
|
||||
/// Get whether this operator is enabled.
|
||||
inline bool isEnabled() const;
|
||||
|
||||
/// Enable or disable this operator.
|
||||
inline void setEnabled(bool v);
|
||||
|
||||
/** Do something on a particle.
|
||||
This method is called by <CODE>ModularProgram</CODE> objects to perform some operations
|
||||
on the particles. You must override it in descendant classes. Common operations
|
||||
consist of modifying the particle's velocity vector. The <CODE>dt</CODE> parameter is
|
||||
the time elapsed from last operation.
|
||||
*/
|
||||
virtual void operate(Particle *P, double dt) = 0;
|
||||
|
||||
/** Do something before processing particles via the <CODE>operate()</CODE> method.
|
||||
Overriding this method could be necessary to query the calling <CODE>Program</CODE> object
|
||||
for the current reference frame. If the reference frame is RELATIVE_TO_PARENTS, then your
|
||||
class should prepare itself to do all operations in local coordinates.
|
||||
*/
|
||||
virtual void beginOperate(Program *) {}
|
||||
|
||||
/// Do something after all particles have been processed.
|
||||
virtual void endOperate() {}
|
||||
|
||||
protected:
|
||||
virtual ~Operator() {}
|
||||
Operator &operator=(const Operator &) { return *this; }
|
||||
|
||||
private:
|
||||
bool enabled_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline Operator::Operator()
|
||||
: osg::Object(), enabled_(true)
|
||||
{
|
||||
}
|
||||
|
||||
inline Operator::Operator(const Operator ©, const osg::CopyOp ©op)
|
||||
: osg::Object(copy, copyop), enabled_(copy.enabled_)
|
||||
{
|
||||
}
|
||||
|
||||
inline bool Operator::isEnabled() const
|
||||
{
|
||||
return enabled_;
|
||||
}
|
||||
|
||||
inline void Operator::setEnabled(bool v)
|
||||
{
|
||||
enabled_ = v;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
399
include/osgParticle/Particle
Normal file
399
include/osgParticle/Particle
Normal file
@@ -0,0 +1,399 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_PARTICLE_
|
||||
#define OSGPARTICLE_PARTICLE_ 1
|
||||
|
||||
#include <osgParticle/Export>
|
||||
#include <osgParticle/Interpolator>
|
||||
#include <osgParticle/range>
|
||||
|
||||
#include <osg/ref_ptr>
|
||||
#include <osg/Vec3>
|
||||
#include <osg/Vec4>
|
||||
#include <osg/Matrix>
|
||||
#include <osg/GL>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/** Implementation of a <B>particle</B>.
|
||||
Objects of this class are particles, they have some graphical properties
|
||||
and some physical properties. Particles are created by emitters and then placed
|
||||
into Particle Systems, where they live and get updated at each frame.
|
||||
Particles can either live forever (lifeTime < 0), or die after a specified
|
||||
time (lifeTime >= 0). For each property which is defined as a range of values, a
|
||||
"current" value will be evaluated at each frame by interpolating the <I>min</I>
|
||||
and <I>max</I> values so that <I>curr_value = min</I> when <I>t == 0</I>, and
|
||||
<I>curr_value = max</I> when <I>t == lifeTime</I>.
|
||||
You may customize the interpolator objects to achieve any kind of transition.
|
||||
If you want the particle to live forever, set its lifetime to any value <= 0;
|
||||
in that case, no interpolation is done to compute real-time properties, and only
|
||||
minimum values are used.
|
||||
*/
|
||||
class OSGPARTICLE_EXPORT Particle {
|
||||
public:
|
||||
|
||||
enum Shape {
|
||||
POINT, // uses GL_POINTS as primitive
|
||||
QUAD, // uses GL_QUADS as primitive
|
||||
QUAD_TRIANGLESTRIP, // uses GL_TRIANGLE_STRIP as primitive, but each particle needs a glBegin/glEnd pair
|
||||
HEXAGON // may save some filling time, but uses more triangles
|
||||
};
|
||||
|
||||
Particle();
|
||||
|
||||
/// Get the shape of the particle.
|
||||
inline Shape getShape() const;
|
||||
|
||||
/// Set the shape of the particle.
|
||||
inline void setShape(Shape s);
|
||||
|
||||
/// Get whether the particle is still alive.
|
||||
inline bool isAlive() const;
|
||||
|
||||
/// Get the life time of the particle (in seconds).
|
||||
inline double getLifeTime() const;
|
||||
|
||||
/// Get the age of the particle (in seconds).
|
||||
inline double getAge() const;
|
||||
|
||||
/// Get the minimum and maximum values for polygon size.
|
||||
inline const rangef &getSizeRange() const;
|
||||
|
||||
/// Get the minimum and maximum values for alpha.
|
||||
inline const rangef &getAlphaRange() const;
|
||||
|
||||
/// Get the minimum and maximum values for color.
|
||||
inline const rangev4 &getColorRange() const;
|
||||
|
||||
/// Get the interpolator for computing the size of polygons.
|
||||
inline const Interpolator *getSizeInterpolator() const;
|
||||
|
||||
/// Get the interpolator for computing alpha values.
|
||||
inline const Interpolator *getAlphaInterpolator() const;
|
||||
|
||||
/// Get the interpolator for computing color values.
|
||||
inline const Interpolator *getColorInterpolator() const;
|
||||
|
||||
/** Get the physical radius of the particle.
|
||||
For built-in operators to work correctly, lengths must be expressed in meters.
|
||||
*/
|
||||
inline float getRadius() const;
|
||||
|
||||
/** Get the mass of the particle.
|
||||
For built-in operators to work correctly, remember that the mass is expressed in kg.
|
||||
*/
|
||||
inline float getMass() const;
|
||||
|
||||
/// Get <CODE>1 / getMass()</CODE>.
|
||||
inline float getMassInv() const;
|
||||
|
||||
/// Get the position vector.
|
||||
inline const osg::Vec3 &getPosition() const;
|
||||
|
||||
/** Get the velocity vector.
|
||||
For built-in operators to work correctly, remember that velocity components are expressed
|
||||
in meters per second.
|
||||
*/
|
||||
inline const osg::Vec3 &getVelocity() const;
|
||||
|
||||
/// Get the previous position (the position before last update).
|
||||
inline const osg::Vec3 &getPreviousPosition() const;
|
||||
|
||||
/** Kill the particle on next update
|
||||
NOTE: after calling this function, the <CODE>isAlive()</CODE> method will still
|
||||
return true until the particle is updated again.
|
||||
*/
|
||||
inline void kill();
|
||||
|
||||
/// Set the life time of the particle.
|
||||
inline void setLifeTime(double t);
|
||||
|
||||
/// Set the minimum and maximum values for polygon size.
|
||||
inline void setSizeRange(const rangef &r);
|
||||
|
||||
/// Set the minimum and maximum values for alpha.
|
||||
inline void setAlphaRange(const rangef &r);
|
||||
|
||||
/// Set the minimum and maximum values for color.
|
||||
inline void setColorRange(const rangev4 &r);
|
||||
|
||||
/// Set the interpolator for computing size values.
|
||||
inline void setSizeInterpolator(Interpolator *ri);
|
||||
|
||||
/// Set the interpolator for computing alpha values.
|
||||
inline void setAlphaInterpolator(Interpolator *ai);
|
||||
|
||||
/// Set the interpolator for computing color values.
|
||||
inline void setColorInterpolator(Interpolator *ci);
|
||||
|
||||
/** Set the physical radius of the particle.
|
||||
For built-in operators to work correctly, lengths must be expressed in meters.
|
||||
*/
|
||||
inline void setRadius(float r);
|
||||
|
||||
/** Set the mass of the particle.
|
||||
For built-in operators to work correctly, remember that the mass is expressed in kg.
|
||||
*/
|
||||
inline void setMass(float m);
|
||||
|
||||
/// Set the position vector.
|
||||
inline void setPosition(const osg::Vec3 &p);
|
||||
|
||||
/** Set the velocity vector.
|
||||
For built-in operators to work correctly, remember that velocity components are expressed
|
||||
in meters per second.
|
||||
*/
|
||||
inline void setVelocity(const osg::Vec3 &v);
|
||||
|
||||
/// Add a vector to the velocity vector.
|
||||
inline void addVelocity(const osg::Vec3 &dv);
|
||||
|
||||
/// Transform position and velocity vectors by a matrix.
|
||||
inline void transformPositionVelocity(const osg::Matrix &xform);
|
||||
|
||||
/** Update the particle (don't call this method manually).
|
||||
This method is called automatically by <CODE>ParticleSystem::update()</CODE>; it
|
||||
updates the graphical properties of the particle for the current time,
|
||||
checks whether the particle is still alive, and then updates its position
|
||||
by computing <I>P = P + V * dt</I> (where <I>P</I> is the position and <I>V</I> is the velocity).
|
||||
*/
|
||||
bool update(double dt);
|
||||
|
||||
/// Perform some pre-rendering tasks. Called automatically by particle systems.
|
||||
inline void beginRender();
|
||||
|
||||
/// Render the particle. Called automatically by particle systems.
|
||||
void render(const osg::Matrix &modelview, float scale = 1.0f) const;
|
||||
|
||||
/// Perform some post-rendering tasks. Called automatically by particle systems.
|
||||
inline void endRender();
|
||||
|
||||
private:
|
||||
Shape shape_;
|
||||
|
||||
rangef sr_;
|
||||
rangef ar_;
|
||||
rangev4 cr_;
|
||||
|
||||
osg::ref_ptr<Interpolator> si_;
|
||||
osg::ref_ptr<Interpolator> ai_;
|
||||
osg::ref_ptr<Interpolator> ci_;
|
||||
|
||||
bool alive_;
|
||||
bool mustdie_;
|
||||
double lifetime_;
|
||||
|
||||
float radius_;
|
||||
float mass_;
|
||||
float massinv_;
|
||||
osg::Vec3 prev_pos_;
|
||||
osg::Vec3 position_;
|
||||
osg::Vec3 velocity_;
|
||||
|
||||
double t0_;
|
||||
|
||||
float current_size_;
|
||||
float current_alpha_;
|
||||
osg::Vec4 current_color_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline Particle::Shape Particle::getShape() const
|
||||
{
|
||||
return shape_;
|
||||
}
|
||||
|
||||
inline void Particle::setShape(Shape s)
|
||||
{
|
||||
shape_ = s;
|
||||
}
|
||||
|
||||
inline bool Particle::isAlive() const
|
||||
{
|
||||
return alive_;
|
||||
}
|
||||
|
||||
inline double Particle::getLifeTime() const
|
||||
{
|
||||
return lifetime_;
|
||||
}
|
||||
|
||||
inline double Particle::getAge() const
|
||||
{
|
||||
return t0_;
|
||||
}
|
||||
|
||||
inline float Particle::getRadius() const
|
||||
{
|
||||
return radius_;
|
||||
}
|
||||
|
||||
inline void Particle::setRadius(float r)
|
||||
{
|
||||
radius_ = r;
|
||||
}
|
||||
|
||||
inline const rangef &Particle::getSizeRange() const
|
||||
{
|
||||
return sr_;
|
||||
}
|
||||
|
||||
inline const rangef &Particle::getAlphaRange() const
|
||||
{
|
||||
return ar_;
|
||||
}
|
||||
|
||||
inline const rangev4 &Particle::getColorRange() const
|
||||
{
|
||||
return cr_;
|
||||
}
|
||||
|
||||
inline const Interpolator *Particle::getSizeInterpolator() const
|
||||
{
|
||||
return si_.get();
|
||||
}
|
||||
|
||||
inline const Interpolator *Particle::getAlphaInterpolator() const
|
||||
{
|
||||
return ai_.get();
|
||||
}
|
||||
|
||||
inline const Interpolator *Particle::getColorInterpolator() const
|
||||
{
|
||||
return ci_.get();
|
||||
}
|
||||
|
||||
inline const osg::Vec3 &Particle::getPosition() const
|
||||
{
|
||||
return position_;
|
||||
}
|
||||
|
||||
inline const osg::Vec3 &Particle::getVelocity() const
|
||||
{
|
||||
return velocity_;
|
||||
}
|
||||
|
||||
inline const osg::Vec3 &Particle::getPreviousPosition() const
|
||||
{
|
||||
return prev_pos_;
|
||||
}
|
||||
|
||||
inline void Particle::kill()
|
||||
{
|
||||
mustdie_ = true;
|
||||
}
|
||||
|
||||
inline void Particle::setLifeTime(double t)
|
||||
{
|
||||
lifetime_ = t;
|
||||
}
|
||||
|
||||
inline void Particle::setSizeRange(const rangef &r)
|
||||
{
|
||||
sr_ = r;
|
||||
}
|
||||
|
||||
inline void Particle::setAlphaRange(const rangef &r)
|
||||
{
|
||||
ar_ = r;
|
||||
}
|
||||
|
||||
inline void Particle::setColorRange(const rangev4 &r)
|
||||
{
|
||||
cr_ = r;
|
||||
}
|
||||
|
||||
inline void Particle::setSizeInterpolator(Interpolator *ri)
|
||||
{
|
||||
si_ = ri;
|
||||
}
|
||||
|
||||
inline void Particle::setAlphaInterpolator(Interpolator *ai)
|
||||
{
|
||||
ai_ = ai;
|
||||
}
|
||||
|
||||
inline void Particle::setColorInterpolator(Interpolator *ci)
|
||||
{
|
||||
ci_ = ci;
|
||||
}
|
||||
|
||||
inline void Particle::setPosition(const osg::Vec3 &p)
|
||||
{
|
||||
position_ = p;
|
||||
}
|
||||
|
||||
inline void Particle::setVelocity(const osg::Vec3 &v)
|
||||
{
|
||||
velocity_ = v;
|
||||
}
|
||||
|
||||
inline void Particle::addVelocity(const osg::Vec3 &v)
|
||||
{
|
||||
velocity_ += v;
|
||||
}
|
||||
|
||||
inline void Particle::transformPositionVelocity(const osg::Matrix &xform)
|
||||
{
|
||||
// this should be optimized!
|
||||
|
||||
osg::Vec3 p1 = position_ + velocity_;
|
||||
|
||||
position_ = xform.preMult(position_);
|
||||
p1 = xform.preMult(p1);
|
||||
|
||||
velocity_ = p1 - position_;
|
||||
}
|
||||
|
||||
inline float Particle::getMass() const
|
||||
{
|
||||
return mass_;
|
||||
}
|
||||
|
||||
inline float Particle::getMassInv() const
|
||||
{
|
||||
return massinv_;
|
||||
}
|
||||
|
||||
inline void Particle::setMass(float m)
|
||||
{
|
||||
mass_ = m;
|
||||
massinv_ = 1 / m;
|
||||
}
|
||||
|
||||
inline void Particle::beginRender()
|
||||
{
|
||||
switch (shape_)
|
||||
{
|
||||
case POINT:
|
||||
glBegin(GL_POINTS);
|
||||
break;
|
||||
case QUAD:
|
||||
glBegin(GL_QUADS);
|
||||
break;
|
||||
default: ;
|
||||
}
|
||||
}
|
||||
|
||||
inline void Particle::endRender()
|
||||
{
|
||||
switch (shape_)
|
||||
{
|
||||
case POINT:
|
||||
case QUAD:
|
||||
glEnd();
|
||||
break;
|
||||
default: ;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
195
include/osgParticle/ParticleProcessor
Normal file
195
include/osgParticle/ParticleProcessor
Normal file
@@ -0,0 +1,195 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_PARTICLEPROCESSOR_
|
||||
#define OSGPARTICLE_PARTICLEPROCESSOR_ 1
|
||||
|
||||
#include <osgParticle/Export>
|
||||
#include <osgParticle/ParticleSystem>
|
||||
|
||||
#include <osg/ref_ptr>
|
||||
#include <osg/Object>
|
||||
#include <osg/Node>
|
||||
#include <osg/NodeVisitor>
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Vec3>
|
||||
#include <osg/Matrix>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/** A common base interface for those classes which need to do something on particles. Such classes
|
||||
are, for example, <CODE>Emitter</CODE> (particle generation) and <CODE>Program</CODE> (particle animation).
|
||||
This class holds some properties, like a <I>reference frame</I> and a reference to a <CODE>ParticleSystem<CODE>;
|
||||
descendant classes should process the particles taking into account the reference frame, computing the right
|
||||
transformations when needed.
|
||||
*/
|
||||
class OSGPARTICLE_EXPORT ParticleProcessor: public osg::Node {
|
||||
public:
|
||||
|
||||
enum ReferenceFrame {
|
||||
RELATIVE_TO_PARENTS,
|
||||
RELATIVE_TO_ABSOLUTE
|
||||
};
|
||||
|
||||
ParticleProcessor();
|
||||
ParticleProcessor(const ParticleProcessor ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
virtual const char *className() const { return "ParticleProcessor"; }
|
||||
virtual bool isSameKindAs(const osg::Object *obj) { return dynamic_cast<const ParticleProcessor*>(obj) != 0; }
|
||||
virtual void accept(osg::NodeVisitor& nv) { if (nv.validNodeMask(*this)) { nv.pushOntoNodePath(this); nv.apply(*this); nv.popFromNodePath(); } }
|
||||
|
||||
/// Get the reference frame.
|
||||
inline ReferenceFrame getReferenceFrame() const;
|
||||
|
||||
/// Set the reference frame.
|
||||
inline void setReferenceFrame(ReferenceFrame rf);
|
||||
|
||||
/// Get whether this processor is enabled or not.
|
||||
inline bool isEnabled() const;
|
||||
|
||||
/// Set whether this processor is enabled or not.
|
||||
inline void setEnabled(bool v);
|
||||
|
||||
/// Get a pointer to the destination particle system.
|
||||
inline ParticleSystem *getParticleSystem();
|
||||
|
||||
/// Get a const pointer to the destination particle system.
|
||||
inline const ParticleSystem *getParticleSystem() const;
|
||||
|
||||
/// Set the destination particle system.
|
||||
inline void setParticleSystem(ParticleSystem *ps);
|
||||
|
||||
void traverse(osg::NodeVisitor &nv);
|
||||
|
||||
/// Get the current local-to-world transformation matrix (valid only during cull traversal).
|
||||
inline const osg::Matrix &getLocalToWorldMatrix();
|
||||
|
||||
/// Get the current world-to-local transformation matrix (valid only during cull traversal).
|
||||
inline const osg::Matrix &getWorldToLocalMatrix();
|
||||
|
||||
/// Transform a point from local to world coordinates (valid only during cull traversal).
|
||||
inline osg::Vec3 transformLocalToWorld(const osg::Vec3 &P);
|
||||
|
||||
/// Transform a vector from local to world coordinates, discarding translation (valid only during cull traversal).
|
||||
inline osg::Vec3 rotateLocalToWorld(const osg::Vec3 &P);
|
||||
|
||||
/// Transform a point from world to local coordinates (valid only during cull traversal).
|
||||
inline osg::Vec3 transformWorldToLocal(const osg::Vec3 &P);
|
||||
|
||||
/// Transform a vector from world to local coordinates, discarding translation (valid only during cull traversal).
|
||||
inline osg::Vec3 rotateWorldToLocal(const osg::Vec3 &P);
|
||||
|
||||
protected:
|
||||
virtual ~ParticleProcessor() {}
|
||||
ParticleProcessor &operator=(const ParticleProcessor &) { return *this; }
|
||||
|
||||
inline const bool computeBound() const;
|
||||
|
||||
virtual void process(double dt) = 0;
|
||||
|
||||
private:
|
||||
ReferenceFrame rf_;
|
||||
bool enabled_;
|
||||
double t0_;
|
||||
osg::ref_ptr<ParticleSystem> ps_;
|
||||
bool need_ltw_matrix_;
|
||||
bool need_wtl_matrix_;
|
||||
osg::Matrix ltw_matrix_;
|
||||
osg::Matrix wtl_matrix_;
|
||||
osg::NodeVisitor *current_nodevisitor_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline ParticleProcessor::ReferenceFrame ParticleProcessor::getReferenceFrame() const
|
||||
{
|
||||
return rf_;
|
||||
}
|
||||
|
||||
inline void ParticleProcessor::setReferenceFrame(ReferenceFrame rf)
|
||||
{
|
||||
rf_ = rf;
|
||||
}
|
||||
|
||||
inline bool ParticleProcessor::isEnabled() const
|
||||
{
|
||||
return enabled_;
|
||||
}
|
||||
|
||||
inline void ParticleProcessor::setEnabled(bool v)
|
||||
{
|
||||
enabled_ = v;
|
||||
if (enabled_) t0_ = -1;
|
||||
}
|
||||
|
||||
inline ParticleSystem *ParticleProcessor::getParticleSystem()
|
||||
{
|
||||
return ps_.get();
|
||||
}
|
||||
|
||||
inline const ParticleSystem *ParticleProcessor::getParticleSystem() const
|
||||
{
|
||||
return ps_.get();
|
||||
}
|
||||
|
||||
inline void ParticleProcessor::setParticleSystem(ParticleSystem *ps)
|
||||
{
|
||||
ps_ = ps;
|
||||
}
|
||||
|
||||
inline const bool ParticleProcessor::computeBound() const
|
||||
{
|
||||
_bsphere.init();
|
||||
_bsphere_computed = true;
|
||||
return true;
|
||||
}
|
||||
|
||||
inline const osg::Matrix &ParticleProcessor::getLocalToWorldMatrix()
|
||||
{
|
||||
if (need_ltw_matrix_) {
|
||||
ltw_matrix_ = osg::Matrix::identity();
|
||||
current_nodevisitor_->getLocalToWorldMatrix(ltw_matrix_, this);
|
||||
need_ltw_matrix_ = false;
|
||||
}
|
||||
return ltw_matrix_;
|
||||
}
|
||||
|
||||
inline const osg::Matrix &ParticleProcessor::getWorldToLocalMatrix()
|
||||
{
|
||||
if (need_wtl_matrix_) {
|
||||
wtl_matrix_ = osg::Matrix::identity();
|
||||
current_nodevisitor_->getWorldToLocalMatrix(wtl_matrix_, this);
|
||||
need_wtl_matrix_ = false;
|
||||
}
|
||||
return wtl_matrix_;
|
||||
}
|
||||
|
||||
inline osg::Vec3 ParticleProcessor::transformLocalToWorld(const osg::Vec3 &P)
|
||||
{
|
||||
return getLocalToWorldMatrix().preMult(P);
|
||||
}
|
||||
|
||||
inline osg::Vec3 ParticleProcessor::transformWorldToLocal(const osg::Vec3 &P)
|
||||
{
|
||||
return getWorldToLocalMatrix().preMult(P);
|
||||
}
|
||||
|
||||
inline osg::Vec3 ParticleProcessor::rotateLocalToWorld(const osg::Vec3 &P)
|
||||
{
|
||||
return getLocalToWorldMatrix().preMult(P) -
|
||||
getLocalToWorldMatrix().preMult(osg::Vec3(0, 0, 0));
|
||||
}
|
||||
|
||||
inline osg::Vec3 ParticleProcessor::rotateWorldToLocal(const osg::Vec3 &P)
|
||||
{
|
||||
return getWorldToLocalMatrix().preMult(P) -
|
||||
getWorldToLocalMatrix().preMult(osg::Vec3(0, 0, 0));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
318
include/osgParticle/ParticleSystem
Normal file
318
include/osgParticle/ParticleSystem
Normal file
@@ -0,0 +1,318 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_PARTICLESYSTEM_
|
||||
#define OSGPARTICLE_PARTICLESYSTEM_ 1
|
||||
|
||||
#include <osgParticle/Export>
|
||||
#include <osgParticle/Particle>
|
||||
|
||||
#include <vector>
|
||||
#include <stack>
|
||||
#include <algorithm>
|
||||
#include <string>
|
||||
|
||||
#include <osg/Object>
|
||||
#include <osg/Drawable>
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/State>
|
||||
#include <osg/Vec3>
|
||||
#include <osg/Statistics>
|
||||
#include <osg/BoundingBox>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/** The heart of this class library; its purpose is to hold a set of particles and manage particle creation, update, rendering and destruction.
|
||||
You can add this drawable to any <CODE>Geode</CODE> as you usually do with other
|
||||
<CODE>Drawable</CODE> classes. Each instance of <CODE>ParticleSystem</CODE> is a separate set of
|
||||
particles; it provides the interface for creating particles and iterating
|
||||
through them (see the <CODE>Emitter</CODE> and <CODE>Program</CODE> classes).
|
||||
*/
|
||||
class OSGPARTICLE_EXPORT ParticleSystem: public osg::Drawable {
|
||||
public:
|
||||
|
||||
ParticleSystem();
|
||||
ParticleSystem(const ParticleSystem ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
META_Object(ParticleSystem);
|
||||
|
||||
/// Get the default bounding box
|
||||
inline const osg::BoundingBox &getDefaultBoundingBox() const;
|
||||
|
||||
/** Set the default bounding box.
|
||||
The default bounding box is used when a real bounding box cannot be computed, for example
|
||||
because no particles has been updated yet.
|
||||
*/
|
||||
inline void setDefaultBoundingBox(const osg::BoundingBox &bbox);
|
||||
|
||||
/// Get the double pass rendering flag.
|
||||
inline bool getDoublePassRendering() const;
|
||||
|
||||
/** Set the double pass rendering flag.
|
||||
Double pass rendering avoids overdraw problems between particle systems
|
||||
and other opaque objects. If you can render all the particle systems <U>after</U>
|
||||
the opaque objects, then double pass is not necessary and can be turned off (best choice).
|
||||
If you set the default attributes with <CODE>setDefaultAttributes</CODE>, then the particle
|
||||
system will fall into a transparent bin.
|
||||
*/
|
||||
inline void setDoublePassRendering(bool v);
|
||||
|
||||
/// Return true if the particle system is frozen.
|
||||
inline bool isFrozen() const;
|
||||
|
||||
/** Set or reset the <I>frozen</I> state.
|
||||
When the particle system is frozen, emitters and programs won't do anything on it.
|
||||
*/
|
||||
inline void setFrozen(bool v);
|
||||
|
||||
/// Get the number of allocated particles (alive + dead).
|
||||
inline int numParticles() const;
|
||||
|
||||
/// Get the number of dead particles.
|
||||
inline int numDeadParticles() const;
|
||||
|
||||
/// Get a pointer to the i-th particle.
|
||||
inline Particle *getParticle(int i);
|
||||
|
||||
/// Get a const pointer to the i-th particle.
|
||||
inline const Particle *getParticle(int i) const;
|
||||
|
||||
/// Create a new particle from the specified template (or the default one if <CODE>ptemplate</CODE> is null).
|
||||
inline virtual Particle *createParticle(const Particle *ptemplate);
|
||||
|
||||
/// Destroy the i-th particle.
|
||||
inline virtual void destroyParticle(int i);
|
||||
|
||||
/// Get the last frame number.
|
||||
inline int getLastFrameNumber() const;
|
||||
|
||||
/// Get a reference to the default particle template.
|
||||
inline const Particle &getDefaultParticleTemplate() const;
|
||||
|
||||
/// Set the default particle template (particle is copied).
|
||||
inline void setDefaultParticleTemplate(const Particle &p);
|
||||
|
||||
/// Get whether the particle system can freeze when culled
|
||||
inline bool getFreezeOnCull() const;
|
||||
|
||||
/// Set whether the particle system can freeze when culled (default is true)
|
||||
inline void setFreezeOnCull(bool v);
|
||||
|
||||
/** A useful method to set the most common <CODE>StateAttribute</CODE>'s in one call.
|
||||
If <CODE>texturefile</CODE> is empty, then texturing is turned off.
|
||||
*/
|
||||
void setDefaultAttributes(const std::string &texturefile = "", bool emissive_particles = true, bool lighting = false);
|
||||
|
||||
/// (<B>EXPERIMENTAL</B>) Get the level of detail.
|
||||
inline int getLevelOfDetail() const;
|
||||
|
||||
/** (<B>EXPERIMENTAL</B>) Set the level of detail. The total number of particles is divided by the detail value to
|
||||
get the actual number of particles to be drawn. This value must be greater than zero.
|
||||
*/
|
||||
inline void setLevelOfDetail(int v);
|
||||
|
||||
/// Update the particles. Don't call this directly, use a <CODE>ParticleSystemUpdater</CODE> instead.
|
||||
virtual void update(double dt);
|
||||
|
||||
inline virtual bool getStats(osg::Statistics &stats);
|
||||
|
||||
protected:
|
||||
virtual ~ParticleSystem();
|
||||
|
||||
ParticleSystem &operator=(const ParticleSystem &) { return *this; }
|
||||
|
||||
inline virtual const bool computeBound() const;
|
||||
virtual void drawImmediateMode(osg::State &state);
|
||||
inline void update_bounds(const osg::Vec3 &p);
|
||||
void single_pass_render(const osg::Matrix &modelview);
|
||||
|
||||
private:
|
||||
typedef std::vector<Particle> Particle_vector;
|
||||
typedef std::stack<Particle*> Death_stack;
|
||||
|
||||
Particle_vector particles_;
|
||||
Death_stack deadparts_;
|
||||
|
||||
osg::BoundingBox def_bbox_;
|
||||
|
||||
bool doublepass_;
|
||||
bool frozen_;
|
||||
int display_list_id_;
|
||||
|
||||
osg::Vec3 bmin_;
|
||||
osg::Vec3 bmax_;
|
||||
|
||||
bool reset_bounds_flag_;
|
||||
bool bounds_computed_;
|
||||
|
||||
Particle def_ptemp_;
|
||||
int last_frame_;
|
||||
bool freeze_on_cull_;
|
||||
|
||||
int detail_;
|
||||
int draw_count_;
|
||||
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline bool ParticleSystem::isFrozen() const
|
||||
{
|
||||
return frozen_;
|
||||
}
|
||||
|
||||
inline void ParticleSystem::setFrozen(bool v)
|
||||
{
|
||||
frozen_ = v;
|
||||
}
|
||||
|
||||
inline const osg::BoundingBox &ParticleSystem::getDefaultBoundingBox() const
|
||||
{
|
||||
return def_bbox_;
|
||||
}
|
||||
|
||||
inline void ParticleSystem::setDefaultBoundingBox(const osg::BoundingBox &bbox)
|
||||
{
|
||||
def_bbox_ = bbox;
|
||||
}
|
||||
|
||||
inline bool ParticleSystem::getDoublePassRendering() const
|
||||
{
|
||||
return doublepass_;
|
||||
}
|
||||
|
||||
inline void ParticleSystem::setDoublePassRendering(bool v)
|
||||
{
|
||||
doublepass_ = v;
|
||||
}
|
||||
|
||||
inline int ParticleSystem::numParticles() const
|
||||
{
|
||||
return static_cast<int>(particles_.size());
|
||||
}
|
||||
|
||||
inline int ParticleSystem::numDeadParticles() const
|
||||
{
|
||||
return static_cast<int>(deadparts_.size());
|
||||
}
|
||||
|
||||
inline Particle *ParticleSystem::getParticle(int i)
|
||||
{
|
||||
return &particles_[i];
|
||||
}
|
||||
|
||||
inline const Particle *ParticleSystem::getParticle(int i) const
|
||||
{
|
||||
return &particles_[i];
|
||||
}
|
||||
|
||||
inline void ParticleSystem::destroyParticle(int i)
|
||||
{
|
||||
particles_[i].kill();
|
||||
}
|
||||
|
||||
inline int ParticleSystem::getLastFrameNumber() const
|
||||
{
|
||||
return last_frame_;
|
||||
}
|
||||
|
||||
inline const bool ParticleSystem::computeBound() const
|
||||
{
|
||||
if (!bounds_computed_) {
|
||||
_bbox = def_bbox_;
|
||||
} else {
|
||||
_bbox._min = bmin_;
|
||||
_bbox._max = bmax_;
|
||||
}
|
||||
_bbox_computed = true;
|
||||
return true;
|
||||
}
|
||||
|
||||
inline bool ParticleSystem::getStats(osg::Statistics &stats)
|
||||
{
|
||||
stats.addNumPrims(draw_count_);
|
||||
return true;
|
||||
}
|
||||
|
||||
inline void ParticleSystem::update_bounds(const osg::Vec3 &p)
|
||||
{
|
||||
if (reset_bounds_flag_) {
|
||||
reset_bounds_flag_ = false;
|
||||
bmin_ = p;
|
||||
bmax_ = p;
|
||||
} else {
|
||||
if (p.x() < bmin_.x()) bmin_.x() = p.x();
|
||||
if (p.y() < bmin_.y()) bmin_.y() = p.y();
|
||||
if (p.z() < bmin_.z()) bmin_.z() = p.z();
|
||||
if (p.x() > bmax_.x()) bmax_.x() = p.x();
|
||||
if (p.y() > bmax_.y()) bmax_.y() = p.y();
|
||||
if (p.z() > bmax_.z()) bmax_.z() = p.z();
|
||||
|
||||
if (!bounds_computed_)
|
||||
bounds_computed_ = true;
|
||||
}
|
||||
}
|
||||
|
||||
inline const Particle &ParticleSystem::getDefaultParticleTemplate() const
|
||||
{
|
||||
return def_ptemp_;
|
||||
}
|
||||
|
||||
inline void ParticleSystem::setDefaultParticleTemplate(const Particle &p)
|
||||
{
|
||||
def_ptemp_ = p;
|
||||
}
|
||||
|
||||
inline bool ParticleSystem::getFreezeOnCull() const
|
||||
{
|
||||
return freeze_on_cull_;
|
||||
}
|
||||
|
||||
inline void ParticleSystem::setFreezeOnCull(bool v)
|
||||
{
|
||||
freeze_on_cull_ = v;
|
||||
}
|
||||
|
||||
inline int ParticleSystem::getLevelOfDetail() const
|
||||
{
|
||||
return detail_;
|
||||
}
|
||||
|
||||
inline void ParticleSystem::setLevelOfDetail(int v)
|
||||
{
|
||||
if (v < 1) v = 1;
|
||||
detail_ = v;
|
||||
}
|
||||
|
||||
// I'm not sure this function should be inlined...
|
||||
|
||||
inline Particle *ParticleSystem::createParticle(const Particle *ptemplate)
|
||||
{
|
||||
// is there any dead particle?
|
||||
if (!deadparts_.empty()) {
|
||||
|
||||
// retrieve a pointer to the last dead particle
|
||||
Particle *P = deadparts_.top();
|
||||
|
||||
// create a new (alive) particle in the same place
|
||||
*P = Particle(ptemplate? *ptemplate: def_ptemp_);
|
||||
|
||||
// remove the pointer from the death stack
|
||||
deadparts_.pop();
|
||||
return P;
|
||||
|
||||
} else {
|
||||
|
||||
// add a new particle to the vector
|
||||
particles_.push_back(Particle(ptemplate? *ptemplate: def_ptemp_));
|
||||
return &particles_.back();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
128
include/osgParticle/ParticleSystemUpdater
Normal file
128
include/osgParticle/ParticleSystemUpdater
Normal file
@@ -0,0 +1,128 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_PARTICLESYSTEMUPDATER_
|
||||
#define OSGPARTICLE_PARTICLESYSTEMUPDATER_ 1
|
||||
|
||||
#include <osgParticle/Export>
|
||||
#include <osgParticle/ParticleSystem>
|
||||
|
||||
#include <vector>
|
||||
|
||||
#include <osg/ref_ptr>
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
#include <osg/Node>
|
||||
#include <osg/NodeVisitor>
|
||||
|
||||
#include <osgUtil/CullVisitor>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/** A useful node class for updating particle systems automatically.
|
||||
When a <CODE>ParticleSystemUpdater</CODE> is traversed by a cull visitor, it calls the
|
||||
<CODE>update()</CODE> method on the specified particle systems. You should place this updater
|
||||
<U>AFTER</U> other nodes like emitters and programs.
|
||||
*/
|
||||
class OSGPARTICLE_EXPORT ParticleSystemUpdater: public osg::Node {
|
||||
public:
|
||||
ParticleSystemUpdater();
|
||||
ParticleSystemUpdater(const ParticleSystemUpdater ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
META_Node(ParticleSystemUpdater);
|
||||
|
||||
/// Return the number of particle systems on the list.
|
||||
inline int numParticleSystems() const;
|
||||
|
||||
/// Add a particle system to the list.
|
||||
inline void addParticleSystem(ParticleSystem *ps);
|
||||
|
||||
/// Get a const particle system from the list.
|
||||
inline const ParticleSystem *getParticleSystem(int i) const;
|
||||
|
||||
/// Get a particle system from the list.
|
||||
inline ParticleSystem *getParticleSystem(int i);
|
||||
|
||||
/// Find a particle system.
|
||||
inline int findParticleSystem(ParticleSystem *ps) const;
|
||||
|
||||
/// Remove a particle system from the list (by index).
|
||||
inline void removeParticleSystem(int i);
|
||||
|
||||
/// Remove a particle system from the list (by pointer).
|
||||
inline bool removeParticleSystem(ParticleSystem *ps);
|
||||
|
||||
virtual void traverse(osg::NodeVisitor &nv);
|
||||
|
||||
protected:
|
||||
virtual ~ParticleSystemUpdater() {}
|
||||
ParticleSystemUpdater &operator=(const ParticleSystemUpdater &) { return *this; }
|
||||
|
||||
inline virtual const bool computeBound() const;
|
||||
|
||||
private:
|
||||
typedef std::vector<osg::ref_ptr<ParticleSystem> > ParticleSystem_Vector;
|
||||
|
||||
ParticleSystem_Vector psv_;
|
||||
double t0_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline const bool ParticleSystemUpdater::computeBound() const
|
||||
{
|
||||
_bsphere.init();
|
||||
_bsphere_computed = true;
|
||||
return true;
|
||||
}
|
||||
|
||||
inline int ParticleSystemUpdater::numParticleSystems() const
|
||||
{
|
||||
return static_cast<int>(psv_.size());
|
||||
}
|
||||
|
||||
inline void ParticleSystemUpdater::addParticleSystem(ParticleSystem *ps)
|
||||
{
|
||||
psv_.push_back(ps);
|
||||
}
|
||||
|
||||
inline const ParticleSystem *ParticleSystemUpdater::getParticleSystem(int i) const
|
||||
{
|
||||
return psv_[i].get();
|
||||
}
|
||||
|
||||
inline ParticleSystem *ParticleSystemUpdater::getParticleSystem(int i)
|
||||
{
|
||||
return psv_[i].get();
|
||||
}
|
||||
|
||||
inline void ParticleSystemUpdater::removeParticleSystem(int i)
|
||||
{
|
||||
psv_.erase(psv_.begin()+i);
|
||||
}
|
||||
|
||||
inline int ParticleSystemUpdater::findParticleSystem(ParticleSystem *ps) const
|
||||
{
|
||||
ParticleSystem_Vector::const_iterator i;
|
||||
int j = 0;
|
||||
for (i=psv_.begin(); i!=psv_.end(); ++i, ++j) {
|
||||
if (i->get() == ps) return j;
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
||||
inline bool ParticleSystemUpdater::removeParticleSystem(ParticleSystem *ps)
|
||||
{
|
||||
int i = findParticleSystem(ps);
|
||||
if (i == -1) return false;
|
||||
removeParticleSystem(i);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
51
include/osgParticle/Placer
Normal file
51
include/osgParticle/Placer
Normal file
@@ -0,0 +1,51 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_PLACER_
|
||||
#define OSGPARTICLE_PLACER_ 1
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
class Particle;
|
||||
|
||||
/** An abstract base class for implementing <I>particle placers</I>. A placer is an object which take
|
||||
a particle as input, and places it somewhere by setting its position vector. Placer objects are
|
||||
used by the <CODE>ModularEmitter</CODE> class as part of the particle emission process.
|
||||
*/
|
||||
class Placer: public osg::Object {
|
||||
public:
|
||||
inline Placer();
|
||||
inline Placer(const Placer ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
virtual const char *className() const { return "Placer"; }
|
||||
virtual bool isSameKindAs(const osg::Object *obj) const { return dynamic_cast<const Placer *>(obj) != 0; }
|
||||
|
||||
/// Place a particle. Must be implemented in descendant classes.
|
||||
virtual void place(Particle *P) const = 0;
|
||||
|
||||
protected:
|
||||
~Placer() {}
|
||||
Placer &operator=(const Placer &) { return *this; }
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline Placer::Placer()
|
||||
: osg::Object()
|
||||
{
|
||||
}
|
||||
|
||||
inline Placer::Placer(const Placer ©, const osg::CopyOp ©op)
|
||||
: osg::Object(copy, copyop)
|
||||
{
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
61
include/osgParticle/PointPlacer
Normal file
61
include/osgParticle/PointPlacer
Normal file
@@ -0,0 +1,61 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_POINTPLACER_
|
||||
#define OSGPARTICLE_POINTPLACER_ 1
|
||||
|
||||
#include <osgParticle/CenteredPlacer>
|
||||
#include <osgParticle/Particle>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/** A point-shaped particle placer.
|
||||
This placer class uses the center point defined in its base class <CODE>CenteredPlacer</CODE>
|
||||
to place there all incoming particles.
|
||||
*/
|
||||
class PointPlacer: public CenteredPlacer {
|
||||
public:
|
||||
inline PointPlacer();
|
||||
inline PointPlacer(const PointPlacer ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
META_Object(PointPlacer);
|
||||
|
||||
/** Place a particle.
|
||||
This method is called automatically by <CODE>ModularEmitter</CODE> and should not be called
|
||||
manually.
|
||||
*/
|
||||
inline void place(Particle *P) const;
|
||||
|
||||
protected:
|
||||
virtual ~PointPlacer() {}
|
||||
PointPlacer &operator=(const PointPlacer &) { return *this; }
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline PointPlacer::PointPlacer()
|
||||
: CenteredPlacer()
|
||||
{
|
||||
}
|
||||
|
||||
inline PointPlacer::PointPlacer(const PointPlacer ©, const osg::CopyOp ©op)
|
||||
: CenteredPlacer(copy, copyop)
|
||||
{
|
||||
}
|
||||
|
||||
inline void PointPlacer::place(Particle *P) const
|
||||
{
|
||||
P->setPosition(getCenter());
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
57
include/osgParticle/Program
Normal file
57
include/osgParticle/Program
Normal file
@@ -0,0 +1,57 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_PROGRAM_
|
||||
#define OSGPARTICLE_PROGRAM_ 1
|
||||
|
||||
#include <osgParticle/Export>
|
||||
#include <osgParticle/ParticleProcessor>
|
||||
|
||||
#include <osg/Object>
|
||||
#include <osg/Node>
|
||||
#include <osg/NodeVisitor>
|
||||
#include <osg/CopyOp>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/** An abstract <CODE>ParticleProcessor</CODE> descendant for modifying particles "on the fly"
|
||||
during the cull traversal.
|
||||
Descendants of this class must implement the <CODE>execute()</CODE> method, which should iterate
|
||||
through all particles in the linked particle system and modify them somehow
|
||||
(usually updating their velocity vector).
|
||||
*/
|
||||
class OSGPARTICLE_EXPORT Program: public ParticleProcessor {
|
||||
public:
|
||||
Program();
|
||||
Program(const Program ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
virtual const char *className() const { return "Program"; }
|
||||
virtual bool isSameKindAs(const osg::Object *obj) { return dynamic_cast<const Program*>(obj) != 0; }
|
||||
virtual void accept(osg::NodeVisitor& nv) { if (nv.validNodeMask(*this)) { nv.pushOntoNodePath(this); nv.apply(*this); nv.popFromNodePath(); } }
|
||||
|
||||
protected:
|
||||
virtual ~Program() {}
|
||||
Program &operator=(const Program &) { return *this; }
|
||||
|
||||
/// Implementation of <CODE>ParticleProcessor::process()</CODE>. Do not call this method by yourself.
|
||||
inline void process(double dt);
|
||||
|
||||
/// Execute the program on the particle system. Must be overriden in descendant classes.
|
||||
virtual void execute(double dt) = 0;
|
||||
|
||||
private:
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline void Program::process(double dt)
|
||||
{
|
||||
execute(dt);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
156
include/osgParticle/RadialShooter
Normal file
156
include/osgParticle/RadialShooter
Normal file
@@ -0,0 +1,156 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_RADIALSHOOTER_
|
||||
#define OSGPARTICLE_RADIALSHOOTER_ 1
|
||||
|
||||
#include <osgParticle/Shooter>
|
||||
#include <osgParticle/Particle>
|
||||
#include <osgParticle/range>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
#include <osg/Math>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/** A shooter class that shoots particles radially.
|
||||
This shooter computes the velocity vector of incoming particles by choosing a
|
||||
random direction and a random speed. Both direction and speed are chosen within
|
||||
specified ranges. The direction is defined by two angles: <B>theta</B>, which
|
||||
is the angle between the velocity vector and the Z axis, and <B>phi</B>, which is
|
||||
the angle between the X axis and the velocity vector projected onto the X-Y plane.
|
||||
*/
|
||||
class RadialShooter: public Shooter {
|
||||
public:
|
||||
inline RadialShooter();
|
||||
inline RadialShooter(const RadialShooter ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
META_Object(RadialShooter);
|
||||
|
||||
/// Get the range of possible values for <B>theta</B> angle.
|
||||
inline const rangef &getThetaRange() const;
|
||||
|
||||
/// Set the range of possible values for <B>theta</B> angle.
|
||||
inline void setThetaRange(const rangef &r);
|
||||
|
||||
/// Set the range of possible values for <B>theta</B> angle.
|
||||
inline void setThetaRange(float r1, float r2);
|
||||
|
||||
/// Get the range of possible values for <B>phi</B> angle.
|
||||
inline const rangef &getPhiRange() const;
|
||||
|
||||
/// Set the range of possible values for <B>phi</B> angle.
|
||||
inline void setPhiRange(const rangef &r);
|
||||
|
||||
/// Set the range of possible values for <B>phi</B> angle.
|
||||
inline void setPhiRange(float r1, float r2);
|
||||
|
||||
/// Get the range of possible values for initial speed of particles.
|
||||
inline const rangef &getInitialSpeedRange() const;
|
||||
|
||||
/// Set the range of possible values for initial speed of particles.
|
||||
inline void setInitialSpeedRange(const rangef &r);
|
||||
|
||||
/// Set the range of possible values for initial speed of particles.
|
||||
inline void setInitialSpeedRange(float r1, float r2);
|
||||
|
||||
/// Shoot a particle. Do not call this method manually.
|
||||
inline void shoot(Particle *P) const;
|
||||
|
||||
protected:
|
||||
virtual ~RadialShooter() {}
|
||||
RadialShooter &operator=(const RadialShooter &) { return *this; }
|
||||
|
||||
private:
|
||||
rangef theta_range_;
|
||||
rangef phi_range_;
|
||||
rangef speed_range_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline RadialShooter::RadialShooter()
|
||||
: Shooter(),
|
||||
theta_range_(0, 0.5f*osg::PI_4),
|
||||
phi_range_(0, 2*osg::PI),
|
||||
speed_range_(10, 10)
|
||||
{
|
||||
}
|
||||
|
||||
inline RadialShooter::RadialShooter(const RadialShooter ©, const osg::CopyOp ©op)
|
||||
: Shooter(copy, copyop),
|
||||
theta_range_(copy.theta_range_),
|
||||
phi_range_(copy.phi_range_),
|
||||
speed_range_(copy.speed_range_)
|
||||
{
|
||||
}
|
||||
|
||||
inline const rangef &RadialShooter::getThetaRange() const
|
||||
{
|
||||
return theta_range_;
|
||||
}
|
||||
|
||||
inline const rangef &RadialShooter::getPhiRange() const
|
||||
{
|
||||
return phi_range_;
|
||||
}
|
||||
|
||||
inline const rangef &RadialShooter::getInitialSpeedRange() const
|
||||
{
|
||||
return speed_range_;
|
||||
}
|
||||
|
||||
inline void RadialShooter::setThetaRange(const rangef &r)
|
||||
{
|
||||
theta_range_ = r;
|
||||
}
|
||||
|
||||
inline void RadialShooter::setThetaRange(float r1, float r2)
|
||||
{
|
||||
theta_range_.min = r1;
|
||||
theta_range_.max = r2;
|
||||
}
|
||||
|
||||
inline void RadialShooter::setPhiRange(const rangef &r)
|
||||
{
|
||||
phi_range_ = r;
|
||||
}
|
||||
|
||||
inline void RadialShooter::setPhiRange(float r1, float r2)
|
||||
{
|
||||
phi_range_.min = r1;
|
||||
phi_range_.max = r2;
|
||||
}
|
||||
|
||||
inline void RadialShooter::setInitialSpeedRange(const rangef &r)
|
||||
{
|
||||
speed_range_ = r;
|
||||
}
|
||||
|
||||
inline void RadialShooter::setInitialSpeedRange(float r1, float r2)
|
||||
{
|
||||
speed_range_.min = r1;
|
||||
speed_range_.max = r2;
|
||||
}
|
||||
|
||||
inline void RadialShooter::shoot(Particle *P) const
|
||||
{
|
||||
float theta = theta_range_.get_random();
|
||||
float phi = phi_range_.get_random();
|
||||
float speed = speed_range_.get_random();
|
||||
|
||||
P->setVelocity(osg::Vec3(
|
||||
speed * sinf(theta) * cosf(phi),
|
||||
speed * sinf(theta) * sinf(phi),
|
||||
speed * cosf(theta)
|
||||
));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
57
include/osgParticle/RandomRateCounter
Normal file
57
include/osgParticle/RandomRateCounter
Normal file
@@ -0,0 +1,57 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_RANDOMRATECOUNTER_
|
||||
#define OSGPARTICLE_RANDOMRATECOUNTER_ 1
|
||||
|
||||
#include <osgParticle/VariableRateCounter>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
class RandomRateCounter: public VariableRateCounter {
|
||||
public:
|
||||
inline RandomRateCounter();
|
||||
inline RandomRateCounter(const RandomRateCounter ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
META_Object(RandomRateCounter);
|
||||
|
||||
/// Return the number of particles to be created in this frame
|
||||
inline int numParticlesToCreate(double dt) const;
|
||||
|
||||
protected:
|
||||
virtual ~RandomRateCounter() {}
|
||||
|
||||
private:
|
||||
mutable float np_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline RandomRateCounter::RandomRateCounter()
|
||||
: VariableRateCounter(), np_(0)
|
||||
{
|
||||
}
|
||||
|
||||
inline RandomRateCounter::RandomRateCounter(const RandomRateCounter ©, const osg::CopyOp ©op)
|
||||
: VariableRateCounter(copy, copyop), np_(copy.np_)
|
||||
{
|
||||
}
|
||||
|
||||
inline int RandomRateCounter::numParticlesToCreate(double dt) const
|
||||
{
|
||||
np_ += dt * getRateRange().get_random();
|
||||
int n = static_cast<int>(np_);
|
||||
np_ -= n;
|
||||
return n;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
124
include/osgParticle/SectorPlacer
Normal file
124
include/osgParticle/SectorPlacer
Normal file
@@ -0,0 +1,124 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_SECTORPLACER_
|
||||
#define OSGPARTICLE_SECTORPLACER_ 1
|
||||
|
||||
#include <osgParticle/CenteredPlacer>
|
||||
#include <osgParticle/Particle>
|
||||
#include <osgParticle/range>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
#include <osg/Vec3>
|
||||
#include <osg/Math>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/** A sector-shaped particle placer.
|
||||
This placer sets the initial position of incoming particle by choosing a random position
|
||||
within a circular sector; this sector is defined by three parameters: a <I>center point</I>,
|
||||
which is inherited directly from <CODE>osgParticle::CenteredPlacer</CODE>, a range of values
|
||||
for <I>radius</I>, and a range of values for the <I>central angle</I> (sometimes called <B>phi</B>).
|
||||
*/
|
||||
class SectorPlacer: public CenteredPlacer {
|
||||
public:
|
||||
inline SectorPlacer();
|
||||
inline SectorPlacer(const SectorPlacer ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
/// Get the range of possible values for radius.
|
||||
inline const rangef &getRadiusRange() const;
|
||||
|
||||
/// Set the range of possible values for radius.
|
||||
inline void setRadiusRange(const rangef &r);
|
||||
|
||||
/// Set the range of possible values for radius.
|
||||
inline void setRadiusRange(float r1, float r2);
|
||||
|
||||
/// Get the range of possible values for the central angle.
|
||||
inline const rangef &getPhiRange() const;
|
||||
|
||||
/// Set the range of possible values for the central angle.
|
||||
inline void setPhiRange(const rangef &r);
|
||||
|
||||
/// Set the range of possible values for the central angle.
|
||||
inline void setPhiRange(float r1, float r2);
|
||||
|
||||
META_Object(SectorPlacer);
|
||||
|
||||
/// Place a particle. Do not call it manually.
|
||||
inline void place(Particle *P) const;
|
||||
|
||||
protected:
|
||||
virtual ~SectorPlacer() {}
|
||||
SectorPlacer &operator=(const SectorPlacer &) { return *this; }
|
||||
|
||||
private:
|
||||
rangef rad_range_;
|
||||
rangef phi_range_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline SectorPlacer::SectorPlacer()
|
||||
: CenteredPlacer(), rad_range_(0, 1), phi_range_(0, osg::PI*2)
|
||||
{
|
||||
}
|
||||
|
||||
inline SectorPlacer::SectorPlacer(const SectorPlacer ©, const osg::CopyOp ©op)
|
||||
: CenteredPlacer(copy, copyop), rad_range_(copy.rad_range_), phi_range_(copy.phi_range_)
|
||||
{
|
||||
}
|
||||
|
||||
inline const rangef &SectorPlacer::getRadiusRange() const
|
||||
{
|
||||
return rad_range_;
|
||||
}
|
||||
|
||||
inline const rangef &SectorPlacer::getPhiRange() const
|
||||
{
|
||||
return phi_range_;
|
||||
}
|
||||
|
||||
inline void SectorPlacer::setRadiusRange(const rangef &r)
|
||||
{
|
||||
rad_range_ = r;
|
||||
}
|
||||
|
||||
inline void SectorPlacer::setRadiusRange(float r1, float r2)
|
||||
{
|
||||
rad_range_.min = r1;
|
||||
rad_range_.max = r2;
|
||||
}
|
||||
|
||||
inline void SectorPlacer::setPhiRange(const rangef &r)
|
||||
{
|
||||
phi_range_ = r;
|
||||
}
|
||||
|
||||
inline void SectorPlacer::setPhiRange(float r1, float r2)
|
||||
{
|
||||
phi_range_.min = r1;
|
||||
phi_range_.max = r2;
|
||||
}
|
||||
|
||||
inline void SectorPlacer::place(Particle *P) const
|
||||
{
|
||||
float rad = rad_range_.get_random();
|
||||
float phi = phi_range_.get_random();
|
||||
|
||||
osg::Vec3 pos(
|
||||
getCenter().x() + rad * cosf(phi),
|
||||
getCenter().y() + rad * sinf(phi),
|
||||
getCenter().z());
|
||||
|
||||
P->setPosition(pos);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
118
include/osgParticle/SegmentPlacer
Normal file
118
include/osgParticle/SegmentPlacer
Normal file
@@ -0,0 +1,118 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_SEGMENTPLACER_
|
||||
#define OSGPARTICLE_SEGMENTPLACER_ 1
|
||||
|
||||
#include <osgParticle/Placer>
|
||||
#include <osgParticle/Particle>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
#include <osg/Vec3>
|
||||
|
||||
namespace osgParticle {
|
||||
|
||||
/** A segment-shaped particle placer.
|
||||
To use this placer you have to define a segment, by setting its two vertices (<B>A</B> and <B>B</B>);
|
||||
when an emitter requests a <CODE>SegmentPlacer</CODE> to place a particle, the position is chosen randomly
|
||||
within that segment.
|
||||
*/
|
||||
class SegmentPlacer: public Placer {
|
||||
public:
|
||||
inline SegmentPlacer();
|
||||
inline SegmentPlacer(const SegmentPlacer ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
META_Object(SegmentPlacer);
|
||||
|
||||
/// get vertex <B>A</B>.
|
||||
inline const osg::Vec3 &getVertexA() const;
|
||||
|
||||
/// Set vertex <B>A</B> of the segment as a vector.
|
||||
inline void setVertexA(const osg::Vec3 &v);
|
||||
|
||||
/// Set vertex <B>A</B> of the segment as three floats.
|
||||
inline void setVertexA(float x, float y, float z);
|
||||
|
||||
/// get vertex <B>B</B>.
|
||||
inline const osg::Vec3 &getVertexB() const;
|
||||
|
||||
/// Set vertex <B>B</B> of the segment as a vector.
|
||||
inline void setVertexB(const osg::Vec3 &v);
|
||||
|
||||
/// Set vertex <B>B</B> of the segment as three floats.
|
||||
inline void setVertexB(float x, float y, float z);
|
||||
|
||||
/// Set both vertices.
|
||||
inline void setSegment(const osg::Vec3 &A, const osg::Vec3 &B);
|
||||
|
||||
/// Place a particle. This method is called by <CODE>ModularEmitter</CODE>, do not call it manually.
|
||||
inline void place(Particle *P) const;
|
||||
|
||||
protected:
|
||||
virtual ~SegmentPlacer() {}
|
||||
SegmentPlacer &operator=(const SegmentPlacer &) { return *this; }
|
||||
|
||||
private:
|
||||
osg::Vec3 A_;
|
||||
osg::Vec3 B_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline SegmentPlacer::SegmentPlacer()
|
||||
: Placer(), A_(-1, 0, 0), B_(1, 0, 0)
|
||||
{
|
||||
}
|
||||
|
||||
inline SegmentPlacer::SegmentPlacer(const SegmentPlacer ©, const osg::CopyOp ©op)
|
||||
: Placer(copy, copyop), A_(copy.A_), B_(copy.B_)
|
||||
{
|
||||
}
|
||||
|
||||
inline const osg::Vec3 &SegmentPlacer::getVertexA() const
|
||||
{
|
||||
return A_;
|
||||
}
|
||||
|
||||
inline const osg::Vec3 &SegmentPlacer::getVertexB() const
|
||||
{
|
||||
return B_;
|
||||
}
|
||||
|
||||
inline void SegmentPlacer::setSegment(const osg::Vec3 &A, const osg::Vec3 &B)
|
||||
{
|
||||
A_ = A;
|
||||
B_ = B;
|
||||
}
|
||||
|
||||
inline void SegmentPlacer::place(Particle *P) const
|
||||
{
|
||||
P->setPosition(rangev3(A_, B_).get_random());
|
||||
}
|
||||
|
||||
inline void SegmentPlacer::setVertexA(const osg::Vec3 &v)
|
||||
{
|
||||
A_ = v;
|
||||
}
|
||||
|
||||
inline void SegmentPlacer::setVertexA(float x, float y, float z)
|
||||
{
|
||||
A_.set(x, y, z);
|
||||
}
|
||||
|
||||
inline void SegmentPlacer::setVertexB(const osg::Vec3 &v)
|
||||
{
|
||||
B_ = v;
|
||||
}
|
||||
|
||||
inline void SegmentPlacer::setVertexB(float x, float y, float z)
|
||||
{
|
||||
B_.set(x, y, z);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
53
include/osgParticle/Shooter
Normal file
53
include/osgParticle/Shooter
Normal file
@@ -0,0 +1,53 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_SHOOTER_
|
||||
#define OSGPARTICLE_SHOOTER_ 1
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
class Particle;
|
||||
|
||||
/** An abstract base class used by ModularEmitter to "shoot" the particles after they have been placed.
|
||||
Descendants of this class must override the <CODE>shoot()</CODE> method.
|
||||
*/
|
||||
class Shooter: public osg::Object {
|
||||
public:
|
||||
inline Shooter();
|
||||
inline Shooter(const Shooter ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
virtual const char *className() const { return "Shooter"; }
|
||||
virtual bool isSameKindAs(const osg::Object *obj) const { return dynamic_cast<const Shooter *>(obj) != 0; }
|
||||
|
||||
/** Shoot a particle. Must be overriden by descendants.
|
||||
This method should only set the velocity vector of particle <CODE>P</CODE>, leaving other
|
||||
attributes unchanged.
|
||||
*/
|
||||
virtual void shoot(Particle *P) const = 0;
|
||||
|
||||
protected:
|
||||
virtual ~Shooter() {}
|
||||
Shooter &operator=(const Shooter &) { return *this; }
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline Shooter::Shooter()
|
||||
: osg::Object()
|
||||
{
|
||||
}
|
||||
|
||||
inline Shooter::Shooter(const Shooter ©, const osg::CopyOp ©op)
|
||||
: osg::Object(copy, copyop)
|
||||
{
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
67
include/osgParticle/VariableRateCounter
Normal file
67
include/osgParticle/VariableRateCounter
Normal file
@@ -0,0 +1,67 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_VARIABLERATECOUNTER_
|
||||
#define OSGPARTICLE_VARIABLERATECOUNTER_ 1
|
||||
|
||||
#include <osgParticle/Counter>
|
||||
#include <osgParticle/range>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
#include <osg/Object>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
class VariableRateCounter: public Counter {
|
||||
public:
|
||||
inline VariableRateCounter();
|
||||
inline VariableRateCounter(const VariableRateCounter ©, const osg::CopyOp ©op = osg::CopyOp::SHALLOW_COPY);
|
||||
|
||||
virtual const char *className() const { return "VariableRateCounter"; }
|
||||
virtual bool isSameKindAs(const osg::Object *obj) const { return dynamic_cast<const VariableRateCounter *>(obj) != 0; }
|
||||
|
||||
inline const rangef &getRateRange() const;
|
||||
inline void setRateRange(const rangef &r);
|
||||
inline void setRateRange(float minrange, float maxrange);
|
||||
|
||||
protected:
|
||||
virtual ~VariableRateCounter() {}
|
||||
|
||||
private:
|
||||
rangef rate_range_;
|
||||
};
|
||||
|
||||
// INLINE FUNCTIONS
|
||||
|
||||
inline VariableRateCounter::VariableRateCounter()
|
||||
: Counter(), rate_range_(1, 1)
|
||||
{
|
||||
}
|
||||
|
||||
inline VariableRateCounter::VariableRateCounter(const VariableRateCounter ©, const osg::CopyOp ©op)
|
||||
: Counter(copy, copyop), rate_range_(copy.rate_range_)
|
||||
{
|
||||
}
|
||||
|
||||
inline const rangef &VariableRateCounter::getRateRange() const
|
||||
{
|
||||
return rate_range_;
|
||||
}
|
||||
|
||||
inline void VariableRateCounter::setRateRange(const rangef &r)
|
||||
{
|
||||
rate_range_ = r;
|
||||
}
|
||||
|
||||
inline void VariableRateCounter::setRateRange(float minrange, float maxrange)
|
||||
{
|
||||
rate_range_.set(minrange, maxrange);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
19
include/osgParticle/Version
Normal file
19
include/osgParticle/Version
Normal file
@@ -0,0 +1,19 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_VERSION_
|
||||
#define OSGPARTICLE_VERSION_ 1
|
||||
|
||||
#include <osgParticle/Export>
|
||||
|
||||
extern "C" {
|
||||
|
||||
OSGPARTICLE_EXPORT const char* osgParticleGetVersion();
|
||||
OSGPARTICLE_EXPORT const char* osgParticleGetLibraryName();
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
65
include/osgParticle/range
Normal file
65
include/osgParticle/range
Normal file
@@ -0,0 +1,65 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2002 Robert Osfield
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
//osgParticle - Copyright (C) 2002 Marco Jez
|
||||
|
||||
#ifndef OSGPARTICLE_RANGE_
|
||||
#define OSGPARTICLE_RANGE_ 1
|
||||
|
||||
#include <cstdlib>
|
||||
|
||||
#include <osg/Vec2>
|
||||
#include <osg/Vec3>
|
||||
#include <osg/Vec4>
|
||||
|
||||
namespace osgParticle
|
||||
{
|
||||
|
||||
/**
|
||||
A simple struct template useful to store ranges of values as min/max pairs.
|
||||
This struct template helps storing min/max ranges for values of any kind; class <CODE>T_</CODE> is
|
||||
the type of values to be stored, and it must support operations <CODE>T_ + T_</CODE>, <CODE>T_ - T_</CODE>,
|
||||
and <CODE>T_ * float</CODE>, otherwise the <CODE>get_random()</CODE> method will not compile.
|
||||
This struct could be extended to customize the random number generator (now it uses only
|
||||
<CODE>std::rand()</CODE>).
|
||||
*/
|
||||
template<class T_> struct range {
|
||||
|
||||
/// Lower bound.
|
||||
T_ min;
|
||||
|
||||
/// Higher bound.
|
||||
T_ max;
|
||||
|
||||
/// Construct the object by calling default constructors for min and max.
|
||||
range() : min(T_()), max(T_()) {}
|
||||
|
||||
/// Construct and initialize min and max directly.
|
||||
range(const T_ &mn, const T_ &mx) : min(mn), max(mx) {}
|
||||
|
||||
/// Set min and max.
|
||||
void set(const T_ &mn, const T_ &mx) { min = mn; max = mx; }
|
||||
|
||||
/// Get a random value between min and max.
|
||||
T_ get_random() const
|
||||
{
|
||||
return min + (max - min) * std::rand() / RAND_MAX;
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
/// Range of floats.
|
||||
typedef range<float> rangef;
|
||||
|
||||
/// Range of osg::Vec2s.
|
||||
typedef range<osg::Vec2> rangev2;
|
||||
|
||||
/// Range of osg::Vec3s.
|
||||
typedef range<osg::Vec3> rangev3;
|
||||
|
||||
/// Range of osg::Vec4s.
|
||||
typedef range<osg::Vec4> rangev4;
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
16
src/Demos/osgparticle/Makefile
Normal file
16
src/Demos/osgparticle/Makefile
Normal file
@@ -0,0 +1,16 @@
|
||||
TOPDIR = ../../..
|
||||
include $(TOPDIR)/Make/makedefs
|
||||
|
||||
CXXFILES =\
|
||||
osgparticle.cpp\
|
||||
|
||||
LIBS += $(OSG_LIBS) $(GLUT_LIB) $(GL_LIBS) $(X_LIBS) $(OTHER_LIBS) -losgParticle
|
||||
|
||||
INSTFILES = \
|
||||
$(CXXFILES)\
|
||||
Makefile.inst=Makefile
|
||||
|
||||
EXEC = osgparticle
|
||||
|
||||
include $(TOPDIR)/Make/makerules
|
||||
|
||||
13
src/Demos/osgparticle/Makefile.inst
Normal file
13
src/Demos/osgparticle/Makefile.inst
Normal file
@@ -0,0 +1,13 @@
|
||||
TOPDIR = ../..
|
||||
include $(TOPDIR)/Make/makedefs
|
||||
|
||||
CXXFILES =\
|
||||
osgparticle.cpp\
|
||||
|
||||
LIBS += $(OSG_LIBS) $(GLUT_LIB) $(GL_LIBS) $(X_LIBS) $(OTHER_LIBS) -losgParticle
|
||||
|
||||
EXEC = osgparticle
|
||||
|
||||
|
||||
include $(TOPDIR)/Make/makerules
|
||||
|
||||
120
src/Demos/osgparticle/osgparticle.cpp
Normal file
120
src/Demos/osgparticle/osgparticle.cpp
Normal file
@@ -0,0 +1,120 @@
|
||||
#include <osg/GL>
|
||||
#include <osgGLUT/glut>
|
||||
#include <osgGLUT/Viewer>
|
||||
|
||||
#include <osg/Transform>
|
||||
#include <osg/Billboard>
|
||||
#include <osg/Geode>
|
||||
#include <osg/Group>
|
||||
#include <osg/Notify>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/ReadFile>
|
||||
|
||||
#include <osgUtil/TrackballManipulator>
|
||||
#include <osgUtil/FlightManipulator>
|
||||
#include <osgUtil/DriveManipulator>
|
||||
#include <osgUtil/Optimizer>
|
||||
|
||||
// ----------------------------------------------------------------------------------
|
||||
// These lines are necessary under Windows because if we don't instantiate at least
|
||||
// one object of osgParticle, the library will not be linked to the exe even if we
|
||||
// add it to the dependancies list, leading to failure when importing .osg files.
|
||||
|
||||
#ifdef WIN32
|
||||
|
||||
#include <osgParticle/Particle>
|
||||
osgParticle::Particle dummy_Particle__;
|
||||
|
||||
#endif
|
||||
|
||||
// ----------------------------------------------------------------------------------
|
||||
|
||||
void write_usage(std::ostream& out,const std::string& name)
|
||||
{
|
||||
out << std::endl;
|
||||
out <<"usage:"<< std::endl;
|
||||
out <<" "<<name<<" [options] infile1 [infile2 ...]"<< std::endl;
|
||||
out << std::endl;
|
||||
out <<"options:"<< std::endl;
|
||||
out <<" -l libraryName - load plugin of name libraryName"<< std::endl;
|
||||
out <<" i.e. -l osgdb_pfb"<< std::endl;
|
||||
out <<" Useful for loading reader/writers which can load"<< std::endl;
|
||||
out <<" other file formats in addition to its extension."<< std::endl;
|
||||
out <<" -e extensionName - load reader/wrter plugin for file extension"<< std::endl;
|
||||
out <<" i.e. -e pfb"<< std::endl;
|
||||
out <<" Useful short hand for specifying full library name as"<< std::endl;
|
||||
out <<" done with -l above, as it automatically expands to"<< std::endl;
|
||||
out <<" the full library name appropriate for each platform."<< std::endl;
|
||||
out <<std::endl;
|
||||
out <<" -stereo - switch on stereo rendering, using the default of,"<< std::endl;
|
||||
out <<" ANAGLYPHIC or the value set in the OSG_STEREO_MODE "<< std::endl;
|
||||
out <<" environmental variable. See doc/stereo.html for "<< std::endl;
|
||||
out <<" further details on setting up accurate stereo "<< std::endl;
|
||||
out <<" for your system. "<< std::endl;
|
||||
out <<" -stereo ANAGLYPHIC - switch on anaglyphic(red/cyan) stereo rendering."<< std::endl;
|
||||
out <<" -stereo QUAD_BUFFER - switch on quad buffered stereo rendering."<< std::endl;
|
||||
out <<std::endl;
|
||||
out <<" -stencil - use a visual with stencil buffer enabled, this "<< std::endl;
|
||||
out <<" also allows the depth complexity statistics mode"<< std::endl;
|
||||
out <<" to be used (press 'p' three times to cycle to it)."<< std::endl;
|
||||
out << std::endl;
|
||||
}
|
||||
|
||||
|
||||
int main( int argc, char **argv )
|
||||
{
|
||||
// initialize the GLUT
|
||||
glutInit( &argc, argv );
|
||||
|
||||
if (argc<2)
|
||||
{
|
||||
write_usage(std::cout,argv[0]);
|
||||
return 0;
|
||||
}
|
||||
|
||||
// create the commandline args.
|
||||
std::vector<std::string> commandLine;
|
||||
for(int i=1;i<argc;++i) commandLine.push_back(argv[i]);
|
||||
|
||||
|
||||
// initialize the viewer.
|
||||
osgGLUT::Viewer viewer;
|
||||
viewer.setWindowTitle(argv[0]);
|
||||
|
||||
// configure the viewer from the commandline arguments, and eat any
|
||||
// parameters that have been matched.
|
||||
viewer.readCommandLine(commandLine);
|
||||
|
||||
// configure the plugin registry from the commandline arguments, and
|
||||
// eat any parameters that have been matched.
|
||||
osgDB::readCommandLine(commandLine);
|
||||
|
||||
// load the nodes from the commandline arguments.
|
||||
osg::Node* rootnode = osgDB::readNodeFiles(commandLine);
|
||||
if (!rootnode)
|
||||
{
|
||||
// write_usage(osg::notify(osg::NOTICE),argv[0]);
|
||||
return 1;
|
||||
}
|
||||
|
||||
// run optimization over the scene graph
|
||||
osgUtil::Optimizer optimzer;
|
||||
optimzer.optimize(rootnode);
|
||||
|
||||
// add a viewport to the viewer and attach the scene graph.
|
||||
viewer.addViewport( rootnode );
|
||||
|
||||
// register trackball, flight and drive.
|
||||
viewer.registerCameraManipulator(new osgUtil::TrackballManipulator);
|
||||
viewer.registerCameraManipulator(new osgUtil::FlightManipulator);
|
||||
viewer.registerCameraManipulator(new osgUtil::DriveManipulator);
|
||||
|
||||
// open the viewer window.
|
||||
viewer.open();
|
||||
|
||||
// fire up the event loop.
|
||||
viewer.run();
|
||||
|
||||
return 0;
|
||||
}
|
||||
17
src/osgParticle/Emitter.cpp
Normal file
17
src/osgParticle/Emitter.cpp
Normal file
@@ -0,0 +1,17 @@
|
||||
#include <osgParticle/Emitter>
|
||||
#include <osgParticle/ParticleProcessor>
|
||||
|
||||
#include <osg/CopyOp>
|
||||
|
||||
osgParticle::Emitter::Emitter()
|
||||
: ParticleProcessor(),
|
||||
usedeftemp_(true)
|
||||
{
|
||||
}
|
||||
|
||||
osgParticle::Emitter::Emitter(const Emitter ©, const osg::CopyOp ©op)
|
||||
: ParticleProcessor(copy, copyop),
|
||||
usedeftemp_(copy.usedeftemp_),
|
||||
ptemp_(copy.ptemp_)
|
||||
{
|
||||
}
|
||||
38
src/osgParticle/FluidFrictionOperator.cpp
Normal file
38
src/osgParticle/FluidFrictionOperator.cpp
Normal file
@@ -0,0 +1,38 @@
|
||||
#include <osgParticle/FluidFrictionOperator>
|
||||
#include <osgParticle/ModularProgram>
|
||||
#include <osgParticle/Operator>
|
||||
#include <osgParticle/Particle>
|
||||
#include <osg/Notify>
|
||||
|
||||
osgParticle::FluidFrictionOperator::FluidFrictionOperator()
|
||||
: Operator(), ovr_rad_(0)
|
||||
{
|
||||
setFluidToAir();
|
||||
}
|
||||
|
||||
osgParticle::FluidFrictionOperator::FluidFrictionOperator(const FluidFrictionOperator ©, const osg::CopyOp ©op)
|
||||
: Operator(copy, copyop),
|
||||
A_(copy.A_),
|
||||
B_(copy.B_),
|
||||
density_(copy.density_),
|
||||
viscosity_(copy.viscosity_),
|
||||
ovr_rad_(copy.ovr_rad_)
|
||||
{
|
||||
}
|
||||
|
||||
void osgParticle::FluidFrictionOperator::operate(Particle *P, double dt)
|
||||
{
|
||||
float r = (ovr_rad_ > 0)? ovr_rad_ : P->getRadius();
|
||||
osg::Vec3 v = P->getVelocity();
|
||||
|
||||
float vm = v.normalize();
|
||||
float R = A_ * r * vm + B_ * r * r * vm * vm;
|
||||
|
||||
osg::Vec3 Fr(-R * v.x(), -R * v.y(), -R * v.z());
|
||||
|
||||
if (current_program_->getReferenceFrame() == ModularProgram::RELATIVE_TO_PARENTS) {
|
||||
Fr = current_program_->rotateLocalToWorld(Fr);
|
||||
}
|
||||
|
||||
P->addVelocity(Fr * (P->getMassInv() * dt));
|
||||
}
|
||||
48
src/osgParticle/IO_AccelOperator.cpp
Normal file
48
src/osgParticle/IO_AccelOperator.cpp
Normal file
@@ -0,0 +1,48 @@
|
||||
|
||||
#include <osgParticle/AccelOperator>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
#include <osg/Vec3>
|
||||
|
||||
#include <iostream>
|
||||
|
||||
bool AccelOperator_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool AccelOperator_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy AccelOperator_Proxy
|
||||
(
|
||||
osgNew osgParticle::AccelOperator,
|
||||
"AccelOperator",
|
||||
"Object Operator AccelOperator",
|
||||
AccelOperator_readLocalData,
|
||||
AccelOperator_writeLocalData
|
||||
);
|
||||
|
||||
bool AccelOperator_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::AccelOperator &aop = static_cast<osgParticle::AccelOperator &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
osg::Vec3 a;
|
||||
|
||||
if (fr[0].matchWord("acceleration")) {
|
||||
if (fr[1].getFloat(a.x()) && fr[2].getFloat(a.y()) && fr[3].getFloat(a.z())) {
|
||||
aop.setAcceleration(a);
|
||||
fr += 4;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool AccelOperator_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::AccelOperator &aop = static_cast<const osgParticle::AccelOperator &>(obj);
|
||||
osg::Vec3 a = aop.getAcceleration();
|
||||
fw.indent() << "acceleration " << a.x() << " " << a.y() << " " << a.z() << std::endl;
|
||||
return true;
|
||||
}
|
||||
49
src/osgParticle/IO_CenteredPlacer.cpp
Normal file
49
src/osgParticle/IO_CenteredPlacer.cpp
Normal file
@@ -0,0 +1,49 @@
|
||||
|
||||
#include <osgParticle/CenteredPlacer>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
#include <osg/Vec3>
|
||||
|
||||
#include <iostream>
|
||||
|
||||
bool CenteredPlacer_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool CenteredPlacer_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy CenteredPlacer_Proxy
|
||||
(
|
||||
0,
|
||||
"CenteredPlacer",
|
||||
"Object Placer CenteredPlacer",
|
||||
CenteredPlacer_readLocalData,
|
||||
CenteredPlacer_writeLocalData
|
||||
);
|
||||
|
||||
bool CenteredPlacer_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::CenteredPlacer &myobj = static_cast<osgParticle::CenteredPlacer &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
osg::Vec3 v;
|
||||
if (fr[0].matchWord("center")) {
|
||||
if (fr[1].getFloat(v.x()) && fr[2].getFloat(v.y()) && fr[3].getFloat(v.z())) {
|
||||
myobj.setCenter(v);
|
||||
fr += 4;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool CenteredPlacer_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::CenteredPlacer &myobj = static_cast<const osgParticle::CenteredPlacer &>(obj);
|
||||
|
||||
osg::Vec3 v = myobj.getCenter();
|
||||
fw.indent() << "center " << v.x() << " " << v.y() << " " << v.z() << std::endl;
|
||||
|
||||
return true;
|
||||
}
|
||||
70
src/osgParticle/IO_Emitter.cpp
Normal file
70
src/osgParticle/IO_Emitter.cpp
Normal file
@@ -0,0 +1,70 @@
|
||||
|
||||
#include <osgParticle/Emitter>
|
||||
|
||||
#include <iostream>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
extern bool read_particle(osgDB::Input &fr, osgParticle::Particle &P);
|
||||
extern void write_particle(const osgParticle::Particle &P, osgDB::Output &fw);
|
||||
|
||||
bool Emitter_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool Emitter_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy Emitter_Proxy
|
||||
(
|
||||
0,
|
||||
"Emitter",
|
||||
"Object Node ParticleProcessor Emitter",
|
||||
Emitter_readLocalData,
|
||||
Emitter_writeLocalData
|
||||
);
|
||||
|
||||
bool Emitter_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::Emitter &myobj = static_cast<osgParticle::Emitter &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
if (fr[0].matchWord("useDefaultTemplate")) {
|
||||
if (fr[1].matchWord("TRUE")) {
|
||||
myobj.setUseDefaultTemplate(true);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
if (fr[1].matchWord("FALSE")) {
|
||||
myobj.setUseDefaultTemplate(false);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (fr[0].matchWord("particleTemplate")) {
|
||||
++fr;
|
||||
itAdvanced = true;
|
||||
osgParticle::Particle P;
|
||||
if (read_particle(fr, P)) {
|
||||
myobj.setParticleTemplate(P);
|
||||
}
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool Emitter_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::Emitter &myobj = static_cast<const osgParticle::Emitter &>(obj);
|
||||
|
||||
fw.indent() << "useDefaultTemplate ";
|
||||
if (!myobj.getUseDefaultTemplate()) {
|
||||
fw << "FALSE" << std::endl;
|
||||
fw.indent() << "particleTemplate ";
|
||||
write_particle(myobj.getParticleTemplate(), fw);
|
||||
fw << std::endl;
|
||||
} else {
|
||||
fw << "TRUE" << std::endl;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
63
src/osgParticle/IO_FluidFrictionOperator.cpp
Normal file
63
src/osgParticle/IO_FluidFrictionOperator.cpp
Normal file
@@ -0,0 +1,63 @@
|
||||
|
||||
#include <osgParticle/FluidFrictionOperator>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
#include <iostream>
|
||||
|
||||
bool FluidFrictionOperator_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool FluidFrictionOperator_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy FluidFrictionOperator_Proxy
|
||||
(
|
||||
osgNew osgParticle::FluidFrictionOperator,
|
||||
"FluidFrictionOperator",
|
||||
"Object Operator FluidFrictionOperator",
|
||||
FluidFrictionOperator_readLocalData,
|
||||
FluidFrictionOperator_writeLocalData
|
||||
);
|
||||
|
||||
bool FluidFrictionOperator_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::FluidFrictionOperator &aop = static_cast<osgParticle::FluidFrictionOperator &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
float f;
|
||||
|
||||
if (fr[0].matchWord("fluidDensity")) {
|
||||
if (fr[1].getFloat(f)) {
|
||||
aop.setFluidDensity(f);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (fr[0].matchWord("fluidViscosity")) {
|
||||
if (fr[1].getFloat(f)) {
|
||||
aop.setFluidViscosity(f);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (fr[0].matchWord("overrideRadius")) {
|
||||
if (fr[1].getFloat(f)) {
|
||||
aop.setOverrideRadius(f);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool FluidFrictionOperator_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::FluidFrictionOperator &aop = static_cast<const osgParticle::FluidFrictionOperator &>(obj);
|
||||
fw.indent() << "fluidDensity " << aop.getFluidDensity() << std::endl;
|
||||
fw.indent() << "fluidViscosity " << aop.getFluidViscosity() << std::endl;
|
||||
fw.indent() << "overrideRadius " << aop.getOverrideRadius();
|
||||
return true;
|
||||
}
|
||||
48
src/osgParticle/IO_ForceOperator.cpp
Normal file
48
src/osgParticle/IO_ForceOperator.cpp
Normal file
@@ -0,0 +1,48 @@
|
||||
|
||||
#include <osgParticle/ForceOperator>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
#include <osg/Vec3>
|
||||
|
||||
#include <iostream>
|
||||
|
||||
bool ForceOperator_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool ForceOperator_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy ForceOperator_Proxy
|
||||
(
|
||||
osgNew osgParticle::ForceOperator,
|
||||
"ForceOperator",
|
||||
"Object Operator ForceOperator",
|
||||
ForceOperator_readLocalData,
|
||||
ForceOperator_writeLocalData
|
||||
);
|
||||
|
||||
bool ForceOperator_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::ForceOperator &fop = static_cast<osgParticle::ForceOperator &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
osg::Vec3 f;
|
||||
|
||||
if (fr[0].matchWord("force")) {
|
||||
if (fr[1].getFloat(f.x()) && fr[2].getFloat(f.y()) && fr[3].getFloat(f.z())) {
|
||||
fop.setForce(f);
|
||||
fr += 4;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool ForceOperator_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::ForceOperator &fop = static_cast<const osgParticle::ForceOperator &>(obj);
|
||||
osg::Vec3 f = fop.getForce();
|
||||
fw.indent() << "force " << f.x() << " " << f.y() << " " << f.z() << std::endl;
|
||||
return true;
|
||||
}
|
||||
28
src/osgParticle/IO_LinearInterpolator.cpp
Normal file
28
src/osgParticle/IO_LinearInterpolator.cpp
Normal file
@@ -0,0 +1,28 @@
|
||||
|
||||
#include <osgParticle/LinearInterpolator>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
bool LinearInterpolator_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool LinearInterpolator_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy LinearInterpolator_Proxy
|
||||
(
|
||||
osgNew osgParticle::LinearInterpolator,
|
||||
"LinearInterpolator",
|
||||
"Object Interpolator LinearInterpolator",
|
||||
LinearInterpolator_readLocalData,
|
||||
LinearInterpolator_writeLocalData
|
||||
);
|
||||
|
||||
bool LinearInterpolator_readLocalData(osg::Object &, osgDB::Input &)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
bool LinearInterpolator_writeLocalData(const osg::Object &, osgDB::Output &)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
62
src/osgParticle/IO_ModularEmitter.cpp
Normal file
62
src/osgParticle/IO_ModularEmitter.cpp
Normal file
@@ -0,0 +1,62 @@
|
||||
|
||||
#include <osgParticle/ModularEmitter>
|
||||
#include <osgParticle/Counter>
|
||||
#include <osgParticle/Placer>
|
||||
#include <osgParticle/Shooter>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
bool ModularEmitter_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool ModularEmitter_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy ModularEmitter_Proxy
|
||||
(
|
||||
osgNew osgParticle::ModularEmitter,
|
||||
"ModularEmitter",
|
||||
"Object Node ParticleProcessor Emitter ModularEmitter",
|
||||
ModularEmitter_readLocalData,
|
||||
ModularEmitter_writeLocalData
|
||||
);
|
||||
|
||||
bool ModularEmitter_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::ModularEmitter &myobj = static_cast<osgParticle::ModularEmitter &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
// we cannot use readObjectOfType() because the Coutner, Placer and Shooter classes are
|
||||
// abstract and we can't create instances to use as prototypes.
|
||||
// So, we call readObject() and then dynamic cast to the desired class.
|
||||
|
||||
osgParticle::Counter *counter = dynamic_cast<osgParticle::Counter *>(fr.readObject());
|
||||
if (counter) {
|
||||
myobj.setCounter(counter);
|
||||
itAdvanced = true;
|
||||
}
|
||||
|
||||
osgParticle::Placer *placer = dynamic_cast<osgParticle::Placer *>(fr.readObject());
|
||||
if (placer) {
|
||||
myobj.setPlacer(placer);
|
||||
itAdvanced = true;
|
||||
}
|
||||
|
||||
osgParticle::Shooter *shooter = dynamic_cast<osgParticle::Shooter *>(fr.readObject());
|
||||
if (shooter) {
|
||||
myobj.setShooter(shooter);
|
||||
itAdvanced = true;
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool ModularEmitter_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::ModularEmitter &myobj = static_cast<const osgParticle::ModularEmitter &>(obj);
|
||||
|
||||
fw.writeObject(*myobj.getCounter());
|
||||
fw.writeObject(*myobj.getPlacer());
|
||||
fw.writeObject(*myobj.getShooter());
|
||||
|
||||
return true;
|
||||
}
|
||||
46
src/osgParticle/IO_ModularProgram.cpp
Normal file
46
src/osgParticle/IO_ModularProgram.cpp
Normal file
@@ -0,0 +1,46 @@
|
||||
|
||||
#include <osgParticle/ModularProgram>
|
||||
#include <osgParticle/Operator>
|
||||
|
||||
#include <iostream>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
bool ModularProgram_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool ModularProgram_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy ModularProgram_Proxy
|
||||
(
|
||||
osgNew osgParticle::ModularProgram,
|
||||
"ModularProgram",
|
||||
"Object Node ParticleProcessor Program ModularProgram",
|
||||
ModularProgram_readLocalData,
|
||||
ModularProgram_writeLocalData
|
||||
);
|
||||
|
||||
bool ModularProgram_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::ModularProgram &myobj = static_cast<osgParticle::ModularProgram &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
osgParticle::Operator *op = dynamic_cast<osgParticle::Operator *>(fr.readObject());
|
||||
if (op) {
|
||||
myobj.addOperator(op);
|
||||
itAdvanced = true;
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool ModularProgram_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::ModularProgram &myobj = static_cast<const osgParticle::ModularProgram &>(obj);
|
||||
|
||||
for (int i=0; i<myobj.numOperators(); ++i) {
|
||||
fw.writeObject(*myobj.getOperator(i));
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
54
src/osgParticle/IO_MultiSegmentPlacer.cpp
Normal file
54
src/osgParticle/IO_MultiSegmentPlacer.cpp
Normal file
@@ -0,0 +1,54 @@
|
||||
|
||||
#include <osgParticle/MultiSegmentPlacer>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
#include <osg/Vec3>
|
||||
|
||||
#include <iostream>
|
||||
|
||||
bool MultiSegmentPlacer_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool MultiSegmentPlacer_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy MultiSegmentPlacer_Proxy
|
||||
(
|
||||
osgNew osgParticle::MultiSegmentPlacer,
|
||||
"MultiSegmentPlacer",
|
||||
"Object Placer MultiSegmentPlacer",
|
||||
MultiSegmentPlacer_readLocalData,
|
||||
MultiSegmentPlacer_writeLocalData
|
||||
);
|
||||
|
||||
bool MultiSegmentPlacer_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::MultiSegmentPlacer &myobj = static_cast<osgParticle::MultiSegmentPlacer &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
osg::Vec3 v;
|
||||
|
||||
if (fr[0].matchWord("vertex")) {
|
||||
if (fr[1].getFloat(v.x()) && fr[2].getFloat(v.y()) && fr[3].getFloat(v.z())) {
|
||||
myobj.addVertex(v);
|
||||
fr += 4;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool MultiSegmentPlacer_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::MultiSegmentPlacer &myobj = static_cast<const osgParticle::MultiSegmentPlacer &>(obj);
|
||||
|
||||
int n = myobj.numVertices();
|
||||
|
||||
for (int i=0; i<n; ++i) {
|
||||
const osg::Vec3 &v = myobj.getVertex(i);
|
||||
fw.indent() << "vertex " << v.x() << " " << v.y() << " " << v.z() << std::endl;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
205
src/osgParticle/IO_Particle.cpp
Normal file
205
src/osgParticle/IO_Particle.cpp
Normal file
@@ -0,0 +1,205 @@
|
||||
|
||||
#include <osgParticle/Particle>
|
||||
#include <osgParticle/Interpolator>
|
||||
#include <osgParticle/range>
|
||||
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
|
||||
#include <osg/Vec3>
|
||||
#include <osg/Vec4>
|
||||
#include <osg/Notify>
|
||||
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
bool read_particle(osgDB::Input &fr, osgParticle::Particle &P)
|
||||
{
|
||||
if (fr[0].matchString("{")) {
|
||||
++fr;
|
||||
int entry = fr[0].getNoNestedBrackets();
|
||||
bool itAdvanced = true;
|
||||
while (!fr.eof() && fr[0].getNoNestedBrackets() >= entry && itAdvanced) {
|
||||
itAdvanced = false;
|
||||
if (fr[0].matchWord("shape")) {
|
||||
const char *ptstr = fr[1].getStr();
|
||||
if (ptstr) {
|
||||
if (std::string(ptstr) == "QUAD") {
|
||||
P.setShape(osgParticle::Particle::QUAD);
|
||||
} else if (std::string(ptstr) == "HEXAGON") {
|
||||
P.setShape(osgParticle::Particle::HEXAGON);
|
||||
} else if (std::string(ptstr) == "POINT") {
|
||||
P.setShape(osgParticle::Particle::POINT);
|
||||
} else if (std::string(ptstr) == "QUAD_TRIANGLESTRIP") {
|
||||
P.setShape(osgParticle::Particle::QUAD_TRIANGLESTRIP);
|
||||
} else {
|
||||
osg::notify(osg::WARN) << "Particle reader warning: invalid shape: " << ptstr << std::endl;
|
||||
}
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
if (fr[0].matchWord("lifeTime")) {
|
||||
float lt;
|
||||
if (fr[1].getFloat(lt)) {
|
||||
P.setLifeTime(lt);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
if (fr[0].matchWord("sizeRange")) {
|
||||
osgParticle::rangef r;
|
||||
if (fr[1].getFloat(r.min) && fr[2].getFloat(r.max)) {
|
||||
P.setSizeRange(r);
|
||||
fr += 3;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
if (fr[0].matchWord("alphaRange")) {
|
||||
osgParticle::rangef r;
|
||||
if (fr[1].getFloat(r.min) && fr[2].getFloat(r.max)) {
|
||||
P.setAlphaRange(r);
|
||||
fr += 3;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
if (fr[0].matchWord("colorRange")) {
|
||||
osgParticle::rangev4 r;
|
||||
if (fr[1].getFloat(r.min.x()) && fr[2].getFloat(r.min.y()) && fr[3].getFloat(r.min.z()) && fr[4].getFloat(r.min.w()) &&
|
||||
fr[5].getFloat(r.max.x()) && fr[6].getFloat(r.max.y()) && fr[7].getFloat(r.max.z()) && fr[8].getFloat(r.max.w())) {
|
||||
P.setColorRange(r);
|
||||
fr += 9;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
if (fr[0].matchWord("position")) {
|
||||
osg::Vec3 v;
|
||||
if (fr[1].getFloat(v.x()) && fr[2].getFloat(v.y()) && fr[3].getFloat(v.z())) {
|
||||
P.setPosition(v);
|
||||
fr += 4;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
if (fr[0].matchWord("velocity")) {
|
||||
osg::Vec3 v;
|
||||
if (fr[1].getFloat(v.x()) && fr[2].getFloat(v.y()) && fr[3].getFloat(v.z())) {
|
||||
P.setVelocity(v);
|
||||
fr += 4;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
if (fr[0].matchWord("radius")) {
|
||||
float f;
|
||||
if (fr[1].getFloat(f)) {
|
||||
P.setRadius(f);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (fr[0].matchWord("mass")) {
|
||||
float f;
|
||||
if (fr[1].getFloat(f)) {
|
||||
P.setMass(f);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
// interpolators
|
||||
|
||||
if (fr[0].matchWord("sizeInterpolator") && fr[1].matchString("{")) {
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
osgParticle::Interpolator *ip = dynamic_cast<osgParticle::Interpolator *>(fr.readObject());
|
||||
if (ip) {
|
||||
P.setSizeInterpolator(ip);
|
||||
}
|
||||
++fr;
|
||||
}
|
||||
if (fr[0].matchWord("alphaInterpolator") && fr[1].matchString("{")) {
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
osgParticle::Interpolator *ip = dynamic_cast<osgParticle::Interpolator *>(fr.readObject());
|
||||
if (ip) {
|
||||
P.setAlphaInterpolator(ip);
|
||||
}
|
||||
++fr;
|
||||
}
|
||||
if (fr[0].matchWord("colorInterpolator") && fr[1].matchString("{")) {
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
osgParticle::Interpolator *ip = dynamic_cast<osgParticle::Interpolator *>(fr.readObject());
|
||||
if (ip) {
|
||||
P.setColorInterpolator(ip);
|
||||
}
|
||||
++fr;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
void write_particle(const osgParticle::Particle &P, osgDB::Output &fw)
|
||||
{
|
||||
fw << "{" << std::endl;
|
||||
fw.moveIn();
|
||||
|
||||
fw.indent() << "shape ";
|
||||
switch (P.getShape())
|
||||
{
|
||||
case osgParticle::Particle::POINT: fw << "POINT" << std::endl; break;
|
||||
case osgParticle::Particle::HEXAGON: fw << "HEXAGON" << std::endl; break;
|
||||
case osgParticle::Particle::QUAD_TRIANGLESTRIP: fw << "QUAD_TRIANGLESTRIP" << std::endl; break;
|
||||
case osgParticle::Particle::QUAD:
|
||||
default: fw << "QUAD" << std::endl; break;
|
||||
}
|
||||
|
||||
fw.indent() << "lifeTime " << P.getLifeTime() << std::endl;
|
||||
|
||||
osgParticle::rangef rf = P.getSizeRange();
|
||||
fw.indent() << "sizeRange " << rf.min << " " << rf.max << std::endl;
|
||||
|
||||
rf = P.getAlphaRange();
|
||||
fw.indent() << "alphaRange " << rf.min << " " << rf.max << std::endl;
|
||||
|
||||
osgParticle::rangev4 rv4 = P.getColorRange();
|
||||
fw.indent() << "colorRange ";
|
||||
fw << rv4.min.x() << " " << rv4.min.y() << " " << rv4.min.z() << " " << rv4.min.w() << " ";
|
||||
fw << rv4.max.x() << " " << rv4.max.y() << " " << rv4.max.z() << " " << rv4.max.w() << std::endl;
|
||||
|
||||
osg::Vec3 v = P.getPosition();
|
||||
fw.indent() << "position ";
|
||||
fw << v.x() << " " << v.y() << " " << v.z() << std::endl;
|
||||
|
||||
v = P.getVelocity();
|
||||
fw.indent() << "velocity ";
|
||||
fw << v.x() << " " << v.y() << " " << v.z() << std::endl;
|
||||
|
||||
fw.indent() << "mass " << P.getMass() << std::endl;
|
||||
fw.indent() << "radius " << P.getRadius() << std::endl;
|
||||
|
||||
// interpolators
|
||||
|
||||
fw.indent() << "sizeInterpolator {" << std::endl;
|
||||
fw.moveIn();
|
||||
fw.writeObject(*P.getSizeInterpolator());
|
||||
fw.moveOut();
|
||||
fw.indent() << "}" << std::endl;
|
||||
|
||||
fw.indent() << "alphaInterpolator {" << std::endl;
|
||||
fw.moveIn();
|
||||
fw.writeObject(*P.getAlphaInterpolator());
|
||||
fw.moveOut();
|
||||
fw.indent() << "}" << std::endl;
|
||||
|
||||
fw.indent() << "colorInterpolator {" << std::endl;
|
||||
fw.moveIn();
|
||||
fw.writeObject(*P.getColorInterpolator());
|
||||
fw.moveOut();
|
||||
fw.indent() << "}" << std::endl;
|
||||
|
||||
fw.moveOut();
|
||||
fw.indent() << "}" << std::endl;
|
||||
}
|
||||
93
src/osgParticle/IO_ParticleProcessor.cpp
Normal file
93
src/osgParticle/IO_ParticleProcessor.cpp
Normal file
@@ -0,0 +1,93 @@
|
||||
|
||||
#include <osgParticle/ParticleProcessor>
|
||||
#include <osgParticle/ParticleSystem>
|
||||
|
||||
#include <iostream>
|
||||
|
||||
#include <osg/ref_ptr>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
extern bool read_particle(osgDB::Input &fr, osgParticle::Particle &P);
|
||||
extern void write_particle(const osgParticle::Particle &P, osgDB::Output &fw);
|
||||
|
||||
bool ParticleProcessor_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool ParticleProcessor_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy ParticleProcessor_Proxy
|
||||
(
|
||||
0,
|
||||
"ParticleProcessor",
|
||||
"Object Node ParticleProcessor",
|
||||
ParticleProcessor_readLocalData,
|
||||
ParticleProcessor_writeLocalData
|
||||
);
|
||||
|
||||
bool ParticleProcessor_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::ParticleProcessor &myobj = static_cast<osgParticle::ParticleProcessor &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
osg::ref_ptr<osgParticle::ParticleSystem> ps_proto = osgNew osgParticle::ParticleSystem;
|
||||
|
||||
osgParticle::ParticleSystem *ps = static_cast<osgParticle::ParticleSystem *>(fr.readObjectOfType(*ps_proto));
|
||||
if (ps) {
|
||||
myobj.setParticleSystem(ps);
|
||||
itAdvanced = true;
|
||||
}
|
||||
|
||||
if (fr[0].matchWord("enabled")) {
|
||||
if (fr[1].matchWord("TRUE")) {
|
||||
myobj.setEnabled(true);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
} else if (fr[1].matchWord("FALSE")) {
|
||||
myobj.setEnabled(false);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (fr[0].matchWord("referenceFrame")) {
|
||||
if (fr[1].matchWord("RELATIVE_TO_ABSOLUTE")) {
|
||||
myobj.setReferenceFrame(osgParticle::ParticleProcessor::RELATIVE_TO_ABSOLUTE);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
if (fr[1].matchWord("RELATIVE_TO_PARENTS")) {
|
||||
myobj.setReferenceFrame(osgParticle::ParticleProcessor::RELATIVE_TO_PARENTS);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool ParticleProcessor_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::ParticleProcessor &myobj = static_cast<const osgParticle::ParticleProcessor &>(obj);
|
||||
|
||||
fw.writeObject(*myobj.getParticleSystem());
|
||||
|
||||
fw.indent() << "enabled ";
|
||||
if (myobj.isEnabled())
|
||||
fw << "TRUE" << std::endl;
|
||||
else
|
||||
fw << "FALSE" << std::endl;
|
||||
|
||||
fw.indent() << "referenceFrame ";
|
||||
switch (myobj.getReferenceFrame())
|
||||
{
|
||||
case osgParticle::ParticleProcessor::RELATIVE_TO_ABSOLUTE:
|
||||
fw << "RELATIVE_TO_ABSOLUTE" << std::endl;
|
||||
break;
|
||||
case osgParticle::ParticleProcessor::RELATIVE_TO_PARENTS:
|
||||
default:
|
||||
fw << "RELATIVE_TO_PARENTS" << std::endl;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
126
src/osgParticle/IO_ParticleSystem.cpp
Normal file
126
src/osgParticle/IO_ParticleSystem.cpp
Normal file
@@ -0,0 +1,126 @@
|
||||
|
||||
#include <osgParticle/ParticleSystem>
|
||||
|
||||
#include <osg/BoundingBox>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
|
||||
extern bool read_particle(osgDB::Input &fr, osgParticle::Particle &P);
|
||||
extern void write_particle(const osgParticle::Particle &P, osgDB::Output &fw);
|
||||
|
||||
bool ParticleSystem_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool ParticleSystem_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy ParticleSystem_Proxy
|
||||
(
|
||||
osgNew osgParticle::ParticleSystem,
|
||||
"ParticleSystem",
|
||||
"Object Drawable ParticleSystem",
|
||||
ParticleSystem_readLocalData,
|
||||
ParticleSystem_writeLocalData
|
||||
);
|
||||
|
||||
bool ParticleSystem_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::ParticleSystem &myobj = static_cast<osgParticle::ParticleSystem &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
if (fr[0].matchWord("DoublePassRendering")) {
|
||||
if (fr[1].matchWord("TRUE")) {
|
||||
myobj.setDoublePassRendering(true);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
} else if (fr[1].matchWord("FALSE")) {
|
||||
myobj.setDoublePassRendering(false);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (fr[0].matchWord("frozen")) {
|
||||
if (fr[1].matchWord("TRUE")) {
|
||||
myobj.setFrozen(true);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
} else if (fr[1].matchWord("FALSE")) {
|
||||
myobj.setFrozen(false); // this might not be necessary
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (fr[0].matchWord("freezeOnCull")) {
|
||||
if (fr[1].matchWord("TRUE")) {
|
||||
myobj.setFreezeOnCull(true);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
} else if (fr[1].matchWord("FALSE")) {
|
||||
myobj.setFreezeOnCull(false);
|
||||
fr += 2;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (fr[0].matchWord("defaultBoundingBox")) {
|
||||
osg::BoundingBox bbox;
|
||||
if ( fr[1].getFloat(bbox.xMin()) &&
|
||||
fr[2].getFloat(bbox.yMin()) &&
|
||||
fr[3].getFloat(bbox.zMin()) &&
|
||||
fr[4].getFloat(bbox.xMax()) &&
|
||||
fr[5].getFloat(bbox.yMax()) &&
|
||||
fr[6].getFloat(bbox.zMax()) ) {
|
||||
myobj.setDefaultBoundingBox(bbox);
|
||||
fr += 7;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (fr[0].matchWord("particleTemplate")) {
|
||||
++fr;
|
||||
itAdvanced = true;
|
||||
osgParticle::Particle P;
|
||||
if (read_particle(fr, P)) {
|
||||
myobj.setDefaultParticleTemplate(P);
|
||||
}
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool ParticleSystem_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::ParticleSystem &myobj = static_cast<const osgParticle::ParticleSystem &>(obj);
|
||||
|
||||
fw.indent() << "DoublePassRendering ";
|
||||
if (myobj.getDoublePassRendering())
|
||||
fw << "TRUE" << std::endl;
|
||||
else
|
||||
fw << "FALSE" << std::endl;
|
||||
|
||||
fw.indent() << "frozen ";
|
||||
if (myobj.isFrozen())
|
||||
fw << "TRUE" << std::endl;
|
||||
else
|
||||
fw << "FALSE" << std::endl;
|
||||
|
||||
fw.indent() << "freezeOnCull ";
|
||||
if (myobj.getFreezeOnCull())
|
||||
fw << "TRUE" << std::endl;
|
||||
else
|
||||
fw << "FALSE" << std::endl;
|
||||
|
||||
osg::BoundingBox bbox = myobj.getDefaultBoundingBox();
|
||||
fw.indent() << "defaultBoundingBox ";
|
||||
fw << bbox.xMin() << " " << bbox.yMin() << " " << bbox.zMin() << " ";
|
||||
fw << bbox.xMax() << " " << bbox.yMax() << " " << bbox.zMax() << std::endl;
|
||||
|
||||
fw.indent() << "particleTemplate ";
|
||||
write_particle(myobj.getDefaultParticleTemplate(), fw);
|
||||
|
||||
return true;
|
||||
}
|
||||
45
src/osgParticle/IO_ParticleSystemUpdater.cpp
Normal file
45
src/osgParticle/IO_ParticleSystemUpdater.cpp
Normal file
@@ -0,0 +1,45 @@
|
||||
|
||||
#include <osgParticle/ParticleSystemUpdater>
|
||||
|
||||
#include <osg/ref_ptr>
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
bool PSU_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool PSU_writeLocalData(const osg::Object &obj, osgDB::Output &fr);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy PSU_Proxy
|
||||
(
|
||||
osgNew osgParticle::ParticleSystemUpdater,
|
||||
"ParticleSystemUpdater",
|
||||
"Object Node ParticleSystemUpdater",
|
||||
PSU_readLocalData,
|
||||
PSU_writeLocalData
|
||||
);
|
||||
|
||||
bool PSU_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::ParticleSystemUpdater &myobj = static_cast<osgParticle::ParticleSystemUpdater &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
osg::ref_ptr<osgParticle::ParticleSystem> proto = osgNew osgParticle::ParticleSystem;
|
||||
osgParticle::ParticleSystem *ps = static_cast<osgParticle::ParticleSystem *>(fr.readObjectOfType(*proto));
|
||||
if (ps) {
|
||||
myobj.addParticleSystem(ps);
|
||||
itAdvanced = true;
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool PSU_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::ParticleSystemUpdater &myobj = static_cast<const osgParticle::ParticleSystemUpdater &>(obj);
|
||||
|
||||
for (int i=0; i<myobj.numParticleSystems(); ++i) {
|
||||
fw.writeObject(*myobj.getParticleSystem(i));
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
28
src/osgParticle/IO_PointPlacer.cpp
Normal file
28
src/osgParticle/IO_PointPlacer.cpp
Normal file
@@ -0,0 +1,28 @@
|
||||
|
||||
#include <osgParticle/PointPlacer>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
bool PointPlacer_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool PointPlacer_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy PointPlacer_Proxy
|
||||
(
|
||||
osgNew osgParticle::PointPlacer,
|
||||
"PointPlacer",
|
||||
"Object Placer CenteredPlacer PointPlacer",
|
||||
PointPlacer_readLocalData,
|
||||
PointPlacer_writeLocalData
|
||||
);
|
||||
|
||||
bool PointPlacer_readLocalData(osg::Object &, osgDB::Input &)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
bool PointPlacer_writeLocalData(const osg::Object &, osgDB::Output &)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
28
src/osgParticle/IO_Program.cpp
Normal file
28
src/osgParticle/IO_Program.cpp
Normal file
@@ -0,0 +1,28 @@
|
||||
|
||||
#include <osgParticle/Program>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
bool Program_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool Program_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy Program_Proxy
|
||||
(
|
||||
0,
|
||||
"Program",
|
||||
"Object Node ParticleProcessor Program",
|
||||
Program_readLocalData,
|
||||
Program_writeLocalData
|
||||
);
|
||||
|
||||
bool Program_readLocalData(osg::Object &, osgDB::Input &)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
bool Program_writeLocalData(const osg::Object &, osgDB::Output &)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
68
src/osgParticle/IO_RadialShooter.cpp
Normal file
68
src/osgParticle/IO_RadialShooter.cpp
Normal file
@@ -0,0 +1,68 @@
|
||||
|
||||
#include <osgParticle/RadialShooter>
|
||||
#include <osgParticle/range>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
bool RadialShooter_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool RadialShooter_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy RadialShooter_Proxy
|
||||
(
|
||||
osgNew osgParticle::RadialShooter,
|
||||
"RadialShooter",
|
||||
"Object Shooter RadialShooter",
|
||||
RadialShooter_readLocalData,
|
||||
RadialShooter_writeLocalData
|
||||
);
|
||||
|
||||
bool RadialShooter_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::RadialShooter &myobj = static_cast<osgParticle::RadialShooter &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
osgParticle::rangef r;
|
||||
|
||||
if (fr[0].matchWord("thetaRange")) {
|
||||
if (fr[1].getFloat(r.min) && fr[2].getFloat(r.max)) {
|
||||
myobj.setThetaRange(r);
|
||||
fr += 3;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (fr[0].matchWord("phiRange")) {
|
||||
if (fr[1].getFloat(r.min) && fr[2].getFloat(r.max)) {
|
||||
myobj.setPhiRange(r);
|
||||
fr += 3;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (fr[0].matchWord("initialSpeedRange")) {
|
||||
if (fr[1].getFloat(r.min) && fr[2].getFloat(r.max)) {
|
||||
myobj.setInitialSpeedRange(r);
|
||||
fr += 3;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool RadialShooter_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::RadialShooter &myobj = static_cast<const osgParticle::RadialShooter &>(obj);
|
||||
osgParticle::rangef r;
|
||||
|
||||
r = myobj.getThetaRange();
|
||||
fw.indent() << "thetaRange " << r.min << " " << r.max << std::endl;
|
||||
r = myobj.getPhiRange();
|
||||
fw.indent() << "phiRange " << r.min << " " << r.max << std::endl;
|
||||
r = myobj.getInitialSpeedRange();
|
||||
fw.indent() << "initialSpeedRange " << r.min << " " << r.max << std::endl;
|
||||
|
||||
return true;
|
||||
}
|
||||
30
src/osgParticle/IO_RandomRateCounter.cpp
Normal file
30
src/osgParticle/IO_RandomRateCounter.cpp
Normal file
@@ -0,0 +1,30 @@
|
||||
|
||||
#include <osgParticle/RandomRateCounter>
|
||||
|
||||
#include <iostream>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
bool RandomRateCounter_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool RandomRateCounter_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy RandomRateCounter_Proxy
|
||||
(
|
||||
osgNew osgParticle::RandomRateCounter,
|
||||
"RandomRateCounter",
|
||||
"Object Counter VariableRateCounter RandomRateCounter",
|
||||
RandomRateCounter_readLocalData,
|
||||
RandomRateCounter_writeLocalData
|
||||
);
|
||||
|
||||
bool RandomRateCounter_readLocalData(osg::Object &, osgDB::Input &)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
bool RandomRateCounter_writeLocalData(const osg::Object &, osgDB::Output &)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
59
src/osgParticle/IO_SectorPlacer.cpp
Normal file
59
src/osgParticle/IO_SectorPlacer.cpp
Normal file
@@ -0,0 +1,59 @@
|
||||
|
||||
#include <osgParticle/SectorPlacer>
|
||||
|
||||
#include <iostream>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
bool SectorPlacer_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool SectorPlacer_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy SectorPlacer_Proxy
|
||||
(
|
||||
osgNew osgParticle::SectorPlacer,
|
||||
"SectorPlacer",
|
||||
"Object Placer CenteredPlacer SectorPlacer",
|
||||
SectorPlacer_readLocalData,
|
||||
SectorPlacer_writeLocalData
|
||||
);
|
||||
|
||||
bool SectorPlacer_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::SectorPlacer &myobj = static_cast<osgParticle::SectorPlacer &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
osgParticle::rangef r;
|
||||
if (fr[0].matchWord("radiusRange")) {
|
||||
if (fr[1].getFloat(r.min) && fr[2].getFloat(r.max)) {
|
||||
myobj.setRadiusRange(r);
|
||||
fr += 3;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (fr[0].matchWord("phiRange")) {
|
||||
if (fr[1].getFloat(r.min) && fr[2].getFloat(r.max)) {
|
||||
myobj.setPhiRange(r);
|
||||
fr += 3;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool SectorPlacer_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::SectorPlacer &myobj = static_cast<const osgParticle::SectorPlacer &>(obj);
|
||||
|
||||
osgParticle::rangef r;
|
||||
|
||||
r = myobj.getRadiusRange();
|
||||
fw.indent() << "radiusRange " << r.min << " " << r.max << std::endl;
|
||||
r = myobj.getPhiRange();
|
||||
fw.indent() << "phiRange " << r.min << " " << r.max << std::endl;
|
||||
|
||||
return true;
|
||||
}
|
||||
60
src/osgParticle/IO_SegmentPlacer.cpp
Normal file
60
src/osgParticle/IO_SegmentPlacer.cpp
Normal file
@@ -0,0 +1,60 @@
|
||||
|
||||
#include <osgParticle/SegmentPlacer>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
#include <osg/Vec3>
|
||||
|
||||
#include <iostream>
|
||||
|
||||
bool SegmentPlacer_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool SegmentPlacer_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy SegmentPlacer_Proxy
|
||||
(
|
||||
osgNew osgParticle::SegmentPlacer,
|
||||
"SegmentPlacer",
|
||||
"Object Placer SegmentPlacer",
|
||||
SegmentPlacer_readLocalData,
|
||||
SegmentPlacer_writeLocalData
|
||||
);
|
||||
|
||||
bool SegmentPlacer_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::SegmentPlacer &myobj = static_cast<osgParticle::SegmentPlacer &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
osg::Vec3 v;
|
||||
|
||||
if (fr[0].matchWord("vertex_A")) {
|
||||
if (fr[1].getFloat(v.x()) && fr[2].getFloat(v.y()) && fr[3].getFloat(v.z())) {
|
||||
myobj.setVertexA(v);
|
||||
fr += 4;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (fr[0].matchWord("vertex_B")) {
|
||||
if (fr[1].getFloat(v.x()) && fr[2].getFloat(v.y()) && fr[3].getFloat(v.z())) {
|
||||
myobj.setVertexB(v);
|
||||
fr += 4;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool SegmentPlacer_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::SegmentPlacer &myobj = static_cast<const osgParticle::SegmentPlacer &>(obj);
|
||||
|
||||
osg::Vec3 v = myobj.getVertexA();
|
||||
fw.indent() << "vertex_A " << v.x() << " " << v.y() << " " << v.z() << std::endl;
|
||||
v = myobj.getVertexB();
|
||||
fw.indent() << "vertex_B " << v.x() << " " << v.y() << " " << v.z() << std::endl;
|
||||
|
||||
return true;
|
||||
}
|
||||
47
src/osgParticle/IO_VariableRateCounter.cpp
Normal file
47
src/osgParticle/IO_VariableRateCounter.cpp
Normal file
@@ -0,0 +1,47 @@
|
||||
|
||||
#include <osgParticle/VariableRateCounter>
|
||||
|
||||
#include <iostream>
|
||||
|
||||
#include <osgDB/Registry>
|
||||
#include <osgDB/Input>
|
||||
#include <osgDB/Output>
|
||||
|
||||
bool VariableRateCounter_readLocalData(osg::Object &obj, osgDB::Input &fr);
|
||||
bool VariableRateCounter_writeLocalData(const osg::Object &obj, osgDB::Output &fw);
|
||||
|
||||
osgDB::RegisterDotOsgWrapperProxy VariableRateCounter_Proxy
|
||||
(
|
||||
0,
|
||||
"VariableRateCounter",
|
||||
"Object Counter VariableRateCounter",
|
||||
VariableRateCounter_readLocalData,
|
||||
VariableRateCounter_writeLocalData
|
||||
);
|
||||
|
||||
bool VariableRateCounter_readLocalData(osg::Object &obj, osgDB::Input &fr)
|
||||
{
|
||||
osgParticle::VariableRateCounter &myobj = static_cast<osgParticle::VariableRateCounter &>(obj);
|
||||
bool itAdvanced = false;
|
||||
|
||||
osgParticle::rangef r;
|
||||
if (fr[0].matchWord("rateRange")) {
|
||||
if (fr[1].getFloat(r.min) && fr[2].getFloat(r.max)) {
|
||||
myobj.setRateRange(r);
|
||||
fr += 3;
|
||||
itAdvanced = true;
|
||||
}
|
||||
}
|
||||
|
||||
return itAdvanced;
|
||||
}
|
||||
|
||||
bool VariableRateCounter_writeLocalData(const osg::Object &obj, osgDB::Output &fw)
|
||||
{
|
||||
const osgParticle::VariableRateCounter &myobj = static_cast<const osgParticle::VariableRateCounter &>(obj);
|
||||
|
||||
osgParticle::rangef r = myobj.getRateRange();
|
||||
fw.indent() << "rateRange " << r.min << " " << r.max << std::endl;
|
||||
|
||||
return true;
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user