Geometry API - Amazon DCV
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

Geometry API

SetCursorPoint

Note

This API is supported by, and only available on, Amazon DCV Windows clients only.

Move the local cursor pointer to a specific position over a streaming area of the Amazon DCV client. Extensions issue a SetCursorPointRequest and receive a synchronous SetCursorPointResponse.

Sequence diagram showing SetCursorPointRequest and SetCursorPointResponse between Extension Client and DCV Client.

Helper structures:

Point + int32 x + int32 y

Request message:

SetCursorPointRequest + Point point
  • point: New position for the cursor pointer expressed in local virtual screen coordinates.

    On Windows the coordinates in the virtual screen are expressed in physical pixels (no custom DPI applied) with the origin corresponding to the top left corner of the main display, displays to the left or to the top have negative coordinates.

Response message:

SetCursorPointResponse (no fields)

GetStreamingViews

This API is available only on DCV client.

Extensions issue a GetStreamingViewRequest and receive a synchronous GetStreamingViewsResponse.

After the first GetStreamingViewsRequest is issued DCV will also start sending asynchronous StreamingViewsChangedEvent messages whenever the geometry of the local streaming views is changed (e.g. the client window is resized or moved) or the geometry of the remote desktop is changed (e.g. a monitor is added or removed).

Sequence diagram showing GetStreamingViews request-response and asynchronous event notification between clients.

Helper structures:

Point + int32 x + int32 y
Rect + int32 x + int32 y + uint32 width + uint32 height
StreamingView + int32 view_id + Rect local_area + double zoom_factor + Point remote_offset + bool has_focus
StreamingViews + StreamingView[] streaming_view + bool has_focus
  • view_id: The view ID, as returned in IsPointInsideStreamingViewsResponse

  • local_area: Coordinates of the local streaming view in the local virtual screen.

    On Windows the coordinates in the virtual screen are expressed in physical pixels (no custom DPI applied) with the origin corresponding to the top left corner of the main display, displays to the left or to the top have negative coordinates.

  • zoom_factor: Local over remote, e.g. 2.0 means that local view is twice as big as remote area

  • remote_offset: Remote virtual screen coordinates, regardless of the remote operating system the origin is on the top left corner of the smallest rectangle containing all remote displays so remote virtual screen coordinates are always positive.

  • has_focus: StreamingView.has_focus indicate whether an individual streaming view has has the keyboard focus or not.

    StreamingViews.has_focus indicate whether the client window has has the keyboard focus or not.

Request message:

GetStreamingViewsRequest (no fields)

Response message:

GetStreamingViewsResponse + StreamingViews streaming_views

Event message:

StreamingViewsChangedEvent + StreamingViews streaming_views

IsPointInsideStreamingViews

This API is available only on Amazon DCV client.

Query whether a position on the local desktop of the client host lies inside a visible part of a streaming area of the Amazon DCV client, i.e. it shows a pixel of the remote desktop. In case a point lies in a streaming view, the id of the streaming view is returned (to be matched to id’s returned in GetStreamingViewsResponse or GetStreamingViewsChangedEvent), in case the point lies outside all streaming views -1 is returned.

Extensions issue a IsPointInsideStreamingViewsRequest and receive a synchronous IsPointInsideStreamingViewsResponse.

Sequence diagram showing IsPointInsideStreamingViews request and response between clients.

Helper structures:

Point + int32 x + int32 y

Request message:

IsPointInsideStreamingViewsRequest + Point point
  • point: Expressed in local virtual screen coordinates.

    On Windows the coordinates in the virtual screen are expressed in physical pixels (no custom DPI applied) with the origin corresponding to the top left corner of the main display, displays to the left or to the top have negative coordinates.

Response message:

IsPointInsideStreamingViewsRequest + int32 view_id
  • view_id: Identification of the streaming view in which the point lies (from GetStreamingViewsResponse or GetStreamingViewsChangedEvent), or -1 if the point lies outside all local views.