|
Aeon Engine c550894
AeonGames Open Source Game Engine
|
Abstract base class for rendering backends. More...
#include <aeongames/Renderer.hpp>


Public Member Functions | |
| virtual DLL | ~Renderer ()=0 |
| Virtual destructor. | |
Renderer specific resource functions | |
| virtual void | LoadMesh (const Mesh &aMesh)=0 |
| Loads mesh data into GPU memory. | |
| virtual void | UnloadMesh (const Mesh &aMesh)=0 |
| Unloads mesh data from GPU memory. | |
| virtual void | LoadPipeline (const Pipeline &aPipeline)=0 |
| Loads a rendering pipeline (shaders and state) into the renderer. | |
| virtual void | UnloadPipeline (const Pipeline &aPipeline)=0 |
| Unloads a rendering pipeline from the renderer. | |
| virtual void | LoadMaterial (const Material &aMaterial)=0 |
| Loads material data into the renderer. | |
| virtual void | UnloadMaterial (const Material &aMaterial)=0 |
| Unloads material data from the renderer. | |
| virtual void | LoadTexture (const Texture &aTexture)=0 |
| Loads a texture into GPU memory. | |
| virtual void | UnloadTexture (const Texture &aTexture)=0 |
| Unloads a texture from GPU memory. | |
Window surface related functions | |
| virtual void | AttachWindow (void *aWindowId)=0 |
| Attach a Window as a rendering surface. | |
| virtual void | DetachWindow (void *aWindowId)=0 |
| Detach a Window as a rendering surface. | |
| virtual void | SetProjectionMatrix (void *aWindowId, const Matrix4x4 &aMatrix)=0 |
| Sets the projection matrix for a specific window surface. | |
| virtual void | SetViewMatrix (void *aWindowId, const Matrix4x4 &aMatrix)=0 |
| Sets the view matrix for a specific window surface. | |
| virtual void | SetClearColor (void *aWindowId, float R, float G, float B, float A)=0 |
| Sets the color to be used to clear the window background. | |
| virtual void | ResizeViewport (void *aWindowId, int32_t aX, int32_t aY, uint32_t aWidth, uint32_t aHeight)=0 |
| Resizes the specific window surface's viewport. | |
| virtual void | BeginRender (void *aWindowId)=0 |
| Begins a render pass for the given window surface. | |
| virtual void | EndRender (void *aWindowId)=0 |
| Ends the current render pass for the given window surface. | |
| virtual void | Render (void *aWindowId, const Matrix4x4 &aModelMatrix, const Mesh &aMesh, const Pipeline &aPipeline, const Material *aMaterial=nullptr, const BufferAccessor *aSkeleton=nullptr, Topology aTopology=Topology::TRIANGLE_LIST, uint32_t aVertexStart=0, uint32_t aVertexCount=0xffffffff, uint32_t aInstanceCount=1, uint32_t aFirstInstance=0) const =0 |
| Issues a draw call for a mesh with the given pipeline and optional material. | |
| virtual const Frustum & | GetFrustum (void *aWindowId) const =0 |
| Returns the view frustum for the given window surface. | |
| virtual BufferAccessor | AllocateSingleFrameUniformMemory (void *aWindowId, size_t aSize)=0 |
| Allocates uniform buffer memory that is valid for a single frame. | |
Abstract base class for rendering backends.
Defines the interface for loading and unloading GPU resources, managing window surfaces, and issuing draw calls. Concrete implementations provide API-specific logic (e.g., Vulkan, OpenGL).
Definition at line 43 of file Renderer.hpp.
|
pure virtual |
Allocates uniform buffer memory that is valid for a single frame.
| aWindowId | Platform dependent window handle. |
| aSize | Size in bytes of the requested allocation. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Attach a Window as a rendering surface.
| aWindowId | Platform depended window handle. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Begins a render pass for the given window surface.
| aWindowId | Platform dependent window handle. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Detach a Window as a rendering surface.
| aWindowId | Platform depended window handle. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Ends the current render pass for the given window surface.
| aWindowId | Platform dependent window handle. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Returns the view frustum for the given window surface.
| aWindowId | Platform dependent window handle. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Loads material data into the renderer.
| aMaterial | The material to load. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Loads mesh data into GPU memory.
| aMesh | The mesh to load. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Loads a rendering pipeline (shaders and state) into the renderer.
| aPipeline | The pipeline to load. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Loads a texture into GPU memory.
| aTexture | The texture to load. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Issues a draw call for a mesh with the given pipeline and optional material.
| aWindowId | Platform dependent window handle. |
| aModelMatrix | Model transformation matrix. |
| aMesh | Mesh to render. |
| aPipeline | Pipeline (shaders/state) to use. |
| aMaterial | Optional material to bind. |
| aSkeleton | Optional skeleton buffer for skinned meshes. |
| aTopology | Primitive topology (default: TRIANGLE_LIST). |
| aVertexStart | First vertex index. |
| aVertexCount | Number of vertices to draw (default: all). |
| aInstanceCount | Number of instances to draw. |
| aFirstInstance | Index of the first instance. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Resizes the specific window surface's viewport.
| aWindowId | Platform dependent window handle. |
| aX | X coordinate of the viewport. |
| aY | Y coordinate of the viewport. |
| aWidth | Width of the viewport. |
| aHeight | Height of the viewport. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Sets the color to be used to clear the window background.
| aWindowId | Platform depended window handle. |
| R | Red component of the clear color. |
| G | Green component of the clear color. |
| B | Blue component of the clear color. |
| A | Alpha component of the clear color. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Sets the projection matrix for a specific window surface.
| aWindowId | Platform depended window handle. |
| aMatrix | The projection matrix. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Sets the view matrix for a specific window surface.
| aWindowId | Platform depended window handle. |
| aMatrix | The view matrix. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Unloads material data from the renderer.
| aMaterial | The material to unload. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Unloads mesh data from GPU memory.
| aMesh | The mesh to unload. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Unloads a rendering pipeline from the renderer.
| aPipeline | The pipeline to unload. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.
|
pure virtual |
Unloads a texture from GPU memory.
| aTexture | The texture to unload. |
Implemented in AeonGames::OpenGLRenderer, and AeonGames::VulkanRenderer.