Vesper 0.5.1
Vesper is short form for the Latin word for "Bat", as Vesper is designed to be small, lightweight, and easily handle things like particles and flocking behaviors in accordance with the nature of bats. \n It is meant to be a particle simulation, VFX editor, and CAN be used secondarily as a small game engine.
GitHub | Vesper Updates | Creator
Loading...
Searching...
No Matches
Vesper::RendererAPI Class Referenceabstract

An abstract class defining the interface for a rendering API. More...

#include <RendererAPI.h>

Inheritance diagram for Vesper::RendererAPI:
Vesper::OpenGLRendererAPI

Public Types

enum class  API { None = 0 , OpenGL = 1 }
 API. More...

Public Member Functions

virtual ~RendererAPI ()=default
virtual void Init ()=0
 Initializes the rendering API.
virtual void SetViewport (uint32_t x, uint32_t y, uint32_t width, uint32_t height)=0
 Sets the viewport dimensions.
virtual void SetClearColor (const glm::vec4 &color)=0
 Sets the clear color for the rendering API.
virtual void Clear ()=0
 Clears the rendering buffers.
virtual void DrawIndexed (const Ref< VertexArray > &vertexArray, uint32_t indexCount=0)=0
 Draws indexed geometry using the provided vertex array.

Static Public Member Functions

static API GetAPI ()
 Returns the current rendering API.

Static Private Attributes

static API s_API = RendererAPI::API::OpenGL

Detailed Description

An abstract class defining the interface for a rendering API.

Member Enumeration Documentation

◆ API

enum class Vesper::RendererAPI::API
strong

API.

Enumerator
None 
OpenGL 
14 {
15 None = 0,
16 OpenGL = 1,
17 };
@ None
Definition Event.h:25

Constructor & Destructor Documentation

◆ ~RendererAPI()

virtual Vesper::RendererAPI::~RendererAPI ( )
virtualdefault

Member Function Documentation

◆ Clear()

virtual void Vesper::RendererAPI::Clear ( )
pure virtual

Clears the rendering buffers.

Implemented in Vesper::OpenGLRendererAPI.

Referenced by Vesper::RenderCommand::Clear().

◆ DrawIndexed()

virtual void Vesper::RendererAPI::DrawIndexed ( const Ref< VertexArray > & vertexArray,
uint32_t indexCount = 0 )
pure virtual

Draws indexed geometry using the provided vertex array.

Implemented in Vesper::OpenGLRendererAPI.

◆ GetAPI()

API Vesper::RendererAPI::GetAPI ( )
inlinestatic

Returns the current rendering API.

34{ return s_API; }
static API s_API
Definition RendererAPI.h:36

References s_API.

Referenced by Vesper::Renderer::GetAPI().

◆ Init()

virtual void Vesper::RendererAPI::Init ( )
pure virtual

Initializes the rendering API.

Implemented in Vesper::OpenGLRendererAPI.

Referenced by Vesper::RenderCommand::Init().

◆ SetClearColor()

virtual void Vesper::RendererAPI::SetClearColor ( const glm::vec4 & color)
pure virtual

Sets the clear color for the rendering API.

Implemented in Vesper::OpenGLRendererAPI.

◆ SetViewport()

virtual void Vesper::RendererAPI::SetViewport ( uint32_t x,
uint32_t y,
uint32_t width,
uint32_t height )
pure virtual

Sets the viewport dimensions.

Implemented in Vesper::OpenGLRendererAPI.

Referenced by Vesper::RenderCommand::SetViewport().

Member Data Documentation

◆ s_API

RendererAPI::API Vesper::RendererAPI::s_API = RendererAPI::API::OpenGL
staticprivate

Referenced by GetAPI().


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