Read Viewport Press State (BETA)#
Read the state of the last viewport press event from the specified viewport. Note that viewport mouse events must be enabled on the specified viewport using a SetViewportMode node.
Installation#
To use this Node, you must enable omni.graph.ui_nodes
in the Extension Manager.
Inputs#
Name |
Type |
Description |
Default |
---|---|---|---|
Use Normalized Coords (useNormalizedCoords) |
|
When true, the components of 2D position outputs are scaled to between 0 and 1, where 0 is top/left and 1 is bottom/right. When false, components are in viewport render resolution pixels. |
False |
Viewport (viewport) |
|
Name of the viewport window to watch for press events |
Viewport |
Gesture (gesture) |
|
The input gesture to trigger viewport press events |
Left Mouse Press |
Outputs#
Name |
Type |
Description |
Default |
---|---|---|---|
Press Position (pressPosition) |
|
The position at which the specified viewport was last pressed |
|
Release Position (releasePosition) |
|
The position at which the last press on the specified viewport was released, or (0,0) if the press was released outside of the viewport or the viewport is currently pressed |
|
Is Release Position Valid (isReleasePositionValid) |
|
True if the press was released inside of the viewport, and false otherwise |
|
Is Pressed (isPressed) |
|
True if the specified viewport is currently pressed |
|
Is Valid (isValid) |
|
True if a valid event state was detected and the outputs of this node are valid, and false otherwise |