Return information about a 2D Graphics window
Window2D_R <ScenarioPath> {DataType} {DataTypeOptions} [WindowId <WinNumber>]
The Window2D_R command will return information about a 2D Graphics window.
Valid {DataType} option is ProjectedPos or Property.
Enter the WindowId <WinNumber> to specify a 2D Graphics window. If not entered, then window 1 is used.
If {DataType} option is ProjectedPos then the command will return the Pixel coordinates (x, y where the upper left corner of the window is 0,0) or Screen coordinates (zoom coordinates) of the specified latitude, longitude point. The command will nack if the lat-lon is not visible on the screen.
The following table describes the valid {DataTypeOptions} for {DataType} ProjectedPos.
{DataTypeOptions} | Description |
---|---|
Lat <LatValue> | Enter the latitude value of the point
in degrees.
Note: This value is required. |
Lon <LonValue> | Enter the longitude value of the point
in degrees.
Note: This value is required. |
Alt <AltValue> | Enter the Altitude value in Connect distance units. Enter this value if the map is in the perspective or orthographic projection. |
Coord {Pixel | Screen} | Specify whether to return coordinates as Pixel or Screen. If not entered then Pixel is returned. |
If {DataType} option is Property then the command will return information about the 2D window.
The following table describes the valid {DataTypeOptions} for {DataType} Property.
{DataTypeOptions} | Description |
---|---|
Size | Returns the size of the 2D Graphics window including borders and frame. |
InnerSize | Returns the size of the 2D Graphics window not including borders or frame. |
Return the pixel coordinates for the specified latitude, longitude position:
Window2d_R * ProjectedPos Lat 45.0 Lon -135.0
94 124
On a window whose projection is set to perspective, get the pixel coordinates:
Window2d_R * ProjectedPos Lat 0.0 Lon -43.5 Alt 1000000
333 196
Return the size of the first 2d window (not including border and frame):
Window2d_R * Property InnerSize
640 360
Return the size of the second 2d window:
Window2d_R * Property Size WindowID 2
687 364
This command belongs to the following group(s):
9.0
STK Programming Interface 11.0.1