add more documentation
This commit is contained in:
@@ -29,7 +29,8 @@
|
||||
*
|
||||
* @section DESCRIPTION
|
||||
*
|
||||
* A data class containing the minimum required data for a hand's forward kinematics.
|
||||
* A data class containing the minimum required data for a hand's forward
|
||||
* kinematics.
|
||||
* Used in both kinematics and calibration.
|
||||
*/
|
||||
|
||||
|
||||
@@ -30,7 +30,8 @@
|
||||
* @section DESCRIPTION
|
||||
*
|
||||
* Represents a Sense Glove Device that has no specific class within the API.
|
||||
* Used to test different iterations of the same product before integrating it into the Core API.
|
||||
* Used to test different iterations of the same product before integrating it
|
||||
* into the Core API.
|
||||
* Allows access to raw sensor values and commands of such a device.
|
||||
*/
|
||||
|
||||
|
||||
@@ -29,7 +29,8 @@
|
||||
*
|
||||
* @section DESCRIPTION
|
||||
*
|
||||
* Interface for SenseCom, allows the retrieval of Devices and Data, but only as.
|
||||
* Interface for SenseCom, allows the retrieval of Devices and Data, but only
|
||||
* as.
|
||||
*/
|
||||
|
||||
|
||||
|
||||
@@ -29,7 +29,8 @@
|
||||
*
|
||||
* @section DESCRIPTION
|
||||
*
|
||||
* An interface for any of our gloves that can track hand motion and/or send force / vibrotactile feedback.
|
||||
* An interface for any of our gloves that can track hand motion and/or send
|
||||
* force / vibrotactile feedback.
|
||||
*/
|
||||
|
||||
|
||||
|
||||
@@ -29,7 +29,6 @@
|
||||
*
|
||||
* @section DESCRIPTION
|
||||
*
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
@@ -53,6 +52,9 @@
|
||||
class FSGHapticGloveCalibrationSequenceImpl;
|
||||
class FSGHapticGloveQuickCalibrationImpl;
|
||||
|
||||
/**
|
||||
* A sequence which collects data points until specific criteria have been met. It must be 'fed' an Update command from your program in order to work.
|
||||
*/
|
||||
UCLASS(BlueprintType)
|
||||
class SENSEGLOVECORE_API USGHapticGloveCalibrationSequence : public UObject
|
||||
{
|
||||
@@ -66,16 +68,28 @@ public:
|
||||
UObject* Outer, TSharedRef<FSGHapticGloveCalibrationSequenceImpl> HapticGloveCalibrationSequence);
|
||||
|
||||
protected:
|
||||
/**
|
||||
*
|
||||
*/
|
||||
static USGHapticGloveCalibrationSequence* NewHapticGloveCalibrationSequence(UObject* Outer);
|
||||
|
||||
public:
|
||||
/**
|
||||
* Create a new instance of a base HapitcGlove Calibration Sequence.
|
||||
*/
|
||||
static USGHapticGloveCalibrationSequence* NewHapticGloveCalibrationSequence(
|
||||
UObject* Outer, const USGHapticGlove* LinkedGlove);
|
||||
|
||||
public:
|
||||
/**
|
||||
* The maximum buffer size for calibration points. Once calibrationPoints exceeds this value, the
|
||||
*/
|
||||
static int32 GetMaxDataPoints();
|
||||
|
||||
public:
|
||||
/**
|
||||
* Converts a calibration range taken from a Calibration sequence, and converts it into a profile. Use this if you're not actually using the sequence.
|
||||
*/
|
||||
static bool CompileProfile(UObject* Outer,
|
||||
const USGSensorRange* SensorRange, ESGDeviceType ForDevice, bool bRightHanded,
|
||||
USGHandProfile*& OutProfile);
|
||||
@@ -92,9 +106,15 @@ private:
|
||||
FImplDeleter PimplDeleter;
|
||||
|
||||
protected:
|
||||
/**
|
||||
*
|
||||
*/
|
||||
USGHapticGloveCalibrationSequence();
|
||||
|
||||
public:
|
||||
/**
|
||||
* Create a new instance of a base HapitcGlove Calibration Sequence.
|
||||
*/
|
||||
explicit USGHapticGloveCalibrationSequence(const USGHapticGlove* LinkedGlove);
|
||||
|
||||
public:
|
||||
@@ -172,41 +192,96 @@ protected:
|
||||
virtual void SyncUProperties();
|
||||
|
||||
public:
|
||||
/**
|
||||
* Glove linked to this calibration sequence. Will attempt to grab data from this glove evey time Update() is called.
|
||||
*/
|
||||
USGHapticGlove* GetLinkedGlove(UObject* Outer) const;
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
void SetLinkedGlove(const USGHapticGlove* LinkedGlove);
|
||||
|
||||
/**
|
||||
* Calibration points collected during this calibration process. One is added every time the "Update()" function is called.
|
||||
* Used to create a profile after the calibration finishes.
|
||||
*/
|
||||
TArray<USGCalibrationDataPoint*> GetCalibrationPoints(UObject* Outer) const;
|
||||
|
||||
/**
|
||||
* How much time has elapsed during this calibration sequence. Useful for logging or for automated functions.
|
||||
*/
|
||||
float GetElapsedTime() const;
|
||||
|
||||
/**
|
||||
* Used to determine if the user has manually ended the sequence, to prevent us from adding any more calibration points.
|
||||
*/
|
||||
bool IsManuallyCompleted() const;
|
||||
|
||||
/**
|
||||
* If a sequence consists of multiple stages, this integer will show you which one is currently active.
|
||||
*/
|
||||
int32 GetCurrentStage() const;
|
||||
|
||||
/**
|
||||
* Returns the amount of calibration points collected so far.
|
||||
*/
|
||||
SIZE_T GetCalibrationPointsCount() const;
|
||||
|
||||
/**
|
||||
* Whether or not this sequence was completed as per its own rules.
|
||||
*/
|
||||
bool AutoCompleted() const;
|
||||
|
||||
/**
|
||||
* Returns true if this sequence is marked as 'complete' and can begin compiling a profile.
|
||||
*/
|
||||
bool Completed() const;
|
||||
|
||||
public:
|
||||
/**
|
||||
* Resets this calibration sequence's data, but not it's LinkedGlove.
|
||||
*/
|
||||
void Reset();
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
void AddDataPoint(const TArray<FVector>& CalibrationPoints);
|
||||
|
||||
/**
|
||||
* Update this calibration sequence with new data. We use deltaSeconds to check for things like stability.
|
||||
*/
|
||||
void Update(float DeltaSeconds);
|
||||
|
||||
/**
|
||||
* Manual confirmation of whatever step we're supposed to making at the moment.
|
||||
*/
|
||||
void ConfirmCurrentStep();
|
||||
|
||||
public:
|
||||
/**
|
||||
* Compile a min/max range from the data points collected by this sequence. Returns true if it's actually possible.
|
||||
*/
|
||||
bool CompileRange(UObject* Outer, USGSensorRange*& OutSensorRange) const;
|
||||
|
||||
/**
|
||||
* Compile a profile from the data points collected by this sequence. Returns true if it's actually possible.
|
||||
*/
|
||||
bool CompileProfile(UObject* Outer, ESGDeviceType ForDevice, bool bRightHanded, USGHandProfile*& OutProfile) const;
|
||||
|
||||
/**
|
||||
* Returns the current HandPose; either the one we should be making, or what it would look like at the moment.
|
||||
*/
|
||||
bool GetHandPose(UObject* Outer, USGHandPose*& OutCurrentHandPose) const;
|
||||
|
||||
/**
|
||||
* Returns the current HandPose; either the one we should be making, or what it would look like at the moment.
|
||||
*/
|
||||
bool GetHandPose(UObject* Outer, bool bRightHanded, USGHandPose*& OutCurrentHandPose) const;
|
||||
|
||||
/**
|
||||
* Retrieve instructions on what to do during the current step.
|
||||
*/
|
||||
FString GetCurrentInstruction(const FString& NextStepKey = FString{""}) const;
|
||||
};
|
||||
@@ -50,6 +50,9 @@ class USGBuzzCommand;
|
||||
class USGForceFeedbackCommand;
|
||||
class USGTimedBuzzCommand;
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
UCLASS(BlueprintType)
|
||||
class SENSEGLOVECORE_API USGHapticGloveCommandBuffer final : public UObject
|
||||
{
|
||||
@@ -60,13 +63,25 @@ public:
|
||||
UObject* Outer, const FSGHapticGloveCommandBufferImpl& HapticGloveCommandBufferImpl);
|
||||
|
||||
public:
|
||||
/**
|
||||
* Create a new HapticsStream for a Haptic Glove.
|
||||
*/
|
||||
static USGHapticGloveCommandBuffer* NewHapticGloveCommandBuffer(UObject* Outer);
|
||||
|
||||
public:
|
||||
/**
|
||||
* The base maximum amount of Force-Feedback Commands that can be in a queue.
|
||||
*/
|
||||
static int32 GetMaxForceFeedbackCommands();
|
||||
|
||||
/**
|
||||
* The base maximum amount of Vibrotactile Commands that can be in a queue.
|
||||
*/
|
||||
static int32 GetMaxBuzzCommands();
|
||||
|
||||
/**
|
||||
* The base maximum amount of Thumper Commands that can be in a queue.
|
||||
*/
|
||||
static int32 GetMaxThumpCommands();
|
||||
|
||||
private:
|
||||
@@ -81,6 +96,9 @@ private:
|
||||
FImplDeleter PimplDeleter;
|
||||
|
||||
public:
|
||||
/**
|
||||
*
|
||||
*/
|
||||
USGHapticGloveCommandBuffer();
|
||||
|
||||
public:
|
||||
@@ -108,38 +126,83 @@ public:
|
||||
const FSGHapticGloveCommandBufferImpl& ToHapticGloveCommandBufferImpl() const;
|
||||
|
||||
public:
|
||||
/**
|
||||
* All Force Feedback Commands that have been received this 'frame'. Will be flattened into a single command during FlushHapitcs.
|
||||
*/
|
||||
TArray<USGForceFeedbackCommand*> GetForceFeedbackCommandsQueue(UObject* Outer) const;
|
||||
|
||||
/**
|
||||
* All Timed Buzz Commands that have been received this 'frame'. Will be flattened into a single command during FlushHapitcs.
|
||||
*/
|
||||
TArray<USGTimedBuzzCommand*> GetBuzzCommandsQueue(UObject* Outer) const;
|
||||
|
||||
/**
|
||||
* All Timed Thump Commands that have been received this 'frame'. Will be flattened into a single command during FlushHapitcs.
|
||||
*/
|
||||
TArray<USGTimedThumpCommand*> GetThumperCommandsQueue(UObject* Outer) const;
|
||||
|
||||
public:
|
||||
/**
|
||||
* Clears only the Force-Feedback Queue.
|
||||
*/
|
||||
void ClearForceFeedbackCommandsQueue();
|
||||
|
||||
/**
|
||||
* Clears all vibrations in the queue(s).
|
||||
*/
|
||||
void ClearVibrations();
|
||||
|
||||
/**
|
||||
* Clear all ongoing effects to this stream.
|
||||
*/
|
||||
void Clear();
|
||||
|
||||
/**
|
||||
* Add a new Force-Feedback command to the queue. Does not actually send it.
|
||||
*/
|
||||
void AddCommand(const USGForceFeedbackCommand* ForceFeedbackCommand);
|
||||
|
||||
/**
|
||||
* Add a new vibrotactile command to the queue. Does not actually send it.
|
||||
*/
|
||||
void AddCommand(const USGTimedBuzzCommand* BuzzCommand);
|
||||
|
||||
/**
|
||||
* Add a new Thumper command to the queue. Does not actually send it. Does not work with SenseGlove, only for Nova's
|
||||
*/
|
||||
void AddCommand(const USGTimedThumpCommand* ThumpCommand);
|
||||
|
||||
/**
|
||||
* Update the active commands, using a deltaSeconds since last update, in seconds. Any timedCommands that are elapsed will be removed from the list.
|
||||
*/
|
||||
void UpdateTimedCommands(float DeltaSeconds);
|
||||
|
||||
public:
|
||||
/**
|
||||
* Compiles all ForceFeedback Levels in the queue into a single one. Does not clear the queue. Returns lastForceFeedbackCommand if no ForceFeedback commands are given.
|
||||
*/
|
||||
USGForceFeedbackCommand* GetTotalForceFeedbackLevels(
|
||||
UObject* Outer, const USGForceFeedbackCommand* LastForceFeedbackCommand) const;
|
||||
|
||||
/**
|
||||
* Compiles all ForceFeedback Levels in the queue into a single one. Does not clear the queue.
|
||||
*/
|
||||
USGForceFeedbackCommand* GetTotalForceFeedbackLevels(UObject* Outer) const;
|
||||
|
||||
/**
|
||||
* Compiles all active vibrotactile in the queue into a single list of levels. Does not clear the queue.
|
||||
*/
|
||||
USGBuzzCommand* GetTotalBuzzLevels(UObject* Outer) const;
|
||||
|
||||
/**
|
||||
* Compiles all active vibrotactile in the queue into a single list of levels. Does not clear the queue.
|
||||
*/
|
||||
USGThumperCommand* GetTotalThumperLevels(UObject* Outer) const;
|
||||
|
||||
public:
|
||||
/**
|
||||
* Compile all commands in the queue(s) into a single set of commands that can be sent to the glove. Only clears the ForceFeedback queue, and only if you want it to.
|
||||
*/
|
||||
void FlushHaptics(UObject* Outer,
|
||||
const USGForceFeedbackCommand* LastBrakeLevel,
|
||||
USGForceFeedbackCommand*& OutForceFeedbackCommand,
|
||||
@@ -147,6 +210,9 @@ public:
|
||||
USGThumperCommand*& OutThumperCommand,
|
||||
bool bClearForceFeedbackQueue = true);
|
||||
|
||||
/**
|
||||
* Compile all commands in the queue(s) into a single set of commands that can be sent to the glove. Also updates & clears all queues.
|
||||
*/
|
||||
void FlushHaptics(UObject* Outer,
|
||||
float DeltaSeconds,
|
||||
const USGForceFeedbackCommand* LastBrakeLevel,
|
||||
|
||||
@@ -29,7 +29,8 @@
|
||||
*
|
||||
* @section DESCRIPTION
|
||||
*
|
||||
* A data class containing the minimum required data for a hand's forward kinematics.
|
||||
* A data class containing the minimum required data for a hand's forward
|
||||
* kinematics.
|
||||
* Used in both kinematics and calibration.
|
||||
*/
|
||||
|
||||
|
||||
@@ -30,7 +30,8 @@
|
||||
* @section DESCRIPTION
|
||||
*
|
||||
* Represents a Sense Glove Device that has no specific class within the API.
|
||||
* Used to test different iterations of the same product before integrating it into the Core API.
|
||||
* Used to test different iterations of the same product before integrating it
|
||||
* into the Core API.
|
||||
* Allows access to raw sensor values and commands of such a device.
|
||||
*/
|
||||
|
||||
|
||||
@@ -29,7 +29,8 @@
|
||||
*
|
||||
* @section DESCRIPTION
|
||||
*
|
||||
* Interface for SenseCom, allows the retrieval of Devices and Data, but only as.
|
||||
* Interface for SenseCom, allows the retrieval of Devices and Data, but only
|
||||
* as.
|
||||
*/
|
||||
|
||||
|
||||
|
||||
@@ -29,8 +29,8 @@
|
||||
*
|
||||
* @section DESCRIPTION
|
||||
*
|
||||
* Data class containing all variables to draw or analyze a virtual hand
|
||||
* in different formats.
|
||||
* Data class containing all variables to draw or analyze a virtual hand in
|
||||
* different formats.
|
||||
*/
|
||||
|
||||
|
||||
|
||||
+67
@@ -47,12 +47,18 @@ class USGHapticGlove;
|
||||
class USGHapticGloveCalibrationSequence;
|
||||
class USGSensorRange;
|
||||
|
||||
/**
|
||||
* A sequence which collects data points until specific criteria have been met. It must be 'fed' an Update command from your program in order to work.
|
||||
*/
|
||||
UCLASS(meta=(ScriptName = "SesneGloveHapticGloveCalibrationSequenceKismetLibrary"))
|
||||
class SENSEGLOVECOREKISMET_API USGHapticGloveCalibrationSequenceKismetLibrary final : public USGBlueprintFunctionLibrary
|
||||
{
|
||||
GENERATED_BODY()
|
||||
|
||||
public:
|
||||
/**
|
||||
* Create a new instance of a base HapitcGlove Calibration Sequence.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, DisplayName="Make Haptic Glove Calibration Sequence",
|
||||
Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
@@ -60,9 +66,15 @@ public:
|
||||
UObject* WorldContextObject,
|
||||
const USGHapticGlove* GloveToCalibrate);
|
||||
|
||||
/**
|
||||
* The maximum buffer size for calibration points. Once calibrationPoints exceeds this value, the
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence")
|
||||
static int32 GetMaxDataPoints();
|
||||
|
||||
/**
|
||||
* Converts a calibration range taken from a Calibration sequence, and converts it into a profile. Use this if you're not actually using the sequence.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, DisplayName="CompileProfile",
|
||||
Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
@@ -70,59 +82,105 @@ public:
|
||||
UObject* WorldContextObject,
|
||||
const USGSensorRange* SensorRange, ESGDeviceType ForDevice, bool bRightHanded, USGHandProfile*& OutProfile);
|
||||
|
||||
/**
|
||||
* Glove linked to this calibration sequence. Will attempt to grab data from this glove evey time Update() is called.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
static USGHapticGlove* GetLinkedGlove(UObject* WorldContextObject,
|
||||
const USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence);
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence")
|
||||
static void SetLinkedGlove(USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence,
|
||||
const USGHapticGlove* LinkedGlove);
|
||||
|
||||
/**
|
||||
* Calibration points collected during this calibration process. One is added every time the "Update()" function is called.
|
||||
* Used to create a profile after the calibration finishes.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
static TArray<USGCalibrationDataPoint*> GetCalibrationPoints(
|
||||
UObject* WorldContextObject,
|
||||
const USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence);
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence")
|
||||
static float GetElapsedTime(const USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence);
|
||||
|
||||
/**
|
||||
* Used to determine if the user has manually ended the sequence, to prevent us from adding any more calibration points.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence")
|
||||
static bool IsManuallyCompleted(const USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence);
|
||||
|
||||
/**
|
||||
* If a sequence consists of multiple stages, this integer will show you which one is currently active.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence")
|
||||
static int32 GetCurrentStage(const USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence);
|
||||
|
||||
/**
|
||||
* Returns the amount of calibration points collected so far.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence")
|
||||
static int64 GetCalibrationPointsCount(const USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence);
|
||||
|
||||
/**
|
||||
* Whether or not this sequence was completed as per its own rules.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence")
|
||||
static bool AutoCompleted(const USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence);
|
||||
|
||||
/**
|
||||
* Returns true if this sequence is marked as 'complete' and can begin compiling a profile.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence")
|
||||
static bool Completed(const USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence);
|
||||
|
||||
/**
|
||||
* Resets this calibration sequence's data, but not it's LinkedGlove.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence")
|
||||
static void Reset(USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence);
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence")
|
||||
static void AddDataPoint(USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence,
|
||||
const TArray<FVector>& CalibrationData);
|
||||
|
||||
/**
|
||||
* Update this calibration sequence with new data. We use deltaSeconds to check for things like stability.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence")
|
||||
static void Update(USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence,
|
||||
float DeltaSeconds);
|
||||
|
||||
/**
|
||||
* Manual confirmation of whatever step we're supposed to making at the moment.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence")
|
||||
static void ConfirmCurrentStep(USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence);
|
||||
|
||||
/**
|
||||
* Compile a min/max range from the data points collected by this sequence. Returns true if it's actually possible.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
static bool CompileRange(UObject* WorldContextObject,
|
||||
const USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence,
|
||||
USGSensorRange*& OutSensorRange);
|
||||
|
||||
/**
|
||||
* Compile a profile from the data points collected by this sequence. Returns true if it's actually possible.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, DisplayName="CompileProfile",
|
||||
Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
@@ -131,6 +189,9 @@ public:
|
||||
const USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence,
|
||||
ESGDeviceType ForDevice, bool bRightHanded, USGHandProfile*& OutProfile);
|
||||
|
||||
/**
|
||||
* Returns the current HandPose; either the one we should be making, or what it would look like at the moment.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, DisplayName="Get Hand Pose",
|
||||
Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
@@ -138,6 +199,9 @@ public:
|
||||
const USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence,
|
||||
USGHandPose*& OutCurrentHandPose);
|
||||
|
||||
/**
|
||||
* Returns the current HandPose; either the one we should be making, or what it would look like at the moment.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, DisplayName="Get Hand Pose",
|
||||
Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
@@ -147,6 +211,9 @@ public:
|
||||
bool bRightHanded,
|
||||
USGHandPose*& OutCurrentHandPose);
|
||||
|
||||
/**
|
||||
* Retrieve instructions on what to do during the current step.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Calibration | Haptic Glove Calibration Sequence")
|
||||
static FString GetCurrentInstruction(const USGHapticGloveCalibrationSequence* HapticGloveCalibrationSequence,
|
||||
const FString& NextStepKey = "");
|
||||
|
||||
+63
@@ -47,71 +47,119 @@ class USGThumperCommand;
|
||||
class USGTimedBuzzCommand;
|
||||
class USGTimedThumpCommand;
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
UCLASS(meta=(ScriptName = "SesneGloveHapticGloveCommandBufferKismetLibrary"))
|
||||
class SENSEGLOVECOREKISMET_API USGHapticGloveCommandBufferKismetLibrary final : public USGBlueprintFunctionLibrary
|
||||
{
|
||||
GENERATED_BODY()
|
||||
|
||||
public:
|
||||
/**
|
||||
* Create a new HapticsStream for a Haptic Glove.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
static USGHapticGloveCommandBuffer* MakeHapticGloveCommandBuffer(UObject* WorldContextObject);
|
||||
|
||||
/**
|
||||
* The base maximum amount of Force-Feedback Commands that can be in a queue.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer")
|
||||
static int32 GetMaxForceFeedbackCommands();
|
||||
|
||||
/**
|
||||
* The base maximum amount of Vibrotactile Commands that can be in a queue.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer")
|
||||
static int32 GetMaxBuzzCommands();
|
||||
|
||||
/**
|
||||
* The base maximum amount of Thumper Commands that can be in a queue.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer")
|
||||
static int32 GetMaxThumpCommands();
|
||||
|
||||
/**
|
||||
* All Force Feedback Commands that have been received this 'frame'. Will be flattened into a single command during FlushHapitcs.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
static TArray<USGForceFeedbackCommand*> GetForceFeedbackCommandsQueue(
|
||||
UObject* WorldContextObject,
|
||||
const USGHapticGloveCommandBuffer* HapticGloveCommandBuffer);
|
||||
|
||||
/**
|
||||
* All Timed Buzz Commands that have been received this 'frame'. Will be flattened into a single command during FlushHapitcs.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
static TArray<USGTimedBuzzCommand*> GetBuzzCommandsQueue(
|
||||
UObject* WorldContextObject,
|
||||
const USGHapticGloveCommandBuffer* HapticGloveCommandBuffer);
|
||||
|
||||
/**
|
||||
* All Timed Thump Commands that have been received this 'frame'. Will be flattened into a single command during FlushHapitcs.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
static TArray<USGTimedThumpCommand*> GetThumperCommandsQueue(
|
||||
UObject* WorldContextObject,
|
||||
const USGHapticGloveCommandBuffer* HapticGloveCommandBuffer);
|
||||
|
||||
/**
|
||||
* Clears only the Force-Feedback Queue.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer")
|
||||
static void ClearForceFeedbackCommandsQueue(UPARAM(ref) USGHapticGloveCommandBuffer* HapticGloveCommandBuffer);
|
||||
|
||||
/**
|
||||
* Clears all vibrations in the queue(s).
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer")
|
||||
static void ClearVibrations(UPARAM(ref) USGHapticGloveCommandBuffer* HapticGloveCommandBuffer);
|
||||
|
||||
/**
|
||||
* Clear all ongoing effects to this stream.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer")
|
||||
static void Clear(UPARAM(ref) USGHapticGloveCommandBuffer* HapticGloveCommandBuffer);
|
||||
|
||||
/**
|
||||
* Add a new Force-Feedback command to the queue. Does not actually send it.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, DisplayName="Add Command",
|
||||
Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer")
|
||||
static void AddCommand_ForceFeedbackCommand(UPARAM(ref) USGHapticGloveCommandBuffer* HapticGloveCommandBuffer,
|
||||
const USGForceFeedbackCommand* ForceFeedbackCommand);
|
||||
|
||||
/**
|
||||
* Add a new vibrotactile command to the queue. Does not actually send it.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, DisplayName="Add Command",
|
||||
Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer")
|
||||
static void AddCommand_BuzzCommand(UPARAM(ref) USGHapticGloveCommandBuffer* HapticGloveCommandBuffer,
|
||||
const USGTimedBuzzCommand* BuzzCommand);
|
||||
|
||||
/**
|
||||
* Add a new Thumper command to the queue. Does not actually send it. Does not work with SenseGlove, only for Nova's
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, DisplayName="Add Command",
|
||||
Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer")
|
||||
static void AddCommand_ThumpCommand(UPARAM(ref) USGHapticGloveCommandBuffer* HapticGloveCommandBuffer,
|
||||
const USGTimedThumpCommand* ThumpCommand);
|
||||
|
||||
/**
|
||||
* Update the active commands, using a deltaSeconds since last update, in seconds. Any timedCommands that are elapsed will be removed from the list.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer")
|
||||
static void UpdateTimedCommands(UPARAM(ref) USGHapticGloveCommandBuffer* HapticGloveCommandBuffer,
|
||||
float DeltaSeconds);
|
||||
|
||||
/**
|
||||
* Compiles all ForceFeedback Levels in the queue into a single one. Does not clear the queue. Returns lastForceFeedbackCommand if no ForceFeedback commands are given.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, DisplayName="Get Total Force Feedback Levels",
|
||||
Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer", meta=(WorldContext="WorldContextObject"))
|
||||
static USGForceFeedbackCommand* GetTotalForceFeedbackLevels_LastForceFeedbackCommand(
|
||||
@@ -119,22 +167,34 @@ public:
|
||||
const USGHapticGloveCommandBuffer* HapticGloveCommandBuffer,
|
||||
const USGForceFeedbackCommand* LastForceFeedbackCommand);
|
||||
|
||||
/**
|
||||
* Compiles all ForceFeedback Levels in the queue into a single one. Does not clear the queue.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
static USGForceFeedbackCommand* GetTotalForceFeedbackLevels(
|
||||
UObject* WorldContextObject,
|
||||
const USGHapticGloveCommandBuffer* HapticGloveCommandBuffer);
|
||||
|
||||
/**
|
||||
* Compiles all active vibrotactile in the queue into a single list of levels. Does not clear the queue.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
static USGBuzzCommand* GetTotalBuzzLevels(UObject* WorldContextObject,
|
||||
const USGHapticGloveCommandBuffer* HapticGloveCommandBuffer);
|
||||
|
||||
/**
|
||||
* Compiles all active vibrotactile in the queue into a single list of levels. Does not clear the queue.
|
||||
*/
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer",
|
||||
meta=(WorldContext="WorldContextObject"))
|
||||
static USGThumperCommand* GetTotalThumperLevels(UObject* WorldContextObject,
|
||||
const USGHapticGloveCommandBuffer* HapticGloveCommandBuffer);
|
||||
|
||||
/**
|
||||
* Compile all commands in the queue(s) into a single set of commands that can be sent to the glove. Only clears the ForceFeedback queue, and only if you want it to.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, DisplayName="Flush Haptics",
|
||||
Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer", meta=(WorldContext="WorldContextObject"))
|
||||
static void FlushHaptics_LBL_OutFFC_OutBC_OutTC_bCFFQ(
|
||||
@@ -146,6 +206,9 @@ public:
|
||||
USGThumperCommand*& OutThumperCommand,
|
||||
bool bClearForceFeedbackQueue = true);
|
||||
|
||||
/**
|
||||
* Compile all commands in the queue(s) into a single set of commands that can be sent to the glove. Also updates & clears all queues.
|
||||
*/
|
||||
UFUNCTION(BlueprintCallable, DisplayName="Flush Haptics",
|
||||
Category="SenseGlove | Core | Haptics | Haptic Glove Command Buffer", meta=(WorldContext="WorldContextObject"))
|
||||
static void FlushHaptics_DS_LBL_OutFFC_OutBuzzCommand_OutTC(
|
||||
|
||||
@@ -29,7 +29,8 @@
|
||||
*
|
||||
* @section DESCRIPTION
|
||||
*
|
||||
* An interface for any of our gloves that can track hand motion and/or send force / vibrotactile feedback.
|
||||
* An interface for any of our gloves that can track hand motion and/or send
|
||||
* force / vibrotactile feedback.
|
||||
*/
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user