HikoGUI
A low latency retained GUI
Loading...
Searching...
No Matches
Public Member Functions | Data Fields
tt::gfx_surface Class Referenceabstract
Inheritance diagram for tt::gfx_surface:
tt::gfx_surface_vulkan tt::gui_window_vulkan_macos

Public Member Functions

 gfx_surface (const gfx_surface &)=delete
 
gfx_surfaceoperator= (const gfx_surface &)=delete
 
 gfx_surface (gfx_surface &&)=delete
 
gfx_surfaceoperator= (gfx_surface &&)=delete
 
virtual void init ()
 
 gfx_surface (gfx_system &system)
 
virtual void set_device (gfx_device *device) noexcept
 
gfx_devicedevice () const noexcept
 
void set_closed () noexcept
 
bool is_closed () const noexcept
 
virtual extent2 update (extent2 minimum_size, extent2 maximum_size) noexcept=0
 Update the surface.
 
virtual std::optional< draw_contextrender_start (aarectangle redraw_rectangle)=0
 
virtual void render_finish (draw_context const &context, color background_color)=0
 

Data Fields

gfx_systemsystem
 
gfx_surface_state state = gfx_surface_state::no_device
 
extent2 size
 The current size of the surface.
 
subpixel_orientation subpixel_orientation = subpixel_orientation::BlueRight
 

Member Function Documentation

◆ set_device()

virtual void tt::gfx_surface::set_device ( gfx_device * device)
virtualnoexcept

Set GPU device to manage this window. Change of the device may be done at runtime.

Parameters
deviceThe device to use for rendering, may be nullptr.

Reimplemented in tt::gfx_surface_vulkan.

◆ update()

virtual extent2 tt::gfx_surface::update ( extent2 minimum_size,
extent2 maximum_size )
pure virtualnoexcept

Update the surface.

This function will check if the graphic pipeline and swapchain needs to be build, rebuild, or torn down.

Parameters
minimum_sizeThe minimum size that the surface is allowed to be.
maximum_sizeThe maximum size that the surface is allowed to be.

Implemented in tt::gfx_surface_vulkan.

Field Documentation

◆ size

extent2 tt::gfx_surface::size

The current size of the surface.

◆ subpixel_orientation

subpixel_orientation tt::gfx_surface::subpixel_orientation = subpixel_orientation::BlueRight

Orientation of the RGB subpixels.


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