Kodi Documentation 22.0
Kodi is an open source media player and entertainment hub.
Loading...
Searching...
No Matches
KODI::WINDOWING::GBM::CGBMUtils::CGBMDevice Class Reference

A wrapper for gbm_device to allow OOP and RAII. More...

#include <GBMUtils.h>

Classes

class  CGBMSurface
 A wrapper for gbm_surface to allow OOP and RAII. More...
 

Public Member Functions

 CGBMDevice (const CGBMDevice &)=delete
 
CGBMDeviceoperator= (const CGBMDevice &)=delete
 
 CGBMDevice (gbm_device *device)
 
 ~CGBMDevice ()=default
 
bool CreateSurface (int width, int height, uint32_t format, const uint64_t *modifiers, const int modifiers_count)
 Create a gbm surface.
 
gbm_device * Get () const
 Get the underlying gbm_device.
 
CGBMDevice::CGBMSurfaceGetSurface () const
 Get the CGBMSurface object.
 

Detailed Description

A wrapper for gbm_device to allow OOP and RAII.

Constructor & Destructor Documentation

◆ CGBMDevice() [1/2]

KODI::WINDOWING::GBM::CGBMUtils::CGBMDevice::CGBMDevice ( const CGBMDevice & )
delete

◆ CGBMDevice() [2/2]

CGBMUtils::CGBMDevice::CGBMDevice ( gbm_device * device)
explicit

◆ ~CGBMDevice()

KODI::WINDOWING::GBM::CGBMUtils::CGBMDevice::~CGBMDevice ( )
default

Member Function Documentation

◆ CreateSurface()

bool CGBMUtils::CGBMDevice::CreateSurface ( int width,
int height,
uint32_t format,
const uint64_t * modifiers,
const int modifiers_count )

Create a gbm surface.

Parameters
widthThe width to use for the surface
heightThe height to use for the surface
formatThe format to use for the surface
modifiersThe modifiers to use for the surface
modifiers_countThe amount of modifiers in the modifiers param
Returns
true The surface creation succeeded
false The surface creation failed

◆ Get()

gbm_device * KODI::WINDOWING::GBM::CGBMUtils::CGBMDevice::Get ( ) const
inline

Get the underlying gbm_device.

Returns
gbm_device* A pointer to the underlying gbm_device

◆ GetSurface()

CGBMDevice::CGBMSurface & KODI::WINDOWING::GBM::CGBMUtils::CGBMDevice::GetSurface ( ) const
inline

Get the CGBMSurface object.

Returns
CGBMSurface* A pointer to the CGBMSurface object

◆ operator=()

CGBMDevice & KODI::WINDOWING::GBM::CGBMUtils::CGBMDevice::operator= ( const CGBMDevice & )
delete

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