Tutorial 6 – Display Layouts hotspot

Requirements:
Tutorial 5 – Display Layouts salvo


In the previous tutorial we learned about the layout property “salvo”.

In this tutorial we’ll learn about the layout property “hotspot”:

“hotspot” defines a viewport and can be pre-populated using “salvo” but is usually left blank to begin with. To populate the hotspot viewport with video, pre-existing or not, left-click on it and then left-click on a viewport with video already displaying.

Here’s an example of its use:

This is a non-uniform layout with the “hotspot” viewport taking up most of the display window. Notice how we don’t need to use “vport” for viewport 0 as “hotspot” will define a viewport for us.

Definition of the layout property “hotspot”:

LayoutProperty: hotspot
Description: Sets up a viewport that can switch to other streams on click.
LayoutParameters: ViewPortID,x,y,x2,y2
ViewPortID: 0 indexed viewport identifier.
x: X coordinate of top left corner, starting at 0.0
y: Y coordinate of top left corner, starting at 0.0
x2: X coordinate of bottom right corner, ends at 1.0
y2: Y coordinate of bottom right corner, ends at 1.0

Here’s a more elaborate example of “hotspot” using the stream switching option of “salvo”:

Note that if you set the “hotspot” viewport to one that is switching it won’t switch with it.

Screenshots of the final program:
Series-1-Tutorial-6-2
Series-1-Tutorial-6-1

Now you can use “hotspot” to make a larger display of other viewports, giving users greater control of what they see.


Next:
Tutorial 7 – Layout Server