Class representing an EGL display connection.
More...
#include <kanzi/core.ui/platform/context_api/egl/egl_display.hpp>
|
static KZ_NO_DISCARD::EGLNativeDisplayType | getDefaultDisplay () noexcept |
| Gets default native display handle. More...
|
|
static KZ_NO_DISCARD::EGLDisplay | getDisplay (::EGLNativeDisplayType nativeDisplay) noexcept |
| Gets EGL display handle from native display handle. More...
|
|
static KZ_NO_DISCARD::EGLDisplay | getNoDisplay () noexcept |
| Gets an no display EGL handle. More...
|
|
Class representing an EGL display connection.
A display connection may either be open or closed.
kanzi::EGLDisplay::EGLDisplay |
( |
| ) |
|
|
explicit |
Default constructor, creates a no display.
- Postcondition
- egl::getError() returns EGL_SUCCESS.
kanzi::EGLDisplay::EGLDisplay |
( |
::EGLDisplay |
eglDisplay | ) |
|
|
explicit |
Constructor.
- Parameters
-
eglDisplay | EGL display handle. |
- Postcondition
- egl::getError() returns EGL_SUCCESS.
static KZ_NO_DISCARD ::EGLNativeDisplayType kanzi::EGLDisplay::getDefaultDisplay |
( |
| ) |
|
|
staticnoexcept |
Gets default native display handle.
- Returns
- Default native display handle.
Gets EGL display handle from native display handle.
- Returns
- Display handle.
Gets an no display EGL handle.
- Returns
- EGL display handle with a value representing no display.
Opens the EGL display connection.
This should be the first function called on a new display object. Use terminate() to close the open connection before destructing the object.
- Returns
- EGL version information.
bool kanzi::EGLDisplay::terminate |
( |
| ) |
|
Closes the EGL display connection.
- Returns
- True on success, false on failure.
bool kanzi::EGLDisplay::makeCurrent |
( |
const ::EGLSurface |
eglDrawSurface, |
|
|
const ::EGLSurface |
eglReadSurface, |
|
|
const ::EGLContext |
eglContext |
|
) |
| const |
|
noexcept |
Binds surfaces to a context and the current thread.
- Parameters
-
eglDrawSurface | Surface bound as draw destination. |
eglReadSurface | Surface bound as read source. |
eglContext | Context to bind to. |
- Returns
- True on success, false on failure.
bool kanzi::EGLDisplay::swapInterval |
( |
int |
interval | ) |
|
Sets minimum number of displayed video frames before a buffer swap.
- Parameters
-
interval | Minimum number of video frames to wait before buffer swap. |
- Returns
- True on success, false on failure.
EGLImage kanzi::EGLDisplay::createImage |
( |
const EGLContext & |
eglContext, |
|
|
EGLenum |
target, |
|
|
void * |
data, |
|
|
const EGLint * |
attributes |
|
) |
| |
|
noexcept |
Creates a new EGL image.
Use destroyImage() to destroy the created image.
- Parameters
-
eglContext | Context for which the image is created. |
target | The image source type. |
data | The image source. |
attributes | The image attributes |
- Returns
- A new EGL image. The value is a no image on failure.
bool kanzi::EGLDisplay::destroyImage |
( |
EGLImage |
image | ) |
|
|
noexcept |
Destroys an EGL image.
- Parameters
-
image | EGL image to destroy. |
- Returns
- True on success, false on failure.
Gets EGL config handle from a graphics format ID.
- Parameters
-
graphicsFormatID | Graphics format ID to use. |
- Returns
- EGL config handle corresponding to the graphics format ID. The value is a no config if there was no match.
Gets EGL config handle using eglChooseConfig and attribute list.
- Parameters
-
attribs | List of EGL attributes used to choose the config. The list must be terminated with EGL_NONE. |
- Returns
- EGL config handle returned by kzsEGLChooseConfig. The value is a no config if there was no match.
Gets the number of EGL configs available.
- Returns
- The number of EGL configs available.
Gets all EGL configs.
- Returns
- A vector of EGL config handles.
KZ_NO_DISCARD bool kanzi::EGLDisplay::getConfigAttributeValue |
( |
::EGLConfig |
eglConfig, |
|
|
EGLint |
attribute, |
|
|
EGLint & |
attributeValue |
|
) |
| const |
|
noexcept |
Gets the value of an EGL config attribute.
- Parameters
-
eglConfig | EGL config to query. |
attribute | The attribute to query. |
attributeValue | Stores the value of the attribute. |
- Returns
- True on success, false on failure.
Gets EGL display handle.
- Returns
- EGL display handle.
The documentation for this class was generated from the following file: