The Video::IRenderer interface represents a generic video renderer. More...
#include "murl_video_i_renderer.h"
Public Member Functions | |
virtual IEnums::VideoApi | GetApi () const =0 |
Get the underlying video API. More... | |
virtual UInt32 | GetNumberOfSupportedShaderLanguages () const =0 |
Get the number of supported shader languages. More... | |
virtual IEnums::ShaderLanguage | GetSupportedShaderLanguage (UInt32 index) const =0 |
Get the supported shader language for a given index. More... | |
virtual Bool | Init (IEngine *engine, const IAppConfiguration *appConfig, IFeatureSet *features, IVideoInterface *videoInterface, UInt32 sizeX, UInt32 sizeY)=0 |
Initialize the renderer. More... | |
virtual Bool | DeInit ()=0 |
De-initialize the renderer. More... | |
virtual Bool | Start ()=0 |
Start the renderer after it has been initialized. More... | |
virtual Bool | Stop ()=0 |
Stop the renderer before it gets deinitialized. More... | |
virtual Bool | Pause ()=0 |
Pause the renderer if it is running. More... | |
virtual Bool | Continue ()=0 |
Continue the renderer if it is paused. More... | |
virtual Bool | SaveData ()=0 |
Save the renderer data. More... | |
virtual Bool | Suspend ()=0 |
Suspend the renderer. More... | |
virtual Bool | Resume ()=0 |
Resume the renderer. More... | |
virtual const IFeatureSet * | GetFeatures () const =0 |
Get the available features. More... | |
virtual IObject * | CreateObject (const String &className)=0 |
Create a renderer object. More... | |
virtual Bool | DestroyObject (IObject *&object)=0 |
Destroy an object that was created by this renderer. More... | |
virtual IBatch * | CreateBatch ()=0 |
Create a renderer batch. More... | |
virtual Bool | DestroyBatch (IBatch *&batch)=0 |
Destroy a batch that was created by this renderer. More... | |
virtual Bool | SetOutputSize (UInt32 sizeX, UInt32 sizeY)=0 |
Set the current output surface dimensions. More... | |
virtual Bool | BeginSubmission ()=0 |
Begin submission of renderer objects for the next frame. More... | |
virtual Bool | EndSubmission ()=0 |
End submission of renderer objects for the next frame. More... | |
virtual Bool | BeginRendering (IEnums::SuspendTrigger trigger)=0 |
Start the actual rendering process after all current objects have been submitted. More... | |
virtual Bool | EndRendering ()=0 |
Wait for the current rendering process to complete, after calling BeginRendering(). More... | |
virtual Bool | BeginBatchRendering (IBatch *batch)=0 |
Start the rendering process for an existing static batch. More... | |
virtual Bool | EndBatchRendering (IBatch *batch)=0 |
Finalize the rendering process for an existing static batch. More... | |
virtual Bool | RegisterRenderThread (UInt64 threadId)=0 |
Register the actual render (main) thread with the renderer. More... | |
virtual Bool | RegisterLogicThread (UInt64 threadId)=0 |
Register the logic processing thread with the renderer. More... | |
virtual Bool | RegisterLoaderThread (UInt64 threadId)=0 |
Register the background loader thread with the renderer. More... | |
virtual Bool | UnregisterRenderThread (UInt64 threadId)=0 |
Unregister a render (main) thread from the renderer. More... | |
virtual Bool | UnregisterLogicThread (UInt64 threadId)=0 |
Unregister a logic processing thread from the renderer. More... | |
virtual Bool | UnregisterLoaderThread (UInt64 threadId)=0 |
Unregister a background loader thread from the renderer. More... | |
virtual Bool | RegisterAutomaticallySuspendableObject (IObject *object)=0 |
Register an object for automatic resource suspension. More... | |
virtual Bool | UnregisterAutomaticallySuspendableObject (IObject *object)=0 |
Unregister an object from automatic resource suspension. More... | |
virtual Bool | RegisterManuallySuspendableObject (IObject *object)=0 |
Register an object for manual resource suspension. More... | |
virtual Bool | UnregisterManuallySuspendableObject (IObject *object)=0 |
Unregister an object from manual resource suspension. More... | |
virtual Bool | RegisterEmergencySuspendableObject (IObject *object)=0 |
Register an object for emergency resource suspension. More... | |
virtual Bool | UnregisterEmergencySuspendableObject (IObject *object)=0 |
Unregister an object from emergency resource suspension. More... | |
virtual Bool | CheckConcurrency () const =0 |
Verify that the caller is allowed to manipulate an object. More... | |
virtual Bool | InvokeOnRenderThread (const IMethodCall *call, Bool force) const =0 |
Invoke a call to an object method on a suitable render thread. More... | |
virtual void | SetCurrentCamera (ICamera *camera)=0 |
Set the current camera affecting subsequent drawables. More... | |
virtual void | SetCurrentLayer (UInt32 layer)=0 |
Set the current layer affecting subsequent drawables. More... | |
virtual void | SetCurrentTransform (const Matrix *transform, SInt32 depthOrder)=0 |
Set the current world transform affecting subsequent drawables. More... | |
virtual void | SetCurrentMaterial (IMaterial *material)=0 |
Set the current material affecting subsequent drawables. More... | |
virtual void | SetCurrentConstants (IConstants *constants)=0 |
Set the current shader variables affecting subsequent drawables. More... | |
virtual void | SetCurrentTexture (ITexture *texture, UInt32 unit)=0 |
Set a single texture at a given unit affecting subsequent drawables. More... | |
virtual void | SetCurrentNumberOfTextureUnitsUsed (UInt32 numberOfUnitsUsed)=0 |
Set the number of active texture units affecting subsequent drawables. More... | |
virtual void | SetCurrentTextures (ITexture **textures, UInt32 numberOfUnitsUsed)=0 |
Set multiple texture units affecting subsequent drawables. More... | |
virtual void | SetCurrentLight (ILight *light, UInt32 unit)=0 |
Set a single light source at a given unit affecting subsequent drawables. More... | |
virtual void | SetCurrentNumberOfLightUnitsUsed (UInt32 numberOfUnitsUsed)=0 |
Set the number of active light source units affecting subsequent drawables. More... | |
virtual void | SetCurrentLights (ILight **lights, UInt32 numberOfUnitsUsed)=0 |
Set multiple light source units affecting subsequent drawables. More... | |
virtual void | SetCurrentBone (IBone *bone, UInt32 unit)=0 |
Set a single bone at a given unit affecting subsequent drawables. More... | |
virtual void | SetCurrentNumberOfBoneUnitsUsed (UInt32 numberOfUnitsUsed)=0 |
Set the number of active bone units affecting subsequent drawables. More... | |
virtual void | SetCurrentBones (IBone **bones, UInt32 numberOfUnitsUsed)=0 |
Set multiple bone units affecting subsequent drawables. More... | |
virtual void | PushObjectForUpdate (IObject *object, Real localTime=0.0)=0 |
Queue up an object for updating. More... | |
virtual void | PushObjectForRendering (IVertices *vertices, IIndices *indices)=0 |
Queue up a drawable object for rendering. More... | |
virtual void | PushObjectForRendering (IDrawable *drawable)=0 |
Queue up a drawable object for rendering. More... | |
virtual void | PushBatchForRendering (IBatch *batch)=0 |
Queue up a static batch for rendering. More... | |
virtual UInt32 | GetCurrentNumberOfTextureUnitsNeeded () const =0 |
Get the current number of texture units needed for rendering. More... | |
virtual UInt32 | GetCurrentNumberOfLightUnitsNeeded () const =0 |
Get the current number of light units needed for rendering. More... | |
virtual UInt32 | GetCurrentNumberOfBoneUnitsNeeded () const =0 |
Get the current number of bone units needed for rendering. More... | |
virtual SInt32 | GetCurrentLightTextureUnit (UInt32 lightUnit) const =0 |
Get the currently active shader's light texture unit, if used. More... | |
virtual Bool | LockStatistics ()=0 |
Lock the module statistics. More... | |
virtual Bool | UnlockStatistics ()=0 |
Unlock the module statistics. More... | |
virtual UInt64 | GetAllocatedResourceByteSize (IEnums::MemoryType memoryType) const =0 |
Query the total number of allocated resource bytes. More... | |
virtual UInt32 | GetNumberOfObjectsCreated () const =0 |
Query the number objects created after the most recent cycle. More... | |
virtual UInt32 | GetNumberOfObjectsSuspended () const =0 |
Query the number objects suspended after the most recent cycle. More... | |
virtual UInt32 | GetNumberOfObjectsRendered () const =0 |
Query the number of most recently rendered objects. More... | |
virtual UInt32 | GetNumberOfBatchesRendered () const =0 |
Query the number of most recently rendered object batches. More... | |
virtual Bool | CollectStatisticsObjects (Index< const IStatisticsObject * > &objects) const =0 |
Populate a given index with all objects currently present in the renderer. More... | |
virtual SInt32 | AcquireIndexBufferId (const String &indexBufferName)=0 |
Acquire a unique integer ID from a given index buffer name. More... | |
virtual SInt32 | AcquireVertexBufferId (const String &vertexBufferName)=0 |
Acquire a unique integer ID from a given vertex buffer name. More... | |
virtual SInt32 | AcquireConstantBufferId (const String &constantBufferName)=0 |
Acquire a unique integer ID from a given constant buffer name. More... | |
virtual SInt32 | AcquireUniformId (const String &uniformName)=0 |
Acquire a unique integer ID from a given uniform variable name. More... | |
virtual SInt32 | AcquireAttributeId (const String &attributeName)=0 |
Acquire a unique integer ID from a given attribute variable name. More... | |
virtual const String & | GetIndexBufferName (SInt32 id) const =0 |
Get the actual name of an index buffer by its unique integer ID. More... | |
virtual const String & | GetVertexBufferName (SInt32 id) const =0 |
Get the actual name of an vertex buffer by its unique integer ID. More... | |
virtual const String & | GetConstantBufferName (SInt32 id) const =0 |
Get the actual name of an constant buffer by its unique integer ID. More... | |
virtual const String & | GetUniformName (SInt32 id) const =0 |
Get the actual name of a uniform variable by its unique integer ID. More... | |
virtual const String & | GetAttributeName (SInt32 id) const =0 |
Get the actual name of an attribute variable by its unique integer ID. More... | |
virtual UInt32 | AcquireConstantBufferSignature (const IConstantBuffer *constantBuffer)=0 |
Acquire a signature for a given constant buffer object. More... | |
virtual Bool | ReleaseConstantBufferSignature (const IConstantBuffer *constantBuffer)=0 |
Release the signature of a given constant buffer object. More... | |
virtual UInt32 | AcquireConstantsSignature (const IConstants *constants)=0 |
Acquire a signature for a given constant buffer group object. More... | |
virtual Bool | ReleaseConstantsSignature (const IConstants *constants)=0 |
Release the signature of a given constant buffer group object. More... | |
virtual UInt32 | AcquireIndexBufferSignature (const IIndexBuffer *indexBuffer)=0 |
Acquire a signature for a given index buffer object. More... | |
virtual Bool | ReleaseIndexBufferSignature (const IIndexBuffer *indexBuffer)=0 |
Release the signature of a given index buffer object. More... | |
virtual UInt32 | AcquireIndicesSignature (const IIndices *indices)=0 |
Acquire a signature for a given index buffer group object. More... | |
virtual Bool | ReleaseIndicesSignature (const IIndices *indices)=0 |
Release the signature of a given index buffer group object. More... | |
virtual UInt32 | AcquireVertexBufferSignature (const IVertexBuffer *vertexBuffer)=0 |
Acquire a signature for a given vertex buffer object. More... | |
virtual Bool | ReleaseVertexBufferSignature (const IVertexBuffer *vertexBuffer)=0 |
Release the signature of a given vertex buffer object. More... | |
virtual UInt32 | AcquireVerticesSignature (const IVertices *vertices)=0 |
Acquire a signature for a given vertex buffer group object. More... | |
virtual Bool | ReleaseVerticesSignature (const IVertices *vertices)=0 |
Release the signature of a given vertex buffer group object. More... | |
virtual void | IncreaseNumberOfResourceBytesAllocated (IEnums::MemoryType memoryType, UInt64 numBytes)=0 |
Increase the internal number of allocated resource bytes. More... | |
virtual void | DecreaseNumberOfResourceBytesAllocated (IEnums::MemoryType memoryType, UInt64 numBytes)=0 |
Decrease the internal number of allocated resource bytes. More... | |
virtual void | IncreaseNumberOfObjectsSuspended ()=0 |
Increase the internal suspended object count by 1. More... | |
virtual void | DecreaseNumberOfObjectsSuspended ()=0 |
Decrease the internal suspended object count by 1. More... | |
virtual Bool | ValidateFrameBufferFormat (IEnums::PixelFormat &colorPixelFormat, IEnums::DepthBufferFormat &depthBufferFormat, IEnums::StencilBufferFormat &stencilBufferFormat)=0 |
Validate a frame buffer format. More... | |
virtual Bool | TakeScreenshot (IVideoStream *outputStream, IEnums::Orientation windowOrientation)=0 |
Take a screenshot. More... | |
virtual Bool | WaitDeviceIdle ()=0 |
waits until device is idle More... | |
Public Member Functions inherited from Murl::IFactoryObject< IRenderer > | |
~IFactoryObject () override | |
The destructor. | |
virtual const ClassInfo * | GetObjectClassInfo () const=0 |
Get the object instance's class info, if present. More... | |
virtual void | ResetObjectProperties ()=0 |
Reset the object instance's properties to their default values. | |
Public Member Functions inherited from Murl::Video::IRendererRegistry | |
virtual Bool | RegisterObjectClass (const IObject::ClassInfo &classInfo)=0 |
Register an object class. More... | |
virtual Bool | UnregisterObjectClass (const IObject::ClassInfo &classInfo)=0 |
Unregister a previously registered object class. More... | |
virtual SInt32 | GetRegisteredObjectClassInfoIndex (const IObject::ClassInfo &classInfo) const =0 |
Query the index of a registered object class, by its ClassInfo structure. More... | |
virtual SInt32 | GetRegisteredObjectClassInfoIndex (const String &className) const =0 |
Query the index of a registered object class, by its class name. More... | |
virtual UInt32 | GetNumberOfRegisteredObjectClassInfos () const =0 |
Get the total number of registered object classes. More... | |
virtual const IObject::ClassInfo * | GetRegisteredObjectClassInfo (UInt32 index) const =0 |
Get the ClassInfo structure of a registered object class. More... | |
Additional Inherited Members | |
Public Types inherited from Murl::IFactoryObject< IRenderer > | |
using | ClassInfoArray = Array< const ClassInfo * > |
Definition of an array of ClassInfo objects. | |
Static Public Member Functions inherited from Murl::IFactoryObject< IRenderer > | |
static const PropertyInfo * | GetPropertyInfo () |
Get the class' property info struct. More... | |
static const AttributeInfo * | GetAttributeInfo () |
Get the class' attribute info struct. More... | |
static void | ResetProperties (IFactoryObject< IRenderer > *object) |
Reset an object instance's properties to their default values. More... | |
Detailed Description
The Video::IRenderer interface represents a generic video renderer.
For most cases, an application does not need to directly interact with this interface. Instead, using video-related nodes from the Murl::Graph Node Interfaces or Murl::Graph Node Classes sections is the preferred way to implement visual output functionality in a cross-platform manner.
Accessing the video renderer interface directly may be useful in advanced use cases, when creating custom video objects or even a complete custom renderer suite.
Member Function Documentation
◆ GetApi()
|
pure virtual |
Get the underlying video API.
- Returns
- The used video API.
◆ GetNumberOfSupportedShaderLanguages()
|
pure virtual |
Get the number of supported shader languages.
If the renderer does not support programmable shaders, this method returns 0. Otherwise, the number of supported languages is returned, the individual languages can be queried using GetSupportedShaderLanguage() with an index from 0 to GetNumberOfSupportedShaderLanguages()-1; the most preferable shader language can be found at index 0.
- Returns
- The number of supported languages.
◆ GetSupportedShaderLanguage()
|
pure virtual |
Get the supported shader language for a given index.
- Parameters
-
index The index, from 0 to GetNumberOfSupportedShaderLanguages()-1.
- Returns
- The supported language.
◆ Init()
|
pure virtual |
Initialize the renderer.
- Parameters
-
engine The engine to attach to. appConfig The application configuration object. features The feature set to possibly update according to this renderer' capabilities. videoInterface An interface to the platform front end's video interface for managing contexts etc. sizeX The initial horizontal output surface size in pixels. sizeY The initial vertical output surface size in pixels.
- Returns
- true if successful.
◆ DeInit()
|
pure virtual |
De-initialize the renderer.
- Returns
- true if successful.
◆ Start()
|
pure virtual |
Start the renderer after it has been initialized.
- Returns
- true if successful.
◆ Stop()
|
pure virtual |
Stop the renderer before it gets deinitialized.
- Returns
- true if successful.
◆ Pause()
|
pure virtual |
Pause the renderer if it is running.
- Returns
- true if successful.
◆ Continue()
|
pure virtual |
Continue the renderer if it is paused.
- Returns
- true if successful.
◆ SaveData()
|
pure virtual |
Save the renderer data.
- Returns
- true if successful.
◆ Suspend()
|
pure virtual |
Suspend the renderer.
- Returns
- true if successful.
◆ Resume()
|
pure virtual |
Resume the renderer.
- Returns
- true if successful.
◆ GetFeatures()
|
pure virtual |
Get the available features.
- Returns
- The set of available features.
◆ CreateObject()
Create a renderer object.
- Parameters
-
className The class name of the renderer object to create.
- Returns
- The newly created object, or null if failed.
◆ DestroyObject()
Destroy an object that was created by this renderer.
- Parameters
-
object A reference to a pointer containing the object to destroy.
- Returns
- true if successful.
◆ CreateBatch()
|
pure virtual |
Create a renderer batch.
- Returns
- The newly created batch, or null if failed.
◆ DestroyBatch()
Destroy a batch that was created by this renderer.
- Parameters
-
batch A reference to a pointer containing the batch to destroy.
- Returns
- true if successful.
◆ SetOutputSize()
Set the current output surface dimensions.
- Parameters
-
sizeX The current horizontal output surface size in pixels. sizeY The current vertical output surface size in pixels.
- Returns
- true if successful.
◆ BeginSubmission()
|
pure virtual |
Begin submission of renderer objects for the next frame.
Any calls to state-changing methods like SetCurrentMaterial(), SetCurrentCamera() etc. as well as any queueing methods like PushObjectForRendering() must happen between a call to this method and the corresponding EndSubmission() call.
- Returns
- true if successful.
◆ EndSubmission()
|
pure virtual |
End submission of renderer objects for the next frame.
- Returns
- true if successful.
◆ BeginRendering()
|
pure virtual |
Start the actual rendering process after all current objects have been submitted.
- Parameters
-
trigger The suspend trigger to apply. If set to a value other than IEnums::SUSPEND_TRIGGER_NONE, all objects registered for that trigger type (manual or emergency) are commanded to release any resources that are not currently needed.
- Returns
- true if successful.
◆ EndRendering()
|
pure virtual |
Wait for the current rendering process to complete, after calling BeginRendering().
- Returns
- true if successful.
◆ BeginBatchRendering()
Start the rendering process for an existing static batch.
- Parameters
-
batch The batch to render.
- Returns
- true if successful.
◆ EndBatchRendering()
Finalize the rendering process for an existing static batch.
- Parameters
-
batch The batch to render.
- Returns
- true if successful.
◆ RegisterRenderThread()
Register the actual render (main) thread with the renderer.
- Parameters
-
threadId The thread ID of the main thread.
- Returns
- true if successful.
◆ RegisterLogicThread()
Register the logic processing thread with the renderer.
- Parameters
-
threadId The thread ID of the logic thread.
- Returns
- true if successful.
◆ RegisterLoaderThread()
Register the background loader thread with the renderer.
- Parameters
-
threadId The thread ID of the loader thread.
- Returns
- true if successful.
◆ UnregisterRenderThread()
Unregister a render (main) thread from the renderer.
- Parameters
-
threadId The thread ID of the main thread.
- Returns
- true if successful.
◆ UnregisterLogicThread()
Unregister a logic processing thread from the renderer.
- Parameters
-
threadId The thread ID of the logic thread.
- Returns
- true if successful.
◆ UnregisterLoaderThread()
Unregister a background loader thread from the renderer.
- Parameters
-
threadId The thread ID of the loader thread.
- Returns
- true if successful.
◆ RegisterAutomaticallySuspendableObject()
|
pure virtual |
Register an object for automatic resource suspension.
- Parameters
-
object The object to register.
- Returns
- true if successful.
◆ UnregisterAutomaticallySuspendableObject()
|
pure virtual |
Unregister an object from automatic resource suspension.
- Parameters
-
object The object to unregister.
- Returns
- true if successful.
◆ RegisterManuallySuspendableObject()
|
pure virtual |
Register an object for manual resource suspension.
- Parameters
-
object The object to register.
- Returns
- true if successful.
◆ UnregisterManuallySuspendableObject()
|
pure virtual |
Unregister an object from manual resource suspension.
- Parameters
-
object The object to unregister.
- Returns
- true if successful.
◆ RegisterEmergencySuspendableObject()
|
pure virtual |
Register an object for emergency resource suspension.
- Parameters
-
object The object to register.
- Returns
- true if successful.
◆ UnregisterEmergencySuspendableObject()
|
pure virtual |
Unregister an object from emergency resource suspension.
- Parameters
-
object The object to unregister.
- Returns
- true if successful.
◆ CheckConcurrency()
|
pure virtual |
Verify that the caller is allowed to manipulate an object.
On release builds, or if video API checks are disabled (set via IEngineConfiguration::SetVideoApiChecksEnabled()) this method always returns true. Otherwise, it only returns true when the caller is running on a registered render or loader thread.
- Returns
- true if successful.
◆ InvokeOnRenderThread()
|
pure virtual |
Invoke a call to an object method on a suitable render thread.
If the platform supports video API calls on a thread other than the (single) main render thread, this feature is also enabled in the engine configuration (See IEngineConfiguration::SetAsyncLoadingEnabled()), and the current thread is not the logic thread, this method tries to directly call the given method. Otherwise, and also if the force parameter is set to true, the call is invoked on the main render thread and this method blocks until the call is finished.
- Parameters
-
call A call handle, obtained via Util::CreateMethodCall(). force If true, main thread invocation is forced.
- Returns
- true if successful.
◆ SetCurrentCamera()
|
pure virtual |
Set the current camera affecting subsequent drawables.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
camera The camera to activate.
◆ SetCurrentLayer()
|
pure virtual |
Set the current layer affecting subsequent drawables.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
layer The layer index to set.
◆ SetCurrentTransform()
|
pure virtual |
Set the current world transform affecting subsequent drawables.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
transform The world transform to apply. depthOrder The depth (sorting) order.
◆ SetCurrentMaterial()
|
pure virtual |
Set the current material affecting subsequent drawables.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
material The material to apply.
◆ SetCurrentConstants()
|
pure virtual |
Set the current shader variables affecting subsequent drawables.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
constants The shader variables to apply.
◆ SetCurrentTexture()
|
pure virtual |
Set a single texture at a given unit affecting subsequent drawables.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
texture The texture to apply. unit The texture unit, from 0 to IEnums::NUM_TEXTURE_UNITS-1.
◆ SetCurrentNumberOfTextureUnitsUsed()
|
pure virtual |
Set the number of active texture units affecting subsequent drawables.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
numberOfUnitsUsed The current number of active texture units, from 0 to IEnums::NUM_TEXTURE_UNITS-1.
◆ SetCurrentTextures()
|
pure virtual |
Set multiple texture units affecting subsequent drawables.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
textures An array of textures to apply. numberOfUnitsUsed The actual number of textures to activate, from 0 to IEnums::NUM_TEXTURE_UNITS-1.
◆ SetCurrentLight()
Set a single light source at a given unit affecting subsequent drawables.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
light The light source to apply. unit The light unit, from 0 to IEnums::NUM_LIGHT_UNITS-1.
◆ SetCurrentNumberOfLightUnitsUsed()
|
pure virtual |
Set the number of active light source units affecting subsequent drawables.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
numberOfUnitsUsed The current number of active light units, from 0 to IEnums::NUM_LIGHT_UNITS-1.
◆ SetCurrentLights()
|
pure virtual |
Set multiple light source units affecting subsequent drawables.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
lights An array of light sources to apply. numberOfUnitsUsed The actual number of light sources to activate, from 0 to IEnums::NUM_LIGHT_UNITS-1.
◆ SetCurrentBone()
Set a single bone at a given unit affecting subsequent drawables.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
bone The bone to apply. unit The bone unit, from 0 to IEnums::NUM_BONE_UNITS-1.
◆ SetCurrentNumberOfBoneUnitsUsed()
|
pure virtual |
Set the number of active bone units affecting subsequent drawables.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
numberOfUnitsUsed The current number of active bone units, from 0 to IEnums::NUM_BONE_UNITS-1.
◆ SetCurrentBones()
|
pure virtual |
Set multiple bone units affecting subsequent drawables.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
bones An array of bones to apply. numberOfUnitsUsed The actual number of bones to activate, from 0 to IEnums::NUM_BONE_UNITS-1.
◆ PushObjectForUpdate()
|
pure virtual |
Queue up an object for updating.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
object The object to queue up. localTime The time stamp.
◆ PushObjectForRendering() [1/2]
|
pure virtual |
Queue up a drawable object for rendering.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
vertices The drawable's vertices to queue up. indices The drawable's optional indices to queue up.
◆ PushObjectForRendering() [2/2]
|
pure virtual |
Queue up a drawable object for rendering.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
drawable The drawable to queue up.
◆ PushBatchForRendering()
|
pure virtual |
Queue up a static batch for rendering.
This method must only be called between BeginSubmission() and EndSubmission().
- Parameters
-
batch The batch to queue up.
◆ GetCurrentNumberOfTextureUnitsNeeded()
|
pure virtual |
Get the current number of texture units needed for rendering.
- Returns
- The number of active texture units.
◆ GetCurrentNumberOfLightUnitsNeeded()
|
pure virtual |
Get the current number of light units needed for rendering.
- Returns
- The number of active light units.
◆ GetCurrentNumberOfBoneUnitsNeeded()
|
pure virtual |
Get the current number of bone units needed for rendering.
- Returns
- The number of active bone units.
◆ GetCurrentLightTextureUnit()
|
pure virtual |
Get the currently active shader's light texture unit, if used.
When the currently active shader renders projective lights, this method returns the shader's actually used texture unit for a given light unit. Otherwise, -1 is returned.
- Parameters
-
lightUnit The light unit to check.
- Returns
- The texture unit used. or -1 if not used.
◆ LockStatistics()
|
pure virtual |
Lock the module statistics.
- Returns
- true if successful.
◆ UnlockStatistics()
|
pure virtual |
Unlock the module statistics.
- Returns
- true if successful.
◆ GetAllocatedResourceByteSize()
|
pure virtual |
Query the total number of allocated resource bytes.
Must be called after EndRendering().
- Parameters
-
memoryType The type of memory.
- Returns
- The number of allocated bytes.
◆ GetNumberOfObjectsCreated()
|
pure virtual |
Query the number objects created after the most recent cycle.
Must be called after EndRendering().
- Returns
- The number of created objects.
◆ GetNumberOfObjectsSuspended()
|
pure virtual |
Query the number objects suspended after the most recent cycle.
Must be called after EndRendering().
- Returns
- The number of suspended objects.
◆ GetNumberOfObjectsRendered()
|
pure virtual |
Query the number of most recently rendered objects.
Must be called after EndRendering().
- Returns
- The number of objects rendered.
◆ GetNumberOfBatchesRendered()
|
pure virtual |
Query the number of most recently rendered object batches.
Must be called after EndRendering().
- Returns
- The number of batches rendered.
◆ CollectStatisticsObjects()
|
pure virtual |
Populate a given index with all objects currently present in the renderer.
For this method to successfully return all the present objects, the method IEngineConfiguration::SetExtendedObjectStatisticsEnabled(true) must be called in the app's Configure() method.
- Parameters
-
objects An index to receive all the present objects.
- Returns
- true if successful.
◆ AcquireIndexBufferId()
|
pure virtual |
Acquire a unique integer ID from a given index buffer name.
- Parameters
-
indexBufferName The name of the index buffer.
- Returns
- The unique index buffer ID.
◆ AcquireVertexBufferId()
|
pure virtual |
Acquire a unique integer ID from a given vertex buffer name.
- Parameters
-
vertexBufferName The name of the vertex buffer.
- Returns
- The unique vertex buffer ID.
◆ AcquireConstantBufferId()
|
pure virtual |
Acquire a unique integer ID from a given constant buffer name.
- Parameters
-
constantBufferName The name of the constant buffer.
- Returns
- The unique constant buffer ID.
◆ AcquireUniformId()
Acquire a unique integer ID from a given uniform variable name.
- Parameters
-
uniformName The name of the uniform variable.
- Returns
- The unique uniform variable ID.
◆ AcquireAttributeId()
|
pure virtual |
Acquire a unique integer ID from a given attribute variable name.
- Parameters
-
attributeName The name of the attribute variable.
- Returns
- The unique attribute variable ID.
◆ GetIndexBufferName()
Get the actual name of an index buffer by its unique integer ID.
- Parameters
-
id The unique integer ID.
- Returns
- The index buffer name, or an empty string if not found.
◆ GetVertexBufferName()
Get the actual name of an vertex buffer by its unique integer ID.
- Parameters
-
id The unique integer ID.
- Returns
- The vertex buffer name, or an empty string if not found.
◆ GetConstantBufferName()
Get the actual name of an constant buffer by its unique integer ID.
- Parameters
-
id The unique integer ID.
- Returns
- The constant buffer name, or an empty string if not found.
◆ GetUniformName()
Get the actual name of a uniform variable by its unique integer ID.
- Parameters
-
id The unique integer ID.
- Returns
- The uniform variable name, or an empty string if not found.
◆ GetAttributeName()
Get the actual name of an attribute variable by its unique integer ID.
- Parameters
-
id The unique integer ID.
- Returns
- The attribute variable name, or an empty string if not found.
◆ AcquireConstantBufferSignature()
|
pure virtual |
Acquire a signature for a given constant buffer object.
- Parameters
-
constantBuffer The constant buffer for which to acquire the signature.
- Returns
- The signature.
◆ ReleaseConstantBufferSignature()
|
pure virtual |
Release the signature of a given constant buffer object.
- Parameters
-
constantBuffer The constant buffer for which to release the signature.
- Returns
- true if successful.
◆ AcquireConstantsSignature()
|
pure virtual |
Acquire a signature for a given constant buffer group object.
- Parameters
-
constants The constant buffer group for which to acquire the signature.
- Returns
- The signature.
◆ ReleaseConstantsSignature()
|
pure virtual |
Release the signature of a given constant buffer group object.
- Parameters
-
constants The constant buffer group for which to release the signature.
- Returns
- true if successful.
◆ AcquireIndexBufferSignature()
|
pure virtual |
Acquire a signature for a given index buffer object.
- Parameters
-
indexBuffer The index buffer for which to acquire the signature.
- Returns
- The signature.
◆ ReleaseIndexBufferSignature()
|
pure virtual |
Release the signature of a given index buffer object.
- Parameters
-
indexBuffer The index buffer for which to release the signature.
- Returns
- true if successful.
◆ AcquireIndicesSignature()
|
pure virtual |
Acquire a signature for a given index buffer group object.
- Parameters
-
indices The index buffer group for which to acquire the signature.
- Returns
- The signature.
◆ ReleaseIndicesSignature()
|
pure virtual |
Release the signature of a given index buffer group object.
- Parameters
-
indices The index buffer group for which to release the signature.
- Returns
- true if successful.
◆ AcquireVertexBufferSignature()
|
pure virtual |
Acquire a signature for a given vertex buffer object.
- Parameters
-
vertexBuffer The vertex buffer for which to acquire the signature.
- Returns
- The signature.
◆ ReleaseVertexBufferSignature()
|
pure virtual |
Release the signature of a given vertex buffer object.
- Parameters
-
vertexBuffer The vertex buffer for which to release the signature.
- Returns
- true if successful.
◆ AcquireVerticesSignature()
|
pure virtual |
Acquire a signature for a given vertex buffer group object.
- Parameters
-
vertices The vertex buffer group for which to acquire the signature.
- Returns
- The signature.
◆ ReleaseVerticesSignature()
|
pure virtual |
Release the signature of a given vertex buffer group object.
- Parameters
-
vertices The vertex buffer group for which to release the signature.
- Returns
- true if successful.
◆ IncreaseNumberOfResourceBytesAllocated()
|
pure virtual |
Increase the internal number of allocated resource bytes.
Called by an object whenever it allocates a new memory resource.
- Parameters
-
memoryType The type of memory. numBytes The number of newly allocated bytes.
◆ DecreaseNumberOfResourceBytesAllocated()
|
pure virtual |
Decrease the internal number of allocated resource bytes.
Called by an object whenever it releases a memory resource.
- Parameters
-
memoryType The type of memory. numBytes The number of freed bytes.
◆ IncreaseNumberOfObjectsSuspended()
|
pure virtual |
Increase the internal suspended object count by 1.
Called by an object entering the suspended state.
◆ DecreaseNumberOfObjectsSuspended()
|
pure virtual |
Decrease the internal suspended object count by 1.
Called by an object leaving the suspended state.
◆ ValidateFrameBufferFormat()
|
pure virtual |
Validate a frame buffer format.
- Parameters
-
colorPixelFormat The color buffer pixel format to check. depthBufferFormat The depth buffer format to check. stencilBufferFormat The stencil buffer format to check.
- Returns
- true if the given buffer format combination represents a valid frame buffer format.
◆ TakeScreenshot()
|
pure virtual |
Take a screenshot.
- Parameters
-
outputStream The video stream receiving the current screen shot. windowOrientation The window orientation.
- Returns
- true if successful.
◆ WaitDeviceIdle()
|
pure virtual |
waits until device is idle
- Returns
- true if successful
The documentation for this interface was generated from the following file:
- murl_video_i_renderer.h