119 lines
5.0 KiB
C++
119 lines
5.0 KiB
C++
/**
|
|
* @file
|
|
*
|
|
* @author Mamadou Babaei <mamadou@senseglove.com>
|
|
*
|
|
* @section LICENSE
|
|
*
|
|
* (The MIT License)
|
|
*
|
|
* Copyright (c) 2020 - 2022 SenseGlove
|
|
*
|
|
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
* of this software and associated documentation files (the "Software"), to deal
|
|
* in the Software without restriction, including without limitation the rights
|
|
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
* copies of the Software, and to permit persons to whom the Software is
|
|
* furnished to do so, subject to the following conditions:
|
|
*
|
|
* The above copyright notice and this permission notice shall be included in all
|
|
* copies or substantial portions of the Software.
|
|
*
|
|
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
* SOFTWARE.
|
|
*
|
|
* @section DESCRIPTION
|
|
*
|
|
*
|
|
*/
|
|
|
|
|
|
#pragma once
|
|
|
|
#include "SGKismet/SGBlueprintFunctionLibrary.h"
|
|
|
|
#include "SGHandProfileKismetLibrary.generated.h"
|
|
|
|
class USGHandProfile;
|
|
class USGNovaGloveHandProfile;
|
|
class USGSenseGloveHandProfile;
|
|
|
|
UCLASS(meta=(ScriptName = "SesneGloveHandProfileKismetLibrary"))
|
|
class SENSEGLOVECOREKISMET_API USGHandProfileKismetLibrary final : public USGBlueprintFunctionLibrary
|
|
{
|
|
GENERATED_BODY()
|
|
|
|
public:
|
|
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Hand Profile", meta=(WorldContext="WorldContextObject"))
|
|
static USGHandProfile* MakeHandProfile(UObject* WorldContextObject);
|
|
|
|
UFUNCTION(BlueprintPure, DisplayName="Make Hand Profile", Category="SenseGlove | Core | Hand Profile",
|
|
meta=(WorldContext="WorldContextObject"))
|
|
static USGHandProfile* MakeHandProfile_bRH_SGHP_NGHP(
|
|
UObject* WorldContextObject,
|
|
bool bRightHanded,
|
|
const USGSenseGloveHandProfile* SenseGloveHandProfile,
|
|
const USGNovaGloveHandProfile* NovaGloveHandProfile);
|
|
|
|
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Hand Profile",
|
|
meta=(WorldContext="WorldContextObject"))
|
|
static USGHandProfile* Default(UObject* WorldContextObject, bool bRightHanded);
|
|
|
|
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Hand Profile",
|
|
meta=(WorldContext="WorldContextObject"))
|
|
static USGHandProfile* Deserialize(UObject* WorldContextObject, const FString& SerializedString);
|
|
|
|
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Hand Profile")
|
|
static FString GetProfileDirectory();
|
|
|
|
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Hand Profile")
|
|
static FString GetLeftHandFileName();
|
|
|
|
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Hand Profile")
|
|
static FString GetRightHandFileName();
|
|
|
|
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Hand Profile")
|
|
static FString GetProfileFileName(bool bRightHanded);
|
|
|
|
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Hand Profile",
|
|
meta=(WorldContext="WorldContextObject"))
|
|
static bool GetLatestProfile(
|
|
UObject* WorldContextObject,
|
|
bool bRightHanded, USGHandProfile*& OutLatestProfile);
|
|
|
|
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Hand Profile")
|
|
static bool StoreProfile(const USGHandProfile* ProfileToStore);
|
|
|
|
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Hand Profile")
|
|
static bool ResetCalibration_bRightHanded_bOnDisk(bool bRightHanded, bool bOnDisk = true);
|
|
|
|
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Hand Profile")
|
|
static void ResetCalibration_bObDisk(bool bOnDisk = true);
|
|
|
|
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Hand Profile")
|
|
static bool IsRight(const USGHandProfile* HandProfile);
|
|
|
|
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Hand Profile",
|
|
meta=(WorldContext="WorldContextObject"))
|
|
static USGSenseGloveHandProfile* GetSenseGloveHandProfile(UObject* WorldContextObject,
|
|
const USGHandProfile* HandProfile);
|
|
|
|
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Hand Profile",
|
|
meta=(WorldContext="WorldContextObject"))
|
|
static USGNovaGloveHandProfile* GetNovaGloveHandProfile(UObject* WorldContextObject,
|
|
const USGHandProfile* HandProfile);
|
|
|
|
UFUNCTION(BlueprintPure, Category="SenseGlove | Core | Hand Profile")
|
|
static bool Equals(const USGHandProfile* A, const USGHandProfile* B);
|
|
|
|
UFUNCTION(BlueprintCallable, Category="SenseGlove | Core | Hand Profile")
|
|
static void Reset(UPARAM(ref) USGHandProfile* HandProfile);
|
|
|
|
UFUNCTION(BlueprintPure, DisplayName="Serialize", Category="SenseGlove | Core | Hand Profile")
|
|
static FString SGSerialize(const USGHandProfile* HandProfile);
|
|
}; |