artumino / PapyrusVR

Initial SKSE Plugin to expose OpenVR to Papyrus, feel free to make suggestions and open issues. BEWARE this is not a stable release, once PapyrusVR will be ready It will be published on the nexus.
GNU Lesser General Public License v3.0
11 stars 2 forks source link

Array size mismatch #2

Closed jacksoncougar closed 6 years ago

jacksoncougar commented 6 years ago

https://github.com/artumino/PapyrusVR/blob/19c8c0d1eba9bb31cfe85ee7dfe0852b8a42abb2/PapyrusVR_Module/VRManager.cpp#L32

_renderPoses and _gamePoses are declared using k_unMaxTrackedDeviceCount from PapyrusVR namespace which has a value of 16, but here you pass them with the size variable of vr::k_unMaxTrackedDeviceCount from the openVR namespace which has a size of 64.

artumino commented 6 years ago

The OpenVR version used in SkyrimVR is currently OpenVR 1.0.10 where k_unMaxTrackedDeviceCount is 16 (as you can see in v1.0.10 headers).

The value is currently duplicated in PapyrusVR in order to remove OpenVR dependency for other plugins that want to use PapyrusVR (and to avoid issues like this where the value differs from the latest available headers).

I'm leaving the issue open and labeling it as enhancement cause this was only a temporary solution to get things started and needs to change in the long run to avoid unnecessary confusion.

artumino commented 6 years ago

Closing this issue as the current SkyrimVR version doesn't have the mismatch anymore and both the k_unMaxTrackedDeviceCount defined in PapyrusVR and the one defined by OpenVR have the same value.