SpiceClientGLib.DisplayChannel¶
- Subclasses:
None
Methods¶
- Inherited:
- Structs:
|
|
|
|
|
|
|
|
|
|
|
|
|
Virtual Methods¶
- Inherited:
Properties¶
- Inherited:
Name |
Type |
Flags |
Short Description |
---|---|---|---|
r |
GL scanout |
||
r |
The primary surface height |
||
r |
The monitors configuration |
||
r |
The current maximum number of monitors |
||
r |
The primary surface width |
Signals¶
- Inherited:
Name |
Short Description |
---|---|
The |
|
The |
|
The |
|
The |
|
The |
|
The |
|
|
Fields¶
- Inherited:
Name |
Type |
Access |
Description |
---|---|---|---|
parent |
r |
Class Details¶
- class SpiceClientGLib.DisplayChannel(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
The
SpiceClientGLib.DisplayChannel
struct is opaque and should not be accessed directly.- display_change_preferred_compression(compression)¶
- Parameters:
compression (
int
) – a #SpiceImageCompression
Tells the spice server to change the preferred image compression for the self.
New in version 0.31.
Deprecated since version 0.35: use
SpiceClientGLib.DisplayChannel.display_channel_change_preferred_compression
() instead.
- display_change_preferred_video_codec_type(codec_type)¶
- Parameters:
codec_type (
int
) – a #SpiceVideoCodecType
Tells the spice server to change the preferred video codec type for streaming in self. Application can set only one preferred video codec per display channel.
New in version 0.34.
Deprecated since version 0.35: use
SpiceClientGLib.DisplayChannel.display_channel_change_preferred_video_codec_type
() instead.
- display_channel_change_preferred_compression(compression)¶
- Parameters:
compression (
int
) – a #SpiceImageCompression
Tells the spice server to change the preferred image compression for the self.
New in version 0.35.
- display_channel_change_preferred_video_codec_type(codec_type)¶
- Parameters:
codec_type (
int
) – a #SpiceVideoCodecType
Tells the spice server to change the preferred video codec type for streaming in self. Application can set only one preferred video codec per display channel.
New in version 0.35.
Deprecated since version 0.38: use
SpiceClientGLib.DisplayChannel.display_channel_change_preferred_video_codec_types
() instead.
- display_channel_change_preferred_video_codec_types(codecs)¶
- Parameters:
codecs ([
int
]) – an array of ncodecs #SpiceVideoCodecType types- Raises:
- Returns:
True
if the preferred codec list was successfully changed, andFalse
otherwise.- Return type:
Tells the spice server the ordered preferred video codec types to use for streaming in self.
New in version 0.38.
- display_channel_get_primary(surface_id, primary)¶
- Parameters:
surface_id (
int
) – a surface idprimary (
SpiceClientGLib.DisplayPrimary
) – aSpiceClientGLib.DisplayPrimary
- Returns:
True
if the primary surface was found and its details collected in primary.- Return type:
Retrieve primary display surface surface_id.
New in version 0.35.
- display_get_primary(surface_id, primary)¶
- Parameters:
surface_id (
int
) – a surface idprimary (
SpiceClientGLib.DisplayPrimary
) – aSpiceClientGLib.DisplayPrimary
- Returns:
True
if the primary surface was found and its details collected in primary.- Return type:
Retrieve primary display surface surface_id.
Deprecated since version 0.35: use
SpiceClientGLib.DisplayChannel.display_channel_get_primary
() instead.
- get_gl_scanout()¶
- Returns:
the current GL scanout, or
None
if none or not valid- Return type:
Retrieves the GL scanout if available
New in version 0.35.
- gl_draw_done()¶
After a
SpiceClientGLib.DisplayChannel
::gl-draw
is emitted, the client should draw the current display with the current GL scanout, and must release the GL resource with a call toSpiceClientGLib.display_gl_draw_done
() (failing to do so for each gl-draw may result in a frozen display).New in version 0.35.
Signal Details¶
- SpiceClientGLib.DisplayChannel.signals.display_invalidate(display_channel, x, y, width, height)¶
- Signal Name:
display-invalidate
- Flags:
- Parameters:
display_channel (
SpiceClientGLib.DisplayChannel
) – The object which received the signalx (
int
) – x positiony (
int
) – y positionwidth (
int
) – widthheight (
int
) – height
The
SpiceClientGLib.DisplayChannel
::display-invalidate
signal is emitted when the rectangular region x/y/w/h of the primary buffer is updated.
- SpiceClientGLib.DisplayChannel.signals.display_mark(display_channel, mark)¶
- Signal Name:
display-mark
- Flags:
- Parameters:
display_channel (
SpiceClientGLib.DisplayChannel
) – The object which received the signal
The
SpiceClientGLib.DisplayChannel
::display-mark
signal is emitted when the %RED_DISPLAY_MARK command is received, and the display should be exposed.
- SpiceClientGLib.DisplayChannel.signals.display_primary_create(display_channel, format, width, height, stride, shmid, imgdata)¶
- Signal Name:
display-primary-create
- Flags:
- Parameters:
display_channel (
SpiceClientGLib.DisplayChannel
) – The object which received the signalformat (
int
) – %SPICE_SURFACE_FMT_32_xRGB or %SPICE_SURFACE_FMT_16_555;width (
int
) – width resolutionheight (
int
) – height resolutionstride (
int
) – the buffer stride (“width” padding)shmid (
int
) – identifier of the shared memory segment associated with the imgdata, or -1 if not shm
The
SpiceClientGLib.DisplayChannel
::display-primary-create
signal provides main display buffer data.
- SpiceClientGLib.DisplayChannel.signals.display_primary_destroy(display_channel)¶
- Signal Name:
display-primary-destroy
- Flags:
- Parameters:
display_channel (
SpiceClientGLib.DisplayChannel
) – The object which received the signal
The
SpiceClientGLib.DisplayChannel
::display-primary-destroy
signal is emitted when the primary surface is freed and should not be accessed anymore.
- SpiceClientGLib.DisplayChannel.signals.gl_draw(display_channel, x, y, width, height)¶
- Signal Name:
gl-draw
- Flags:
- Parameters:
display_channel (
SpiceClientGLib.DisplayChannel
) – The object which received the signalx (
int
) – x positiony (
int
) – y positionwidth (
int
) – widthheight (
int
) – height
The
SpiceClientGLib.DisplayChannel
::gl-draw
signal is emitted when the rectangular region x/y/w/h of the GL scanout is updated and must be drawn. When the draw is finished, you must callSpiceClientGLib.display_gl_draw_done
() in order to release the GL resources.New in version 0.31.
- SpiceClientGLib.DisplayChannel.signals.gst_video_overlay(display_channel, pipeline)¶
- Signal Name:
gst-video-overlay
- Flags:
- Parameters:
display_channel (
SpiceClientGLib.DisplayChannel
) – The object which received the signalpipeline (
Gst.Pipeline
) – pointer to GStreamer’s pipeline
- Returns:
True
if the overlay is being set- Return type:
The
SpiceClientGLib.DisplayChannel
::gst-video-overlay
signal is emitted when pipeline is ready and can be passed to widget to register GStreamer overlay interface and other GStreamer callbacks. If the pipeline pointer isNone
, the drawing area of the native renderer is set visible.New in version 0.36.
- SpiceClientGLib.DisplayChannel.signals.streaming_mode(display_channel, streaming_mode)¶
- Signal Name:
streaming-mode
- Flags:
- Parameters:
display_channel (
SpiceClientGLib.DisplayChannel
) – The object which received the signal
- Returns:
handle for the display window if possible
The
SpiceClientGLib.DisplayChannel
::streaming-mode
signal is emitted when spice server is working in streaming mode.- Return type:
New in version 0.35.
Deprecated since version 0.36: use
SpiceClientGLib.DisplayChannel
::gst-video-overlay
instead
Property Details¶
- SpiceClientGLib.DisplayChannel.props.gl_scanout¶
- Name:
gl-scanout
- Type:
- Default Value:
- Flags:
The last
SpiceClientGLib.GlScanout
received.New in version 0.31.
- SpiceClientGLib.DisplayChannel.props.height¶
-
The primary surface height
- SpiceClientGLib.DisplayChannel.props.monitors¶
- Name:
monitors
- Type:
- Default Value:
- Flags:
Current monitors configuration.
New in version 0.13.
- SpiceClientGLib.DisplayChannel.props.monitors_max¶
-
The maximum number of monitors the server or guest supports. May change during client lifetime, for instance guest may reboot or dynamically adjust this.
New in version 0.13.