libguac 1.6.0
 
Loading...
Searching...
No Matches
display.h File Reference

Provides an abstract display implementation (guac_display), which handles optimization automatically. More...

Go to the source code of this file.

Data Structures

struct  guac_display_layer_cairo_context
 The current Cairo drawing context of a guac_display_layer, including a Cairo image surface wrapping the underlying drawing buffer of the guac_display_layer. More...
 
struct  guac_display_layer_raw_context
 The current raw drawing context of a guac_display_layer, including the underlying drawing buffer of the guac_display_layer and memory layout information. More...
 

Macros

#define GUAC_DISPLAY_LAYER_RAW_BUFFER(context, rect)
 Returns the memory address of the given rectangle within the image buffer of the given guac_display_layer_raw_context, where the upper-left corner of the given buffer is (0, 0).
 

Functions

guac_displayguac_display_alloc (guac_client *client)
 Allocates a new guac_display representing the remote display shared by all connected users of the given guac_client.
 
void guac_display_free (guac_display *display)
 Frees all resources associated with the given guac_display.
 
void guac_display_dup (guac_display *display, guac_socket *socket)
 Replicates the current remote display state across the given socket.
 
void guac_display_notify_user_left (guac_display *display, guac_user *user)
 Notifies the given guac_display that a specific user has left the connection and need no longer be considered for future updates/events.
 
void guac_display_notify_user_moved_mouse (guac_display *display, guac_user *user, int x, int y, int mask)
 Notifies the given guac_display that a specific user has changed the state of the mouse, such as through moving the pointer or pressing/releasing a mouse button.
 
void guac_display_end_frame (guac_display *display)
 Ends the current frame, where the number of input frames that were considered in creating this frame is either unknown or inapplicable, allowing the guac_display to complete sending the frame to connected clients.
 
void guac_display_end_mouse_frame (guac_display *display)
 Ends the current frame only if the user-visible changes consist purely of updates to the mouse cursor position or icon.
 
void guac_display_end_multiple_frames (guac_display *display, int frames)
 Ends the current frame, where that frame may combine or otherwise represent the changes of an arbitrary number of input frames, allowing the guac_display to complete sending the frame to connected clients.
 
guac_display_layerguac_display_default_layer (guac_display *display)
 Returns the default layer for the given display.
 
guac_display_layerguac_display_alloc_layer (guac_display *display, int opaque)
 Allocates a new layer for the given display.
 
guac_display_layerguac_display_alloc_buffer (guac_display *display, int opaque)
 Allocates a new buffer (offscreen layer) for the given display.
 
void guac_display_free_layer (guac_display_layer *display_layer)
 Frees the given layer, releasing any underlying memory.
 
guac_display_layerguac_display_cursor (guac_display *display)
 Returns a layer representing the current mouse cursor icon.
 
void guac_display_set_cursor (guac_display *display, guac_display_cursor_type cursor_type)
 Sets the remote mouse cursor to the given built-in cursor icon.
 
void guac_display_set_cursor_hotspot (guac_display *display, int x, int y)
 Sets the hotspot location of the remote mouse cursor.
 
void guac_display_layer_get_bounds (guac_display_layer *layer, guac_rect *bounds)
 Stores the current bounding rectangle of the given layer in the given guac_rect.
 
void guac_display_layer_move (guac_display_layer *layer, int x, int y)
 Moves the given layer to the given coordinates.
 
void guac_display_layer_stack (guac_display_layer *layer, int z)
 Sets the stacking position of the given layer relative to all other sibling layers (direct children of the same parent).
 
void guac_display_layer_set_parent (guac_display_layer *layer, const guac_display_layer *parent)
 Reparents the given layer such that it is a direct child of the given parent layer.
 
void guac_display_layer_set_opacity (guac_display_layer *layer, int opacity)
 Sets the opacity of the given layer.
 
void guac_display_layer_set_lossless (guac_display_layer *layer, int lossless)
 Sets whether graphical changes to the given layer are allowed to be represented, updated, or sent using methods that can cause some loss of information, such as JPEG or WebP compression.
 
void guac_display_layer_set_multitouch (guac_display_layer *layer, int touches)
 Sets the level of multitouch support available for the given layer.
 
void guac_display_layer_resize (guac_display_layer *layer, int width, int height)
 Resizes the given layer to the given dimensions.
 
guac_display_layer_raw_contextguac_display_layer_open_raw (guac_display_layer *layer)
 Begins a drawing operation for the given layer, returning a context that can be used to draw directly to the raw image buffer containing the layer's current pending frame.
 
void guac_display_layer_close_raw (guac_display_layer *layer, guac_display_layer_raw_context *context)
 Ends a drawing operation that was started with a call to guac_display_layer_open_raw() and relinquishes exclusive access to the display.
 
void guac_display_layer_raw_context_set (guac_display_layer_raw_context *context, const guac_rect *dst, uint32_t color)
 Fills a rectangle of image data within the given raw context with a single color.
 
void guac_display_layer_raw_context_put (guac_display_layer_raw_context *context, const guac_rect *dst, const void *restrict buffer, size_t stride)
 Copies a rectangle of image data from the given buffer to the given raw context, replacing all pixel values within the given rectangle.
 
guac_display_layer_cairo_contextguac_display_layer_open_cairo (guac_display_layer *layer)
 Begins a drawing operation for the given layer, returning a context that can be used to draw to a Cairo surface containing the layer's current pending frame.
 
void guac_display_layer_close_cairo (guac_display_layer *layer, guac_display_layer_cairo_context *context)
 Ends a drawing operation that was started with a call to guac_display_layer_open_cairo() and relinquishes exclusive access to the display.
 
guac_display_render_threadguac_display_render_thread_create (guac_display *display)
 Creates and starts a rendering thread for the given guac_display.
 
void guac_display_render_thread_notify_modified (guac_display_render_thread *render_thread)
 Notifies the given render thread that the graphical state of the display has been modified in some visible way.
 
void guac_display_render_thread_notify_frame (guac_display_render_thread *render_thread)
 Notifies the given render thread that a frame boundary has been reached.
 
void guac_display_render_thread_destroy (guac_display_render_thread *render_thread)
 Safely stops and frees all resources associated with the given render thread.
 

Detailed Description

Provides an abstract display implementation (guac_display), which handles optimization automatically.