Skip to content

Commit 95db130

Browse files
committed
Add /new /old support for module libs
1 parent 8025f13 commit 95db130

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

SRanipalExtTrackingModule/SRanipalExtTrackingModule.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
<ItemGroup>
2525
<Reference Include="VRCFaceTracking.Core">
26-
<HintPath>..\..\..\..\Downloads\VRCFaceTracking-Next\VRCFaceTracking\bin\x64\Debug\net7.0-windows10.0.19041.0\win10-x64\VRCFaceTracking.Core.dll</HintPath>
26+
<HintPath>..\..\..\..\..\..\Program Files\WindowsApps\96ba052f-0948-44d8-86c4-a0212e4ae047_5.0.1.1_x64__d7rcq4vxghz0r\VRCFaceTracking.Core.dll</HintPath>
2727
</Reference>
2828
</ItemGroup>
2929

SRanipalExtTrackingModule/SRanipalTrackingInterface.cs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,13 @@ public override (bool eyeSuccess, bool expressionSuccess) Initialize(bool eyeAva
3232

3333
// Look for SRanipal assemblies here. Placeholder for unmanaged assemblies not being embedded in the dll.
3434
var currentDllDirectory = System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location);
35-
SetDllDirectory(currentDllDirectory + "\\ModuleLibs");
35+
36+
// Get the currently installed sr_runtime version. If it's above 1.3.6.* then we use ModuleLibs\\New
37+
var srRuntimeVer = FileVersionInfo.GetVersionInfo("C:\\Program Files\\VIVE\\SRanipal\\sr_runtime.exe").FileVersion;
38+
39+
Logger.LogInformation($"SRanipalExtTrackingModule: SRanipal version: {srRuntimeVer}");
40+
41+
SetDllDirectory(currentDllDirectory + "\\ModuleLibs\\" + (srRuntimeVer.StartsWith("1.3.6") ? "New" : "Old"));
3642

3743
Error eyeError = Error.UNDEFINED, lipError = Error.UNDEFINED;
3844

0 commit comments

Comments
 (0)