PixelLightAPI  .
Public Member Functions
PLMesh::MeshManager Class Reference

This is a manager for the mesh resource. More...

#include <MeshManager.h>

Inheritance diagram for PLMesh::MeshManager:
Inheritance graph
[legend]

List of all members.

Public Member Functions

PLMESH_API MeshManager (PLRenderer::Renderer &cRenderer)
 Constructor.
virtual PLMESH_API ~MeshManager ()
 Destructor.
PLMESH_API PLRenderer::RendererGetRenderer () const
 Returns the used renderer.
PLMESH_API MeshCreateMesh ()
 Creates the mesh and adds the required LODs.
PLMESH_API MeshCreateMesh (const PLCore::String &sName, bool bStatic=true)
 Creates a new mesh resource.
PLMESH_API MeshCreateMesh (const PLCore::String &sName, bool bStatic, const PLCore::String &sParameters)
 Creates a mesh resource using a mesh creator.
PLMESH_API MeshLoadMesh (const PLCore::String &sFilename, const PLCore::String &sParams="", const PLCore::String &sMethod="", bool bReloadMesh=false, bool bStatic=true)
 Load mesh.
PLMESH_API SkeletonManagerGetSkeletonManager () const
 Returns the skeleton manager.

Detailed Description

This is a manager for the mesh resource.

Note:
  • Unloads unused resources automatically by default

Constructor & Destructor Documentation

Constructor.

Parameters:
[in]cRendererRenderer to use
virtual PLMESH_API PLMesh::MeshManager::~MeshManager ( ) [virtual]

Destructor.


Member Function Documentation

Returns the used renderer.

Returns:
Pointer to the renderer the meshes should use, can be a null pointer

Creates the mesh and adds the required LODs.

Returns:
The created mesh, a null pointer on error
Note:
  • If the mesh is created, the 'Material' is added automatically
PLMESH_API Mesh* PLMesh::MeshManager::CreateMesh ( const PLCore::String sName,
bool  bStatic = true 
)

Creates a new mesh resource.

Parameters:
[in]sNameResource name, if empty an unused name is set automatically
[in]bStaticStatic mesh? (better performance!)
Returns:
Pointer to the created resource, a null pointer if there was an error
Note:
  • If there's already a resource with this name, this resource is returned
PLMESH_API Mesh* PLMesh::MeshManager::CreateMesh ( const PLCore::String sName,
bool  bStatic,
const PLCore::String sParameters 
)

Creates a mesh resource using a mesh creator.

Parameters:
[in]sNameMesh creator class name (for instance "MeshCreatorSphere")
[in]bStaticStatic mesh? (better performance!)
[in]sParametersMesh creator parameters. (for instance "Radius='4.0' Detail='20'") This parameters depend on the used mesh creator.
Returns:
Pointer to the created resource, a null pointer if there was an error (maybe unknown class or the class is not derived from 'MeshCreator')
PLMESH_API Mesh* PLMesh::MeshManager::LoadMesh ( const PLCore::String sFilename,
const PLCore::String sParams = "",
const PLCore::String sMethod = "",
bool  bReloadMesh = false,
bool  bStatic = true 
)

Load mesh.

Parameters:
[in]sFilenameMesh filename. It's also possible to create meshes dynamically. "Create MeshCreatorSphere Name=\"Sphere" Radius="4.0" Detail="20.0"" For instance will use the mesh creator class 'MeshCreatorSphere' to create a mesh with the name 'Sphere' and some parameters.
[in]sParamsOptional load method parameters, can be an empty string
[in]sMethodOptional name of the load method to use, can be an empty string
[in]bReloadMeshForce mesh itself to be reloaded?
[in]bStaticStatic mesh? (better performance!)
Returns:
The loaded mesh, a null pointer on error

Returns the skeleton manager.

Returns:
The skeleton manager

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


PixelLight PixelLight 0.9.10-R1
Copyright (C) 2002-2011 by The PixelLight Team
Last modified Fri Dec 23 2011 15:51:21
The content of this PixelLight document is published under the
Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported