cae  0.0.0
Cross-API graphics engine
Loading...
Searching...
No Matches
cae::VULKN Class Referencefinal

Class for the Vulkan plugin. More...

#include <VULKN.hpp>

+ Inheritance diagram for cae::VULKN:
+ Collaboration diagram for cae::VULKN:

Public Member Functions

 VULKN ()=default
 
 ~VULKN () override=default
 
 VULKN (const VULKN &)=delete
 
VULKNoperator= (const VULKN &)=delete
 
 VULKN (VULKN &&)=delete
 
VULKNoperator= (VULKN &&)=delete
 
std::string getName () const override
 Get the name of the plugin.
 
utl::PluginType getType () const override
 Get the type of the plugin.
 
utl::PluginPlatform getPlatform () const override
 Get the handled platform of the plugin.
 
void setVSyncEnabled (bool enabled) override
 Enable or disable VSync.
 
void setClearColor (const Color &color) override
 Set the clear color.
 
bool isVSyncEnabled () const override
 Check if VSync is enabled.
 
void initialize (const NativeWindowHandle &nativeWindowHandle, const Color &clearColor) override
 Initialize the renderer with a native window handle and clear color.
 
void createPipeline (const ShaderID &id, const ShaderIRModule &vertex, const ShaderIRModule &fragment) override
 Create a rendering pipeline with vertex and fragment shaders.
 
void draw (const WindowSize &windowSize, const ShaderID &shaderId, glm::mat4 mvp) override
 Draw the scene using the specified shader and window size.
 
void createMesh (const std::vector< float > &vertices) override
 Create a mesh with the given vertex data.
 
- Public Member Functions inherited from cae::ARenderer
 ~ARenderer () override=default
 
- Public Member Functions inherited from cae::IRenderer
 ~IRenderer () override=default
 
- Public Member Functions inherited from utl::IPlugin
virtual ~IPlugin ()=default
 

Detailed Description

Class for the Vulkan plugin.

Definition at line 21 of file VULKN.hpp.

Constructor & Destructor Documentation

◆ VULKN() [1/3]

cae::VULKN::VULKN ( )
default

◆ ~VULKN()

cae::VULKN::~VULKN ( )
overridedefault

◆ VULKN() [2/3]

cae::VULKN::VULKN ( const VULKN & )
delete

◆ VULKN() [3/3]

cae::VULKN::VULKN ( VULKN && )
delete

Member Function Documentation

◆ createMesh()

void cae::VULKN::createMesh ( const std::vector< float > & vertices)
inlineoverridevirtual

Create a mesh with the given vertex data.

Parameters
verticesVertex data to create the mesh

Implements cae::IRenderer.

Definition at line 48 of file VULKN.hpp.

◆ createPipeline()

void cae::VULKN::createPipeline ( const ShaderID & id,
const ShaderIRModule & vertex,
const ShaderIRModule & fragment )
inlineoverridevirtual

Create a rendering pipeline with vertex and fragment shaders.

Parameters
idShader ID
vertexVertex shader IR module
fragmentFragment shader IR module

Implements cae::IRenderer.

Definition at line 43 of file VULKN.hpp.

◆ draw()

void cae::VULKN::draw ( const WindowSize & windowSize,
const ShaderID & shaderId,
glm::mat4 mvp )
inlineoverridevirtual

Draw the scene using the specified shader and window size.

Parameters
windowSizeCurrent window size
shaderIdShader ID to use for drawing
mvpModel-View-Projection matrix

Implements cae::IRenderer.

Definition at line 47 of file VULKN.hpp.

◆ getName()

std::string cae::VULKN::getName ( ) const
inlinenodiscardoverridevirtual

Get the name of the plugin.

Returns
The name of the plugin

Implements utl::IPlugin.

Definition at line 33 of file VULKN.hpp.

◆ getPlatform()

utl::PluginPlatform cae::VULKN::getPlatform ( ) const
inlinenodiscardoverridevirtual

Get the handled platform of the plugin.

Returns
The handled platform of the plugin

Implements utl::IPlugin.

Definition at line 35 of file VULKN.hpp.

References utl::ALL.

◆ getType()

utl::PluginType cae::VULKN::getType ( ) const
inlinenodiscardoverridevirtual

Get the type of the plugin.

Returns
The type of the plugin

Implements utl::IPlugin.

Definition at line 34 of file VULKN.hpp.

References utl::RENDERER.

◆ initialize()

void cae::VULKN::initialize ( const NativeWindowHandle & nativeWindowHandle,
const Color & clearColor )
inlineoverridevirtual

Initialize the renderer with a native window handle and clear color.

Parameters
nativeWindowHandleNative window handle
clearColorClear color (default: white)

Implements cae::IRenderer.

Definition at line 42 of file VULKN.hpp.

◆ isVSyncEnabled()

bool cae::VULKN::isVSyncEnabled ( ) const
inlinenodiscardoverridevirtual

Check if VSync is enabled.

Returns
Whether VSync is enabled

Implements cae::IRenderer.

Definition at line 40 of file VULKN.hpp.

◆ operator=() [1/2]

VULKN & cae::VULKN::operator= ( const VULKN & )
delete

◆ operator=() [2/2]

VULKN & cae::VULKN::operator= ( VULKN && )
delete

◆ setClearColor()

void cae::VULKN::setClearColor ( const Color & color)
inlineoverridevirtual

Set the clear color.

Parameters
colorClear color to set

Implements cae::IRenderer.

Definition at line 38 of file VULKN.hpp.

◆ setVSyncEnabled()

void cae::VULKN::setVSyncEnabled ( bool enabled)
inlineoverridevirtual

Enable or disable VSync.

Parameters
enabledWhether VSync is enabled

Implements cae::IRenderer.

Definition at line 37 of file VULKN.hpp.


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