24 #ifndef INCLUDED_MODELRENDERER
25 #define INCLUDED_MODELRENDERER
27 #include <boost/shared_ptr.hpp>
297 #endif // INCLUDED_MODELRENDERER
virtual ~ShaderModelRenderer()
virtual void EndFrame()
EndFrame: Remove all models from the list of submitted models.
static void BuildUV(const CModelDefPtr &mdef, const VertexArrayIterator< float[2]> &UV, int UVset)
BuildUV: Copy UV coordinates into the given vertex array.
virtual void Submit(CModel *model)=0
Submit: Submit a model for rendering this frame.
ShaderModelRendererInternals * m
static void CopyPositionAndNormals(const CModelDefPtr &mdef, const VertexArrayIterator< CVector3D > &Position, const VertexArrayIterator< CVector3D > &Normal)
CopyPositionAndNormals: Copy unanimated object-space vertices and normals into the given vertex array...
virtual void Filter(CModelFilter &filter, int passed, int flags=0)=0
Filter: Filter submitted models, setting the passed flags on any models that pass the filter...
Internal data of the ShaderModelRenderer.
shared_ptr< RenderModifier > RenderModifierPtr
virtual void Render(const RenderModifierPtr &modifier, const CShaderDefines &context, int flags)
Render: Render submitted models, using the given RenderModifier to setup the fragment stage...
virtual void EndFrame()=0
EndFrame: Remove all models from the list of submitted models.
Implementation of ModelRenderer that loads the appropriate shaders for rendering each model...
virtual void PrepareModels()
PrepareModels: Calculate renderer data for all previously submitted models.
static void BuildColor4ub(CModel *model, const VertexArrayIterator< CVector3D > &Normal, const VertexArrayIterator< SColor4ub > &Color)
BuildColor4ub: Build lighting colors for the given model, based on previously calculated world space ...
virtual void Render(const RenderModifierPtr &modifier, const CShaderDefines &context, int flags)=0
Render: Render submitted models, using the given RenderModifier to setup the fragment stage...
virtual bool Filter(CModel *model)=0
static void Init()
Initialise global settings.
NONCOPYABLE(CModelFilter)
shared_ptr< ModelRenderer > ModelRendererPtr
CModelRData(const void *key)
static void BuildPositionAndNormals(CModel *model, const VertexArrayIterator< CVector3D > &Position, const VertexArrayIterator< CVector3D > &Normal)
BuildPositionAndNormals: Build animated vertices and normals, transformed into world space...
shared_ptr< ModelVertexRenderer > ModelVertexRendererPtr
Class ModelRenderer: Abstract base class for all model renders.
static void BuildIndices(const CModelDefPtr &mdef, const VertexArrayIterator< u16 > &Indices)
BuildIndices: Create the indices array for the given CModelDef.
virtual void Submit(CModel *model)
Submit: Submit a model for rendering this frame.
Represents a mapping of name strings to value strings, for use with #if and #ifdef and similar condit...
const void * m_Key
The key for model renderer identification.
Class RenderModifier: Some ModelRenderer implementations provide vertex management behaviour but allo...
static void GenTangents(const CModelDefPtr &mdef, std::vector< float > &newVertices, bool gpuSkinning)
GenTangents: Generate tangents for the given CModelDef.
Class CModelRData: Render data that is maintained per CModel.
shared_ptr< LitRenderModifier > LitRenderModifierPtr
Class ModelVertexRenderer: Normal ModelRenderer implementations delegate vertex array management and ...
virtual void PrepareModels()=0
PrepareModels: Calculate renderer data for all previously submitted models.
const void * GetKey() const
GetKey: Retrieve the key that can be used to identify the ModelRenderer that created this data...
virtual void Filter(CModelFilter &filter, int passed, int flags)
Filter: Filter submitted models, setting the passed flags on any models that pass the filter...
ShaderModelRenderer(ModelVertexRendererPtr vertexrender)
Class LitRenderModifier: Abstract base class for RenderModifiers that apply a shadow map...
boost::shared_ptr< CModelDef > CModelDefPtr