Classes | Public Member Functions | Protected Types | Protected Member Functions

sp::scene::SceneLoaderSPSB Class Reference

#include <spSceneLoaderSPSB.hpp>

Inheritance diagram for sp::scene::SceneLoaderSPSB:
sp::scene::SceneLoader sp::io::BaseFileFormatHandler

List of all members.


struct  SParentQueue
struct  SStoryQueueItem

Public Member Functions

 SceneLoaderSPSB ()
virtual ~SceneLoaderSPSB ()
virtual MeshloadScene (const io::stringc &Filename, const io::stringc &TexturePath, const s32 Flags)

Protected Types


Protected Member Functions

virtual void Error (const std::string &Message, const EErrorTypes Type=ERROR_DEFAULT)
virtual void Warning (const std::string &Message, const EWarningType Type=WARNING_DEFAULT)
virtual bool CatchHeader (const SpHeader &Header)
virtual bool CatchSceneConfig (const SpSceneConfig &Object)
virtual bool CatchMesh (const SpMesh &Object)
virtual bool CatchCamera (const SpCamera &Object)
virtual bool CatchWayPoint (const SpWayPoint &Object)
virtual bool CatchLight (const SpLight &Object)
virtual bool CatchBoundVolume (const SpBoundVolume &Object)
virtual bool CatchSound (const SpSound &Object)
virtual bool CatchSprite (const SpSprite &Object)
virtual bool CatchAnimNode (const SpAnimNode &Object)
virtual bool CatchTexture (const SpTexture &Object)
virtual bool CatchTextureClass (const SpTextureClass &Object)
virtual bool CatchLightmap (const SpLightmap &Object)
virtual bool CatchLightmapScene (const SpLightmapScene &Object)
virtual bool CatchShaderClass (const SpShaderClass &Object)
virtual bool CatchStoryboardItem (const SpStoryboardItem &Object)
virtual io::stringc getFinalPath (const io::stringc &Path) const
 Returns the final file path.
virtual void applyQueues ()
 Applies all queues: parent node setup, bot way point links, storyboard items etc.
virtual void addObjectToParentQueue (SceneNode *Node, u32 ParentId)
virtual SpTextureClass * findTextureClass (u32 Id)
virtual video::TexturefindTexture (u32 Id)
virtual video::ShaderClassfindShaderClass (u32 Id)
virtual Transformation findAnimNodeTransformation (u32 Id)
virtual bool setupBaseObject (SceneNode *Node, const SpBaseObject &Object)
 Applies base object information: transformation, name and visibility.
virtual bool setupViewCulling (SceneNode *Node, const SpViewCulling &Object)
virtual bool setupAnimation (SceneNode *Node, const SpAnimationObject &Object)
virtual bool setupMaterial (video::MaterialStates *Material, const SpMaterial &Object)
virtual bool setupSurface (Mesh *MeshObj, video::MeshBuffer *Surface, const SpSurface &Object, u32 Index)
virtual bool setupSurfaceTexture (video::MeshBuffer *Surface, video::Texture *Tex, u32 TexId, u8 Layer)
virtual bool setupSurfaceTextureClass (video::MeshBuffer *Surface, const SpTextureClassLayer &TexClassLayer, bool NeedDefaultTex, u8 Layer)
virtual bool setupMeshBufferFormat (video::MeshBuffer *Surface, const video::VertexFormat *VxFormat, const video::ERendererDataTypes IxFormat)
virtual bool setupMeshCollision (Mesh *MeshObj, const ECollisionModels CollModel, s32 Flags)
virtual bool setupMeshShader (Mesh *MeshObj, u32 ShaderClassId)
virtual bool setupScriptTemplates (SceneNode *Node, const SpBaseObject &Object, const SpScriptData &Script)
virtual bool setupTexture (video::Texture *Tex, const SpTexture &Object)
virtual bool setupLightmapSceneSurface (video::MeshBuffer *Surface, const SpLightmapSceneSurface &Object)
virtual bool setupShaderConstants (video::Shader *ShaderObj, const SpShader &Object)
virtual bool completeMeshConstruct (Mesh *MeshObj, const SpMesh &Object)
virtual bool completeCameraConstruct (Camera *CameraObj, const SpCamera &Object)
virtual bool completeLightConstruct (Light *LightObj, const SpLight &Object)
virtual bool completeSpriteConstruct (Billboard *SpriteObj, const SpSprite &Object)
virtual MeshcreateSkyBox (const std::string(&SkyBoxTexFilenames)[6])
virtual MeshcreateMeshBasic (const SpMeshConstructionBasic &Construct)
virtual MeshcreateMeshResource (const SpMeshConstructionResource &Construct)
virtual video::ShadercreateShader (const SpShader &Object, video::ShaderClass *ShaderClassObj, const video::EShaderTypes Type)
virtual tool::TriggercreateStoryboardItem (const SpStoryboardItem &Object)
virtual video::VertexFormatgetVertexFormat (s8 VertexFormat)
template<typename T >
T * findObjectById (u32 Id, std::map< u32, T * > &Map, const io::stringc &Name)
dim::point2df convert (const SpVector2 &Vec) const
dim::vector3df convert (const SpVector3 &Vec) const
dim::vector4df convert (const SpVector4 &Vec) const
dim::matrix4f convert (const SpMatrix4 &Mat) const
video::color convert (const SpColor &Color) const
Transformation convertTransformation (const SpBaseObject &Object) const

Detailed Description

"SoftPixel Sandbox Scene" loader class. This class is used to load 3D scenes created by the "SoftPixel Sandbox" (Official world editor of the "SoftPixel Engine"). You can simply load the basic construction of a scene by calling: spScene->loadScene("YourSceneFile.spsb"). When you want to use this scene format in your own games you have to write a sub-class which inherits from this one.

Member Enumeration Documentation


Constructor & Destructor Documentation

sp::scene::SceneLoaderSPSB::SceneLoaderSPSB (  ) 
sp::scene::SceneLoaderSPSB::~SceneLoaderSPSB (  )  [virtual]

Member Function Documentation

void sp::scene::SceneLoaderSPSB::addObjectToParentQueue ( SceneNode Node,
u32  ParentId 
) [protected, virtual]
void sp::scene::SceneLoaderSPSB::applyQueues (  )  [protected, virtual]

Applies all queues: parent node setup, bot way point links, storyboard items etc.

bool sp::scene::SceneLoaderSPSB::CatchAnimNode ( const SpAnimNode &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchBoundVolume ( const SpBoundVolume &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchCamera ( const SpCamera &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchHeader ( const SpHeader &  Header  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchLight ( const SpLight &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchLightmap ( const SpLightmap &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchLightmapScene ( const SpLightmapScene &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchMesh ( const SpMesh &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchSceneConfig ( const SpSceneConfig &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchShaderClass ( const SpShaderClass &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchSound ( const SpSound &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchSprite ( const SpSprite &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchStoryboardItem ( const SpStoryboardItem &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchTexture ( const SpTexture &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchTextureClass ( const SpTextureClass &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::CatchWayPoint ( const SpWayPoint &  Object  )  [protected, virtual]
bool sp::scene::SceneLoaderSPSB::completeCameraConstruct ( Camera CameraObj,
const SpCamera &  Object 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::completeLightConstruct ( Light LightObj,
const SpLight &  Object 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::completeMeshConstruct ( Mesh MeshObj,
const SpMesh &  Object 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::completeSpriteConstruct ( Billboard SpriteObj,
const SpSprite &  Object 
) [protected, virtual]
dim::matrix4f sp::scene::SceneLoaderSPSB::convert ( const SpMatrix4 &  Mat  )  const [inline, protected]
dim::point2df sp::scene::SceneLoaderSPSB::convert ( const SpVector2 &  Vec  )  const [inline, protected]
dim::vector4df sp::scene::SceneLoaderSPSB::convert ( const SpVector4 &  Vec  )  const [inline, protected]
dim::vector3df sp::scene::SceneLoaderSPSB::convert ( const SpVector3 &  Vec  )  const [inline, protected]
video::color sp::scene::SceneLoaderSPSB::convert ( const SpColor &  Color  )  const [inline, protected]
Transformation sp::scene::SceneLoaderSPSB::convertTransformation ( const SpBaseObject &  Object  )  const [inline, protected]
Mesh * sp::scene::SceneLoaderSPSB::createMeshBasic ( const SpMeshConstructionBasic &  Construct  )  [protected, virtual]
Mesh * sp::scene::SceneLoaderSPSB::createMeshResource ( const SpMeshConstructionResource &  Construct  )  [protected, virtual]
video::Shader * sp::scene::SceneLoaderSPSB::createShader ( const SpShader &  Object,
video::ShaderClass ShaderClassObj,
const video::EShaderTypes  Type 
) [protected, virtual]
Mesh * sp::scene::SceneLoaderSPSB::createSkyBox ( const std::string(&)  SkyBoxTexFilenames[6]  )  [protected, virtual]
tool::Trigger * sp::scene::SceneLoaderSPSB::createStoryboardItem ( const SpStoryboardItem &  Object  )  [protected, virtual]
void sp::scene::SceneLoaderSPSB::Error ( const std::string &  Message,
const EErrorTypes  Type = ERROR_DEFAULT 
) [protected, virtual]
Transformation sp::scene::SceneLoaderSPSB::findAnimNodeTransformation ( u32  Id  )  [protected, virtual]
template<typename T >
T* sp::scene::SceneLoaderSPSB::findObjectById ( u32  Id,
std::map< u32, T * > &  Map,
const io::stringc Name 
) [inline, protected]
video::ShaderClass * sp::scene::SceneLoaderSPSB::findShaderClass ( u32  Id  )  [protected, virtual]
video::Texture * sp::scene::SceneLoaderSPSB::findTexture ( u32  Id  )  [protected, virtual]
SpSceneFormatHandler::SpTextureClass * sp::scene::SceneLoaderSPSB::findTextureClass ( u32  Id  )  [protected, virtual]
io::stringc sp::scene::SceneLoaderSPSB::getFinalPath ( const io::stringc Path  )  const [protected, virtual]

Returns the final file path.

video::VertexFormat * sp::scene::SceneLoaderSPSB::getVertexFormat ( s8  VertexFormat  )  [protected, virtual]
Mesh * sp::scene::SceneLoaderSPSB::loadScene ( const io::stringc Filename,
const io::stringc TexturePath,
const s32  Flags 
) [virtual]
bool sp::scene::SceneLoaderSPSB::setupAnimation ( SceneNode Node,
const SpAnimationObject &  Object 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::setupBaseObject ( SceneNode Node,
const SpBaseObject &  Object 
) [protected, virtual]

Applies base object information: transformation, name and visibility.

bool sp::scene::SceneLoaderSPSB::setupLightmapSceneSurface ( video::MeshBuffer Surface,
const SpLightmapSceneSurface &  Object 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::setupMaterial ( video::MaterialStates Material,
const SpMaterial &  Object 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::setupMeshBufferFormat ( video::MeshBuffer Surface,
const video::VertexFormat VxFormat,
const video::ERendererDataTypes  IxFormat 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::setupMeshCollision ( Mesh MeshObj,
const ECollisionModels  CollModel,
s32  Flags 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::setupMeshShader ( Mesh MeshObj,
u32  ShaderClassId 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::setupScriptTemplates ( SceneNode Node,
const SpBaseObject &  Object,
const SpScriptData &  Script 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::setupShaderConstants ( video::Shader ShaderObj,
const SpShader &  Object 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::setupSurface ( Mesh MeshObj,
video::MeshBuffer Surface,
const SpSurface &  Object,
u32  Index 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::setupSurfaceTexture ( video::MeshBuffer Surface,
video::Texture Tex,
u32  TexId,
u8  Layer 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::setupSurfaceTextureClass ( video::MeshBuffer Surface,
const SpTextureClassLayer &  TexClassLayer,
bool  NeedDefaultTex,
u8  Layer 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::setupTexture ( video::Texture Tex,
const SpTexture &  Object 
) [protected, virtual]
bool sp::scene::SceneLoaderSPSB::setupViewCulling ( SceneNode Node,
const SpViewCulling &  Object 
) [protected, virtual]
void sp::scene::SceneLoaderSPSB::Warning ( const std::string &  Message,
const EWarningType  Type = WARNING_DEFAULT 
) [protected, virtual]

The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines