fix a chain of glove and hand-tracking bugs that render the hand-tracking state invalid at certain times
This commit is contained in:
@@ -51,7 +51,7 @@ struct SENSEGLOVESETTINGS_API FSGGloveTrackingSettings
|
||||
|
||||
public:
|
||||
/**
|
||||
* The interval in which the tracking module checks for glove connectivity.
|
||||
* The interval in which the tracking module checks for glove connectivity (in milliseconds).
|
||||
*
|
||||
* The default is 16.666666f which means 60 times per second.
|
||||
*/
|
||||
|
||||
@@ -58,7 +58,7 @@ struct USGGloveTracker::FImpl
|
||||
{
|
||||
const USGSettings* Settings{USGSettings::GetInstance()};
|
||||
ensureAlwaysMsgf(Settings, TEXT("The settings subsystem has not been initialized!"));
|
||||
return Settings->GetTrackingSettings().GloveTrackingSettings.GloveConnectivityCheckInterval;
|
||||
return Settings->GetTrackingSettings().GloveTrackingSettings.GloveConnectivityCheckInterval * 0.001f;
|
||||
}
|
||||
|
||||
/************************
|
||||
@@ -137,7 +137,16 @@ void USGGloveTracker::Initialize(FSubsystemCollectionBase& Collection)
|
||||
Pimpl->GloveConnectivityCheckTimer, GloveConnectivityCheckHandler, GloveConnectivityCheckInterval,
|
||||
true, -1.0f);
|
||||
|
||||
SGLOG("The glove connectivity check timer has been started successfully!");
|
||||
if (ensureAlwaysMsgf(TimerManager.IsTimerActive(Pimpl->GloveConnectivityCheckTimer),
|
||||
TEXT("GloveConnectivityCheckTimer is not active")))
|
||||
{
|
||||
SGLOG("The glove connectivity check timer has been started successfully!");
|
||||
SGLOG("The glove connectivity timer interval is: ", GloveConnectivityCheckInterval);
|
||||
}
|
||||
else
|
||||
{
|
||||
SGLOG_ERROR("The glove connectivity check timer has failed to start!");
|
||||
}
|
||||
}
|
||||
|
||||
SGLOG("The SenseGlove tracking singleton has been successfully initialized with the world lifetime!");
|
||||
|
||||
Reference in New Issue
Block a user