Berserk
Public Member Functions | Protected Member Functions | List of all members
RHIResource Class Reference

Base class for RHI resource. More...

#include <RHIResource.hpp>

Inheritance diagram for RHIResource:
Inheritance graph
[legend]
Collaboration diagram for RHIResource:
Collaboration graph
[legend]

Public Member Functions

BRK_API ~RHIResource () override=default
 
- Public Member Functions inherited from RefCnt
virtual ~RefCnt ()
 
bool IsUnique () const
 
std::int32_t GetRefs () const
 
std::int32_t AddRef () const
 
std::int32_t RelRef () const
 

Protected Member Functions

void Destroy () const override
 

Detailed Description

Base class for RHI resource.

Base class for any RHI resource, created by driver and exposed to the user. Uses automated reference counting, required for safe resource life-time tracking and passing among several system threads.

Resource utilise rhi thread command buffer, so it creation/destruction is deferred and executed only on rhi thread as a command.

Constructor & Destructor Documentation

◆ ~RHIResource()

BRK_API RHIResource::~RHIResource ( )
overridedefault

Member Function Documentation

◆ Destroy()

BRK_NS_BEGIN void RHIResource::Destroy ( ) const
overrideprotectedvirtual

Internal: Destroy resource on rhi thread

Reimplemented from RefCnt.


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