Package org.lwjgl.openvr
Class VREventMouse
java.lang.Object
org.lwjgl.system.Pointer.Default
org.lwjgl.system.Struct<VREventMouse>
org.lwjgl.openvr.VREventMouse
- All Implemented Interfaces:
org.lwjgl.system.Pointer
Used for simulated mouse events in overlay space.
Layout
struct VREvent_Mouse_t {
float x();
float y;
uint32_t button();
uint32_t cursorIndex();
}-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class org.lwjgl.system.Struct
org.lwjgl.system.Struct.StructValidationNested classes/interfaces inherited from interface org.lwjgl.system.Pointer
org.lwjgl.system.Pointer.Default -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe struct alignment in bytes.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct size in bytes.static final intThe struct member offsets.static final intThe struct member offsets.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE -
Constructor Summary
ConstructorsConstructorDescriptionVREventMouse(ByteBuffer container) Creates aVREventMouseinstance at the current position of the specifiedByteBuffercontainer. -
Method Summary
Modifier and TypeMethodDescriptionintbutton()static VREventMousecreate(long address) Returns a newVREventMouseinstance for the specified memory address.static VREventMouse.Buffercreate(long address, int capacity) Create aVREventMouse.Bufferinstance at the specified memory.static @Nullable VREventMousecreateSafe(long address) static @Nullable VREventMouse.BuffercreateSafe(long address, int capacity) intif from an event triggered by cursor input on an overlay that supports multiple cursors, this is the index of which tracked cursor the event is forstatic intnbutton(long struct) Unsafe version ofbutton().static intncursorIndex(long struct) Unsafe version ofcursorIndex().static floatnx(long struct) Unsafe version ofx().static floatny(long struct) Unsafe version ofy().intsizeof()floatx()coords are in GL space, bottom left of the texture is 0,0floaty()Methods inherited from class org.lwjgl.system.Struct
clear, free, isNull, validate, validateMethods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
-
Field Details
-
SIZEOF
public static final int SIZEOFThe struct size in bytes. -
ALIGNOF
public static final int ALIGNOFThe struct alignment in bytes. -
X
public static final int XThe struct member offsets. -
Y
public static final int YThe struct member offsets. -
BUTTON
public static final int BUTTONThe struct member offsets. -
CURSORINDEX
public static final int CURSORINDEXThe struct member offsets.
-
-
Constructor Details
-
VREventMouse
Creates aVREventMouseinstance at the current position of the specifiedByteBuffercontainer. Changes to the buffer's content will be visible to the struct instance and vice versa.The created instance holds a strong reference to the container object.
-
-
Method Details
-
sizeof
public int sizeof()- Specified by:
sizeofin classorg.lwjgl.system.Struct<VREventMouse>
-
x
public float x()coords are in GL space, bottom left of the texture is 0,0 -
y
public float y()- Returns:
- the value of the
yfield.
-
button
public int button() -
cursorIndex
public int cursorIndex()if from an event triggered by cursor input on an overlay that supports multiple cursors, this is the index of which tracked cursor the event is for -
create
Returns a newVREventMouseinstance for the specified memory address. -
createSafe
-
create
Create aVREventMouse.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
-
nx
public static float nx(long struct) Unsafe version ofx(). -
ny
public static float ny(long struct) Unsafe version ofy(). -
nbutton
public static int nbutton(long struct) Unsafe version ofbutton(). -
ncursorIndex
public static int ncursorIndex(long struct) Unsafe version ofcursorIndex().
-