Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
21b2e3371e
|
||
|
|
9eb818e867
|
||
|
|
fee9657be4
|
||
|
|
c276a6ef40
|
||
|
|
698653c786
|
||
|
|
4688c0690c
|
||
|
|
ca07b6c6a9
|
||
|
|
f1d0d77a13
|
||
|
|
3fd2421446
|
||
|
|
738e1af1f9
|
||
|
|
d7c835ce79
|
||
|
|
a245094c81
|
||
|
|
dc1c3c7f7f
|
||
|
|
1e78c68f1f
|
||
|
|
943f8c59b3
|
||
|
|
4e9c141282
|
||
|
|
4b1caccd10
|
||
|
|
1cc4dab31f
|
||
|
|
76e39c26b6
|
||
|
|
66b8c5e254
|
||
|
|
d1583f97fe
|
||
|
|
5d2abd62b9
|
||
|
|
a66185061f
|
||
|
|
6fb1ccaee5
|
||
|
|
c491c79e27
|
||
|
|
55e9a67592
|
||
|
|
9519d5e49b
|
||
|
|
eaa5fbb1df
|
||
|
|
50a0a81a0b
|
||
|
|
818f926137
|
||
|
|
4453c2b61f
|
||
|
|
fc9a1fc0d7
|
||
|
|
955e5fee9b
|
||
|
|
b33125dbbd
|
||
|
|
8976e4c04d
|
||
|
|
fb7f42ed09
|
||
|
|
93f24493d6
|
||
|
|
0ac79a81a1
|
||
|
|
1363e292cc
|
||
|
|
2fbfbd3067
|
||
|
|
02a88d2977
|
||
|
|
8f50017365
|
||
|
|
b03d8970ab
|
||
|
|
4cc2f8a110
|
||
|
|
98db0e32a5
|
||
|
|
1159fc845a
|
||
|
|
3185d7a6f2
|
||
|
|
de19604e19
|
||
|
|
5fb888346f
|
||
|
|
349b25988c
|
||
|
|
dd7d9e044d
|
||
|
|
7c07a1e709
|
||
|
|
b11a169b64
|
||
|
|
4eb69ea798
|
||
|
|
8896d77b32
|
||
|
|
8f9724b726
|
||
|
|
56131693f0
|
||
|
|
22af36b9ad
|
||
|
|
472c014a5e
|
||
|
|
d6b821903a
|
||
|
|
26f9305364
|
||
|
|
b2a09ca7b8
|
||
|
|
77092ce04c
|
||
|
|
b93ca620b5
|
||
|
|
732894fbe2
|
||
|
|
2ddfaecc0d
|
||
|
|
912b9e0d39
|
||
|
|
ddb368440c
|
||
|
|
579cf55dc4
|
||
|
|
ccd2ac2ad9
|
||
|
|
897394fbf2
|
||
|
|
0849a64a55
|
||
|
|
aca8c4c534
|
||
|
|
90b5a886df
|
||
|
|
1e0501966f
|
||
|
|
18ec23251c
|
||
|
|
c9ef501868
|
||
|
|
4dad555486
|
||
|
|
7a83ad5877
|
||
|
|
708d35fd59
|
||
|
|
d6e53d45bd
|
||
|
|
a4176fbca7
|
||
|
|
ea29e1020e
|
||
|
|
5a697e567e
|
||
|
|
9a40ee4fcd
|
||
|
|
8e945ecb2a
|
||
|
|
c43efc6f59
|
||
|
|
031abc5845
|
||
|
|
1980a8da54
|
||
|
|
b2cd582813
|
||
|
|
5e787278dd
|
||
|
|
66efa0b0de
|
||
|
|
43c41dbdcb
|
||
|
|
4000682362
|
||
|
|
89d1288ec2
|
||
|
|
0a505e3211
|
||
|
|
9dd6b8c096
|
||
|
|
14c026e1ff
|
||
|
|
3adbe0f0ee
|
||
|
|
fb3704f25d
|
||
|
|
8e63d9987e
|
||
|
|
1edd20004c
|
||
|
|
71b0334a60
|
||
|
|
2014f3a035
|
||
|
|
42e210af45
|
||
|
|
7b233c6476
|
||
|
|
93f4f47afe
|
||
|
|
52fc61df7f
|
||
|
|
d027f8564b
|
||
|
|
61e2f6a6ba
|
||
|
|
6e49d38907
|
||
|
|
890378a0df
|
||
|
|
fb2503a8db
|
||
|
|
5b1dd49da2
|
||
|
|
3c49dcf658
|
||
|
|
2d2cef372d
|
||
|
|
56afd24b4b
|
||
|
|
a2465e017b
|
||
|
|
cfef8fa303
|
||
|
|
e788117eaf
|
||
|
|
c020ee8e30
|
||
|
|
b5ecede76f
|
||
|
|
cca67f9967
|
||
|
|
18ce1d32ac
|
||
|
|
8d868c4b4c
|
||
|
|
6102133433
|
||
|
|
70a674b51c
|
||
|
|
b33a0c3a04
|
||
|
|
16abee7e30
|
||
|
|
e978383a7c
|
||
|
|
ace4d935bc
|
||
|
|
d8ce1e41cf
|
||
|
|
139d2ede99
|
||
|
|
1d74105bd3
|
||
|
|
badd49612e
|
||
|
|
ed91c07786
|
||
|
|
45dcf00bfa
|
||
|
|
bbc737100d
|
||
|
|
8bcdbabc8b
|
||
|
|
ade21e02e5
|
||
|
|
6405fb2345
|
||
|
|
3605b5e029
|
||
|
|
8aeda537ab
|
||
|
|
e977af1fd5
|
||
|
|
5823c41576
|
||
|
|
da09d43307
|
||
|
|
456a270bed
|
||
|
|
9c27b51df4
|
||
|
|
330a158f64
|
||
|
|
29fdcc51c7
|
||
|
|
fe58b440a9
|
||
|
|
d962804a49
|
||
|
|
1340bc875c
|
||
|
|
ef8d77043f
|
||
|
|
9ea59a4197
|
||
|
|
75185406da
|
||
|
|
e85488c217
|
||
|
|
a5c441230a
|
||
|
|
c0dc9e4183
|
||
|
|
56f26a3532
|
||
|
|
2882b577e2
|
||
|
|
bcb84edf59
|
||
|
|
672c63b51f
|
||
|
|
02f27b7ac0
|
||
|
|
6c2ff82176
|
||
|
|
7634328e44
|
||
|
|
12daff0a1b
|
||
|
|
18159ec740
|
||
|
|
ba459504e0
|
||
|
|
15b1389fad
|
||
|
|
bb41b195e2
|
||
|
|
528b97390b
|
||
|
|
db38deff27
|
||
|
|
c665b65512
|
||
|
|
1f957a056b
|
||
|
|
3c34c5c493
|
||
|
|
1266ca5feb
|
||
|
|
244d2d91fe
|
||
|
|
f000901b35
|
||
|
|
ad4b527847
|
||
|
|
ebb0b02805
|
||
|
|
8912292f59
|
||
|
|
72f9b35a71
|
||
|
|
9ea132a98a
|
||
|
|
611ea0438a
|
||
|
|
5f95972a05
|
||
|
|
685a200577
|
||
|
|
e0dd8d2ff0
|
||
|
|
8ad01e0be9
|
||
|
|
bed2280b1d
|
||
|
|
ac5da45507
|
||
|
|
769e59cd05
|
||
|
|
88211f903d
|
||
|
|
c11f654996
|
||
|
|
dd4e1d8a00
|
||
|
|
73aee75b9b
|
||
|
|
8659e75e1e
|
||
|
|
ba8e67865e
|
||
|
|
d1b777336c
|
||
|
|
3edc108c89
|
||
|
|
cad7acb96c
|
||
|
|
67b7f689df
|
||
|
|
95e25aca4a
|
||
|
|
0cecc3b1cb
|
||
|
|
1b171ae653
|
||
|
|
ed0949224c
|
||
|
|
602f81f418
|
||
|
|
3d3f6a6211
|
||
|
|
aaad9d1da2
|
||
|
|
e87f343e32
|
||
|
|
ca0956d81b
|
||
|
|
9e36e66c9b
|
||
|
|
368f12482a
|
||
|
|
7ceb338990
|
||
|
|
c47b2a9d32
|
||
|
|
1039990fb1
|
||
|
|
5d45dbe9d9
|
||
|
|
e2d154a01c
|
||
|
|
5b0581277d
|
||
|
|
656ef3c719
|
||
|
|
00d09c1fd1
|
||
|
|
fecf0606a4
|
||
|
|
209c7cce41
|
||
|
|
4c7afbc72c
|
||
|
|
09d8ea15f8
|
||
|
|
f7b6d4142a
|
||
|
|
108cdf44f0
|
||
|
|
193d75f010
|
||
|
|
186fd4238f
|
||
|
|
d9df793987
|
||
|
|
3d6238cf94
|
||
|
|
685f2c4fea
|
||
|
|
5357ae21cf
|
||
|
|
1c9bf84d33
|
||
|
|
5d585c27ec
|
||
|
|
2d1cb0bb8f
|
||
|
|
3b8be231aa
|
||
|
|
f84a744110
|
||
|
|
06cb6a1f8f
|
||
|
|
9f3054ddc0
|
||
|
|
f75863fedc
|
||
|
|
f72c595371
|
||
|
|
9ebc24ebdd
|
||
|
|
f7701cfd92
|
||
|
|
c26f200aa5
|
||
|
|
25b658657c
|
||
|
|
578bbb29a5
|
||
|
|
5e7b127324
|
||
|
|
f31cfc6a34
|
||
|
|
caf92df577
|
||
|
|
cc6679a38c
|
||
|
|
3a8edb6190
|
||
|
|
a5fcd2e567
|
||
|
|
2f2aafea65
|
||
|
|
e951d0c426
|
||
|
|
d4e0b22839
|
||
|
|
e54287ed7e
|
||
|
|
46ea6266a5
|
||
|
|
68f853abad
|
||
|
|
3d3fcd2881
|
||
|
|
2319052306
|
||
|
|
b8aeea558c
|
||
|
|
4680aedd24
|
||
|
|
fbe7236b75
|
||
|
|
61ce2cfc7c
|
||
|
|
ca3594026b
|
||
|
|
d39320e00c
|
||
|
|
d792a57291
|
||
|
|
9ed5cbbbd8
|
||
|
|
1545878a9d
|
||
|
|
8dbfc7ce47
|
||
|
|
e50f85a919
|
||
|
|
58504effbc
|
||
|
|
cebba656fe
|
||
|
|
897fa5c5d3
|
||
|
|
47c7e9d417
|
||
|
|
f52770cd9c
|
||
|
|
66a3381579
|
||
|
|
8d12529554
|
||
|
|
63967b5eb7
|
||
|
|
317092792d
|
||
|
|
b2b0392f9c
|
||
|
|
fcdedeb81f
|
||
|
|
4be10c3e57
|
||
|
|
ca7f51dcfd
|
||
|
|
46ac6fd9d0
|
||
|
|
ac861b0a13
|
||
|
|
a993d877d1
|
||
|
|
dd7bf2686b
|
||
|
|
2aee68dc52
|
||
|
|
533638b1ea
|
||
|
|
a924c02cdb
|
||
|
|
b1da967d41
|
||
|
|
d11ef47931
|
||
|
|
ab035cae2e
|
||
|
|
c07dc2561c
|
||
|
|
4af827a46a
|
||
|
|
8e9f3869b3
|
||
|
|
7a9e54de64
|
||
|
|
5f0a238d7a
|
||
|
|
b0a328289a
|
||
|
|
74499d33e7
|
||
|
|
9e22912a6f
|
||
|
|
14df135d1c
|
||
|
|
3247adc68c
|
||
|
|
733eab9481
|
||
|
|
64f5d3306b
|
||
|
|
07c4fb7334
|
||
|
|
ac8f901c04
|
||
|
|
e3ce3e6060
|
||
|
|
0edd0d257a
|
||
|
|
9b42ffe45f
|
||
|
|
55bd48ed97
|
||
|
|
329aae9638
|
||
|
|
ec315d6fb3
|
||
|
|
2d3f9b73d6
|
||
|
|
82f2873cf2
|
||
|
|
71cdaffd51
|
||
|
|
3716d75eb2
|
||
|
|
176ed9504b
|
||
|
|
028ef2b4d5
|
||
|
|
0e386789e0
|
||
|
|
b7e9126c14
|
||
|
|
4714b478c5
|
||
|
|
c02203d3e3
|
||
|
|
f8969d79b7
|
||
|
|
3ba496aa49
|
||
|
|
3ea3162b01
|
||
|
|
a51e8578f5
|
||
|
|
7c1218adf3
|
||
|
|
d62d7119ed
|
||
|
|
fc2c607cac
|
||
|
|
a10ad6b620
|
||
|
|
a83e4e89de
|
||
|
|
bfc0e0dd56
|
||
|
|
eda3087b51
|
||
|
|
5495444667
|
||
|
|
e4e5f4875f
|
||
|
|
819637efa6
|
||
|
|
280df24671
|
||
|
|
9211a2465b
|
||
|
|
66de2950b4
|
-111
@@ -5,117 +5,6 @@ All notable changes to this project will be documented in this file.
|
||||
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
||||
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||
|
||||
## [1.8.0] - 2023-10-10
|
||||
|
||||
### Added
|
||||
|
||||
- Introduced new SGPawn events: OnActorGrabbed, OnActorReleased, OnActorBeginTouch, and OnActorEndTouch.
|
||||
- Exposed OnGrabStateUpdated, OnTouchStateUpdated, OnActorGrabbed, OnActorReleased, OnActorBeginTouch, and OnActorEndTouch events to Blueprint as BlueprintImplementableEvent.
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fix a bug where the OnTouchStateUpdated event is mistakenly triggered instead of the OnGrabStateUpdated when the right thumb fingertip grab collider overlaps with a grabbable actor.
|
||||
|
||||
## [1.7.0] - 2023-09-14
|
||||
|
||||
### Added
|
||||
|
||||
- Introduce SGGameInstance, a customized SenseGlove game instance for future use.
|
||||
- Added the new SenseGloveBackend and SenseGloveBackendKismet modules.
|
||||
- Added SG_CPP20 C++ macro for C++20 detection, which is now default from UE 5.3 onwards.
|
||||
- Added SG_CAPTURE_THIS C++ macro as a workaround for error C4855: implicit capture of 'this' via '[=]' is deprecated in /std:c++20 in order to build the same lambda captures without extra #ifdefs on all supported engine versions.
|
||||
|
||||
### Changed
|
||||
|
||||
- SenseGlove libraries have been updated to v2.12.0-19c9854.
|
||||
- SGCoreImpl/SGPlatform has been moved to SGBuildHacks/SGPlatform.
|
||||
|
||||
### Fixed
|
||||
|
||||
- Proper initialization of the SenseGlove backend in order to fix a bug in certain situations where SGConnect::Init() gets called every frame.
|
||||
- Some other minor fixes and improvements.
|
||||
|
||||
## [1.6.1] - 2023-08-14
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fix Unreal Engine 5.0 build issues.
|
||||
- Minor documentation fixes.
|
||||
|
||||
## [1.6.0] - 2023-08-14
|
||||
|
||||
### Added
|
||||
|
||||
- Added support for the upcoming Unreal Engine 5.3.
|
||||
- Now, the hand's velocity is applied to grabbed actors after being released from the hand.
|
||||
- Introduce the real hands to the SenseGlove module (SGPawn) API.
|
||||
- Added separation of the virtual and real hand rendering.
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fix the wrong default debug virtual hand gizmo colors when initialized using the default constructor.
|
||||
- Some minor performance fixes and improvements.
|
||||
|
||||
### Changed
|
||||
|
||||
- SenseGlove libraries have been updated to v2.11.0-b775a05.
|
||||
|
||||
## [1.5.3] - 2023-07-19
|
||||
|
||||
This is a hotfix release mostly addressing Android Bluetooth performance issues.
|
||||
|
||||
### Fixed
|
||||
|
||||
- Minor changelog fixes.
|
||||
|
||||
### Changed
|
||||
|
||||
- SenseGlove libraries have been updated to v2.10.1-3b0e7c9.
|
||||
|
||||
## [1.5.2] - 2023-07-19
|
||||
|
||||
This is a hotfix release mostly addressing Android-related issues.
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fix a build issue with Android shipping builds due to sgconnect.jar not getting copied automatically in the AFSProject which is compiled for shipping builds when AndroidFileServer (AFS) is enabled.
|
||||
- Minor changelog fixes and some source code formatting fixes.
|
||||
|
||||
## [1.5.1] - 2023-07-13
|
||||
|
||||
This is a hotfix release addressing a few critical issues introduced by the recent changes.
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fix a wrist tracker bug where left and right hands' wrist trackers are mistakenly tracking the opposite hand's motion source.
|
||||
- Fix a bug where the right hand is not able to do grab or release.
|
||||
|
||||
## [1.5.0] - 2023-06-16
|
||||
|
||||
This release breaks ABI/API compatibility with the previous versions in some areas as documented below.
|
||||
|
||||
### Added
|
||||
|
||||
- Added HTC VIVE Focus 3 positional tracking hardware enum.
|
||||
- Added support for the Meta Quest Pro, HTC VIVE, and HTC VIVE Focus 3 positional tracking hardware.
|
||||
- Added two options to the wrist tracker settings (to the global plugin settings and the overrides in the wrist tracker component) in order to be able to specify a custom motion source for the left and right hands, so that it allows SteamVR-based trackers such as HTC VIVE or HTC VIVE Focus 3 to operate with the SGPawn.
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fix a bug where SteamVR trackers such as HTC VIVE and HTC VIVE Focus 3's wrist orientation and location were not being tracked.
|
||||
|
||||
### Changed
|
||||
|
||||
- Fully refactored the top-level configurations in the settings system into USTRUCTs.
|
||||
- SenseGlove libraries have been updated to v2.10.0-12133ac.
|
||||
|
||||
### Removed
|
||||
|
||||
- Dropped support for the Epic Native Toolchain v19, MSVC v141 (Visual Studio 2017), and thus Unreal Engine 4.27 as it has been marked as deprecated since v1.4.x.
|
||||
- Removed any kind of support for Oculus Touch (Oculus Rift S and Oculus Quest 1) positional tracking hardware, thus the enum as well.
|
||||
- Removed any kind of support for Pico Neo 2 positional tracking hardware, thus the enum as well.
|
||||
- Removed any kind of support for Pico Neo 3 positional tracking hardware, thus the enum as well.
|
||||
|
||||
## [1.4.3] - 2023-06-01
|
||||
|
||||
This is a hotfix release addressing a critical Android crash.
|
||||
|
||||
@@ -13,11 +13,10 @@ This repository relies on Git LFS for storing binary blobs (e.g. third-party lib
|
||||
| **4.24** | ⚠️ v1.0.x | ⚠️ v1.0.x | ❌ | ⚠️ v1.0.x | ❌ | ❌ | ❌ | ⚠️ v1.0.4 |
|
||||
| **4.25** | ⚠️ v1.0.x | ⚠️ v1.0.x | ❌ | ⚠️ v1.0.x | ❌ | ❌ | ❌ | ⚠️ v1.0.4 |
|
||||
| **4.26** | ⚠️ v1.0.x | ⚠️ v1.0.x | ❌ | ⚠️ v1.0.x | ❌ | ❌ | ❌ | ⚠️ v1.0.4 |
|
||||
| **4.27** | ⚠️ v1.4.x | ⚠️ v1.4.x | ⚠️ v1.4.x | ⚠️ v1.4.x | ⚠️ v1.4.x | ⚠️ v1.4.x (r21e) | ⚠️ v1.3.1 | ⚠️ v1.4.3 |
|
||||
| **5.0** | ❌ | ⚠️ v1.6.x | ⚠️ v1.6.x | ⚠️ v1.6.x | ⚠️ v1.6.x | ⚠️ v1.6.x (r21e) | ⚠️ v1.6.1 | ⚠️ v1.6.1 |
|
||||
| **5.1** | ❌ | ✅ v1.8.x | ✅ v1.8.x | ✅ v1.8.x | ✅ v1.8.x | ✅ v1.8.x (r25b) | ✅ v1.8.0 | ✅ v1.8.0 |
|
||||
| **5.2** | ❌ | ✅ v1.8.x | ✅ v1.8.x | ✅ v1.8.x | ✅ v1.8.x | ✅ v1.8.x (r25b) | ✅ v1.8.0 | ✅ v1.8.0 |
|
||||
| **5.3** | ❌ | ✅ v1.8.x | ✅ v1.8.x | ✅ v1.8.x | ✅ v1.8.x | ✅ v1.8.x (r25b) | ✅ v1.8.0 | ✅ v1.8.0 |
|
||||
| **4.27** | ✅ v1.4.x | ✅ v1.4.x | ✅ v1.4.x | ✅ v1.4.x | ✅ v1.4.x | ✅ v1.4.x (r21e) | ⚠️ v1.3.1 | ✅ v1.4.3 |
|
||||
| **5.0** | ❌ | ✅ v1.4.x | ✅ v1.4.x | ✅ v1.4.x | ✅ v1.4.x | ✅ v1.4.x (r21e) | ✅ v1.4.3 | ✅ v1.4.3 |
|
||||
| **5.1** | ❌ | ✅ v1.4.x | ✅ v1.4.x | ✅ v1.4.x | ✅ v1.4.x | ✅ v1.4.x (r25b) | ✅ v1.4.3 | ✅ v1.4.3 |
|
||||
| **5.2** | ❌ | ✅ v1.4.x | ✅ v1.4.x | ✅ v1.4.x | ✅ v1.4.x | ✅ v1.4.x (r25b) | ✅ v1.4.3 | ✅ v1.4.3 |
|
||||
|
||||
* <code>✅</code> Supported
|
||||
* <code>⚠️</code> Not supported by the latest release and might be lacking features
|
||||
@@ -174,6 +173,20 @@ Please note that modules postfixed with **Impl** are intended for interal use an
|
||||
│
|
||||
├── linux
|
||||
│ │
|
||||
│ ├── v19 (UE 4.27 Linux dependencies)
|
||||
│ │ │
|
||||
│ │ ├── aarch64 (dependencies targeting AArch64 Linux architecture)
|
||||
│ │ │ │
|
||||
│ │ │ ├── debug
|
||||
│ │ │ │
|
||||
│ │ │ └── release
|
||||
│ │ │
|
||||
│ │ └── x86-64 (dependencies targeting x86-64 Linux architecture)
|
||||
│ │ │
|
||||
│ │ ├── debug
|
||||
│ │ │
|
||||
│ │ └── release
|
||||
│ │
|
||||
│ ├── v20 (UE 5.0 and 5.1 Linux dependencies)
|
||||
│ │ │
|
||||
│ │ ├── aarch64 (dependencies targeting AArch64 Linux architecture)
|
||||
@@ -188,21 +201,7 @@ Please note that modules postfixed with **Impl** are intended for interal use an
|
||||
│ │ │
|
||||
│ │ └── release
|
||||
│ │
|
||||
│ ├── v21 (UE 5.2 Linux dependencies)
|
||||
│ │ │
|
||||
│ │ ├── aarch64 (dependencies targeting AArch64 Linux architecture)
|
||||
│ │ │ │
|
||||
│ │ │ ├── debug
|
||||
│ │ │ │
|
||||
│ │ │ └── release
|
||||
│ │ │
|
||||
│ │ └── x86-64 (dependencies targeting x86-64 Linux architecture)
|
||||
│ │ │
|
||||
│ │ ├── debug
|
||||
│ │ │
|
||||
│ │ └── release
|
||||
│ │
|
||||
│ └── v22 (UE 5.3 Linux dependencies)
|
||||
│ └── v21 (UE 5.2 Linux dependencies)
|
||||
│ │
|
||||
│ ├── aarch64 (dependencies targeting AArch64 Linux architecture)
|
||||
│ │ │
|
||||
@@ -217,6 +216,12 @@ Please note that modules postfixed with **Impl** are intended for interal use an
|
||||
│ └── release
|
||||
│
|
||||
└── win64
|
||||
│
|
||||
├── msvc141 (Microsoft Visual Studio 2017 dependencies)
|
||||
│ │
|
||||
│ ├── debug
|
||||
│ │
|
||||
│ └── release
|
||||
│
|
||||
├── msvc142 (Microsoft Visual Studio 2019 dependencies)
|
||||
│ │
|
||||
|
||||
+20
-41
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"FileVersion": 3,
|
||||
"Version": 1,
|
||||
"VersionName": "1.8.0",
|
||||
"VersionName": "1.4.3",
|
||||
"FriendlyName": "SenseGlove",
|
||||
"Description": "Integrating the SenseGlove haptic controller into Unreal Engine",
|
||||
"Category": "Virtual Reality",
|
||||
@@ -10,6 +10,7 @@
|
||||
"DocsURL": "https://senseglove.gitlab.io/unreal-blueprint-docs/",
|
||||
"MarketplaceURL": "com.epicgames.launcher://ue/marketplace/product/5e1d408f517b4966a269ec1035de0b9e",
|
||||
"SupportURL": "https://www.senseglove.com/support/",
|
||||
"EngineVersion": "4.27.0",
|
||||
"CanContainContent": true,
|
||||
"IsBetaVersion": false,
|
||||
"IsExperimentalVersion": false,
|
||||
@@ -27,7 +28,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -38,7 +39,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -49,29 +50,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
{
|
||||
"Name": "SenseGloveBackend",
|
||||
"Type": "Runtime",
|
||||
"LoadingPhase": "PreDefault",
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
{
|
||||
"Name": "SenseGloveBackendKismet",
|
||||
"Type": "Runtime",
|
||||
"LoadingPhase": "PreDefault",
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -82,7 +61,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -93,7 +72,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -104,7 +83,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -115,7 +94,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -126,7 +105,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -137,7 +116,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -148,7 +127,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -158,7 +137,7 @@
|
||||
"LoadingPhase": "PostEngineInit",
|
||||
"WhitelistPlatforms": [
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -169,7 +148,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -180,7 +159,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -191,7 +170,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -202,7 +181,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -213,7 +192,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -224,7 +203,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
},
|
||||
@@ -235,7 +214,7 @@
|
||||
"WhitelistPlatforms": [
|
||||
"Android",
|
||||
"Linux",
|
||||
"LinuxArm64",
|
||||
"LinuxAArch64",
|
||||
"Win64"
|
||||
]
|
||||
}
|
||||
|
||||
@@ -45,9 +45,11 @@
|
||||
|
||||
#include "SenseGlove/Animation/SGVirtualHandAnimInstance.h"
|
||||
#include "SenseGlove/Components/SGWristTrackerComponent.h"
|
||||
#include "SGBackend/SGBackend.h"
|
||||
#include "SGConnect/SGConnect.h"
|
||||
#include "SGCore/SGDeviceList.h"
|
||||
#include "SGCore/SGHandPose.h"
|
||||
#include "SGCore/SGHapticGlove.h"
|
||||
#include "SGCore/SGHapticGloveHandProfiles.h"
|
||||
#include "SGDebug/SGDebugVirtualHand.h"
|
||||
#include "SGLog/SGLog.h"
|
||||
|
||||
@@ -121,12 +123,11 @@ struct USGVirtualHandComponent::FImpl
|
||||
USkeleton* GetSkeleton() const;
|
||||
const FReferenceSkeleton& GetRefSkeleton() const;
|
||||
|
||||
bool InitializeBackend() const;
|
||||
bool UninitializeBackend() const;
|
||||
bool CheckGlove() const;
|
||||
|
||||
FORCEINLINE void SetVisibility(const bool bInVisible) const
|
||||
{
|
||||
Owner->SetVisibility(bInVisible, true);
|
||||
}
|
||||
void SetVisibility(bool bInVisible) const;
|
||||
|
||||
void DrawDebugVirtualHand() const;
|
||||
};
|
||||
@@ -209,7 +210,6 @@ USGVirtualHandComponent::USGVirtualHandComponent(const FObjectInitializer& Objec
|
||||
Super::SetAnimClass(USGVirtualHandAnimInstance::StaticClass());
|
||||
|
||||
bRight = true;
|
||||
bHiddenInGameIfNoGloveDetected = false;
|
||||
|
||||
bAutoStopAllHapticsOnEndPlay = true;
|
||||
|
||||
@@ -229,8 +229,9 @@ USGVirtualHandComponent::USGVirtualHandComponent(const FObjectInitializer& Objec
|
||||
RingFingertipTouchSocketName = FName{TEXT("TouchRingFingertip")};
|
||||
PinkyFingertipTouchSocketName = FName{TEXT("TouchPinkyFingertip")};
|
||||
|
||||
bHiddenInGameIfNoGloveDetected = false;
|
||||
|
||||
DebugVirtualHandSettings = FSGDebugVirtualHandSettings{
|
||||
false,
|
||||
ESGDebugVirtualHandDrawingMode::None,
|
||||
FVector(0.5f, 0.5f, 0.5f),
|
||||
FColor(255, 0, 0, 255),
|
||||
@@ -243,6 +244,7 @@ USGVirtualHandComponent::USGVirtualHandComponent(const FObjectInitializer& Objec
|
||||
|
||||
Super::SetSkeletalMesh(nullptr, true);
|
||||
|
||||
bBackendInitialized = false;
|
||||
Glove = nullptr;
|
||||
WristTracker = nullptr;
|
||||
}
|
||||
@@ -304,24 +306,27 @@ void USGVirtualHandComponent::InitializeComponent()
|
||||
Pimpl->SetDefaultMesh();
|
||||
}
|
||||
|
||||
(void) Pimpl->CheckGlove();
|
||||
if (Pimpl->InitializeBackend())
|
||||
{
|
||||
(void) Pimpl->CheckGlove();
|
||||
}
|
||||
}
|
||||
|
||||
void USGVirtualHandComponent::UninitializeComponent()
|
||||
{
|
||||
Super::UninitializeComponent();
|
||||
|
||||
if (IsValid(Glove) && AutoStopsAllHapticsOnEndPlay())
|
||||
{
|
||||
Glove->StopHaptics();
|
||||
}
|
||||
(void) Pimpl->UninitializeBackend();
|
||||
}
|
||||
|
||||
void USGVirtualHandComponent::BeginPlay()
|
||||
{
|
||||
Super::BeginPlay();
|
||||
|
||||
(void) Pimpl->CheckGlove();
|
||||
if (Pimpl->InitializeBackend())
|
||||
{
|
||||
(void) Pimpl->CheckGlove();
|
||||
}
|
||||
}
|
||||
|
||||
void USGVirtualHandComponent::EndPlay(const EEndPlayReason::Type EndPlayReason)
|
||||
@@ -332,6 +337,8 @@ void USGVirtualHandComponent::EndPlay(const EEndPlayReason::Type EndPlayReason)
|
||||
{
|
||||
Glove->StopHaptics();
|
||||
}
|
||||
|
||||
(void) Pimpl->UninitializeBackend();
|
||||
}
|
||||
|
||||
void USGVirtualHandComponent::TickComponent(
|
||||
@@ -608,11 +615,101 @@ const FReferenceSkeleton& USGVirtualHandComponent::FImpl::GetRefSkeleton() const
|
||||
return Mesh->GetRefSkeleton();
|
||||
}
|
||||
|
||||
bool USGVirtualHandComponent::FImpl::InitializeBackend() const
|
||||
{
|
||||
if (!Owner->bBackendInitialized)
|
||||
{
|
||||
#if PLATFORM_ANDROID
|
||||
const int32_t Result = FSGConnect::Init();
|
||||
switch (Result)
|
||||
{
|
||||
case -3:
|
||||
SGLOG_ERROR("An Unexpected error occurred. Please try again.");
|
||||
return false;
|
||||
case -2:
|
||||
SGLOG_ERROR("Device Scanning is already running within a different program.");
|
||||
return false;
|
||||
case -1:
|
||||
SGLOG_ERROR("Device Scanning already being initialized (function called twice in short succession).");
|
||||
return false;
|
||||
case 0:
|
||||
// Do not pollute the logs!
|
||||
//SGLOG_ERROR("Device Scanning is already running within this program.");
|
||||
// We must return here in case there are two virtual hand components are present in the scene.
|
||||
return true;
|
||||
case 1:
|
||||
SGLOG("Successfully started up DeviceScanning from the current program.");
|
||||
break;
|
||||
default:
|
||||
ensureAlwaysMsgf(false, TEXT("Unhandled Init return status code!"));
|
||||
return false;
|
||||
}
|
||||
#endif /* PLATFORM_ANDROID */
|
||||
|
||||
// Ensure that the device list is empty before doing anything.
|
||||
FSGDeviceList::Dispose();
|
||||
FSGDeviceList::Reinitialize();
|
||||
|
||||
// Load the latest hand profiles.
|
||||
FSGHapticGloveHandProfiles::TryLoadingFromDisk();
|
||||
|
||||
Owner->bBackendInitialized = true;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
bool USGVirtualHandComponent::FImpl::UninitializeBackend() const
|
||||
{
|
||||
// NOTE
|
||||
// In Editor builds we should be avoiding dispose, since stopping the game in PIE mode, causes the virtual-hand
|
||||
// to disappear in the editor as the plugin won't be able to retrieve the glove status anymore.
|
||||
#if ! WITH_EDITOR
|
||||
if (Owner->bBackendInitialized)
|
||||
{
|
||||
FSGDeviceList::Dispose();
|
||||
|
||||
#if PLATFORM_ANDROID
|
||||
const int32_t Result = FSGConnect::Dispose();
|
||||
switch (Result)
|
||||
{
|
||||
case -3:
|
||||
SGLOG_ERROR("An Unexpected error occurred. Please try again.");
|
||||
return false;
|
||||
case -2:
|
||||
SGLOG_ERROR("Not allowed to dispose of Device Scanning because this is not the program which started it.");
|
||||
return false;
|
||||
case -1:
|
||||
SGLOG_ERROR("Device Scanning is currently being disposed off. This takes a second or two. (function called twice in short succession).");
|
||||
return false;
|
||||
case 0:
|
||||
SGLOG_ERROR("There is no deviceScanner running from any program, so disposing is skipped.");
|
||||
return false;
|
||||
case 1:
|
||||
SGLOG("Successfully disposed of DeviceScanner resources.");
|
||||
break;
|
||||
default:
|
||||
ensureAlwaysMsgf(false, TEXT("Unhandled Dispose return status code!"));
|
||||
return false;
|
||||
}
|
||||
#endif /* PLATFORM_ANDROID */
|
||||
|
||||
Owner->bBackendInitialized = false;
|
||||
|
||||
return true;
|
||||
}
|
||||
#endif /* ! WITH_EDITOR */
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
bool USGVirtualHandComponent::FImpl::CheckGlove() const
|
||||
{
|
||||
if (!USGBackend::GetInstance()->IsBackendInitialized())
|
||||
if (!Owner->bBackendInitialized)
|
||||
{
|
||||
const bool bSucceeded = USGBackend::GetInstance()->InitializeBackend();
|
||||
const bool bSucceeded = InitializeBackend();
|
||||
if (!bSucceeded)
|
||||
{
|
||||
return false;
|
||||
@@ -661,6 +758,11 @@ bool USGVirtualHandComponent::FImpl::CheckGlove() const
|
||||
return bFoundGlove;
|
||||
}
|
||||
|
||||
void USGVirtualHandComponent::FImpl::SetVisibility(const bool bInVisible) const
|
||||
{
|
||||
Owner->SetVisibility(bInVisible, true);
|
||||
}
|
||||
|
||||
void USGVirtualHandComponent::FImpl::DrawDebugVirtualHand() const
|
||||
{
|
||||
const UWorld* World{Owner->GetWorld()};
|
||||
|
||||
@@ -40,8 +40,10 @@
|
||||
#include "Engine/SkeletalMesh.h"
|
||||
#include "UObject/ConstructorHelpers.h"
|
||||
|
||||
#include "SGBackend/SGBackend.h"
|
||||
#include "SGConnect/SGConnect.h"
|
||||
#include "SGCore/SGDeviceList.h"
|
||||
#include "SGCore/SGHapticGlove.h"
|
||||
#include "SGCore/SGHapticGloveHandProfiles.h"
|
||||
#include "SGDebug/SGDebugGizmo.h"
|
||||
#include "SGLog/SGLog.h"
|
||||
#include "SGSettings/SGSettings.h"
|
||||
@@ -78,9 +80,10 @@ struct USGWristTrackerComponent::FImpl
|
||||
|
||||
bool IsEditor() const;
|
||||
|
||||
bool InitializeBackend() const;
|
||||
bool UninitializeBackend() const;
|
||||
bool CheckGlove() const;
|
||||
|
||||
void UpdateMotionSource() const;
|
||||
void UpdateWristTrackingData() const;
|
||||
void DrawDebugGizmo();
|
||||
};
|
||||
@@ -103,61 +106,165 @@ USGWristTrackerComponent::USGWristTrackerComponent(const FObjectInitializer& Obj
|
||||
SetReceivesDecals(false);
|
||||
SetCanEverAffectNavigation(false);
|
||||
|
||||
SetRight(true);
|
||||
|
||||
bOverridePluginWristTrackingSettings = false;
|
||||
WristTrackingSettings = FSGWristTrackingSettings(
|
||||
ESGPositionalTrackingHardware::None,
|
||||
FVector::ZeroVector,
|
||||
FVector::ZeroVector,
|
||||
FRotator::ZeroRotator,
|
||||
FRotator::ZeroRotator,
|
||||
EControllerHand::Left,
|
||||
EControllerHand::Right,
|
||||
false,
|
||||
FSGDebugGizmoSettings(
|
||||
4.0f, 1.0f,
|
||||
FColor(255, 0, 0, 255),
|
||||
FColor(0, 255, 0, 255),
|
||||
FColor(0, 0, 255, 255),
|
||||
false, 1.1f, 0
|
||||
)
|
||||
bDrawWristTrackerDebugGizmo = false;
|
||||
TrackingHardware = ESGPositionalTrackingHardware::None;
|
||||
TrackingHardwareLocationOffset = FVector::ZeroVector;
|
||||
TrackingHardwareLocationOffset = FVector::ZeroVector;
|
||||
|
||||
bOverridePluginWristTrackingDebugSettings = false;
|
||||
bDrawWristTrackerDebugGizmo = false;
|
||||
WristTrackerDebugGizmoSettings = FSGDebugGizmoSettings(
|
||||
4.0f, 1.0f,
|
||||
FColor(255, 0, 0, 255),
|
||||
FColor(0, 255, 0, 255),
|
||||
FColor(0, 0, 255, 255),
|
||||
false, 1.1f, 0
|
||||
);
|
||||
bDrawWristTrackerDebugGizmo = false;
|
||||
|
||||
bRight = true;
|
||||
|
||||
bBackendInitialized = false;
|
||||
Glove = nullptr;
|
||||
WristLocation = FVector::ZeroVector;
|
||||
WristRotation = FRotator::ZeroRotator;
|
||||
}
|
||||
|
||||
void USGWristTrackerComponent::SetRight(const bool bInRight)
|
||||
void USGWristTrackerComponent::SetRight(const bool bRight)
|
||||
{
|
||||
bRight = bInRight;
|
||||
Pimpl->UpdateMotionSource();
|
||||
SetTrackingSource(bRight ? EControllerHand::Right : EControllerHand::Left);
|
||||
}
|
||||
|
||||
const FSGWristTrackingSettings& USGWristTrackerComponent::GetWristTrackingSettings() const
|
||||
ESGPositionalTrackingHardware USGWristTrackerComponent::GetTrackingHardware() const
|
||||
{
|
||||
if (OverridesPluginWristTrackingSettings())
|
||||
{
|
||||
return WristTrackingSettings;
|
||||
return TrackingHardware;
|
||||
}
|
||||
|
||||
const USGSettings* Settings{USGSettings::GetInstance()};
|
||||
if (!ensureAlwaysMsgf(Settings, TEXT("The settings subsystem has not been initialized!")))
|
||||
{
|
||||
return WristTrackingSettings;
|
||||
}
|
||||
|
||||
return Settings->GetWristTrackingSettings();
|
||||
return USGSettings::GetInstance()->GetTrackingHardware();
|
||||
}
|
||||
|
||||
void USGWristTrackerComponent::SetWristTrackingSettings(const FSGWristTrackingSettings& InWristTrackingSettings)
|
||||
void USGWristTrackerComponent::SetTrackingHardware(const ESGPositionalTrackingHardware InTrackingHardware)
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
OverridesPluginWristTrackingSettings(),
|
||||
TEXT( "Setting WristTrackingSettings is only permitted when bOverridePluginWristTrackingSettings is enabled!"));
|
||||
TEXT( "Setting TrackingHardware is only permitted when bOverridePluginWristTrackingSettings is enabled!"));
|
||||
|
||||
WristTrackingSettings = InWristTrackingSettings;
|
||||
TrackingHardware = InTrackingHardware;
|
||||
}
|
||||
|
||||
const FVector& USGWristTrackerComponent::GetTrackingHardwareLocationOffset() const
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
GetTrackingHardware() == ESGPositionalTrackingHardware::Custom,
|
||||
TEXT( "Getting TrackingHardwareLocationOffset is only permitted when TrackingHardware is set to Custom!"));
|
||||
|
||||
if (OverridesPluginWristTrackingSettings())
|
||||
{
|
||||
return TrackingHardwareLocationOffset;
|
||||
}
|
||||
|
||||
return IsRight()
|
||||
? USGSettings::GetInstance()->GetTrackingHardwareLocationOffsetRightHand()
|
||||
: USGSettings::GetInstance()->GetTrackingHardwareLocationOffsetLeftHand();
|
||||
}
|
||||
|
||||
void USGWristTrackerComponent::SetTrackingHardwareLocationOffset(const FVector& InTrackingHardwareLocationOffset)
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
OverridesPluginWristTrackingSettings(),
|
||||
TEXT(
|
||||
"Setting TrackingHardwareLocationOffset is only permitted when bOverridePluginWristTrackingSettings is enabled!"
|
||||
));
|
||||
|
||||
ensureAlwaysMsgf(
|
||||
GetTrackingHardware() == ESGPositionalTrackingHardware::Custom,
|
||||
TEXT( "Setting TrackingHardwareLocationOffset is only permitted when TrackingHardware is set to Custom!"));
|
||||
|
||||
TrackingHardwareLocationOffset = InTrackingHardwareLocationOffset;
|
||||
}
|
||||
|
||||
const FRotator& USGWristTrackerComponent::GetTrackingHardwareRotationOffset() const
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
GetTrackingHardware() == ESGPositionalTrackingHardware::Custom,
|
||||
TEXT( "Getting TrackingHardwareRotationOffset is only permitted when TrackingHardware is set to Custom!"));
|
||||
|
||||
if (OverridesPluginWristTrackingSettings())
|
||||
{
|
||||
return TrackingHardwareRotationOffset;
|
||||
}
|
||||
|
||||
return IsRight()
|
||||
? USGSettings::GetInstance()->GetTrackingHardwareRotationOffsetRightHand()
|
||||
: USGSettings::GetInstance()->GetTrackingHardwareRotationOffsetLeftHand();
|
||||
}
|
||||
|
||||
void USGWristTrackerComponent::SetTrackingHardwareRotationOffset(const FRotator& InTrackingHardwareRotationOffset)
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
OverridesPluginWristTrackingSettings(),
|
||||
TEXT(
|
||||
"Setting TrackingHardwareRotationOffset is only permitted when bOverridePluginWristTrackingSettings is enabled!"
|
||||
));
|
||||
|
||||
ensureAlwaysMsgf(
|
||||
GetTrackingHardware() == ESGPositionalTrackingHardware::Custom,
|
||||
TEXT("Setting TrackingHardwareRotationOffsetRightHand is only permitted when TrackingHardware is set to Custom!"
|
||||
));
|
||||
|
||||
TrackingHardwareRotationOffset = InTrackingHardwareRotationOffset;
|
||||
}
|
||||
|
||||
bool USGWristTrackerComponent::GetDrawWristTrackerDebugGizmo() const
|
||||
{
|
||||
if (OverridesPluginWristTrackingDebugSettings())
|
||||
{
|
||||
return !!bDrawWristTrackerDebugGizmo;
|
||||
}
|
||||
|
||||
return USGSettings::GetInstance()->GetDrawWristTrackerDebugGizmo();
|
||||
}
|
||||
|
||||
void USGWristTrackerComponent::SetDrawWristTrackerDebugGizmo(const bool bInDrawWristTrackerDebugGizmo)
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
OverridesPluginWristTrackingDebugSettings(),
|
||||
TEXT( "Setting bDrawWristTrackerDebugGizmo is only permitted when bOverridePluginWristTrackingDebugSettings is"
|
||||
" enabled!"));
|
||||
|
||||
bDrawWristTrackerDebugGizmo = bInDrawWristTrackerDebugGizmo;
|
||||
}
|
||||
|
||||
const FSGDebugGizmoSettings& USGWristTrackerComponent::GetWristTrackerDebugGizmoSettings() const
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
GetDrawWristTrackerDebugGizmo(),
|
||||
TEXT("Getting WristTrackerDebugGizmoLength is only permitted when bDrawWristTrackerDebugGizmo is enabled!"));
|
||||
|
||||
if (OverridesPluginWristTrackingDebugSettings())
|
||||
{
|
||||
return WristTrackerDebugGizmoSettings;
|
||||
}
|
||||
|
||||
return USGSettings::GetInstance()->GetWristTrackerDebugGizmoSettings();
|
||||
}
|
||||
|
||||
void USGWristTrackerComponent::SetWristTrackerDebugGizmoSettings(
|
||||
const FSGDebugGizmoSettings& InWristTrackerDebugGizmoSettings)
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
OverridesPluginWristTrackingDebugSettings(),
|
||||
TEXT("Setting WristTrackerDebugGizmoLength is only permitted when bOverridePluginWristTrackingDebugSettings is"
|
||||
" enabled!"));
|
||||
|
||||
ensureAlwaysMsgf(
|
||||
GetDrawWristTrackerDebugGizmo(),
|
||||
TEXT("Setting WristTrackerDebugGizmoLength is only permitted when bDrawWristTrackerDebugGizmo is enabled!"));
|
||||
|
||||
WristTrackerDebugGizmoSettings = InWristTrackerDebugGizmoSettings;
|
||||
}
|
||||
|
||||
#if WITH_EDITOR
|
||||
@@ -179,18 +286,34 @@ void USGWristTrackerComponent::InitializeComponent()
|
||||
{
|
||||
Super::InitializeComponent();
|
||||
|
||||
(void) Pimpl->CheckGlove();
|
||||
if (Pimpl->InitializeBackend())
|
||||
{
|
||||
(void) Pimpl->CheckGlove();
|
||||
}
|
||||
}
|
||||
|
||||
Pimpl->UpdateMotionSource();
|
||||
void USGWristTrackerComponent::UninitializeComponent()
|
||||
{
|
||||
Super::UninitializeComponent();
|
||||
|
||||
(void) Pimpl->UninitializeBackend();
|
||||
}
|
||||
|
||||
void USGWristTrackerComponent::BeginPlay()
|
||||
{
|
||||
Super::BeginPlay();
|
||||
|
||||
(void) Pimpl->CheckGlove();
|
||||
if (Pimpl->InitializeBackend())
|
||||
{
|
||||
(void) Pimpl->CheckGlove();
|
||||
}
|
||||
}
|
||||
|
||||
Pimpl->UpdateMotionSource();
|
||||
void USGWristTrackerComponent::EndPlay(const EEndPlayReason::Type EndPlayReason)
|
||||
{
|
||||
Super::EndPlay(EndPlayReason);
|
||||
|
||||
(void) Pimpl->UninitializeBackend();
|
||||
}
|
||||
|
||||
void USGWristTrackerComponent::TickComponent(
|
||||
@@ -206,7 +329,7 @@ void USGWristTrackerComponent::TickComponent(
|
||||
|
||||
Super::TickComponent(DeltaTime, TickType, ThisTickFunction);
|
||||
|
||||
if (!!WristTrackingSettings.bDrawWristTrackerDebugGizmo)
|
||||
if (GetDrawWristTrackerDebugGizmo())
|
||||
{
|
||||
Pimpl->DrawDebugGizmo();
|
||||
}
|
||||
@@ -239,11 +362,101 @@ bool USGWristTrackerComponent::FImpl::IsEditor() const
|
||||
return false;
|
||||
}
|
||||
|
||||
bool USGWristTrackerComponent::FImpl::InitializeBackend() const
|
||||
{
|
||||
if (!Owner->bBackendInitialized)
|
||||
{
|
||||
#if PLATFORM_ANDROID
|
||||
const int32_t Result = FSGConnect::Init();
|
||||
switch (Result)
|
||||
{
|
||||
case -3:
|
||||
SGLOG_ERROR("An Unexpected error occurred. Please try again.");
|
||||
return false;
|
||||
case -2:
|
||||
SGLOG_ERROR("Device Scanning is already running within a different program.");
|
||||
return false;
|
||||
case -1:
|
||||
SGLOG_ERROR("Device Scanning already being initialized (function called twice in short succession).");
|
||||
return false;
|
||||
case 0:
|
||||
// Do not pollute the logs!
|
||||
//SGLOG_ERROR("Device Scanning is already running within this program.");
|
||||
// We must return here in case two virtual hand components are present in the scene.
|
||||
return true;
|
||||
case 1:
|
||||
SGLOG("Successfully started up DeviceScanning from the current program.");
|
||||
break;
|
||||
default:
|
||||
ensureAlwaysMsgf(false, TEXT("Unhandled Init return status code!"));
|
||||
return false;
|
||||
}
|
||||
#endif /* PLATFORM_ANDROID */
|
||||
|
||||
// Ensure that the device list is empty before doing anything.
|
||||
FSGDeviceList::Dispose();
|
||||
FSGDeviceList::Reinitialize();
|
||||
|
||||
// Load the latest hand profiles.
|
||||
FSGHapticGloveHandProfiles::TryLoadingFromDisk();
|
||||
|
||||
Owner->bBackendInitialized = true;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
bool USGWristTrackerComponent::FImpl::UninitializeBackend() const
|
||||
{
|
||||
// NOTE
|
||||
// In Editor builds we should be avoiding dispose, since stopping the game in PIE mode, causes the virtual-hand
|
||||
// to disappear in the editor as the plugin won't be able to retrieve the glove status anymore.
|
||||
#if ! WITH_EDITOR
|
||||
if (Owner->bBackendInitialized)
|
||||
{
|
||||
FSGDeviceList::Dispose();
|
||||
|
||||
#if PLATFORM_ANDROID
|
||||
const int32_t Result = FSGConnect::Dispose();
|
||||
switch (Result)
|
||||
{
|
||||
case -3:
|
||||
SGLOG_ERROR("An Unexpected error occurred. Please try again.");
|
||||
return false;
|
||||
case -2:
|
||||
SGLOG_ERROR("Not allowed to dispose of Device Scanning because this is not the program which started it.");
|
||||
return false;
|
||||
case -1:
|
||||
SGLOG_ERROR("Device Scanning is currently being disposed off. This takes a second or two. (function called twice in short succession).");
|
||||
return false;
|
||||
case 0:
|
||||
SGLOG_ERROR("There is no deviceScanner running from any program, so disposing is skipped.");
|
||||
return false;
|
||||
case 1:
|
||||
SGLOG("Successfully disposed of DeviceScanner resources.");
|
||||
break;
|
||||
default:
|
||||
ensureAlwaysMsgf(false, TEXT("Unhandled Dispose return status code!"));
|
||||
return false;
|
||||
}
|
||||
#endif /* PLATFORM_ANDROID */
|
||||
|
||||
Owner->bBackendInitialized = false;
|
||||
|
||||
return true;
|
||||
}
|
||||
#endif /* ! WITH_EDITOR */
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
bool USGWristTrackerComponent::FImpl::CheckGlove() const
|
||||
{
|
||||
if (!USGBackend::GetInstance()->IsBackendInitialized())
|
||||
if (!Owner->bBackendInitialized)
|
||||
{
|
||||
const bool bSucceeded = USGBackend::GetInstance()->InitializeBackend();
|
||||
const bool bSucceeded = InitializeBackend();
|
||||
if (!bSucceeded)
|
||||
{
|
||||
return false;
|
||||
@@ -267,16 +480,6 @@ bool USGWristTrackerComponent::FImpl::CheckGlove() const
|
||||
return bFoundGlove;
|
||||
}
|
||||
|
||||
void USGWristTrackerComponent::FImpl::UpdateMotionSource() const
|
||||
{
|
||||
if (GEngine)
|
||||
{
|
||||
Owner->SetTrackingSource(Owner->IsRight()
|
||||
? Owner->GetWristTrackingSettings().RightHandMotionSource
|
||||
: Owner->GetWristTrackingSettings().LeftHandMotionSource);
|
||||
}
|
||||
}
|
||||
|
||||
void USGWristTrackerComponent::FImpl::UpdateWristTrackingData() const
|
||||
{
|
||||
ensureAlwaysMsgf(Owner->Glove, TEXT("Invalid Glove!"));
|
||||
@@ -284,23 +487,15 @@ void USGWristTrackerComponent::FImpl::UpdateWristTrackingData() const
|
||||
FVector TrackerLocation{Owner->GetComponentLocation()};
|
||||
FRotator TrackerRotation{Owner->GetComponentRotation()};
|
||||
|
||||
ESGPositionalTrackingHardware TrackerHardware = Owner->GetWristTrackingSettings().TrackingHardware;
|
||||
ESGPositionalTrackingHardware TrackerHardware = Owner->GetTrackingHardware();
|
||||
if (TrackerHardware == ESGPositionalTrackingHardware::None)
|
||||
{
|
||||
TrackerHardware = ESGPositionalTrackingHardware::Custom;
|
||||
}
|
||||
else if (TrackerHardware == ESGPositionalTrackingHardware::Custom)
|
||||
{
|
||||
if (Owner->IsRight())
|
||||
{
|
||||
TrackerLocation += Owner->GetWristTrackingSettings().TrackingHardwareLocationOffsetRightHand;
|
||||
TrackerRotation += Owner->GetWristTrackingSettings().TrackingHardwareRotationOffsetRightHand;
|
||||
}
|
||||
else
|
||||
{
|
||||
TrackerLocation += Owner->GetWristTrackingSettings().TrackingHardwareLocationOffsetLeftHand;
|
||||
TrackerRotation += Owner->GetWristTrackingSettings().TrackingHardwareRotationOffsetLeftHand;
|
||||
}
|
||||
TrackerLocation += Owner->GetTrackingHardwareLocationOffset();
|
||||
TrackerRotation += Owner->GetTrackingHardwareRotationOffset();
|
||||
}
|
||||
|
||||
FVector NewWristLocation;
|
||||
@@ -342,7 +537,7 @@ void USGWristTrackerComponent::FImpl::DrawDebugGizmo()
|
||||
const UWorld* World{Owner->GetWorld()};
|
||||
const FVector& Location{Owner->GetComponentLocation()};
|
||||
const FRotator& Rotation{Owner->GetComponentRotation()};
|
||||
const FSGDebugGizmoSettings& DebugGizmoSettings{Owner->GetWristTrackingSettings().WristTrackerDebugGizmoSettings};
|
||||
const FSGDebugGizmoSettings& DebugGizmoSettings{Owner->GetWristTrackerDebugGizmoSettings()};
|
||||
|
||||
FSGDebugGizmo::Draw(World, Location, Rotation, DebugGizmoSettings);
|
||||
}
|
||||
|
||||
@@ -1,57 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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
|
||||
*
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
#include "SenseGlove/Engine/SGGameInstance.h"
|
||||
|
||||
#include "SGLog/SGLog.h"
|
||||
|
||||
USGGameInstance::USGGameInstance(const FObjectInitializer& ObjectInitializer)
|
||||
: Super(ObjectInitializer)
|
||||
{
|
||||
}
|
||||
|
||||
void USGGameInstance::Init()
|
||||
{
|
||||
Super::Init();
|
||||
|
||||
SGLOG("Initializing the SenseGlove GameInstance...")
|
||||
}
|
||||
|
||||
void USGGameInstance::Shutdown()
|
||||
{
|
||||
Super::Shutdown();
|
||||
|
||||
SGLOG("Shutting down the SenseGlove GameInstance...")
|
||||
}
|
||||
@@ -33,7 +33,7 @@
|
||||
*/
|
||||
|
||||
|
||||
#include "SenseGlove/GameFramework/SGGameModeBase.h"
|
||||
#include "SenseGlove/GameFramework//SGGameModeBase.h"
|
||||
|
||||
#include "SenseGlove/GameFramework/SGPawn.h"
|
||||
#include "SenseGlove/GameFramework/SGPlayerController.h"
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -48,7 +48,6 @@
|
||||
#include "SenseGlove/GameFramework/SGPawn.h"
|
||||
#include "SenseGlove/Haptics/SGGrabState.h"
|
||||
#include "SenseGlove/Haptics/SGTouchState.h"
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCore/SGBuzzCommand.h"
|
||||
#include "SGCore/SGForceFeedbackCommand.h"
|
||||
#include "SGCore/SGHapticGlove.h"
|
||||
@@ -205,7 +204,7 @@ void ASGPlayerController::BeginPlay()
|
||||
}
|
||||
|
||||
SGPawn->OnGrabStateUpdated().AddWeakLambda(
|
||||
this, [= SG_CAPTURE_THIS](const FSGGrabState& GrabState) -> void
|
||||
this, [=](const FSGGrabState& GrabState) -> void
|
||||
{
|
||||
if (!IsValid(SGPawn))
|
||||
{
|
||||
@@ -236,7 +235,7 @@ void ASGPlayerController::BeginPlay()
|
||||
});
|
||||
|
||||
SGPawn->OnTouchStateUpdated().AddWeakLambda(
|
||||
this, [= SG_CAPTURE_THIS](const FSGTouchState& TouchState) -> void
|
||||
this, [=](const FSGTouchState& TouchState) -> void
|
||||
{
|
||||
Pimpl->UpdateHapticsFeedback(TouchState);
|
||||
});
|
||||
@@ -339,7 +338,7 @@ void ASGPlayerController::FImpl::UpdateHapticsFeedback(const FSGTouchState& Touc
|
||||
Owner->GetWorldTimerManager().ClearTimer(TouchBuzzStopTimer);
|
||||
|
||||
FTimerDelegate TouchBuzzStopHandler;
|
||||
TouchBuzzStopHandler.BindLambda([= SG_CAPTURE_THIS]()-> void
|
||||
TouchBuzzStopHandler.BindLambda([=]()-> void
|
||||
{
|
||||
Glove->SendHaptics(USGBuzzCommand::Off(Owner));
|
||||
});
|
||||
|
||||
@@ -249,7 +249,7 @@ ASGVirtualHandActor::ASGVirtualHandActor(const FObjectInitializer& ObjectInitial
|
||||
|
||||
WristTracker->SetRight(VirtualHand->IsRight());
|
||||
|
||||
GrabState = FSGGrabState(VirtualHand, FVector::Zero(), {}, nullptr, nullptr, nullptr, nullptr);
|
||||
GrabState = FSGGrabState(VirtualHand, nullptr, nullptr, nullptr, nullptr);
|
||||
TouchState = FSGTouchState(VirtualHand, nullptr, nullptr, nullptr, nullptr, nullptr);
|
||||
}
|
||||
|
||||
|
||||
@@ -41,8 +41,6 @@
|
||||
|
||||
FSGGrabState::FSGGrabState()
|
||||
: Hand(nullptr),
|
||||
PreviousHandLocation(FVector::Zero()),
|
||||
HandVelocityHistory{},
|
||||
ActorThumbCanGrab(nullptr),
|
||||
ActorIndexCanGrab(nullptr),
|
||||
ActorMiddleCanGrab(nullptr),
|
||||
@@ -51,15 +49,11 @@ FSGGrabState::FSGGrabState()
|
||||
}
|
||||
|
||||
FSGGrabState::FSGGrabState(USGVirtualHandComponent* InHand,
|
||||
const FVector& InPreviousHandLocation,
|
||||
const TArray<FVector>& InHandVelocityHistory,
|
||||
AActor* InActorThumbCanGrab,
|
||||
AActor* InActorIndexCanGrab,
|
||||
AActor* InActorMiddleCanGrab,
|
||||
AActor* InGrabbedActor)
|
||||
: Hand(InHand),
|
||||
PreviousHandLocation(InPreviousHandLocation),
|
||||
HandVelocityHistory(InHandVelocityHistory),
|
||||
ActorThumbCanGrab(InActorThumbCanGrab),
|
||||
ActorIndexCanGrab(InActorIndexCanGrab),
|
||||
ActorMiddleCanGrab(InActorMiddleCanGrab),
|
||||
|
||||
@@ -84,9 +84,6 @@ private:
|
||||
UPROPERTY(EditAnywhere, Category="SenseGlove", meta=(AllowPrivateAccess="false"))
|
||||
uint8 bRight : 1;
|
||||
|
||||
UPROPERTY(EditAnywhere, Category="SenseGlove", meta=(AllowPrivateAccess="false"))
|
||||
uint8 bHiddenInGameIfNoGloveDetected : 1;
|
||||
|
||||
UPROPERTY(EditAnywhere, Category="SenseGlove | Haptics", meta=(AllowPrivateAccess="false"))
|
||||
uint8 bAutoStopAllHapticsOnEndPlay : 1;
|
||||
|
||||
@@ -124,9 +121,16 @@ private:
|
||||
FName PinkyFingertipTouchSocketName;
|
||||
|
||||
UPROPERTY(EditAnywhere, Category="SenseGlove", meta=(AllowPrivateAccess="false"))
|
||||
uint8 bHiddenInGameIfNoGloveDetected : 1;
|
||||
|
||||
UPROPERTY(EditAnywhere, Category="SenseGlove",
|
||||
meta=(AllowPrivateAccess="false", EditCondition="bDrawDebugVirtualHand", EditConditionHides))
|
||||
FSGDebugVirtualHandSettings DebugVirtualHandSettings;
|
||||
|
||||
private:
|
||||
UPROPERTY(Transient)
|
||||
uint8 bBackendInitialized : 1;
|
||||
|
||||
UPROPERTY(Transient)
|
||||
USGHapticGlove* Glove;
|
||||
|
||||
@@ -146,16 +150,6 @@ public:
|
||||
|
||||
void SetRight(const bool bInRight);
|
||||
|
||||
FORCEINLINE const FName& GetMiddleFingertipTouchSocketName() const
|
||||
{
|
||||
return MiddleFingertipTouchSocketName;
|
||||
}
|
||||
|
||||
FORCEINLINE void SetMiddleFingertipTouchSocketName(const FName& SocketName)
|
||||
{
|
||||
MiddleFingertipTouchSocketName = SocketName;
|
||||
}
|
||||
|
||||
FORCEINLINE bool AutoStopsAllHapticsOnEndPlay() const
|
||||
{
|
||||
return !!bAutoStopAllHapticsOnEndPlay;
|
||||
@@ -163,7 +157,7 @@ public:
|
||||
|
||||
FORCEINLINE void SetAutoStopAllHapticsOnEndPlay(const bool bInAutoStopAllHapticsOnEndPlay)
|
||||
{
|
||||
bAutoStopAllHapticsOnEndPlay = bInAutoStopAllHapticsOnEndPlay;
|
||||
bAutoStopAllHapticsOnEndPlay = bInAutoStopAllHapticsOnEndPlay;
|
||||
}
|
||||
|
||||
FORCEINLINE const FName& GetGrabSocketName() const
|
||||
@@ -231,6 +225,16 @@ public:
|
||||
IndexFingertipTouchSocketName = SocketName;
|
||||
}
|
||||
|
||||
FORCEINLINE const FName& GetMiddleFingertipTouchSocketName() const
|
||||
{
|
||||
return MiddleFingertipTouchSocketName;
|
||||
}
|
||||
|
||||
FORCEINLINE void SetMiddleFingertipTouchSocketName(const FName& SocketName)
|
||||
{
|
||||
MiddleFingertipTouchSocketName = SocketName;
|
||||
}
|
||||
|
||||
FORCEINLINE const FName& GetRingFingertipTouchSocketName() const
|
||||
{
|
||||
return RingFingertipTouchSocketName;
|
||||
@@ -251,21 +255,6 @@ public:
|
||||
PinkyFingertipTouchSocketName = SocketName;
|
||||
}
|
||||
|
||||
FORCEINLINE const FSGDebugVirtualHandSettings& GetDebugVirtualHandSettings() const
|
||||
{
|
||||
return DebugVirtualHandSettings;
|
||||
}
|
||||
|
||||
FORCEINLINE FSGDebugVirtualHandSettings& GetDebugVirtualHandSettings()
|
||||
{
|
||||
return DebugVirtualHandSettings;
|
||||
}
|
||||
|
||||
FORCEINLINE void SetDebugVirtualHandSettings(const FSGDebugVirtualHandSettings& InDebugVirtualHandSettings)
|
||||
{
|
||||
DebugVirtualHandSettings = InDebugVirtualHandSettings;
|
||||
}
|
||||
|
||||
FORCEINLINE bool IsHiddenInGameIfNoGloveDetected() const
|
||||
{
|
||||
return !!bHiddenInGameIfNoGloveDetected;
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
#include "MotionControllerComponent.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGSettings/SGWristTrackingSettings.h"
|
||||
#include "SGSettings/SGDebugGizmoSettings.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
#include "SGWristTrackerComponent.generated.h"
|
||||
@@ -94,23 +94,56 @@ private:
|
||||
FImplDeleter PimplDeleter;
|
||||
|
||||
private:
|
||||
UPROPERTY(EditAnywhere, Category="SenseGlove", meta=(AllowPrivateAccess="false"))
|
||||
uint8 bRight : 1;
|
||||
|
||||
/**
|
||||
* Determines whether to override the plugin's wrist tracking settings or not.
|
||||
*/
|
||||
UPROPERTY(EditAnywhere, Category = "SenseGlove", meta=(AllowPrivateAccess="false"))
|
||||
UPROPERTY(Config, EditAnywhere, Category = "Override Plugin Settings")
|
||||
uint8 bOverridePluginWristTrackingSettings : 1;
|
||||
|
||||
/**
|
||||
* Overrides the plugin's wrist tracking settings.
|
||||
* If set to Custom, any desired location and rotation can be specified.
|
||||
*/
|
||||
UPROPERTY(EditAnywhere, Category = "SenseGlove",
|
||||
meta=(AllowPrivateAccess="false", EditCondition="bOverridePluginWristTrackingSettings", EditConditionHides))
|
||||
FSGWristTrackingSettings WristTrackingSettings;
|
||||
UPROPERTY(Config, EditAnywhere, Category = "Override Plugin Settings",
|
||||
meta=(EditCondition="bOverridePluginWristTrackingSettings", EditConditionHides))
|
||||
ESGPositionalTrackingHardware TrackingHardware;
|
||||
|
||||
/**
|
||||
* Valid only if TrackingHardware is set to Custom.
|
||||
*/
|
||||
UPROPERTY(Config, EditAnywhere, Category = "Override Plugin Settings",
|
||||
meta=(EditCondition=
|
||||
"bOverridePluginWristTrackingSettings && TrackingHardware == ESGPositionalTrackingHardware::Custom",
|
||||
EditConditionHides))
|
||||
FVector TrackingHardwareLocationOffset;
|
||||
|
||||
/**
|
||||
* Valid only if TrackingHardware is set to Custom.
|
||||
*/
|
||||
UPROPERTY(Config, EditAnywhere, Category = "Override Plugin Settings",
|
||||
meta=(EditCondition=
|
||||
"bOverridePluginWristTrackingSettings && TrackingHardware == ESGPositionalTrackingHardware::Custom",
|
||||
EditConditionHides))
|
||||
FRotator TrackingHardwareRotationOffset;
|
||||
|
||||
UPROPERTY(Config, EditAnywhere, Category = "Override Plugin Settings")
|
||||
uint8 bOverridePluginWristTrackingDebugSettings : 1;
|
||||
|
||||
/**
|
||||
* If enabled, draws debug Wrist trackers where possible.
|
||||
*/
|
||||
UPROPERTY(Config, EditAnywhere, Category = "Override Plugin Settings",
|
||||
meta=(EditCondition="bOverridePluginWristTrackingDebugSettings", EditConditionHides))
|
||||
uint8 bDrawWristTrackerDebugGizmo : 1;
|
||||
|
||||
/**
|
||||
* Valid only if bDrawWristTrackerDebugGizmo is enabled.
|
||||
*/
|
||||
UPROPERTY(Config, EditAnywhere, Category = "Override Plugin Settings",
|
||||
meta=(EditCondition="bOverridePluginWristTrackingDebugSettings && bDrawWristTrackerDebugGizmo",
|
||||
EditConditionHides))
|
||||
FSGDebugGizmoSettings WristTrackerDebugGizmoSettings;
|
||||
|
||||
private:
|
||||
UPROPERTY(Transient)
|
||||
uint8 bBackendInitialized : 1;
|
||||
|
||||
UPROPERTY(Transient)
|
||||
USGHapticGlove* Glove;
|
||||
|
||||
@@ -121,18 +154,6 @@ private:
|
||||
FRotator WristRotation;
|
||||
|
||||
public:
|
||||
FORCEINLINE bool IsLeft() const
|
||||
{
|
||||
return !IsRight();
|
||||
}
|
||||
|
||||
FORCEINLINE bool IsRight() const
|
||||
{
|
||||
return !!bRight;
|
||||
}
|
||||
|
||||
void SetRight(const bool bInRight);
|
||||
|
||||
FORCEINLINE bool OverridesPluginWristTrackingSettings() const
|
||||
{
|
||||
return !!bOverridePluginWristTrackingSettings;
|
||||
@@ -143,8 +164,42 @@ public:
|
||||
bOverridePluginWristTrackingSettings = bInOverridePluginWristTrackingSettings;
|
||||
}
|
||||
|
||||
const FSGWristTrackingSettings& GetWristTrackingSettings() const;
|
||||
void SetWristTrackingSettings(const FSGWristTrackingSettings& InWristTrackingSettings);
|
||||
ESGPositionalTrackingHardware GetTrackingHardware() const;
|
||||
void SetTrackingHardware(ESGPositionalTrackingHardware InTrackingHardware);
|
||||
|
||||
const FVector& GetTrackingHardwareLocationOffset() const;
|
||||
void SetTrackingHardwareLocationOffset(const FVector& InTrackingHardwareLocationOffset);
|
||||
|
||||
const FRotator& GetTrackingHardwareRotationOffset() const;
|
||||
void SetTrackingHardwareRotationOffset(const FRotator& InTrackingHardwareRotationOffset);
|
||||
|
||||
FORCEINLINE bool OverridesPluginWristTrackingDebugSettings() const
|
||||
{
|
||||
return !!bOverridePluginWristTrackingDebugSettings;
|
||||
}
|
||||
|
||||
FORCEINLINE void OverridePluginWristTrackingDebugSettings(const bool bInOverridePluginWristTrackingDebugSettings)
|
||||
{
|
||||
bOverridePluginWristTrackingDebugSettings = bInOverridePluginWristTrackingDebugSettings;
|
||||
}
|
||||
|
||||
bool GetDrawWristTrackerDebugGizmo() const;
|
||||
void SetDrawWristTrackerDebugGizmo(bool bInDrawWristTrackerDebugGizmo);
|
||||
|
||||
const FSGDebugGizmoSettings& GetWristTrackerDebugGizmoSettings() const;
|
||||
void SetWristTrackerDebugGizmoSettings(const FSGDebugGizmoSettings& InWristTrackerDebugGizmoSettings);
|
||||
|
||||
FORCEINLINE bool IsLeft() const
|
||||
{
|
||||
return GetTrackingSource() == EControllerHand::Left;
|
||||
}
|
||||
|
||||
FORCEINLINE bool IsRight() const
|
||||
{
|
||||
return GetTrackingSource() == EControllerHand::Right;
|
||||
}
|
||||
|
||||
void SetRight(const bool bRight);
|
||||
|
||||
FORCEINLINE const FVector& GetWristLocation() const
|
||||
{
|
||||
@@ -163,8 +218,12 @@ public:
|
||||
|
||||
virtual void InitializeComponent() override;
|
||||
|
||||
virtual void UninitializeComponent() override;
|
||||
|
||||
virtual void BeginPlay() override;
|
||||
|
||||
virtual void EndPlay(const EEndPlayReason::Type EndPlayReason) override;
|
||||
|
||||
virtual void TickComponent(float DeltaTime,
|
||||
enum ELevelTick TickType,
|
||||
FActorComponentTickFunction* ThisTickFunction) override;
|
||||
|
||||
@@ -1,50 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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 "Engine/GameInstance.h"
|
||||
|
||||
#include "SGGameInstance.generated.h"
|
||||
|
||||
UCLASS(config=Game, Transient, BlueprintType, Blueprintable)
|
||||
class SENSEGLOVE_API USGGameInstance : public UGameInstance
|
||||
{
|
||||
GENERATED_UCLASS_BODY()
|
||||
|
||||
public:
|
||||
virtual void Init() override;
|
||||
virtual void Shutdown() override;
|
||||
};
|
||||
@@ -35,7 +35,6 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "Containers/Array.h"
|
||||
#include "GameFramework/Pawn.h"
|
||||
#include "SenseGlove/Components/SGVirtualHandComponent.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
@@ -58,55 +57,23 @@ class SENSEGLOVE_API ASGPawn : public APawn
|
||||
GENERATED_UCLASS_BODY()
|
||||
|
||||
public:
|
||||
DECLARE_EVENT_OneParam(ASGPawn, FGrabStateUpdatedEvent, const FSGGrabState& GrabState);
|
||||
DECLARE_EVENT_OneParam(ASGVirtualHandActor, FGrabStateUpdatedEvent, const FSGGrabState& GrabState);
|
||||
|
||||
FGrabStateUpdatedEvent& OnGrabStateUpdated()
|
||||
{
|
||||
return GrabStateUpdatedEvent;
|
||||
};
|
||||
|
||||
DECLARE_EVENT_OneParam(ASGPawn, FTouchStateUpdatedEvent, const FSGTouchState& TouchState)
|
||||
DECLARE_EVENT_OneParam(ASGVirtualHandActor, FTouchStateUpdatedEvent, const FSGTouchState& TouchState)
|
||||
|
||||
FTouchStateUpdatedEvent& OnTouchStateUpdated()
|
||||
{
|
||||
return TouchStateUpdatedEvent;
|
||||
};
|
||||
|
||||
DECLARE_EVENT_TwoParams(ASGPawn, FActorGrabbedEvent, const USGVirtualHandComponent* Hand, const AActor* Actor);
|
||||
|
||||
FActorGrabbedEvent& OnGrabbed()
|
||||
{
|
||||
return ActorGrabbedEvent;
|
||||
};
|
||||
|
||||
DECLARE_EVENT_TwoParams(ASGPawn, FActorReleasedEvent, const USGVirtualHandComponent* Hand, const AActor* Actor);
|
||||
|
||||
FActorReleasedEvent& OnReleased()
|
||||
{
|
||||
return ActorReleasedEvent;
|
||||
};
|
||||
|
||||
DECLARE_EVENT_TwoParams(ASGPawn, FActorBeginTouchEvent, const USGVirtualHandComponent* Hand, const AActor* Actor);
|
||||
|
||||
FActorBeginTouchEvent& OnActorBeginTouch()
|
||||
{
|
||||
return ActorBeginTouchEvent;
|
||||
};
|
||||
|
||||
DECLARE_EVENT_TwoParams(ASGPawn, FActorEndTouchEvent, const USGVirtualHandComponent* Hand, const AActor* Actor);
|
||||
|
||||
FActorEndTouchEvent& OnActorEndTouch()
|
||||
{
|
||||
return ActorEndTouchEvent;
|
||||
};
|
||||
|
||||
private:
|
||||
FGrabStateUpdatedEvent GrabStateUpdatedEvent;
|
||||
FTouchStateUpdatedEvent TouchStateUpdatedEvent;
|
||||
FActorGrabbedEvent ActorGrabbedEvent;
|
||||
FActorReleasedEvent ActorReleasedEvent;
|
||||
FActorBeginTouchEvent ActorBeginTouchEvent;
|
||||
FActorEndTouchEvent ActorEndTouchEvent;
|
||||
|
||||
private:
|
||||
struct FImpl;
|
||||
@@ -132,9 +99,6 @@ private:
|
||||
UPROPERTY(VisibleAnywhere, Category="SenseGlove", meta=(AllowPrivateAccess="false"))
|
||||
USGVirtualHandComponent* HandLeft;
|
||||
|
||||
UPROPERTY(VisibleAnywhere, Category="SenseGlove", meta=(AllowPrivateAccess="false"))
|
||||
USGVirtualHandComponent* RealHandLeft;
|
||||
|
||||
UPROPERTY(EditAnywhere, Category="SenseGlove", meta=(AllowPrivateAccess="false"))
|
||||
USphereComponent* LeftThumbFingertipGrabCollider;
|
||||
|
||||
@@ -165,9 +129,6 @@ private:
|
||||
UPROPERTY(VisibleAnywhere, Category="SenseGlove", meta=(AllowPrivateAccess="false"))
|
||||
USGVirtualHandComponent* HandRight;
|
||||
|
||||
UPROPERTY(VisibleAnywhere, Category="SenseGlove", meta=(AllowPrivateAccess="false"))
|
||||
USGVirtualHandComponent* RealHandRight;
|
||||
|
||||
UPROPERTY(EditAnywhere, Category="SenseGlove", meta=(AllowPrivateAccess="false"))
|
||||
USphereComponent* RightThumbFingertipGrabCollider;
|
||||
|
||||
@@ -192,9 +153,6 @@ private:
|
||||
UPROPERTY(EditAnywhere, Category="SenseGlove", meta=(AllowPrivateAccess="false"))
|
||||
USphereComponent* RightPinkyFingertipTouchCollider;
|
||||
|
||||
UPROPERTY(EditAnywhere, Category="SenseGlove", meta=(AllowPrivateAccess="false"))
|
||||
int32 MaxNumberOfHandVelocitySamples;
|
||||
|
||||
private:
|
||||
UPROPERTY(Transient)
|
||||
FSGGrabState LeftHandGrabState;
|
||||
@@ -208,31 +166,6 @@ private:
|
||||
UPROPERTY(Transient)
|
||||
FSGTouchState RightHandTouchState;
|
||||
|
||||
UPROPERTY(Transient)
|
||||
TArray<const AActor*> LeftHandOverlappedActors;
|
||||
|
||||
UPROPERTY(Transient)
|
||||
TArray<const AActor*> RightHandOverlappedActors;
|
||||
|
||||
protected:
|
||||
UFUNCTION(BlueprintImplementableEvent, Category="SenseGlove | Game Framework | Pawn")
|
||||
void OnGrabStateUpdated(const FSGGrabState& GrabState);
|
||||
|
||||
UFUNCTION(BlueprintImplementableEvent, Category="SenseGlove | Game Framework | Pawn")
|
||||
void OnTouchStateUpdated(const FSGTouchState& TouchState);
|
||||
|
||||
UFUNCTION(BlueprintImplementableEvent, Category="SenseGlove | Game Framework | Pawn")
|
||||
void OnActorGrabbed(const USGVirtualHandComponent* Hand, const AActor* Actor);
|
||||
|
||||
UFUNCTION(BlueprintImplementableEvent, Category="SenseGlove | Game Framework | Pawn")
|
||||
void OnActorReleased(const USGVirtualHandComponent* Hand, const AActor* Actor);
|
||||
|
||||
UFUNCTION(BlueprintImplementableEvent, Category="SenseGlove | Game Framework | Pawn")
|
||||
void OnActorBeginTouch(const USGVirtualHandComponent* Hand, const AActor* Actor);
|
||||
|
||||
UFUNCTION(BlueprintImplementableEvent, Category="SenseGlove | Game Framework | Pawn")
|
||||
void OnActorEndTouch(const USGVirtualHandComponent* Hand, const AActor* Actor);
|
||||
|
||||
public:
|
||||
FORCEINLINE UCameraComponent* GetCamera() const
|
||||
{
|
||||
@@ -249,11 +182,6 @@ public:
|
||||
return HandLeft;
|
||||
}
|
||||
|
||||
FORCEINLINE USGVirtualHandComponent* GetRealHandLeft() const
|
||||
{
|
||||
return RealHandLeft;
|
||||
}
|
||||
|
||||
FORCEINLINE USphereComponent* GetLeftThumbFingertipGrabCollider() const
|
||||
{
|
||||
return LeftThumbFingertipGrabCollider;
|
||||
@@ -304,11 +232,6 @@ public:
|
||||
return HandRight;
|
||||
}
|
||||
|
||||
FORCEINLINE USGVirtualHandComponent* GetRealHandRight() const
|
||||
{
|
||||
return RealHandRight;
|
||||
}
|
||||
|
||||
FORCEINLINE USphereComponent* GetRightThumbFingertipGrabCollider() const
|
||||
{
|
||||
return RightThumbFingertipGrabCollider;
|
||||
@@ -349,56 +272,12 @@ public:
|
||||
return RightPinkyFingertipTouchCollider;
|
||||
}
|
||||
|
||||
FORCEINLINE int32 GetMaxNumberOfHandVelocitySamples() const
|
||||
{
|
||||
return MaxNumberOfHandVelocitySamples;
|
||||
}
|
||||
|
||||
FORCEINLINE void SetMaxNumberOfHandVelocitySamples(const int32 InMaxNumberOfHandVelocitySamples)
|
||||
{
|
||||
MaxNumberOfHandVelocitySamples = InMaxNumberOfHandVelocitySamples;
|
||||
}
|
||||
|
||||
public:
|
||||
virtual void BeginPlay() override;
|
||||
virtual void EndPlay(const EEndPlayReason::Type EndPlayReason) override;
|
||||
virtual void Tick(float DeltaSeconds) override;
|
||||
virtual void PreInitializeComponents() override;
|
||||
virtual void PostInitializeComponents() override;
|
||||
|
||||
protected:
|
||||
UFUNCTION()
|
||||
virtual void OnRealLeftHandOverlapBegins(
|
||||
UPrimitiveComponent* OverlappedComponent,
|
||||
AActor* OtherActor,
|
||||
UPrimitiveComponent* OtherComp,
|
||||
int32 OtherBodyIndex,
|
||||
bool bFromSweep,
|
||||
const FHitResult& SweepResult);
|
||||
|
||||
UFUNCTION()
|
||||
virtual void OnRealLeftHandOverlapEnds(
|
||||
UPrimitiveComponent* OverlappedComponent,
|
||||
AActor* OtherActor,
|
||||
UPrimitiveComponent* OtherComp,
|
||||
int32 OtherBodyIndex);
|
||||
|
||||
UFUNCTION()
|
||||
virtual void OnRealRightHandOverlapBegins(
|
||||
UPrimitiveComponent* OverlappedComponent,
|
||||
AActor* OtherActor,
|
||||
UPrimitiveComponent* OtherComp,
|
||||
int32 OtherBodyIndex,
|
||||
bool bFromSweep,
|
||||
const FHitResult& SweepResult);
|
||||
|
||||
UFUNCTION()
|
||||
virtual void OnRealRightHandOverlapEnds(
|
||||
UPrimitiveComponent* OverlappedComponent,
|
||||
AActor* OtherActor,
|
||||
UPrimitiveComponent* OtherComp,
|
||||
int32 OtherBodyIndex);
|
||||
|
||||
UFUNCTION()
|
||||
virtual void OnLeftThumbFingertipGrabColliderOverlapBegins(
|
||||
UPrimitiveComponent* OverlappedComponent,
|
||||
@@ -694,19 +573,19 @@ public:
|
||||
|
||||
FORCEINLINE bool CanGrab(const USGVirtualHandComponent* Hand, const AActor* Actor) const
|
||||
{
|
||||
return Hand == HandRight ? CanRightHandGrab(Actor) : CanLeftHandGrab(Actor);
|
||||
return Hand == HandLeft ? CanLeftHandGrab(Actor) : CanRightHandGrab(Actor);
|
||||
}
|
||||
|
||||
FORCEINLINE bool IsGrabbing(const USGVirtualHandComponent* Hand, const AActor* Actor) const
|
||||
{
|
||||
return Hand == HandRight ? IsRightHandGrabbing(Actor) : IsLeftHandGrabbing(Actor);
|
||||
return Hand == HandLeft ? IsLeftHandGrabbing(Actor) : IsRightHandGrabbing(Actor);
|
||||
}
|
||||
|
||||
bool IsGrabbing(const USGVirtualHandComponent* Hand, AActor*& OutActor) const;
|
||||
|
||||
FORCEINLINE bool IsGrabbing(const USGVirtualHandComponent* Hand) const
|
||||
{
|
||||
return Hand == HandRight ? IsRightHandGrabbing() : IsLeftHandGrabbing();
|
||||
return Hand == HandLeft ? IsLeftHandGrabbing() : IsRightHandGrabbing();
|
||||
}
|
||||
|
||||
public:
|
||||
@@ -728,6 +607,6 @@ public:
|
||||
|
||||
FORCEINLINE void Release(const USGVirtualHandComponent* Hand)
|
||||
{
|
||||
return Hand == HandRight ? ReleaseRight() : ReleaseLeft();
|
||||
return Hand == HandLeft ? ReleaseLeft() : ReleaseRight();
|
||||
}
|
||||
};
|
||||
@@ -35,8 +35,6 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "Containers/Array.h"
|
||||
#include "Math/Vector.h"
|
||||
#include "UObject/ObjectMacros.h"
|
||||
|
||||
#include "SGGrabState.generated.h"
|
||||
@@ -55,12 +53,6 @@ public:
|
||||
UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = "SenseGlove")
|
||||
USGVirtualHandComponent* Hand;
|
||||
|
||||
UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = "SenseGlove")
|
||||
FVector PreviousHandLocation;
|
||||
|
||||
UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = "SenseGlove")
|
||||
TArray<FVector> HandVelocityHistory;
|
||||
|
||||
UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = "SenseGlove")
|
||||
AActor* ActorThumbCanGrab;
|
||||
|
||||
@@ -77,8 +69,6 @@ public:
|
||||
FSGGrabState();
|
||||
|
||||
explicit FSGGrabState(USGVirtualHandComponent* InHand,
|
||||
const FVector& InPreviousHandLocation,
|
||||
const TArray<FVector>& InHandVelocityHistory,
|
||||
AActor* InActorThumbCanGrab,
|
||||
AActor* InActorIndexCanGrab,
|
||||
AActor* InActorMiddleCanGrab,
|
||||
|
||||
@@ -56,8 +56,6 @@ public class SenseGlove : ModuleRules
|
||||
"CoreUObject",
|
||||
"Engine",
|
||||
"HeadMountedDisplay",
|
||||
"InputCore",
|
||||
"SenseGloveBackend",
|
||||
"SenseGloveConnect",
|
||||
"SenseGloveCore",
|
||||
"SenseGloveDebug",
|
||||
@@ -66,12 +64,5 @@ public class SenseGlove : ModuleRules
|
||||
"SenseGloveTypes",
|
||||
}
|
||||
);
|
||||
|
||||
PrivateIncludePathModuleNames.AddRange(
|
||||
new string[]
|
||||
{
|
||||
"SenseGloveBuildHacks",
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -59,30 +59,12 @@
|
||||
<log text="SenseGloveAndroid [WARN]: this architecture is not supported!"/>
|
||||
</false>
|
||||
</if>
|
||||
|
||||
<setBoolFromProperty result="bCreateAFSProject" ini="Engine" section="/Script/AndroidFileServerEditor.AndroidFileServerRuntimeSettings" property="bEnablePlugin" default="true"/>
|
||||
</init>
|
||||
|
||||
<resourceCopies>
|
||||
<copyFile src="$S(PluginDir)/../ThirdParty/android/sgconnect.jar" dst="$S(BuildDir)/gradle/app/libs/sgconnect.jar" />
|
||||
</resourceCopies>
|
||||
|
||||
<gradleCopies>
|
||||
<if condition="bCreateAFSProject">
|
||||
<true>
|
||||
<!-- Also copy into AFSProject -->
|
||||
<!--
|
||||
We have a dependency in the buildGradleAdditions which
|
||||
isn't in the AFSProject which is compiled for shipping
|
||||
builds when AndroidFileServer (AFS) is enabled. To keep
|
||||
the size of the AFS APK small it doesn't automatically
|
||||
copy all the libs over.
|
||||
-->
|
||||
<copyFile src="$S(PluginDir)/../ThirdParty/android/sgconnect.jar" dst="$S(BuildDir)/gradle/AFSProject/app/libs/sgconnect.jar" />
|
||||
</true>
|
||||
</if>
|
||||
</gradleCopies>
|
||||
|
||||
<gradleProperties>
|
||||
<insert>
|
||||
kapt.incremental.apt=true
|
||||
@@ -91,15 +73,18 @@
|
||||
|
||||
<proguardAdditions>
|
||||
<insert>
|
||||
|
||||
<!-- Disable obfuscation for SenseGlove classes -->
|
||||
-dontwarn com.senseglove.**
|
||||
-keep class com.senseglove.** { *; }
|
||||
-keep interface com.senseglove.** { *; }
|
||||
-keep public class com.senseglove.sgconnect.** { public protected *; }
|
||||
|
||||
</insert>
|
||||
</proguardAdditions>
|
||||
|
||||
<androidManifestUpdates>
|
||||
|
||||
<!-- For target SDK 31 update the SplashActivity activity -->
|
||||
<loopElements tag="activity">
|
||||
<setStringFromAttribute result="activityName" tag="$" name="android:name"/>
|
||||
@@ -115,6 +100,7 @@
|
||||
<addPermission android:name="android.permission.BLUETOOTH_ADMIN"/>
|
||||
<addPermission android:name="android.permission.ACCESS_BACKGROUND_LOCATION"/>
|
||||
<addPermission android:name="android.permission.ACCESS_FINE_LOCATION"/>
|
||||
|
||||
</androidManifestUpdates>
|
||||
|
||||
<buildGradleAdditions>
|
||||
@@ -137,6 +123,7 @@
|
||||
dependencies {
|
||||
implementation files('libs/sgconnect.jar')
|
||||
}
|
||||
|
||||
</insert>
|
||||
</buildGradleAdditions>
|
||||
|
||||
|
||||
@@ -1,223 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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
|
||||
*
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
#include "SGBackend/SGBackend.h"
|
||||
|
||||
#include "Engine/Engine.h"
|
||||
|
||||
#include "SGConnect/SGConnect.h"
|
||||
#include "SGCore/SGDeviceList.h"
|
||||
#include "SGCore/SGHapticGloveHandProfiles.h"
|
||||
#include "SGLog/SGLog.h"
|
||||
|
||||
struct USGBackend::FImpl
|
||||
{
|
||||
/************************
|
||||
* Owner object
|
||||
************************/
|
||||
|
||||
USGBackend* Owner;
|
||||
|
||||
/************************
|
||||
* Constructor / Destructor
|
||||
************************/
|
||||
|
||||
explicit FImpl(USGBackend* InOwner);
|
||||
~FImpl();
|
||||
|
||||
/************************
|
||||
* Default copy constructor & copy assignment operator
|
||||
************************/
|
||||
|
||||
FImpl(const FImpl& Rhs) = default;
|
||||
FImpl& operator=(const FImpl& Rhs) = default;
|
||||
};
|
||||
|
||||
USGBackend* USGBackend::GetInstance()
|
||||
{
|
||||
if (!ensureAlwaysMsgf(GEngine, TEXT("The engine has not been initialized!")))
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
USGBackend* Instance{GEngine->GetEngineSubsystem<USGBackend>()};
|
||||
return Instance;
|
||||
}
|
||||
|
||||
USGBackend::USGBackend()
|
||||
: Pimpl(TUniquePtr<FImpl, FImplDeleter>(new FImpl{this}, PimplDeleter))
|
||||
{
|
||||
bBackendInitialized = false;
|
||||
}
|
||||
|
||||
bool USGBackend::InitializeBackend()
|
||||
{
|
||||
if (!IsBackendInitialized())
|
||||
{
|
||||
#if PLATFORM_ANDROID
|
||||
const int32_t Result = FSGConnect::Init();
|
||||
switch (Result)
|
||||
{
|
||||
case -3:
|
||||
SGLOG_ERROR("An Unexpected error occurred. Please try again.");
|
||||
return false;
|
||||
case -2:
|
||||
SGLOG_ERROR("Device Scanning is already running within a different program.");
|
||||
return false;
|
||||
case -1:
|
||||
SGLOG_ERROR("Device Scanning already being initialized (function called twice in short succession).");
|
||||
return false;
|
||||
case 0:
|
||||
SGLOG_ERROR("Device Scanning is already running within this program.");
|
||||
return false;
|
||||
case 1:
|
||||
SGLOG("Successfully started up DeviceScanning from the current program.");
|
||||
break;
|
||||
default:
|
||||
ensureAlwaysMsgf(false, TEXT("Unhandled Init return status code!"));
|
||||
return false;
|
||||
}
|
||||
#endif /* PLATFORM_ANDROID */
|
||||
|
||||
// Ensure that the device list is empty before doing anything.
|
||||
FSGDeviceList::Dispose();
|
||||
FSGDeviceList::Reinitialize();
|
||||
|
||||
// Load the latest hand profiles.
|
||||
FSGHapticGloveHandProfiles::TryLoadingFromDisk();
|
||||
|
||||
bBackendInitialized = true;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
bool USGBackend::UninitializeBackend()
|
||||
{
|
||||
if (IsBackendInitialized())
|
||||
{
|
||||
FSGDeviceList::Dispose();
|
||||
|
||||
#if PLATFORM_ANDROID
|
||||
const int32_t Result = FSGConnect::Dispose();
|
||||
switch (Result)
|
||||
{
|
||||
case -3:
|
||||
SGLOG_ERROR("An Unexpected error occurred. Please try again.");
|
||||
return false;
|
||||
case -2:
|
||||
SGLOG_ERROR("Not allowed to dispose of Device Scanning because this is not the program which started it.");
|
||||
return false;
|
||||
case -1:
|
||||
SGLOG_ERROR("Device Scanning is currently being disposed off. This takes a second or two. (function called twice in short succession).");
|
||||
return false;
|
||||
case 0:
|
||||
SGLOG_ERROR("There is no deviceScanner running from any program, so disposing is skipped.");
|
||||
return false;
|
||||
case 1:
|
||||
SGLOG("Successfully disposed of DeviceScanner resources.");
|
||||
break;
|
||||
default:
|
||||
ensureAlwaysMsgf(false, TEXT("Unhandled Dispose return status code!"));
|
||||
return false;
|
||||
}
|
||||
#endif /* PLATFORM_ANDROID */
|
||||
|
||||
bBackendInitialized = false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
bool USGBackend::ShouldCreateSubsystem(UObject* Outer) const
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
void USGBackend::Initialize(FSubsystemCollectionBase& Collection)
|
||||
{
|
||||
SGLOG("Initializing the SenseGlove Backend singleton with the engine lifetime...");
|
||||
|
||||
Super::Initialize(Collection);
|
||||
|
||||
SGLOG("Initializing the SenseGlove Backend singleton with the engine lifetime...");
|
||||
|
||||
if (InitializeBackend())
|
||||
{
|
||||
SGLOG("The bridge to the SenseGlove Backend has been initialized successfully!")
|
||||
}
|
||||
else
|
||||
{
|
||||
SGLOG_ERROR("Failed to initialize the bridge to the SenseGlove Backend!")
|
||||
}
|
||||
|
||||
SGLOG("The SenseGlove Backend singleton has been successfully initialized with the engine lifetime!");
|
||||
}
|
||||
|
||||
void USGBackend::Deinitialize()
|
||||
{
|
||||
SGLOG("De-initializing the SenseGlove Backend singleton due to the engine lifetime expiration...");
|
||||
|
||||
Super::Deinitialize();
|
||||
|
||||
if (UninitializeBackend())
|
||||
{
|
||||
SGLOG("The bridge to the SenseGlove Backend has been uninitialized successfully!")
|
||||
}
|
||||
else
|
||||
{
|
||||
SGLOG_ERROR("Failed to uninitialize the bridge to the SenseGlove Backend!")
|
||||
}
|
||||
|
||||
(void)Pimpl.Release();
|
||||
|
||||
SGLOG("The SenseGlove Backend singleton has been successfully de-initialized!");
|
||||
}
|
||||
|
||||
USGBackend::FImpl::FImpl(USGBackend* InOwner)
|
||||
: Owner(InOwner)
|
||||
{
|
||||
}
|
||||
|
||||
USGBackend::FImpl::~FImpl() = default;
|
||||
|
||||
void USGBackend::FImplDeleter::operator()(const FImpl* P) const
|
||||
{
|
||||
delete P;
|
||||
}
|
||||
@@ -1,40 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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
|
||||
*
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
#include "SenseGloveBackend.h"
|
||||
#include "Modules/ModuleManager.h"
|
||||
#include "SenseGloveBackendModule.h"
|
||||
|
||||
IMPLEMENT_MODULE(FSenseGloveBackendModule, SenseGloveBackend)
|
||||
@@ -1,38 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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 "CoreMinimal.h"
|
||||
@@ -1,63 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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
|
||||
*
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
#include "SenseGloveBackendModule.h"
|
||||
|
||||
#include "SGLog/SGLog.h"
|
||||
#include "SGBackend/SGBackend.h"
|
||||
|
||||
#define LOCTEXT_NAMESPACE "FSenseGloveBackendModule"
|
||||
|
||||
void FSenseGloveBackendModule::StartupModule()
|
||||
{
|
||||
SGLOG("Starting up SenseGloveBackend module...");
|
||||
}
|
||||
|
||||
void FSenseGloveBackendModule::PreUnloadCallback()
|
||||
{
|
||||
SGLOG("Unloading SenseGloveBackend module...");
|
||||
}
|
||||
|
||||
void FSenseGloveBackendModule::PostLoadCallback()
|
||||
{
|
||||
SGLOG("Loading of SenseGloveBackend module has succeeded!");
|
||||
}
|
||||
|
||||
void FSenseGloveBackendModule::ShutdownModule()
|
||||
{
|
||||
SGLOG("Shutting down SenseGloveBackend module...");
|
||||
}
|
||||
|
||||
#undef LOCTEXT_NAMESPACE
|
||||
@@ -1,51 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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 "Modules/ModuleInterface.h"
|
||||
|
||||
#define LOCTEXT_NAMESPACE "SenseGloveBackend"
|
||||
|
||||
class FSenseGloveBackendModule : public IModuleInterface
|
||||
{
|
||||
public:
|
||||
virtual void StartupModule() override;
|
||||
virtual void PreUnloadCallback() override;
|
||||
virtual void PostLoadCallback() override;
|
||||
virtual void ShutdownModule() override;
|
||||
};
|
||||
|
||||
#undef LOCTEXT_NAMESPACE
|
||||
@@ -1,87 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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 "Math/Color.h"
|
||||
#include "Math/Rotator.h"
|
||||
#include "Math/Vector.h"
|
||||
#include "Subsystems/EngineSubsystem.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
#include "UObject/ObjectMacros.h"
|
||||
|
||||
#include "SGBackend.generated.h"
|
||||
|
||||
UCLASS(config = SenseGloveBackend)
|
||||
class SENSEGLOVEBACKEND_API USGBackend : public UEngineSubsystem
|
||||
{
|
||||
GENERATED_BODY()
|
||||
|
||||
private:
|
||||
UPROPERTY(Transient)
|
||||
uint8 bBackendInitialized : 1;
|
||||
|
||||
public:
|
||||
static USGBackend* GetInstance();
|
||||
|
||||
private:
|
||||
struct FImpl;
|
||||
|
||||
struct FImplDeleter
|
||||
{
|
||||
void operator()(const FImpl* P) const;
|
||||
};
|
||||
|
||||
TUniquePtr<FImpl, FImplDeleter> Pimpl;
|
||||
FImplDeleter PimplDeleter;
|
||||
|
||||
public:
|
||||
USGBackend();
|
||||
|
||||
public:
|
||||
FORCEINLINE bool IsBackendInitialized() const
|
||||
{
|
||||
return !!bBackendInitialized;
|
||||
}
|
||||
|
||||
bool InitializeBackend();
|
||||
bool UninitializeBackend();
|
||||
|
||||
public:
|
||||
virtual bool ShouldCreateSubsystem(UObject* Outer) const override;
|
||||
|
||||
virtual void Initialize(FSubsystemCollectionBase& Collection) override;
|
||||
virtual void Deinitialize() override;
|
||||
};
|
||||
@@ -1,65 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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
|
||||
*
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
using System;
|
||||
using UnrealBuildTool;
|
||||
|
||||
public class SenseGloveBackend : ModuleRules
|
||||
{
|
||||
public SenseGloveBackend(ReadOnlyTargetRules Target) : base(Target)
|
||||
{
|
||||
PCHUsage = ModuleRules.PCHUsageMode.UseExplicitOrSharedPCHs;
|
||||
|
||||
PublicDependencyModuleNames.AddRange(
|
||||
new string[]
|
||||
{
|
||||
"Core",
|
||||
}
|
||||
);
|
||||
|
||||
PrivateDependencyModuleNames.AddRange(
|
||||
new string[]
|
||||
{
|
||||
"CoreUObject",
|
||||
"Engine",
|
||||
"InputCore",
|
||||
"SenseGloveConnect",
|
||||
"SenseGloveCore",
|
||||
"SenseGloveLog",
|
||||
"SenseGloveTypes",
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -1,58 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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
|
||||
*
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
#include "SGBackendKismet/SGBackendKismetLibrary.h"
|
||||
|
||||
#include "SGBackend/SGBackend.h"
|
||||
|
||||
USGBackend* USGBackendKismetLibrary::GetInstance()
|
||||
{
|
||||
return USGBackend::GetInstance();
|
||||
}
|
||||
|
||||
bool USGBackendKismetLibrary::IsBackendInitialized(const USGBackend* Backend)
|
||||
{
|
||||
return Backend->IsBackendInitialized();
|
||||
}
|
||||
|
||||
bool USGBackendKismetLibrary::InitializeBackend(USGBackend* Backend)
|
||||
{
|
||||
return Backend->InitializeBackend();
|
||||
}
|
||||
|
||||
bool USGBackendKismetLibrary::UninitializeBackend(USGBackend* Backend)
|
||||
{
|
||||
return Backend->UninitializeBackend();
|
||||
}
|
||||
@@ -1,40 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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
|
||||
*
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
#include "SenseGloveBackendKismet.h"
|
||||
#include "Modules/ModuleManager.h"
|
||||
#include "SenseGloveBackendKismetModule.h"
|
||||
|
||||
IMPLEMENT_MODULE(FSenseGloveBackendKismetModule, SenseGloveBackendKismet)
|
||||
@@ -1,38 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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 "CoreMinimal.h"
|
||||
@@ -1,62 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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
|
||||
*
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
#include "SenseGloveBackendKismetModule.h"
|
||||
|
||||
#include "SGLog/SGLog.h"
|
||||
|
||||
#define LOCTEXT_NAMESPACE "FSenseGloveBackendKismetModule"
|
||||
|
||||
void FSenseGloveBackendKismetModule::StartupModule()
|
||||
{
|
||||
SGLOG("Starting up SenseGloveBackendKismet module...");
|
||||
}
|
||||
|
||||
void FSenseGloveBackendKismetModule::PreUnloadCallback()
|
||||
{
|
||||
SGLOG("Unloading SenseGloveBackendKismet module...");
|
||||
}
|
||||
|
||||
void FSenseGloveBackendKismetModule::PostLoadCallback()
|
||||
{
|
||||
SGLOG("Loading of SenseGloveBackendKismet module has succeeded!");
|
||||
}
|
||||
|
||||
void FSenseGloveBackendKismetModule::ShutdownModule()
|
||||
{
|
||||
SGLOG("Shutting down SenseGloveBackendKismet module...");
|
||||
}
|
||||
|
||||
#undef LOCTEXT_NAMESPACE
|
||||
@@ -1,51 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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 "Modules/ModuleInterface.h"
|
||||
|
||||
#define LOCTEXT_NAMESPACE "SenseGloveBackendKismet"
|
||||
|
||||
class FSenseGloveBackendKismetModule : public IModuleInterface
|
||||
{
|
||||
public:
|
||||
virtual void StartupModule() override;
|
||||
virtual void PreUnloadCallback() override;
|
||||
virtual void PostLoadCallback() override;
|
||||
virtual void ShutdownModule() override;
|
||||
};
|
||||
|
||||
#undef LOCTEXT_NAMESPACE
|
||||
@@ -1,61 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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 "SGBackendKismetLibrary.generated.h"
|
||||
|
||||
class USGBackend;
|
||||
|
||||
UCLASS(meta=(ScriptName = "SesneGloveBackendKismetLibrary"))
|
||||
class SENSEGLOVEBACKENDKISMET_API USGBackendKismetLibrary final : public USGBlueprintFunctionLibrary
|
||||
{
|
||||
GENERATED_BODY()
|
||||
|
||||
public:
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Backend")
|
||||
static USGBackend* GetInstance();
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Backend")
|
||||
static bool IsBackendInitialized(const USGBackend* Backend);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Backend")
|
||||
bool InitializeBackend(UPARAM(ref) USGBackend* Backend);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Backend")
|
||||
bool UninitializeBackend(UPARAM(ref) USGBackend* Backend);
|
||||
};
|
||||
@@ -1,64 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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
|
||||
*
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
using System;
|
||||
using UnrealBuildTool;
|
||||
|
||||
public class SenseGloveBackendKismet : ModuleRules
|
||||
{
|
||||
public SenseGloveBackendKismet(ReadOnlyTargetRules Target) : base(Target)
|
||||
{
|
||||
PCHUsage = ModuleRules.PCHUsageMode.UseExplicitOrSharedPCHs;
|
||||
|
||||
PublicDependencyModuleNames.AddRange(
|
||||
new string[]
|
||||
{
|
||||
"Core",
|
||||
}
|
||||
);
|
||||
|
||||
PrivateDependencyModuleNames.AddRange(
|
||||
new string[]
|
||||
{
|
||||
"CoreUObject",
|
||||
"Engine",
|
||||
"SenseGloveBackend",
|
||||
"SenseGloveLog",
|
||||
"SenseGloveKismet",
|
||||
"SenseGloveTypes",
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -87,10 +87,10 @@ public class SenseGloveConnectImpl : ModuleRules
|
||||
|
||||
#if UE_5_1_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "r25b"));
|
||||
#elif UE_5_0_OR_LATER
|
||||
#elif UE_4_27_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "r21e"));
|
||||
#else
|
||||
Debug.Assert(false, "Developing for Android on UE versions older than 5.0 is not supported!");
|
||||
Debug.Assert(false, "Developing for Android on UE versions older than 4.27 is not supported!");
|
||||
#endif
|
||||
|
||||
#if UE_5_2_OR_LATER
|
||||
@@ -147,12 +147,12 @@ public class SenseGloveConnectImpl : ModuleRules
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "linux"));
|
||||
LibraryName = string.Format("lib{0}.a", LibraryName);
|
||||
|
||||
#if UE_5_3_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v22"));
|
||||
#elif UE_5_2_OR_LATER
|
||||
#if UE_5_2_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v21"));
|
||||
#elif UE_5_0_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v20"));
|
||||
#elif UE_4_27_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v19"));
|
||||
#else
|
||||
Debug.Assert(false, "Unsupported engine version or compiler!");
|
||||
#endif
|
||||
@@ -168,12 +168,12 @@ public class SenseGloveConnectImpl : ModuleRules
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "linux"));
|
||||
LibraryName = string.Format("lib{0}.a", LibraryName);
|
||||
|
||||
#if UE_5_3_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v22"));
|
||||
#elif UE_5_2_OR_LATER
|
||||
#if UE_5_2_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v21"));
|
||||
#elif UE_5_0_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v20"));
|
||||
#elif UE_4_27_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v19"));
|
||||
#else
|
||||
Debug.Assert(false, "Unsupported engine version or compiler!");
|
||||
#endif
|
||||
@@ -185,13 +185,18 @@ public class SenseGloveConnectImpl : ModuleRules
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "win64"));
|
||||
switch (Target.WindowsPlatform.Compiler)
|
||||
{
|
||||
#if UE_5_0_OR_LATER
|
||||
#if UE_4_27_OR_LATER
|
||||
case WindowsCompiler.VisualStudio2022:
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "msvc143"));
|
||||
break;
|
||||
case WindowsCompiler.VisualStudio2019:
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "msvc142"));
|
||||
break;
|
||||
#endif
|
||||
#if ! UE_5_0_OR_LATER && UE_4_27_OR_LATER
|
||||
case WindowsCompiler.VisualStudio2017:
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "msvc141"));
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
Debug.Assert(false, "Unsupported engine version or compiler!");
|
||||
@@ -236,10 +241,10 @@ public class SenseGloveConnectImpl : ModuleRules
|
||||
|
||||
#if UE_5_1_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "r25b"));
|
||||
#elif UE_4_5_OR_LATER
|
||||
#elif UE_4_27_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "r21e"));
|
||||
#else
|
||||
Debug.Assert(false, "Developing for Android on UE versions older than 5.0 is not supported!");
|
||||
Debug.Assert(false, "Developing for Android on UE versions older than 4.27 is not supported!");
|
||||
#endif
|
||||
|
||||
#if UE_5_2_OR_LATER
|
||||
@@ -296,12 +301,12 @@ public class SenseGloveConnectImpl : ModuleRules
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "linux"));
|
||||
LibraryName = string.Format("lib{0}.a", LibraryName);
|
||||
|
||||
#if UE_5_3_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v22"));
|
||||
#elif UE_5_2_OR_LATER
|
||||
#if UE_5_2_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v21"));
|
||||
#elif UE_5_0_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v20"));
|
||||
#elif UE_4_27_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v19"));
|
||||
#else
|
||||
Debug.Assert(false, "Unsupported engine version or compiler!");
|
||||
#endif
|
||||
@@ -317,12 +322,12 @@ public class SenseGloveConnectImpl : ModuleRules
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "linux"));
|
||||
LibraryName = string.Format("lib{0}.a", LibraryName);
|
||||
|
||||
#if UE_5_3_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v22"));
|
||||
#elif UE_5_2_OR_LATER
|
||||
#if UE_5_2_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v21"));
|
||||
#elif UE_5_0_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v20"));
|
||||
#elif UE_4_27_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v19"));
|
||||
#else
|
||||
Debug.Assert(false, "Unsupported engine version or compiler!");
|
||||
#endif
|
||||
@@ -334,13 +339,18 @@ public class SenseGloveConnectImpl : ModuleRules
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "win64"));
|
||||
switch (Target.WindowsPlatform.Compiler)
|
||||
{
|
||||
#if UE_5_0_OR_LATER
|
||||
#if UE_4_27_OR_LATER
|
||||
case WindowsCompiler.VisualStudio2022:
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "msvc143"));
|
||||
break;
|
||||
case WindowsCompiler.VisualStudio2019:
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "msvc142"));
|
||||
break;
|
||||
#endif
|
||||
#if ! UE_5_0_OR_LATER && UE_4_27_OR_LATER
|
||||
case WindowsCompiler.VisualStudio2017:
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "msvc141"));
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
Debug.Assert(false, "Unsupported engine version or compiler!");
|
||||
|
||||
@@ -63,10 +63,9 @@ public class SenseGloveCore : ModuleRules
|
||||
}
|
||||
);
|
||||
|
||||
PrivateIncludePathModuleNames.AddRange(
|
||||
PublicIncludePathModuleNames.AddRange(
|
||||
new string[]
|
||||
{
|
||||
"SenseGloveBuildHacks",
|
||||
"SenseGloveTypes",
|
||||
}
|
||||
);
|
||||
|
||||
@@ -42,7 +42,6 @@
|
||||
#include "Runtime/Launch/Resources/Version.h"
|
||||
|
||||
#include "SGBuildHacks/SGInclude_Core_BasicHandModel.h"
|
||||
#include "SGBuildHacks/SGInclude_Core_Quat.h"
|
||||
#include "SGBuildHacks/SGInclude_Core_Vect3D.h"
|
||||
#include "SGCoreImpl/SGCoreEnumCast.h"
|
||||
#include "SGCoreImpl/SGQuatImpl.h"
|
||||
|
||||
@@ -313,12 +313,14 @@ FSGCoreEnumCast::FEPositionalTrackingHardware FSGCoreEnumCast::ToEPositionalTrac
|
||||
return FEPositionalTrackingHardware::Custom;
|
||||
case ESGPositionalTrackingHardware::ViveTracker:
|
||||
return FEPositionalTrackingHardware::ViveTracker;
|
||||
case ESGPositionalTrackingHardware::OculusTouch:
|
||||
return FEPositionalTrackingHardware::OculusTouch;
|
||||
case ESGPositionalTrackingHardware::Quest2Controller:
|
||||
return FEPositionalTrackingHardware::Quest2Controller;
|
||||
case ESGPositionalTrackingHardware::ViveFocus3WristTracker:
|
||||
return FEPositionalTrackingHardware::ViveFocus3WristTracker;
|
||||
case ESGPositionalTrackingHardware::QuestProController:
|
||||
return FEPositionalTrackingHardware::QuestProController;
|
||||
case ESGPositionalTrackingHardware::PicoNeo2:
|
||||
return FEPositionalTrackingHardware::PicoNeo2;
|
||||
case ESGPositionalTrackingHardware::PicoNeo3:
|
||||
return FEPositionalTrackingHardware::PicoNeo3;
|
||||
default:
|
||||
ensureAlwaysMsgf(false, TEXT("Unhandled enum cast item!"));
|
||||
break;
|
||||
@@ -336,12 +338,14 @@ ESGPositionalTrackingHardware FSGCoreEnumCast::ToESGPositionalTrackingHardware(c
|
||||
return ESGPositionalTrackingHardware::Custom;
|
||||
case FEPositionalTrackingHardware::ViveTracker:
|
||||
return ESGPositionalTrackingHardware::ViveTracker;
|
||||
case FEPositionalTrackingHardware::OculusTouch:
|
||||
return ESGPositionalTrackingHardware::OculusTouch;
|
||||
case FEPositionalTrackingHardware::Quest2Controller:
|
||||
return ESGPositionalTrackingHardware::Quest2Controller;
|
||||
case FEPositionalTrackingHardware::ViveFocus3WristTracker:
|
||||
return ESGPositionalTrackingHardware::ViveFocus3WristTracker;
|
||||
case FEPositionalTrackingHardware::QuestProController:
|
||||
return ESGPositionalTrackingHardware::QuestProController;
|
||||
case FEPositionalTrackingHardware::PicoNeo2:
|
||||
return ESGPositionalTrackingHardware::PicoNeo2;
|
||||
case FEPositionalTrackingHardware::PicoNeo3:
|
||||
return ESGPositionalTrackingHardware::PicoNeo3;
|
||||
default:
|
||||
ensureAlwaysMsgf(false, TEXT("Unhandled enum cast item!"));
|
||||
break;
|
||||
|
||||
@@ -43,7 +43,6 @@
|
||||
|
||||
#include "SGBuildHacks/SGInclude_Core_Quat.h"
|
||||
#include "SGBuildHacks/SGInclude_Core_HandInterpolator.h"
|
||||
#include "SGBuildHacks/SGInclude_Core_InterpolationSet.h"
|
||||
#include "SGBuildHacks/SGInclude_Core_Vect3D.h"
|
||||
#include "SGCoreImpl/SGCoreEnumCast.h"
|
||||
#include "SGCoreImpl/SGInterpolationSetImpl.h"
|
||||
|
||||
+1
-1
@@ -33,4 +33,4 @@
|
||||
*/
|
||||
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
@@ -40,7 +40,7 @@
|
||||
#include "Math/Vector.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
class FSGVect3DImpl;
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
#include "Math/Vector.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
namespace SGCore
|
||||
{
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
#include "Math/Vector.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
namespace SGCore
|
||||
|
||||
@@ -43,8 +43,8 @@
|
||||
#include "Templates/SharedPointer.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGDeviceImpl.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
namespace SGCore
|
||||
|
||||
@@ -39,8 +39,8 @@
|
||||
#include "Templates/SharedPointer.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGFingerCommandImpl.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
namespace SGCore
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
#include "Containers/UnrealString.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
namespace SGCore
|
||||
{
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
#include "Templates/SharedPointer.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
namespace SGCore
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
#include "Containers/UnrealString.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
namespace SGCore
|
||||
{
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
#include "Templates/SharedPointer.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
namespace SGCore
|
||||
{
|
||||
|
||||
@@ -39,8 +39,8 @@
|
||||
#include "Templates/SharedPointer.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGFingerCommandImpl.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
namespace SGCore
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
#include "Math/Vector.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
class FSGInterpolationSetImpl;
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
#include "Containers/UnrealString.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
class FSGHandInterpolatorImpl;
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
#include "Containers/UnrealString.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
class FSGHandInterpolatorImpl;
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
#include "Math/Vector.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
namespace SGCore
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGCoreImpl/SGHapticGloveCalibrationSequenceImpl.h"
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
namespace SGCore
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
#include "Containers/Array.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
namespace SGCore
|
||||
{
|
||||
|
||||
@@ -44,8 +44,8 @@
|
||||
#include "Templates/SharedPointer.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGDeviceImpl.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
namespace SGCore
|
||||
|
||||
@@ -39,8 +39,8 @@
|
||||
#include "Math/Vector.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGHapticGloveCalibrationSequenceImpl.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
namespace SGCore
|
||||
{
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
#include "Containers/UnrealString.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
namespace SGCore
|
||||
{
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
#include "Containers/UnrealString.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
class FSGHandInterpolatorImpl;
|
||||
|
||||
|
||||
@@ -44,8 +44,8 @@
|
||||
#include "Templates/SharedPointer.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGHapticGloveImpl.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
namespace SGCore
|
||||
{
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
#include "Containers/UnrealString.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
namespace SGCore
|
||||
{
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
#include "Math/Vector.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
namespace SGCore
|
||||
{
|
||||
|
||||
+3
-15
@@ -41,20 +41,8 @@
|
||||
#define SG_CPP17 0
|
||||
#endif /* ( ( defined( _MSVC_LANG ) && _MSVC_LANG >= 201703L ) || __cplusplus >= 201703L ) */
|
||||
|
||||
#if ( ( defined( _MSVC_LANG ) && _MSVC_LANG >= 202002L ) || __cplusplus >= 202002L )
|
||||
#define SG_CPP20 1
|
||||
#else /* ( ( defined( _MSVC_LANG ) && _MSVC_LANG >= 202002L ) || __cplusplus >= 202002L ) */
|
||||
#define SG_CPP20 0
|
||||
#endif /* ( ( defined( _MSVC_LANG ) && _MSVC_LANG >= 202002L ) || __cplusplus >= 202002L ) */
|
||||
|
||||
#if SG_CPP17 || SG_CPP20
|
||||
#if SG_CPP17
|
||||
#define SG_NOEXCEPT noexcept
|
||||
#else /* SG_CPP17 || SG_CPP20 */
|
||||
#else /* SG_CPP17 */
|
||||
#define SG_NOEXCEPT
|
||||
#endif /* SG_CPP17 || SG_CPP20 */
|
||||
|
||||
#if SG_CPP20
|
||||
#define SG_CAPTURE_THIS , this
|
||||
#else /* SG_CPP17 || SG_CPP20 */
|
||||
#define SG_CAPTURE_THIS
|
||||
#endif /* SG_CPP17 || SG_CPP20 */
|
||||
#endif /* SG_CPP17 */
|
||||
@@ -39,7 +39,7 @@
|
||||
#include "Math/Vector.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
class FSGHandInterpolatorImpl;
|
||||
|
||||
@@ -44,8 +44,8 @@
|
||||
#include "Templates/SharedPointer.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGHapticGloveImpl.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
namespace SGCore
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
#include "Math/Vector.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
namespace SGCore
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
#include "Math/Vector.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
namespace SGCore
|
||||
{
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
#include "Containers/UnrealString.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
namespace SGCore
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
#include "Math/Vector.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
namespace SGCore
|
||||
{
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
#include "HAL/Platform.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
namespace SGCore
|
||||
{
|
||||
|
||||
@@ -40,8 +40,8 @@
|
||||
#include "Templates/SharedPointer.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGBuzzCommandImpl.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
namespace SGCore
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
#include "HAL/Platform.h"
|
||||
#include "Templates/UniquePtr.h"
|
||||
|
||||
#include "SGBuildHacks/SGPlatform.h"
|
||||
#include "SGCoreImpl/SGPlatform.h"
|
||||
|
||||
namespace SGCore
|
||||
{
|
||||
|
||||
@@ -58,6 +58,7 @@ public class SenseGloveCoreImpl : ModuleRules
|
||||
PrivateDependencyModuleNames.AddRange(
|
||||
new string[]
|
||||
{
|
||||
"SenseGloveBuildHacks",
|
||||
"SenseGloveInterop",
|
||||
"SenseGloveLog",
|
||||
"SenseGloveTypes",
|
||||
@@ -65,13 +66,6 @@ public class SenseGloveCoreImpl : ModuleRules
|
||||
}
|
||||
);
|
||||
|
||||
PrivateIncludePathModuleNames.AddRange(
|
||||
new string[]
|
||||
{
|
||||
"SenseGloveBuildHacks",
|
||||
}
|
||||
);
|
||||
|
||||
AddCoreLibrary(Target);
|
||||
|
||||
PublicDefinitions.Add("SENSEGLOVE_BUILDING_CORE_IMPL_MODULE");
|
||||
@@ -92,10 +86,10 @@ public class SenseGloveCoreImpl : ModuleRules
|
||||
|
||||
#if UE_5_1_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "r25b"));
|
||||
#elif UE_5_0_OR_LATER
|
||||
#elif UE_4_27_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "r21e"));
|
||||
#else
|
||||
Debug.Assert(false, "Developing for Android on UE versions older than 5.0 is not supported!");
|
||||
Debug.Assert(false, "Developing for Android on UE versions older than 4.27 is not supported!");
|
||||
#endif
|
||||
|
||||
#if UE_5_2_OR_LATER
|
||||
@@ -152,12 +146,12 @@ public class SenseGloveCoreImpl : ModuleRules
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "linux"));
|
||||
LibraryName = string.Format("lib{0}.a", LibraryName);
|
||||
|
||||
#if UE_5_3_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v22"));
|
||||
#elif UE_5_2_OR_LATER
|
||||
#if UE_5_2_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v21"));
|
||||
#elif UE_5_0_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v20"));
|
||||
#elif UE_4_27_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v19"));
|
||||
#else
|
||||
Debug.Assert(false, "Unsupported engine version or compiler!");
|
||||
#endif
|
||||
@@ -173,12 +167,12 @@ public class SenseGloveCoreImpl : ModuleRules
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "linux"));
|
||||
LibraryName = string.Format("lib{0}.a", LibraryName);
|
||||
|
||||
#if UE_5_3_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v22"));
|
||||
#elif UE_5_2_OR_LATER
|
||||
#if UE_5_2_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v21"));
|
||||
#elif UE_5_0_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v20"));
|
||||
#elif UE_4_27_OR_LATER
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "v19"));
|
||||
#else
|
||||
Debug.Assert(false, "Unsupported engine version or compiler!");
|
||||
#endif
|
||||
@@ -190,13 +184,18 @@ public class SenseGloveCoreImpl : ModuleRules
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "win64"));
|
||||
switch (Target.WindowsPlatform.Compiler)
|
||||
{
|
||||
#if UE_5_0_OR_LATER
|
||||
#if UE_4_27_OR_LATER
|
||||
case WindowsCompiler.VisualStudio2022:
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "msvc143"));
|
||||
break;
|
||||
case WindowsCompiler.VisualStudio2019:
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "msvc142"));
|
||||
break;
|
||||
#endif
|
||||
#if ! UE_5_0_OR_LATER && UE_4_27_OR_LATER
|
||||
case WindowsCompiler.VisualStudio2017:
|
||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "msvc141"));
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
Debug.Assert(false, "Unsupported engine version or compiler!");
|
||||
|
||||
@@ -60,9 +60,8 @@ public class SenseGloveInterop : ModuleRules
|
||||
PrivateIncludePathModuleNames.AddRange(
|
||||
new string[]
|
||||
{
|
||||
"SenseGloveBuildHacks",
|
||||
"SenseGloveCoreImpl",
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -57,11 +57,6 @@ USGVirtualHandComponent* UPawnKismetLibrary::GetHandLeft(const ASGPawn* Pawn)
|
||||
return Pawn->GetHandLeft();
|
||||
}
|
||||
|
||||
USGVirtualHandComponent* UPawnKismetLibrary::GetRealHandLeft(const ASGPawn* Pawn)
|
||||
{
|
||||
return Pawn->GetHandLeft();
|
||||
}
|
||||
|
||||
USphereComponent* UPawnKismetLibrary::GetLeftThumbFingertipGrabCollider(const ASGPawn* Pawn)
|
||||
{
|
||||
return Pawn->GetLeftThumbFingertipGrabCollider();
|
||||
@@ -112,11 +107,6 @@ USGVirtualHandComponent* UPawnKismetLibrary::GetHandRight(const ASGPawn* Pawn)
|
||||
return Pawn->GetHandRight();
|
||||
}
|
||||
|
||||
USGVirtualHandComponent* UPawnKismetLibrary::GetRealHandRight(const ASGPawn* Pawn)
|
||||
{
|
||||
return Pawn->GetRealHandRight();
|
||||
}
|
||||
|
||||
USphereComponent* UPawnKismetLibrary::GetRightThumbFingertipGrabCollider(const ASGPawn* Pawn)
|
||||
{
|
||||
return Pawn->GetRightThumbFingertipGrabCollider();
|
||||
|
||||
@@ -72,32 +72,20 @@ bool UVirtualHandComponentKismetLibrary::IsRight(const USGVirtualHandComponent*
|
||||
return VirtualHandComponent->IsRight();
|
||||
}
|
||||
|
||||
void UVirtualHandComponentKismetLibrary::SetRight(
|
||||
USGVirtualHandComponent* VirtualHandComponent, const bool bInRight)
|
||||
void UVirtualHandComponentKismetLibrary::SetRight(USGVirtualHandComponent* VirtualHandComponent,
|
||||
const bool bInRight)
|
||||
{
|
||||
VirtualHandComponent->SetRight(bInRight);
|
||||
}
|
||||
|
||||
bool UVirtualHandComponentKismetLibrary::IsHiddenInGameIfNoGloveDetected(
|
||||
const USGVirtualHandComponent* VirtualHandComponent)
|
||||
{
|
||||
return VirtualHandComponent->IsHiddenInGameIfNoGloveDetected();
|
||||
}
|
||||
|
||||
void UVirtualHandComponentKismetLibrary::SetHiddenIfNoGloveDetected(
|
||||
USGVirtualHandComponent* VirtualHandComponent, const bool bInHiddenIfNoGloveDetected)
|
||||
{
|
||||
VirtualHandComponent->SetHiddenIfNoGloveDetected(bInHiddenIfNoGloveDetected);
|
||||
}
|
||||
|
||||
bool UVirtualHandComponentKismetLibrary::AutoStopsAllHapticsOnEndPlay(
|
||||
const USGVirtualHandComponent* VirtualHandComponent)
|
||||
{
|
||||
return VirtualHandComponent->AutoStopsAllHapticsOnEndPlay();
|
||||
}
|
||||
|
||||
void UVirtualHandComponentKismetLibrary::SetAutoStopAllHapticsOnEndPlay(
|
||||
USGVirtualHandComponent* VirtualHandComponent, const bool bInAutoStopAllHapticsOnEndPlay)
|
||||
void UVirtualHandComponentKismetLibrary::SetAutoStopAllHapticsOnEndPlay(USGVirtualHandComponent* VirtualHandComponent,
|
||||
const bool bInAutoStopAllHapticsOnEndPlay)
|
||||
{
|
||||
VirtualHandComponent->SetAutoStopAllHapticsOnEndPlay(bInAutoStopAllHapticsOnEndPlay);
|
||||
}
|
||||
@@ -119,8 +107,8 @@ const FName& UVirtualHandComponentKismetLibrary::GetThumbFingertipGrabSocketName
|
||||
return VirtualHandComponent->GetThumbFingertipGrabSocketName();
|
||||
}
|
||||
|
||||
void UVirtualHandComponentKismetLibrary::SetThumbFingertipGrabSocketName(
|
||||
USGVirtualHandComponent* VirtualHandComponent, const FName& SocketName)
|
||||
void UVirtualHandComponentKismetLibrary::SetThumbFingertipGrabSocketName(USGVirtualHandComponent* VirtualHandComponent,
|
||||
const FName& SocketName)
|
||||
{
|
||||
VirtualHandComponent->SetThumbFingertipGrabSocketName(SocketName);
|
||||
}
|
||||
@@ -131,8 +119,8 @@ const FName& UVirtualHandComponentKismetLibrary::GetIndexFingertipGrabSocketName
|
||||
return VirtualHandComponent->GetIndexFingertipGrabSocketName();
|
||||
}
|
||||
|
||||
void UVirtualHandComponentKismetLibrary::SetIndexFingertipGrabSocketName(
|
||||
USGVirtualHandComponent* VirtualHandComponent, const FName& SocketName)
|
||||
void UVirtualHandComponentKismetLibrary::SetIndexFingertipGrabSocketName(USGVirtualHandComponent* VirtualHandComponent,
|
||||
const FName& SocketName)
|
||||
{
|
||||
VirtualHandComponent->SetIndexFingertipGrabSocketName(SocketName);
|
||||
}
|
||||
@@ -143,8 +131,8 @@ const FName& UVirtualHandComponentKismetLibrary::GetMiddleFingertipGrabSocketNam
|
||||
return VirtualHandComponent->GetMiddleFingertipGrabSocketName();
|
||||
}
|
||||
|
||||
void UVirtualHandComponentKismetLibrary::SetMiddleFingertipGrabSocketName(
|
||||
USGVirtualHandComponent* VirtualHandComponent, const FName& SocketName)
|
||||
void UVirtualHandComponentKismetLibrary::SetMiddleFingertipGrabSocketName(USGVirtualHandComponent* VirtualHandComponent,
|
||||
const FName& SocketName)
|
||||
{
|
||||
VirtualHandComponent->SetMiddleFingertipGrabSocketName(SocketName);
|
||||
}
|
||||
@@ -161,8 +149,8 @@ const FName& UVirtualHandComponentKismetLibrary::GetThumbFingertipTouchSocketNam
|
||||
return VirtualHandComponent->GetThumbFingertipTouchSocketName();
|
||||
}
|
||||
|
||||
void UVirtualHandComponentKismetLibrary::SetThumbFingertipTouchSocketName(
|
||||
USGVirtualHandComponent* VirtualHandComponent, const FName& SocketName)
|
||||
void UVirtualHandComponentKismetLibrary::SetThumbFingertipTouchSocketName(USGVirtualHandComponent* VirtualHandComponent,
|
||||
const FName& SocketName)
|
||||
{
|
||||
VirtualHandComponent->SetThumbFingertipTouchSocketName(SocketName);
|
||||
}
|
||||
@@ -173,8 +161,8 @@ const FName& UVirtualHandComponentKismetLibrary::GetIndexFingertipTouchSocketNam
|
||||
return VirtualHandComponent->GetIndexFingertipTouchSocketName();
|
||||
}
|
||||
|
||||
void UVirtualHandComponentKismetLibrary::SetIndexFingertipTouchSocketName(
|
||||
USGVirtualHandComponent* VirtualHandComponent, const FName& SocketName)
|
||||
void UVirtualHandComponentKismetLibrary::SetIndexFingertipTouchSocketName(USGVirtualHandComponent* VirtualHandComponent,
|
||||
const FName& SocketName)
|
||||
{
|
||||
VirtualHandComponent->SetIndexFingertipTouchSocketName(SocketName);
|
||||
}
|
||||
@@ -198,8 +186,8 @@ const FName& UVirtualHandComponentKismetLibrary::GetRingFingertipTouchSocketName
|
||||
return VirtualHandComponent->GetRingFingertipTouchSocketName();
|
||||
}
|
||||
|
||||
void UVirtualHandComponentKismetLibrary::SetRingFingertipTouchSocketName(
|
||||
USGVirtualHandComponent* VirtualHandComponent, const FName& SocketName)
|
||||
void UVirtualHandComponentKismetLibrary::SetRingFingertipTouchSocketName(USGVirtualHandComponent* VirtualHandComponent,
|
||||
const FName& SocketName)
|
||||
{
|
||||
VirtualHandComponent->SetRingFingertipTouchSocketName(SocketName);
|
||||
}
|
||||
@@ -210,23 +198,22 @@ const FName& UVirtualHandComponentKismetLibrary::GetPinkyFingertipTouchSocketNam
|
||||
return VirtualHandComponent->GetPinkyFingertipTouchSocketName();
|
||||
}
|
||||
|
||||
void UVirtualHandComponentKismetLibrary::SetPinkyFingertipTouchSocketName(
|
||||
USGVirtualHandComponent* VirtualHandComponent, const FName& SocketName)
|
||||
void UVirtualHandComponentKismetLibrary::SetPinkyFingertipTouchSocketName(USGVirtualHandComponent* VirtualHandComponent,
|
||||
const FName& SocketName)
|
||||
{
|
||||
VirtualHandComponent->SetPinkyFingertipTouchSocketName(SocketName);
|
||||
}
|
||||
|
||||
const FSGDebugVirtualHandSettings& UVirtualHandComponentKismetLibrary::GetDebugVirtualHandSettings(
|
||||
bool UVirtualHandComponentKismetLibrary::IsHiddenInGameIfNoGloveDetected(
|
||||
const USGVirtualHandComponent* VirtualHandComponent)
|
||||
{
|
||||
return VirtualHandComponent->GetDebugVirtualHandSettings();
|
||||
return VirtualHandComponent->IsHiddenInGameIfNoGloveDetected();
|
||||
}
|
||||
|
||||
void UVirtualHandComponentKismetLibrary::SetDebugVirtualHandSettings(
|
||||
USGVirtualHandComponent* VirtualHandComponent,
|
||||
const FSGDebugVirtualHandSettings& InDebugVirtualHandSettings)
|
||||
void UVirtualHandComponentKismetLibrary::SetHiddenIfNoGloveDetected(
|
||||
USGVirtualHandComponent* VirtualHandComponent, const bool bInHiddenIfNoGloveDetected)
|
||||
{
|
||||
VirtualHandComponent->SetDebugVirtualHandSettings(InDebugVirtualHandSettings);
|
||||
VirtualHandComponent->SetHiddenIfNoGloveDetected(bInHiddenIfNoGloveDetected);
|
||||
}
|
||||
|
||||
bool UVirtualHandComponentKismetLibrary::IsGloveConnected(const USGVirtualHandComponent* VirtualHandComponent)
|
||||
@@ -234,8 +221,7 @@ bool UVirtualHandComponentKismetLibrary::IsGloveConnected(const USGVirtualHandCo
|
||||
return VirtualHandComponent->IsGloveConnected();
|
||||
}
|
||||
|
||||
USGHapticGlove* UVirtualHandComponentKismetLibrary::GetConnectedGlove(
|
||||
const USGVirtualHandComponent* VirtualHandComponent)
|
||||
USGHapticGlove* UVirtualHandComponentKismetLibrary::GetConnectedGlove(const USGVirtualHandComponent* VirtualHandComponent)
|
||||
{
|
||||
return VirtualHandComponent->GetConnectedGlove();
|
||||
}
|
||||
|
||||
@@ -49,17 +49,78 @@ void UWristTrackerComponentKismetLibrary::OverridePluginWristTrackingSettings(
|
||||
WristTrackerComponent->OverridePluginWristTrackingSettings(bInOverridePluginWristTrackingSettings);
|
||||
}
|
||||
|
||||
const FSGWristTrackingSettings& UWristTrackerComponentKismetLibrary::GetWristTrackingSettings(
|
||||
ESGPositionalTrackingHardware UWristTrackerComponentKismetLibrary::GetTrackingHardware(
|
||||
const USGWristTrackerComponent* WristTrackerComponent)
|
||||
{
|
||||
return WristTrackerComponent->GetWristTrackingSettings();
|
||||
return WristTrackerComponent->GetTrackingHardware();
|
||||
}
|
||||
|
||||
void UWristTrackerComponentKismetLibrary::SetWristTrackingSettings(
|
||||
USGWristTrackerComponent* WristTrackerComponent,
|
||||
const FSGWristTrackingSettings& InWristTrackingSettings)
|
||||
void UWristTrackerComponentKismetLibrary::SetTrackingHardware(
|
||||
USGWristTrackerComponent* WristTrackerComponent, ESGPositionalTrackingHardware InTrackingHardware)
|
||||
{
|
||||
WristTrackerComponent->SetWristTrackingSettings(InWristTrackingSettings);
|
||||
WristTrackerComponent->SetTrackingHardware(InTrackingHardware);
|
||||
}
|
||||
|
||||
const FVector& UWristTrackerComponentKismetLibrary::GetTrackingHardwareLocationOffset(
|
||||
const USGWristTrackerComponent* WristTrackerComponent)
|
||||
{
|
||||
return WristTrackerComponent->GetTrackingHardwareLocationOffset();
|
||||
}
|
||||
|
||||
void UWristTrackerComponentKismetLibrary::SetTrackingHardwareLocationOffset(
|
||||
USGWristTrackerComponent* WristTrackerComponent,
|
||||
const FVector& InTrackingHardwareLocationOffset)
|
||||
{
|
||||
WristTrackerComponent->SetTrackingHardwareLocationOffset(InTrackingHardwareLocationOffset);
|
||||
}
|
||||
|
||||
const FRotator& UWristTrackerComponentKismetLibrary::GetTrackingHardwareRotationOffset(
|
||||
const USGWristTrackerComponent* WristTrackerComponent)
|
||||
{
|
||||
return WristTrackerComponent->GetTrackingHardwareRotationOffset();
|
||||
}
|
||||
|
||||
void UWristTrackerComponentKismetLibrary::SetTrackingHardwareRotationOffset(
|
||||
USGWristTrackerComponent* WristTrackerComponent,
|
||||
const FRotator& InTrackingHardwareRotationOffset)
|
||||
{
|
||||
WristTrackerComponent->SetTrackingHardwareRotationOffset(InTrackingHardwareRotationOffset);
|
||||
}
|
||||
|
||||
bool UWristTrackerComponentKismetLibrary::OverridesPluginWristTrackingDebugSettings(
|
||||
const USGWristTrackerComponent* WristTrackerComponent)
|
||||
{
|
||||
return WristTrackerComponent->OverridesPluginWristTrackingDebugSettings();
|
||||
}
|
||||
|
||||
void UWristTrackerComponentKismetLibrary::OverridePluginWristTrackingDebugSettings(
|
||||
USGWristTrackerComponent* WristTrackerComponent, const bool bInOverridePluginWristTrackingDebugSettings)
|
||||
{
|
||||
WristTrackerComponent->OverridePluginWristTrackingDebugSettings(bInOverridePluginWristTrackingDebugSettings);
|
||||
}
|
||||
|
||||
bool UWristTrackerComponentKismetLibrary::GetDrawWristTrackerDebugGizmo(
|
||||
const USGWristTrackerComponent* WristTrackerComponent)
|
||||
{
|
||||
return WristTrackerComponent->GetDrawWristTrackerDebugGizmo();
|
||||
}
|
||||
|
||||
void UWristTrackerComponentKismetLibrary::SetDrawWristTrackerDebugGizmo(
|
||||
USGWristTrackerComponent* WristTrackerComponent, const bool bInDrawWristTrackerDebugGizmo)
|
||||
{
|
||||
WristTrackerComponent->SetDrawWristTrackerDebugGizmo(bInDrawWristTrackerDebugGizmo);
|
||||
}
|
||||
|
||||
const FSGDebugGizmoSettings& UWristTrackerComponentKismetLibrary::GetWristTrackerDebugGizmoSettings(
|
||||
const USGWristTrackerComponent* WristTrackerComponent)
|
||||
{
|
||||
return WristTrackerComponent->GetWristTrackerDebugGizmoSettings();
|
||||
}
|
||||
|
||||
void UWristTrackerComponentKismetLibrary::SetWristTrackerDebugGizmoSettings(
|
||||
USGWristTrackerComponent* WristTrackerComponent, const FSGDebugGizmoSettings& InWristTrackerDebugGizmoSettings)
|
||||
{
|
||||
WristTrackerComponent->SetWristTrackerDebugGizmoSettings(InWristTrackerDebugGizmoSettings);
|
||||
}
|
||||
|
||||
bool UWristTrackerComponentKismetLibrary::IsLeft(const USGWristTrackerComponent* WristTrackerComponent)
|
||||
|
||||
@@ -71,9 +71,6 @@ public:
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Game Framework | Pawn")
|
||||
static USGVirtualHandComponent* GetHandLeft(const ASGPawn* Pawn);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Game Framework | Pawn")
|
||||
static USGVirtualHandComponent* GetRealHandLeft(const ASGPawn* Pawn);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Game Framework | Pawn")
|
||||
static USphereComponent* GetLeftThumbFingertipGrabCollider(const ASGPawn* Pawn);
|
||||
|
||||
@@ -104,9 +101,6 @@ public:
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Game Framework | Pawn")
|
||||
static USGVirtualHandComponent* GetHandRight(const ASGPawn* Pawn);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Game Framework | Pawn")
|
||||
static USGVirtualHandComponent* GetRealHandRight(const ASGPawn* Pawn);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Game Framework | Pawn")
|
||||
static USphereComponent* GetRightThumbFingertipGrabCollider(const ASGPawn* Pawn);
|
||||
|
||||
|
||||
@@ -44,7 +44,6 @@
|
||||
#include "UObject/NameTypes.h"
|
||||
|
||||
#include "SGKismet/SGBlueprintFunctionLibrary.h"
|
||||
#include "SGSettings/SGDebugVirtualHandSettings.h"
|
||||
#include "SGTypes/SGNameArray.h"
|
||||
|
||||
#include "SGVirtualHandComponentKismetLibrary.generated.h"
|
||||
@@ -82,13 +81,6 @@ public:
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Components | Virtual Hand Component")
|
||||
static void SetRight(UPARAM(ref) USGVirtualHandComponent* VirtualHandComponent, bool bInRight);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Components | Virtual Hand Component")
|
||||
static bool IsHiddenInGameIfNoGloveDetected(const USGVirtualHandComponent* VirtualHandComponent);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Components | Virtual Hand Component")
|
||||
static void SetHiddenIfNoGloveDetected(UPARAM(ref) USGVirtualHandComponent* VirtualHandComponent,
|
||||
bool bInHiddenIfNoGloveDetected);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Components | Virtual Hand Component")
|
||||
static bool AutoStopsAllHapticsOnEndPlay(const USGVirtualHandComponent* VirtualHandComponent);
|
||||
|
||||
@@ -162,12 +154,11 @@ public:
|
||||
const FName& SocketName);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Components | Virtual Hand Component")
|
||||
static const FSGDebugVirtualHandSettings& GetDebugVirtualHandSettings(
|
||||
const USGVirtualHandComponent* VirtualHandComponent);
|
||||
static bool IsHiddenInGameIfNoGloveDetected(const USGVirtualHandComponent* VirtualHandComponent);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Components | Virtual Hand Component")
|
||||
static void SetDebugVirtualHandSettings(UPARAM(ref) USGVirtualHandComponent* VirtualHandComponent,
|
||||
const FSGDebugVirtualHandSettings& InDebugVirtualHandSettings);
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Components | Virtual Hand Component")
|
||||
static void SetHiddenIfNoGloveDetected(UPARAM(ref) USGVirtualHandComponent* VirtualHandComponent,
|
||||
bool bInHiddenIfNoGloveDetected);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Components | Virtual Hand Component")
|
||||
static bool IsGloveConnected(const USGVirtualHandComponent* VirtualHandComponent);
|
||||
|
||||
@@ -38,7 +38,9 @@
|
||||
#pragma once
|
||||
|
||||
#include "SGKismet/SGBlueprintFunctionLibrary.h"
|
||||
#include "SGSettings/SGWristTrackingSettings.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
#include "SGSettings/SGDebugGizmoSettings.h"
|
||||
|
||||
#include "SGWristTrackerComponentKismetLibrary.generated.h"
|
||||
|
||||
@@ -61,12 +63,47 @@ public:
|
||||
bool bInOverridePluginWristTrackingSettings);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Components | Wrist Tracker Component")
|
||||
static const FSGWristTrackingSettings& GetWristTrackingSettings(
|
||||
static ESGPositionalTrackingHardware GetTrackingHardware(const USGWristTrackerComponent* WristTrackerComponent);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Components | Wrist Tracker Component")
|
||||
static void SetTrackingHardware(UPARAM(ref) USGWristTrackerComponent* WristTrackerComponent,
|
||||
ESGPositionalTrackingHardware InTrackingHardware);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Components | Wrist Tracker Component")
|
||||
static const FVector& GetTrackingHardwareLocationOffset(const USGWristTrackerComponent* WristTrackerComponent);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Components | Wrist Tracker Component")
|
||||
static void SetTrackingHardwareLocationOffset(UPARAM(ref) USGWristTrackerComponent* WristTrackerComponent,
|
||||
const FVector& InTrackingHardwareLocationOffset);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Components | Wrist Tracker Component")
|
||||
static const FRotator& GetTrackingHardwareRotationOffset(const USGWristTrackerComponent* WristTrackerComponent);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Components | Wrist Tracker Component")
|
||||
static void SetTrackingHardwareRotationOffset(UPARAM(ref) USGWristTrackerComponent* WristTrackerComponent,
|
||||
const FRotator& InTrackingHardwareRotationOffset);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Components | Wrist Tracker Component")
|
||||
static bool OverridesPluginWristTrackingDebugSettings(const USGWristTrackerComponent* WristTrackerComponent);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Components | Wrist Tracker Component")
|
||||
static void OverridePluginWristTrackingDebugSettings(UPARAM(ref) USGWristTrackerComponent* WristTrackerComponent,
|
||||
bool bInOverridePluginWristTrackingDebugSettings);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Components | Wrist Tracker Component")
|
||||
static bool GetDrawWristTrackerDebugGizmo(const USGWristTrackerComponent* WristTrackerComponent);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Components | Wrist Tracker Component")
|
||||
static void SetDrawWristTrackerDebugGizmo(UPARAM(ref) USGWristTrackerComponent* WristTrackerComponent,
|
||||
bool bInDrawWristTrackerDebugGizmo);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Components | Wrist Tracker Component")
|
||||
static const FSGDebugGizmoSettings& GetWristTrackerDebugGizmoSettings(
|
||||
const USGWristTrackerComponent* WristTrackerComponent);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Components | Wrist Tracker Component")
|
||||
static void SetWristTrackingSettings(UPARAM(ref) USGWristTrackerComponent* WristTrackerComponent,
|
||||
const FSGWristTrackingSettings& InWristTrackingSettings);
|
||||
static void SetWristTrackerDebugGizmoSettings(UPARAM(ref) USGWristTrackerComponent* WristTrackerComponent,
|
||||
const FSGDebugGizmoSettings& InWristTrackerDebugGizmoSettings);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Components | Wrist Tracker Component")
|
||||
static bool IsLeft(const USGWristTrackerComponent* WristTrackerComponent);
|
||||
|
||||
@@ -35,32 +35,13 @@
|
||||
|
||||
#include "SGSettings/SGDebugVirtualHandSettings.h"
|
||||
|
||||
FSGDebugVirtualHandSettings::FSGDebugVirtualHandSettings()
|
||||
: bDrawDebugVirtualHand(false),
|
||||
DrawingMode(ESGDebugVirtualHandDrawingMode::None),
|
||||
CubeExtent(FVector(0.5f, 0.5f, 0.5f)),
|
||||
CubeColor(255, 0, 0, 255),
|
||||
CubeThickness(0.1f),
|
||||
GizmoLength(1.0f),
|
||||
GizmoThickness(1.0f),
|
||||
GizmoXAxisColor(255, 0, 0, 255),
|
||||
GizmoYAxisColor(0, 255, 0, 255),
|
||||
GizmoZAxisColor(0, 0, 255, 255),
|
||||
bPersistentLines(false),
|
||||
LifeTimeModifier(1.1f),
|
||||
DepthPriority(0)
|
||||
{
|
||||
}
|
||||
|
||||
FSGDebugVirtualHandSettings::FSGDebugVirtualHandSettings(
|
||||
const bool bInDrawDebugVirtualHand,
|
||||
const ESGDebugVirtualHandDrawingMode InDrawingMode,
|
||||
const FVector& InCubeExtent, const FColor& InCubeColor, const float InCubeThickness,
|
||||
const float InGizmoLength, const float InGizmoThickness,
|
||||
const FColor& InGizmoXAxisColor, const FColor& InGizmoYAxisColor, const FColor& InGizmoZAxisColor,
|
||||
const bool bInPersistentLines, const float InLifeTimeModifier, const uint8 InDepthPriority)
|
||||
: bDrawDebugVirtualHand(bInDrawDebugVirtualHand),
|
||||
DrawingMode(InDrawingMode),
|
||||
: DrawingMode(InDrawingMode),
|
||||
CubeExtent(InCubeExtent),
|
||||
CubeColor(InCubeColor),
|
||||
CubeThickness(InCubeThickness),
|
||||
|
||||
@@ -42,6 +42,10 @@
|
||||
|
||||
struct USGSettings::FImpl
|
||||
{
|
||||
/************************
|
||||
* Static methods
|
||||
************************/
|
||||
|
||||
/************************
|
||||
* Owner object
|
||||
************************/
|
||||
@@ -61,15 +65,16 @@ struct USGSettings::FImpl
|
||||
|
||||
FImpl(const FImpl& Rhs) = default;
|
||||
FImpl& operator=(const FImpl& Rhs) = default;
|
||||
|
||||
/************************
|
||||
* Methods
|
||||
************************/
|
||||
|
||||
void ResetTrackingHardwareValuesToZero();
|
||||
};
|
||||
|
||||
USGSettings* USGSettings::GetInstance()
|
||||
{
|
||||
if (!ensureAlwaysMsgf(GEngine, TEXT("The engine has not been initialized!")))
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
USGSettings* Instance{GEngine->GetEngineSubsystem<USGSettings>()};
|
||||
return Instance;
|
||||
}
|
||||
@@ -77,25 +82,118 @@ USGSettings* USGSettings::GetInstance()
|
||||
USGSettings::USGSettings()
|
||||
: Pimpl(TUniquePtr<FImpl, FImplDeleter>(new FImpl{this}, PimplDeleter))
|
||||
{
|
||||
WristTrackingSettings = FSGWristTrackingSettings(
|
||||
ESGPositionalTrackingHardware::None,
|
||||
FVector::ZeroVector,
|
||||
FVector::ZeroVector,
|
||||
FRotator::ZeroRotator,
|
||||
FRotator::ZeroRotator,
|
||||
EControllerHand::Left,
|
||||
EControllerHand::Right,
|
||||
false,
|
||||
FSGDebugGizmoSettings(
|
||||
4.0f, 1.0f,
|
||||
FColor(255, 0, 0, 255),
|
||||
FColor(0, 255, 0, 255),
|
||||
FColor(0, 0, 255, 255),
|
||||
false, 1.1f, 0
|
||||
)
|
||||
TrackingHardware = ESGPositionalTrackingHardware::None;
|
||||
|
||||
Pimpl->ResetTrackingHardwareValuesToZero();
|
||||
|
||||
TrackingHardware = ESGPositionalTrackingHardware::None;
|
||||
TrackingHardwareLocationOffsetLeftHand = FVector::ZeroVector;
|
||||
TrackingHardwareLocationOffsetRightHand = FVector::ZeroVector;
|
||||
TrackingHardwareRotationOffsetLeftHand = FRotator::ZeroRotator;
|
||||
TrackingHardwareRotationOffsetRightHand = FRotator::ZeroRotator;
|
||||
|
||||
bDrawWristTrackerDebugGizmo = false;
|
||||
WristTrackerDebugGizmoSettings = FSGDebugGizmoSettings(
|
||||
4.0f, 1.0f,
|
||||
FColor(255, 0, 0, 255),
|
||||
FColor(0, 255, 0, 255),
|
||||
FColor(0, 0, 255, 255),
|
||||
false, 1.1f, 0
|
||||
);
|
||||
}
|
||||
|
||||
const FVector& USGSettings::GetTrackingHardwareLocationOffsetLeftHand() const
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
TrackingHardware == ESGPositionalTrackingHardware::Custom,
|
||||
TEXT( "Getting TrackingHardwareLocationOffsetLeftHand is only permitted when TrackingHardware is set to"
|
||||
" Custom!"));
|
||||
return TrackingHardwareLocationOffsetLeftHand;
|
||||
}
|
||||
|
||||
void USGSettings::SetTrackingHardwareLocationOffsetLeftHand(const FVector& InTrackingHardwareLocationOffsetLeftHand)
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
TrackingHardware == ESGPositionalTrackingHardware::Custom,
|
||||
TEXT( "Setting TrackingHardwareLocationOffsetLeftHand is only permitted when TrackingHardware is set to"
|
||||
" Custom!"));
|
||||
TrackingHardwareLocationOffsetLeftHand = InTrackingHardwareLocationOffsetLeftHand;
|
||||
}
|
||||
|
||||
const FVector& USGSettings::GetTrackingHardwareLocationOffsetRightHand() const
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
TrackingHardware == ESGPositionalTrackingHardware::Custom,
|
||||
TEXT( "Getting TrackingHardwareLocationOffsetRightHand is only permitted when TrackingHardware is set to"
|
||||
" Custom!"));
|
||||
return TrackingHardwareLocationOffsetRightHand;
|
||||
}
|
||||
|
||||
void USGSettings::SetTrackingHardwareLocationOffsetRightHand(const FVector& InTrackingHardwareLocationOffsetRightHand)
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
TrackingHardware == ESGPositionalTrackingHardware::Custom,
|
||||
TEXT( "Setting TrackingHardwareLocationOffsetRightHand is only permitted when TrackingHardware is set to"
|
||||
" Custom!"));
|
||||
TrackingHardwareLocationOffsetRightHand = InTrackingHardwareLocationOffsetRightHand;
|
||||
}
|
||||
|
||||
const FRotator& USGSettings::GetTrackingHardwareRotationOffsetLeftHand() const
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
TrackingHardware == ESGPositionalTrackingHardware::Custom,
|
||||
TEXT( "Getting TrackingHardwareRotationOffsetLeftHand is only permitted when TrackingHardware is set to"
|
||||
" Custom!"));
|
||||
return TrackingHardwareRotationOffsetLeftHand;
|
||||
}
|
||||
|
||||
void USGSettings::SetTrackingHardwareRotationOffsetLeftHand(
|
||||
const FRotator& InTrackingHardwareRotationOffsetLeftHand)
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
TrackingHardware == ESGPositionalTrackingHardware::Custom,
|
||||
TEXT("Setting TrackingHardwareRotationOffsetRightHand is only permitted when TrackingHardware is set to"
|
||||
" Custom!"));
|
||||
TrackingHardwareRotationOffsetLeftHand = InTrackingHardwareRotationOffsetLeftHand;
|
||||
}
|
||||
|
||||
const FRotator& USGSettings::GetTrackingHardwareRotationOffsetRightHand() const
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
TrackingHardware == ESGPositionalTrackingHardware::Custom,
|
||||
TEXT("Getting TrackingHardwareRotationOffsetRightHand is only permitted when TrackingHardware is set to"
|
||||
" Custom!"));
|
||||
return TrackingHardwareRotationOffsetRightHand;
|
||||
}
|
||||
|
||||
void USGSettings::SetTrackingHardwareRotationOffsetRightHand(
|
||||
const FRotator& InTrackingHardwareRotationOffsetRightHand)
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
TrackingHardware == ESGPositionalTrackingHardware::Custom,
|
||||
TEXT("Setting TrackingHardwareRotationOffsetRightHand is only permitted when TrackingHardware is set to"
|
||||
" Custom!"));
|
||||
TrackingHardwareRotationOffsetRightHand = InTrackingHardwareRotationOffsetRightHand;
|
||||
}
|
||||
|
||||
const FSGDebugGizmoSettings& USGSettings::GetWristTrackerDebugGizmoSettings() const
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
GetDrawWristTrackerDebugGizmo(),
|
||||
TEXT("Getting DebugWristTrackerGizmoThickness is only permitted when bDrawDebugWristTrackerGizmo is"
|
||||
" enabled!"));
|
||||
return WristTrackerDebugGizmoSettings;
|
||||
}
|
||||
|
||||
void USGSettings::SetWristTrackerDebugGizmoSettings(const FSGDebugGizmoSettings& InWristTrackerDebugGizmoSettings)
|
||||
{
|
||||
ensureAlwaysMsgf(
|
||||
GetDrawWristTrackerDebugGizmo(),
|
||||
TEXT("Setting DebugWristTrackerGizmoThickness is only permitted when bDrawDebugWristTrackerGizmo is"
|
||||
" enabled!"));
|
||||
WristTrackerDebugGizmoSettings = InWristTrackerDebugGizmoSettings;
|
||||
}
|
||||
|
||||
bool USGSettings::ShouldCreateSubsystem(UObject* Outer) const
|
||||
{
|
||||
return true;
|
||||
@@ -107,6 +205,8 @@ void USGSettings::Initialize(FSubsystemCollectionBase& Collection)
|
||||
|
||||
Super::Initialize(Collection);
|
||||
|
||||
SGLOG("Initializing the SenseGlove settings singleton with the engine lifetime...");
|
||||
|
||||
SGLOG("The SenseGlove settings singleton has been successfully initialized with the engine lifetime!");
|
||||
}
|
||||
|
||||
@@ -116,11 +216,46 @@ void USGSettings::Deinitialize()
|
||||
|
||||
Super::Deinitialize();
|
||||
|
||||
(void)Pimpl.Release();
|
||||
Pimpl.Release();
|
||||
|
||||
SGLOG("The SenseGlove settings singleton has been successfully de-initialized!");
|
||||
}
|
||||
|
||||
#if WITH_EDITOR
|
||||
bool USGSettings::CanEditChange(const FProperty* InProperty) const
|
||||
{
|
||||
bool bCanEditChange = Super::CanEditChange(InProperty);
|
||||
|
||||
/*const FName PropertyName{InProperty ? InProperty->GetFName() : NAME_None};
|
||||
|
||||
if (PropertyName == GET_MEMBER_NAME_CHECKED(USGSettings, TrackingHardware))
|
||||
{
|
||||
return TrackingHardware == ESGPositionalTrackingHardware::Custom;
|
||||
}*/
|
||||
|
||||
return bCanEditChange;
|
||||
}
|
||||
#endif /* WITH_EDITOR */
|
||||
|
||||
#if WITH_EDITOR
|
||||
void USGSettings::PostEditChangeProperty(FPropertyChangedEvent& PropertyChangedEvent)
|
||||
{
|
||||
Super::PostEditChangeProperty(PropertyChangedEvent);
|
||||
|
||||
const FName PropertyName{
|
||||
PropertyChangedEvent.Property
|
||||
? PropertyChangedEvent.Property->GetFName()
|
||||
: NAME_None
|
||||
};
|
||||
|
||||
if (PropertyName == GET_MEMBER_NAME_CHECKED(USGSettings, TrackingHardware))
|
||||
{
|
||||
Pimpl->ResetTrackingHardwareValuesToZero();
|
||||
return;
|
||||
}
|
||||
}
|
||||
#endif /* WITH_EDITOR */
|
||||
|
||||
USGSettings::FImpl::FImpl(USGSettings* InOwner)
|
||||
: Owner(InOwner)
|
||||
{
|
||||
@@ -128,6 +263,14 @@ USGSettings::FImpl::FImpl(USGSettings* InOwner)
|
||||
|
||||
USGSettings::FImpl::~FImpl() = default;
|
||||
|
||||
void USGSettings::FImpl::ResetTrackingHardwareValuesToZero()
|
||||
{
|
||||
Owner->TrackingHardwareLocationOffsetLeftHand = FVector::ZeroVector;
|
||||
Owner->TrackingHardwareLocationOffsetRightHand = FVector::ZeroVector;
|
||||
Owner->TrackingHardwareRotationOffsetLeftHand = FRotator::ZeroRotator;
|
||||
Owner->TrackingHardwareRotationOffsetRightHand = FRotator::ZeroRotator;
|
||||
}
|
||||
|
||||
void USGSettings::FImplDeleter::operator()(const FImpl* P) const
|
||||
{
|
||||
delete P;
|
||||
|
||||
@@ -1,71 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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
|
||||
*
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
#include "SGSettings/SGWristTrackingSettings.h"
|
||||
|
||||
FSGWristTrackingSettings::FSGWristTrackingSettings()
|
||||
: TrackingHardware(ESGPositionalTrackingHardware::None),
|
||||
TrackingHardwareLocationOffsetLeftHand(FVector::ZeroVector),
|
||||
TrackingHardwareLocationOffsetRightHand(FVector::ZeroVector),
|
||||
TrackingHardwareRotationOffsetLeftHand(FRotator::ZeroRotator),
|
||||
TrackingHardwareRotationOffsetRightHand(FRotator::ZeroRotator),
|
||||
LeftHandMotionSource(EControllerHand::Left),
|
||||
RightHandMotionSource(EControllerHand::Right),
|
||||
bDrawWristTrackerDebugGizmo(false),
|
||||
WristTrackerDebugGizmoSettings(FSGDebugGizmoSettings())
|
||||
{
|
||||
}
|
||||
|
||||
FSGWristTrackingSettings::FSGWristTrackingSettings(
|
||||
const ESGPositionalTrackingHardware InTrackingHardware,
|
||||
const FVector& InTrackingHardwareLocationOffsetLeftHand,
|
||||
const FVector& InTrackingHardwareLocationOffsetRightHand,
|
||||
const FRotator& InTrackingHardwareRotationOffsetLeftHand,
|
||||
const FRotator& InTrackingHardwareRotationOffsetRightHand,
|
||||
const EControllerHand InLeftHandMotionSource,
|
||||
const EControllerHand InRightHandMotionSource,
|
||||
const bool bInDrawWristTrackerDebugGizmo,
|
||||
const FSGDebugGizmoSettings& InWristTrackerDebugGizmoSettings)
|
||||
: TrackingHardware(InTrackingHardware),
|
||||
TrackingHardwareLocationOffsetLeftHand(InTrackingHardwareLocationOffsetLeftHand),
|
||||
TrackingHardwareLocationOffsetRightHand(InTrackingHardwareLocationOffsetRightHand),
|
||||
TrackingHardwareRotationOffsetLeftHand(InTrackingHardwareRotationOffsetLeftHand),
|
||||
TrackingHardwareRotationOffsetRightHand(InTrackingHardwareRotationOffsetRightHand),
|
||||
LeftHandMotionSource(InLeftHandMotionSource),
|
||||
RightHandMotionSource(InRightHandMotionSource),
|
||||
bDrawWristTrackerDebugGizmo(bInDrawWristTrackerDebugGizmo),
|
||||
WristTrackerDebugGizmoSettings(InWristTrackerDebugGizmoSettings)
|
||||
{
|
||||
}
|
||||
@@ -48,10 +48,6 @@ struct SENSEGLOVESETTINGS_API FSGDebugVirtualHandSettings
|
||||
|
||||
public:
|
||||
UPROPERTY(EditAnywhere, Category = "Debug Virtual Hand Settings")
|
||||
uint8 bDrawDebugVirtualHand : 1;
|
||||
|
||||
UPROPERTY(EditAnywhere, Category = "Debug Virtual Hand Settings",
|
||||
meta=(EditCondition="bDrawDebugVirtualHand", EditConditionHides))
|
||||
ESGDebugVirtualHandDrawingMode DrawingMode;
|
||||
|
||||
UPROPERTY(EditAnywhere, Category = "Debug Virtual Hand Settings",
|
||||
@@ -99,10 +95,7 @@ public:
|
||||
uint8 DepthPriority;
|
||||
|
||||
public:
|
||||
FSGDebugVirtualHandSettings();
|
||||
|
||||
explicit FSGDebugVirtualHandSettings(
|
||||
bool bInDrawDebugVirtualHand,
|
||||
ESGDebugVirtualHandDrawingMode InDrawingMode = ESGDebugVirtualHandDrawingMode::None,
|
||||
const FVector& InCubeExtent = FVector(0.5f, 0.5f, 0.5f),
|
||||
const FColor& InCubeColor = FColor(255, 0, 0, 255),
|
||||
|
||||
@@ -42,7 +42,8 @@
|
||||
#include "Templates/UniquePtr.h"
|
||||
#include "UObject/ObjectMacros.h"
|
||||
|
||||
#include "SGSettings/SGWristTrackingSettings.h"
|
||||
#include "SGSettings/SGDebugGizmoSettings.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
#include "SGSettings.generated.h"
|
||||
|
||||
@@ -66,26 +67,101 @@ private:
|
||||
FImplDeleter PimplDeleter;
|
||||
|
||||
private:
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "SenseGlove")
|
||||
FSGWristTrackingSettings WristTrackingSettings;
|
||||
/**
|
||||
* If set to Custom, any desired location and rotation can be specified.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "Wrist Tracking")
|
||||
ESGPositionalTrackingHardware TrackingHardware;
|
||||
|
||||
/**
|
||||
* Valid only if TrackingHardware is set to Custom.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "Wrist Tracking",
|
||||
meta=(EditCondition="TrackingHardware == ESGPositionalTrackingHardware::Custom", EditConditionHides))
|
||||
FVector TrackingHardwareLocationOffsetLeftHand;
|
||||
|
||||
/**
|
||||
* Valid only if TrackingHardware is set to Custom.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "Wrist Tracking",
|
||||
meta=(EditCondition="TrackingHardware == ESGPositionalTrackingHardware::Custom", EditConditionHides))
|
||||
FVector TrackingHardwareLocationOffsetRightHand;
|
||||
|
||||
/**
|
||||
* Valid only if TrackingHardware is set to Custom.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "Wrist Tracking",
|
||||
meta=(EditCondition="TrackingHardware == ESGPositionalTrackingHardware::Custom", EditConditionHides))
|
||||
FRotator TrackingHardwareRotationOffsetLeftHand;
|
||||
|
||||
/**
|
||||
* Valid only if TrackingHardware is set to Custom.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "Wrist Tracking",
|
||||
meta=(EditCondition="TrackingHardware == ESGPositionalTrackingHardware::Custom", EditConditionHides))
|
||||
FRotator TrackingHardwareRotationOffsetRightHand;
|
||||
|
||||
/**
|
||||
* If enabled, draws debug Wrist trackers where possible.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "Wrist Tracking Debug")
|
||||
uint8 bDrawWristTrackerDebugGizmo : 1;
|
||||
|
||||
/**
|
||||
* Valid only if bDrawDebugWristTrackerGizmo is enabled.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "Wrist Tracking Debug",
|
||||
meta=(EditCondition="bDrawWristTrackerDebugGizmo", EditConditionHides))
|
||||
FSGDebugGizmoSettings WristTrackerDebugGizmoSettings;
|
||||
|
||||
public:
|
||||
USGSettings();
|
||||
|
||||
public:
|
||||
FORCEINLINE const FSGWristTrackingSettings& GetWristTrackingSettings() const
|
||||
FORCEINLINE ESGPositionalTrackingHardware GetTrackingHardware() const
|
||||
{
|
||||
return WristTrackingSettings;
|
||||
return TrackingHardware;
|
||||
}
|
||||
|
||||
void SetWristTrackingSettings(const FSGWristTrackingSettings& InWristTrackingSettings)
|
||||
FORCEINLINE void SetTrackingHardware(const ESGPositionalTrackingHardware InTrackingHardware)
|
||||
{
|
||||
WristTrackingSettings = InWristTrackingSettings;
|
||||
TrackingHardware = InTrackingHardware;
|
||||
}
|
||||
|
||||
const FVector& GetTrackingHardwareLocationOffsetLeftHand() const;
|
||||
void SetTrackingHardwareLocationOffsetLeftHand(const FVector& InTrackingHardwareLocationOffsetLeftHand);
|
||||
|
||||
const FVector& GetTrackingHardwareLocationOffsetRightHand() const;
|
||||
void SetTrackingHardwareLocationOffsetRightHand(const FVector& InTrackingHardwareLocationOffsetRightHand);
|
||||
|
||||
const FRotator& GetTrackingHardwareRotationOffsetLeftHand() const;
|
||||
void SetTrackingHardwareRotationOffsetLeftHand(const FRotator& InTrackingHardwareRotationOffsetLeftHand);
|
||||
|
||||
const FRotator& GetTrackingHardwareRotationOffsetRightHand() const;
|
||||
void SetTrackingHardwareRotationOffsetRightHand(const FRotator& InTrackingHardwareRotationOffsetRightHand);
|
||||
|
||||
FORCEINLINE bool GetDrawWristTrackerDebugGizmo() const
|
||||
{
|
||||
return !!bDrawWristTrackerDebugGizmo;
|
||||
}
|
||||
|
||||
void SetDrawWristTrackerDebugGizmo(const bool bInDrawWristTrackerDebugGizmo)
|
||||
{
|
||||
bDrawWristTrackerDebugGizmo = bInDrawWristTrackerDebugGizmo;
|
||||
}
|
||||
|
||||
const FSGDebugGizmoSettings& GetWristTrackerDebugGizmoSettings() const;
|
||||
void SetWristTrackerDebugGizmoSettings(const FSGDebugGizmoSettings& InWristTrackerDebugGizmoSettings);
|
||||
|
||||
public:
|
||||
virtual bool ShouldCreateSubsystem(UObject* Outer) const override;
|
||||
|
||||
virtual void Initialize(FSubsystemCollectionBase& Collection) override;
|
||||
virtual void Deinitialize() override;
|
||||
|
||||
public:
|
||||
#if WITH_EDITOR
|
||||
virtual bool CanEditChange(const FProperty* InProperty) const override;
|
||||
virtual void PostEditChangeProperty(FPropertyChangedEvent& PropertyChangedEvent) override;
|
||||
#endif /* WITH_EDITOR */
|
||||
};
|
||||
@@ -1,126 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @author Mamadou Babaei <mamadou@senseglove.com>
|
||||
*
|
||||
* @section LICENSE
|
||||
*
|
||||
* (The MIT License)
|
||||
*
|
||||
* Copyright (c) 2020 - 2023 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 "InputCoreTypes.h"
|
||||
#include "UObject/ObjectMacros.h"
|
||||
|
||||
#include "SGSettings/SGDebugGizmoSettings.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
#include "SGWristTrackingSettings.generated.h"
|
||||
|
||||
USTRUCT(BlueprintType)
|
||||
struct SENSEGLOVESETTINGS_API FSGWristTrackingSettings
|
||||
{
|
||||
GENERATED_USTRUCT_BODY()
|
||||
|
||||
public:
|
||||
/**
|
||||
* If set to Custom, any desired location and rotation can be specified.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "Wrist Tracking")
|
||||
ESGPositionalTrackingHardware TrackingHardware;
|
||||
|
||||
/**
|
||||
* Valid only if TrackingHardware is set to Custom.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "Wrist Tracking",
|
||||
meta=(EditCondition="TrackingHardware == ESGPositionalTrackingHardware::Custom", EditConditionHides))
|
||||
FVector TrackingHardwareLocationOffsetLeftHand;
|
||||
|
||||
/**
|
||||
* Valid only if TrackingHardware is set to Custom.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "Wrist Tracking",
|
||||
meta=(EditCondition="TrackingHardware == ESGPositionalTrackingHardware::Custom", EditConditionHides))
|
||||
FVector TrackingHardwareLocationOffsetRightHand;
|
||||
|
||||
/**
|
||||
* Valid only if TrackingHardware is set to Custom.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "Wrist Tracking",
|
||||
meta=(EditCondition="TrackingHardware == ESGPositionalTrackingHardware::Custom", EditConditionHides))
|
||||
FRotator TrackingHardwareRotationOffsetLeftHand;
|
||||
|
||||
/**
|
||||
* Valid only if TrackingHardware is set to Custom.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "Wrist Tracking",
|
||||
meta=(EditCondition="TrackingHardware == ESGPositionalTrackingHardware::Custom", EditConditionHides))
|
||||
FRotator TrackingHardwareRotationOffsetRightHand;
|
||||
|
||||
/**
|
||||
* Determines which motion source to use.
|
||||
* For Oculus this is usually Left, and for VIVE usually LeftFoot.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category="Wrist Tracking")
|
||||
EControllerHand LeftHandMotionSource;
|
||||
|
||||
/**
|
||||
* Determines which motion source to use.
|
||||
* For Oculus this is usually Right, and for VIVE usually RightFoot.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category="Wrist Tracking")
|
||||
EControllerHand RightHandMotionSource;
|
||||
|
||||
/**
|
||||
* If enabled, draws debug Wrist trackers where possible.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "Debug Wrist Tracking")
|
||||
uint8 bDrawWristTrackerDebugGizmo : 1;
|
||||
|
||||
/**
|
||||
* Valid only if bDrawDebugWristTrackerGizmo is enabled.
|
||||
*/
|
||||
UPROPERTY(Config, EditDefaultsOnly, Category = "Debug Wrist Tracking",
|
||||
meta=(EditCondition="bDrawWristTrackerDebugGizmo", EditConditionHides))
|
||||
FSGDebugGizmoSettings WristTrackerDebugGizmoSettings;
|
||||
|
||||
public:
|
||||
FSGWristTrackingSettings();
|
||||
|
||||
explicit FSGWristTrackingSettings(
|
||||
ESGPositionalTrackingHardware InTrackingHardware,
|
||||
const FVector& InTrackingHardwareLocationOffsetLeftHand,
|
||||
const FVector& InTrackingHardwareLocationOffsetRightHand,
|
||||
const FRotator& InTrackingHardwareRotationOffsetLeftHand,
|
||||
const FRotator& InTrackingHardwareRotationOffsetRightHand,
|
||||
EControllerHand InLeftHandMotionSource,
|
||||
EControllerHand InRightHandMotionSource,
|
||||
bool bInDrawWristTrackerDebugGizmo,
|
||||
const FSGDebugGizmoSettings& InWristTrackerDebugGizmoSettings);
|
||||
};
|
||||
@@ -54,7 +54,6 @@ public class SenseGloveSettings : ModuleRules
|
||||
{
|
||||
"CoreUObject",
|
||||
"Engine",
|
||||
"InputCore",
|
||||
"SenseGloveCore",
|
||||
"SenseGloveLog",
|
||||
"SenseGloveTypes",
|
||||
|
||||
+71
-5
@@ -42,13 +42,79 @@ USGSettings* USGSettingsKismetLibrary::GetInstance()
|
||||
return USGSettings::GetInstance();
|
||||
}
|
||||
|
||||
const FSGWristTrackingSettings& USGSettingsKismetLibrary::GetWristTrackingSettings(const USGSettings* Settings)
|
||||
ESGPositionalTrackingHardware USGSettingsKismetLibrary::GetTrackingHardware(const USGSettings* Settings)
|
||||
{
|
||||
return Settings->GetWristTrackingSettings();
|
||||
return Settings->GetTrackingHardware();
|
||||
}
|
||||
|
||||
void USGSettingsKismetLibrary::SetWristTrackingSettings(
|
||||
USGSettings* Settings, const FSGWristTrackingSettings& InWristTrackingSettings)
|
||||
void USGSettingsKismetLibrary::SetTrackingHardware(
|
||||
USGSettings* Settings, const ESGPositionalTrackingHardware InTrackingHardware)
|
||||
{
|
||||
Settings->SetWristTrackingSettings(InWristTrackingSettings);
|
||||
Settings->SetTrackingHardware(InTrackingHardware);
|
||||
}
|
||||
|
||||
const FVector& USGSettingsKismetLibrary::GetTrackingHardwareLocationOffsetLeftHand(const USGSettings* Settings)
|
||||
{
|
||||
return Settings->GetTrackingHardwareLocationOffsetLeftHand();
|
||||
}
|
||||
|
||||
void USGSettingsKismetLibrary::SetTrackingHardwareLocationOffsetLeftHand(
|
||||
USGSettings* Settings, const FVector& InTrackingHardwareLocationOffsetLeftHand)
|
||||
{
|
||||
Settings->SetTrackingHardwareLocationOffsetLeftHand(InTrackingHardwareLocationOffsetLeftHand);
|
||||
}
|
||||
|
||||
const FVector& USGSettingsKismetLibrary::GetTrackingHardwareLocationOffsetRightHand(const USGSettings* Settings)
|
||||
{
|
||||
return Settings->GetTrackingHardwareLocationOffsetRightHand();
|
||||
}
|
||||
|
||||
void USGSettingsKismetLibrary::SetTrackingHardwareLocationOffsetRightHand(
|
||||
USGSettings* Settings, const FVector& InTrackingHardwareLocationOffsetRightHand)
|
||||
{
|
||||
Settings->SetTrackingHardwareLocationOffsetRightHand(InTrackingHardwareLocationOffsetRightHand);
|
||||
}
|
||||
|
||||
const FRotator& USGSettingsKismetLibrary::GetTrackingHardwareRotationOffsetLeftHand(const USGSettings* Settings)
|
||||
{
|
||||
return Settings->GetTrackingHardwareRotationOffsetLeftHand();
|
||||
}
|
||||
|
||||
void USGSettingsKismetLibrary::SetTrackingHardwareRotationOffsetLeftHand(
|
||||
USGSettings* Settings, const FRotator& InTrackingHardwareRotationOffsetLeftHand)
|
||||
{
|
||||
Settings->SetTrackingHardwareRotationOffsetLeftHand(InTrackingHardwareRotationOffsetLeftHand);
|
||||
}
|
||||
|
||||
const FRotator& USGSettingsKismetLibrary::GetTrackingHardwareRotationOffsetRightHand(const USGSettings* Settings)
|
||||
{
|
||||
return Settings->GetTrackingHardwareRotationOffsetRightHand();
|
||||
}
|
||||
|
||||
void USGSettingsKismetLibrary::SetTrackingHardwareRotationOffsetRightHand(
|
||||
USGSettings* Settings, const FRotator& InTrackingHardwareRotationOffsetRightHand)
|
||||
{
|
||||
Settings->SetTrackingHardwareRotationOffsetRightHand(InTrackingHardwareRotationOffsetRightHand);
|
||||
}
|
||||
|
||||
bool USGSettingsKismetLibrary::GetDrawWristTrackerDebugGizmo(const USGSettings* Settings)
|
||||
{
|
||||
return Settings->GetDrawWristTrackerDebugGizmo();
|
||||
}
|
||||
|
||||
void USGSettingsKismetLibrary::SetDrawWristTrackerDebugGizmo(
|
||||
USGSettings* Settings, const bool bInDrawWristTrackerDebugGizmo)
|
||||
{
|
||||
Settings->SetDrawWristTrackerDebugGizmo(bInDrawWristTrackerDebugGizmo);
|
||||
}
|
||||
|
||||
const FSGDebugGizmoSettings& USGSettingsKismetLibrary::GetWristTrackerDebugGizmoSettings(const USGSettings* Settings)
|
||||
{
|
||||
return Settings->GetWristTrackerDebugGizmoSettings();
|
||||
}
|
||||
|
||||
void USGSettingsKismetLibrary::SetWristTrackerDebugGizmoSettings(USGSettings* Settings,
|
||||
const FSGDebugGizmoSettings& InWristTrackerDebugGizmoSettings)
|
||||
{
|
||||
Settings->SetWristTrackerDebugGizmoSettings(InWristTrackerDebugGizmoSettings);
|
||||
}
|
||||
@@ -36,7 +36,9 @@
|
||||
#pragma once
|
||||
|
||||
#include "SGKismet/SGBlueprintFunctionLibrary.h"
|
||||
#include "SGSettings/SGWristTrackingSettings.h"
|
||||
#include "SGTypes/SGCoreTypes.h"
|
||||
|
||||
#include "SGSettings/SGDebugGizmoSettings.h"
|
||||
|
||||
#include "SGSettingsKismetLibrary.generated.h"
|
||||
|
||||
@@ -52,9 +54,50 @@ public:
|
||||
static USGSettings* GetInstance();
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Settings")
|
||||
static const FSGWristTrackingSettings& GetWristTrackingSettings(const USGSettings* Settings);
|
||||
static ESGPositionalTrackingHardware GetTrackingHardware(const USGSettings* Settings);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Settings")
|
||||
static void SetWristTrackingSettings(UPARAM(ref) USGSettings* Settings,
|
||||
const FSGWristTrackingSettings& InWristTrackingSettings);
|
||||
static void SetTrackingHardware(UPARAM(ref) USGSettings* Settings,
|
||||
ESGPositionalTrackingHardware InTrackingHardware);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Settings")
|
||||
static const FVector& GetTrackingHardwareLocationOffsetLeftHand(const USGSettings* Settings);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Settings")
|
||||
static void SetTrackingHardwareLocationOffsetLeftHand(UPARAM(ref) USGSettings* Settings,
|
||||
const FVector& InTrackingHardwareLocationOffsetLeftHand);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Settings")
|
||||
static const FVector& GetTrackingHardwareLocationOffsetRightHand(const USGSettings* Settings);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Settings")
|
||||
static void SetTrackingHardwareLocationOffsetRightHand(UPARAM(ref) USGSettings* Settings,
|
||||
const FVector& InTrackingHardwareLocationOffsetRightHand);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Settings")
|
||||
static const FRotator& GetTrackingHardwareRotationOffsetLeftHand(const USGSettings* Settings);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Settings")
|
||||
static void SetTrackingHardwareRotationOffsetLeftHand(UPARAM(ref) USGSettings* Settings,
|
||||
const FRotator& InTrackingHardwareRotationOffsetLeftHand);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Settings")
|
||||
static const FRotator& GetTrackingHardwareRotationOffsetRightHand(const USGSettings* Settings);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Settings")
|
||||
static void SetTrackingHardwareRotationOffsetRightHand(UPARAM(ref) USGSettings* Settings,
|
||||
const FRotator& InTrackingHardwareRotationOffsetRightHand);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Settings")
|
||||
static bool GetDrawWristTrackerDebugGizmo(const USGSettings* Settings);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Settings")
|
||||
static void SetDrawWristTrackerDebugGizmo(UPARAM(ref) USGSettings* Settings, bool bInDrawWristTrackerDebugGizmo);
|
||||
|
||||
UFUNCTION(BlueprintPure, Category="SenseGlove | Settings")
|
||||
static const FSGDebugGizmoSettings& GetWristTrackerDebugGizmoSettings(const USGSettings* Settings);
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category="SenseGlove | Settings")
|
||||
static void SetWristTrackerDebugGizmoSettings(UPARAM(ref) USGSettings* Settings,
|
||||
const FSGDebugGizmoSettings& InWristTrackerDebugGizmoSettings);
|
||||
};
|
||||
@@ -256,17 +256,20 @@ enum class ESGPositionalTrackingHardware : uint8
|
||||
/* Custom tracking hardware, we don't apply any offsets. */
|
||||
Custom UMETA(DisplayName = "Custom"),
|
||||
|
||||
/* HTC VIVE Tracker (v1.0 or v2.0). */
|
||||
ViveTracker UMETA(DisplayName = "VIVE Tracker"),
|
||||
/* HTC Vive Tracker (v1.0 or v2.0). */
|
||||
ViveTracker UMETA(DisplayName = "Vive Tracker"),
|
||||
|
||||
/* Oculus Touch controller (left or right) for Rift S and Quest 1. */
|
||||
OculusTouch UMETA(DisplayName = "Oculus Touch"),
|
||||
|
||||
/* Touch controller for Oculus Quest 2. */
|
||||
Quest2Controller UMETA(DisplayName = "Quest 2 Controller"),
|
||||
Quest2Controller UMETA(DisplayName = "Quest2 Controller"),
|
||||
|
||||
/* Wrist tracker for the VIVE Focus 3. */
|
||||
ViveFocus3WristTracker UMETA(DisplayName = "VIVE Focus 3 Wrist Tracker"),
|
||||
/* Pico Neo 2 Controller(s). */
|
||||
PicoNeo2 UMETA(DisplayName = "Pico Neo 2"),
|
||||
|
||||
/* Oculus Touch Controller that comes with the Meta Quest Pro. */
|
||||
QuestProController UMETA(DisplayName = "Quest Pro Controller"),
|
||||
/* Pico Neo 2 Controller(s). */
|
||||
PicoNeo3 UMETA(DisplayName = "Pico Neo 3"),
|
||||
};
|
||||
|
||||
/* Indices to access Sensor Data in Shared Memory. */
|
||||
|
||||
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user