A Demo Project for the UnrealEngineSDK
Loading...
Searching...
No Matches
PixoVRGripInterface.h
Go to the documentation of this file.
1// Copyright(c) 2017 PixoFactor, LLC. All Rights Reserved
2
3#pragma once
4
5#include "CoreMinimal.h"
6#include "VRGripInterface.h"
7#include "PixoVRGripInterface.generated.h"
8
9class UPixoVRMotionControllerComponent;
10
14UENUM(BlueprintType)
15enum class EPixoVRGripTriggerModeEnum : uint8
16{
18 GRIP_TRIGGER_AUTO_DROP UMETA(Displayname="Auto Drop"),
19
21 GRIP_TRIGGER_TOGGLE_DROP UMETA(DisplayName="Toggle Drop"),
22};
23
27UENUM(BlueprintType)
28enum class EPixoVRGripModeEnum : uint8
29{
31 GRIP_STATIC UMETA(Displayname="Grip Static"),
32
34 GRIP_PHYSICS UMETA(DisplayName="Grip Physics"),
35};
36
40//UE_DEPRECATED(4.27, "Use instead FBPInterfaceProperties.")
41USTRUCT(BlueprintType)
42struct PIXOCORE_API FGripInterfaceSettings
43{
44 GENERATED_BODY()
45
46 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "PixoVR | Grip Interface Settings")
47 bool bDenyGripping = false;
48
49 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "PixoVR | Grip Interface Settings")
50 bool bDenyDropping = false;
52 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "PixoVR | Grip Interface Settings")
54
55 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "PixoVR | Grip Interface Settings")
57
58 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "PixoVR | Grip Interface Settings")
59 bool bUseCustomTransform = false;
61 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "PixoVR | Grip Interface Settings")
62 FTransform CustomTransform;
63};
64
69//UE_DEPRECATED(4.27, "Use instead UVRGripInterface")
70UINTERFACE(MinimalAPI)
72{
73 GENERATED_BODY()
74};
75
79//UE_DEPRECATED(4.27, "Use instead IVRGripInterface")
80class PIXOCORE_API IPixoVRGripInterface
82 GENERATED_BODY()
83
84public:
85
87 UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "PixoVR | Grip Interface")
88 bool DenyGrippingPixoVR(UGripMotionControllerComponent* GrippingController);
89
91 UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "PixoVR | Grip Interface")
92 bool DenyTriggerGripping();
93
95 UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "PixoVR | Grip Interface")
96 bool DenyDropping();
97
99 UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "PixoVR | Grip Interface")
100 void OnGripObject(UGripMotionControllerComponent* GrippingController, AActor* GrippedActor);
101
103 UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "PixoVR | Grip Interface")
104 void OnTryGripObject(UGripMotionControllerComponent* GrippingController, AActor* GrippedActor);
105
107 UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "PixoVR | Grip Interface")
108 void OnGripObjectRelease(UGripMotionControllerComponent* ReleasingController, AActor* GrippedActor);
111 UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "PixoVR | Grip Interface")
112 void GripTriggerMode(EPixoVRGripTriggerModeEnum& GripTriggerMode);
113
115 UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "PixoVR | Grip Interface")
116 void GripTriggerTransform(UGripMotionControllerComponent* GrippingController, bool& UseCustomTransform, FTransform& CustomTransform);
117
119 UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "PixoVR | Grip Interface")
120 void GripMode(EPixoVRGripModeEnum& GripMode);
121
123 UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "PixoVR | Grip Interface")
124 bool DisablePhysicsOnDrop();
125
127 UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "PixoVR | Grip Interface")
128 void OnObjectPaused();
129
131 UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "PixoVR | Grip Interface")
132 void OnObjectUnPaused();
133};
EPixoVRGripModeEnum
UENUM(BlueprintType)
EPixoVRGripTriggerModeEnum
UENUM(BlueprintType)
void OnTryGripObject(UGripMotionControllerComponent *GrippingController, AActor *GrippedActor)
Will be called when user tried to grab the object.
bool DenyGrippingPixoVR(UGripMotionControllerComponent *GrippingController)
Deny gripping. If this is set to true the actor can't be gripped anymore until set the false again.
void OnObjectPaused()
This event runs when the user "pauses" this object. Pausing should turn off visibility and functional...
void GripTriggerMode(EPixoVRGripTriggerModeEnum &GripTriggerMode)
Will be used to determine how the gripping trigger should behave.
void OnGripObjectRelease(UGripMotionControllerComponent *ReleasingController, AActor *GrippedActor)
Will be called when the user releases an object.
void GripTriggerTransform(UGripMotionControllerComponent *GrippingController, bool &UseCustomTransform, FTransform &CustomTransform)
This specified transformation will be used when flag is set and a grip is happening.
void GripMode(EPixoVRGripModeEnum &GripMode)
Will be used to determine how to do the grabbing. Using normal attachment or a physics constraint.
void OnObjectUnPaused()
This event runs when the user "unpauses" this object. Unpausing should turn on visibility and functio...
bool DisablePhysicsOnDrop()
Disable Physics on Drop. When this is set to 'true' if user drops object it will disable physics else...
void OnGripObject(UGripMotionControllerComponent *GrippingController, AActor *GrippedActor)
Will be called when user grabs an object.
bool DenyTriggerGripping()
Deny gripping after triggering grip.
bool DenyDropping()
Deny dropping. If this is set to true the actor will not be dropped after releasing until set to fals...
UCLASS(Blueprintable, meta = (BlueprintSpawnableComponent), ClassGroup = MotionController)
UINTERFACE(MinimalAPI)
USTRUCT(BlueprintType)
FTransform CustomTransform
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "PixoVR | Grip Interface Settings")