(chore): nova rewrite initial commit
No files matched your search
@@ -0,0 +1,2 @@
|
||||
ko_fi: hyblocker
|
||||
patreon: hekky
|
||||
@@ -0,0 +1,14 @@
|
||||
---
|
||||
name: Bug report
|
||||
about: Something is broken
|
||||
title: ''
|
||||
labels: bug
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
<!--
|
||||
If you are having trouble setting this up with SteamVR and would like help, the fastest way is to ask in the Discord group. https://discord.com/invite/m7g2Wyj
|
||||
|
||||
If you are having issues after updating SteamVR, please check for a new release at https://github.com/pushrax/OpenVR-SpaceCalibrator/releases before posting an issue.
|
||||
-->
|
||||
@@ -0,0 +1,10 @@
|
||||
---
|
||||
name: Feature request
|
||||
about: Suggest an idea for this project
|
||||
title: ''
|
||||
labels: enhancement
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
|
||||
|
After Width: | Height: | Size: 256 KiB |
|
After Width: | Height: | Size: 56 KiB |
|
After Width: | Height: | Size: 56 KiB |
@@ -0,0 +1,9 @@
|
||||
ipch
|
||||
.vs
|
||||
*.db
|
||||
*.opendb
|
||||
*.aps
|
||||
*.user
|
||||
.code
|
||||
/install/*.exe
|
||||
[bB]in
|
||||
@@ -0,0 +1,12 @@
|
||||
[submodule "vendor/imgui"]
|
||||
path = vendor/imgui
|
||||
url = https://github.com/ocornut/imgui
|
||||
[submodule "vendor/openvr"]
|
||||
path = vendor/openvr
|
||||
url = https://github.com/ValveSoftware/openvr
|
||||
[submodule "vendor/glfw"]
|
||||
path = vendor/glfw
|
||||
url = https://github.com/glfw/glfw
|
||||
[submodule "vendor/minhook"]
|
||||
path = vendor/minhook
|
||||
url = https://github.com/TsudaKageyu/minhook
|
||||
@@ -0,0 +1,60 @@
|
||||
cmake_minimum_required (VERSION 3.8)
|
||||
|
||||
set_property(GLOBAL PROPERTY USE_FOLDERS ON)
|
||||
|
||||
# Build directory
|
||||
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/artifacts)
|
||||
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/artifacts)
|
||||
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/artifacts)
|
||||
|
||||
# Function because lazy
|
||||
function(adjust_bin_paths lib)
|
||||
set_target_properties(${lib}
|
||||
PROPERTIES
|
||||
RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/artifacts
|
||||
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/artifacts
|
||||
ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/artifacts
|
||||
)
|
||||
endfunction()
|
||||
|
||||
project("SpaceCalibrator")
|
||||
|
||||
# Include project
|
||||
add_subdirectory ("src")
|
||||
|
||||
# 3rd party stuff
|
||||
add_subdirectory ("vendor")
|
||||
|
||||
if ("${CMAKE_CXX_COMPILER}" MATCHES "Clang" OR "${CMAKE_C_COMPILER_ID}" STREQUAL "Clang")
|
||||
# add_compile_options(-Werror=return-type -Wall -Wextra -Wpedantic /MP)
|
||||
add_compile_options(-Werror=return-type /MP)
|
||||
elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU" OR "${CMAKE_C_COMPILER_ID}" STREQUAL "GNU")
|
||||
# add_compile_options(-Werror=return-type -Wall -Wextra -Wpedantic)
|
||||
add_compile_options(-Werror=return-type)
|
||||
elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Intel" OR "${CMAKE_C_COMPILER_ID}" STREQUAL "Intel")
|
||||
# add_compile_options(-Werror=return-type -Wall -Wextra -Wpedantic)
|
||||
add_compile_options(/Qdiag-error-return)
|
||||
elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "MSVC" OR "${CMAKE_C_COMPILER_ID}" STREQUAL "MSVC")
|
||||
add_compile_options(
|
||||
# treat warnings as errors
|
||||
/we4715 # not all control paths return a value
|
||||
/we4828 # disallow invalid characters
|
||||
# prinf-like functions: format mismatch
|
||||
/we4473 # : not enough arguments passed for format string
|
||||
/we4474 # : too many arguments passed for format string
|
||||
/we4475 # : length modifier cannot be used with type field character in format specifier
|
||||
/we4476 # : unknown type field character in format specifier
|
||||
/we4477 # : format string requires an argument of type , but variadic argument has type
|
||||
/we4478 # : positional and non-positional placeholders cannot be mixed in the same format string
|
||||
/we4775 # nonstandard extension used in format string of function
|
||||
/we4776 # % is not allowed in the format string of function
|
||||
/we4777 # : format string requires an argument of type , but variadic argument has type
|
||||
/we4778 # : unterminated format string
|
||||
# macro arg mismatch
|
||||
/we4002 # too many actual parameters for macro 'identifier'
|
||||
/we4003 # not enough actual parameters for macro 'identifier'
|
||||
/Zc:threadSafeInit- # https://connect.microsoft.com/VisualStudio/feedback/details/1789709/visual-c-2015-runtime-broken-on-windows-server-2003-c-11-magic-statics
|
||||
/MP # multiprocessor compilation
|
||||
/utf-8 # utf-8 source & exec
|
||||
/GF) # eliminate duplicate strings
|
||||
endif()
|
||||
@@ -0,0 +1,2 @@
|
||||
@ECHO OFF
|
||||
cmake -G "Visual Studio 17 2022" -A x64 -B bin -S .
|
||||
@@ -0,0 +1,589 @@
|
||||
== Space Calibrator ==
|
||||
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2023-2025 Hyblocker and other contributors
|
||||
Copyright (c) 2020-2022 Justin Li and other contributors
|
||||
|
||||
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.
|
||||
|
||||
This software also includes components licensed as follows:
|
||||
|
||||
== MinHook ==
|
||||
|
||||
MinHook - The Minimalistic API Hooking Library for x64/x86
|
||||
Copyright (C) 2009-2017 Tsuda Kageyu.
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions
|
||||
are met:
|
||||
|
||||
1. Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
2. Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in the
|
||||
documentation and/or other materials provided with the distribution.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER
|
||||
OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
||||
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
||||
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
||||
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
================================================================================
|
||||
Portions of this software are Copyright (c) 2008-2009, Vyacheslav Patkov.
|
||||
================================================================================
|
||||
Hacker Disassembler Engine 32 C
|
||||
Copyright (c) 2008-2009, Vyacheslav Patkov.
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions
|
||||
are met:
|
||||
|
||||
1. Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
2. Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in the
|
||||
documentation and/or other materials provided with the distribution.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR
|
||||
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
||||
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
||||
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
||||
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
Hacker Disassembler Engine 64 C
|
||||
Copyright (c) 2008-2009, Vyacheslav Patkov.
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions
|
||||
are met:
|
||||
|
||||
1. Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
2. Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in the
|
||||
documentation and/or other materials provided with the distribution.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR
|
||||
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
||||
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
||||
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
||||
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
== ImGui ==
|
||||
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2014-2022 Omar Cornut
|
||||
|
||||
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.
|
||||
|
||||
== ImPlot ==
|
||||
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2020 Evan Pezent
|
||||
|
||||
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.
|
||||
|
||||
== glfw ==
|
||||
|
||||
Copyright (c) 2002-2006 Marcus Geelnard
|
||||
Copyright (c) 2006-2016 Camilla Berglund <elmindreda@glfw.org>
|
||||
|
||||
This software is provided 'as-is', without any express or implied
|
||||
warranty. In no event will the authors be held liable for any damages
|
||||
arising from the use of this software.
|
||||
|
||||
Permission is granted to anyone to use this software for any purpose,
|
||||
including commercial applications, and to alter it and redistribute it
|
||||
freely, subject to the following restrictions:
|
||||
|
||||
1. The origin of this software must not be misrepresented; you must not
|
||||
claim that you wrote the original software. If you use this software
|
||||
in a product, an acknowledgment in the product documentation would
|
||||
be appreciated but is not required.
|
||||
|
||||
2. Altered source versions must be plainly marked as such, and must not
|
||||
be misrepresented as being the original software.
|
||||
|
||||
3. This notice may not be removed or altered from any source
|
||||
distribution.
|
||||
|
||||
== gl3w ==
|
||||
|
||||
|
||||
This is free and unencumbered software released into the public domain.
|
||||
|
||||
Anyone is free to copy, modify, publish, use, compile, sell, or
|
||||
distribute this software, either in source code form or as a compiled
|
||||
binary, for any purpose, commercial or non-commercial, and by any
|
||||
means.
|
||||
|
||||
In jurisdictions that recognize copyright laws, the author or authors
|
||||
of this software dedicate any and all copyright interest in the
|
||||
software to the public domain. We make this dedication for the benefit
|
||||
of the public at large and to the detriment of our heirs and
|
||||
successors. We intend this dedication to be an overt act of
|
||||
relinquishment in perpetuity of all present and future rights to this
|
||||
software under copyright law.
|
||||
|
||||
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 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.
|
||||
|
||||
== Eigen ==
|
||||
|
||||
Portions copyrighted by many parties; see source code for names.
|
||||
(The upstream distribution does not provide any single listing)
|
||||
|
||||
This application uses only the MPL-2.0 licensed components of Eigen.
|
||||
|
||||
Mozilla Public License Version 2.0
|
||||
==================================
|
||||
|
||||
1. Definitions
|
||||
--------------
|
||||
|
||||
1.1. "Contributor"
|
||||
means each individual or legal entity that creates, contributes to
|
||||
the creation of, or owns Covered Software.
|
||||
|
||||
1.2. "Contributor Version"
|
||||
means the combination of the Contributions of others (if any) used
|
||||
by a Contributor and that particular Contributor's Contribution.
|
||||
|
||||
1.3. "Contribution"
|
||||
means Covered Software of a particular Contributor.
|
||||
|
||||
1.4. "Covered Software"
|
||||
means Source Code Form to which the initial Contributor has attached
|
||||
the notice in Exhibit A, the Executable Form of such Source Code
|
||||
Form, and Modifications of such Source Code Form, in each case
|
||||
including portions thereof.
|
||||
|
||||
1.5. "Incompatible With Secondary Licenses"
|
||||
means
|
||||
|
||||
(a) that the initial Contributor has attached the notice described
|
||||
in Exhibit B to the Covered Software; or
|
||||
|
||||
(b) that the Covered Software was made available under the terms of
|
||||
version 1.1 or earlier of the License, but not also under the
|
||||
terms of a Secondary License.
|
||||
|
||||
1.6. "Executable Form"
|
||||
means any form of the work other than Source Code Form.
|
||||
|
||||
1.7. "Larger Work"
|
||||
means a work that combines Covered Software with other material, in
|
||||
a separate file or files, that is not Covered Software.
|
||||
|
||||
1.8. "License"
|
||||
means this document.
|
||||
|
||||
1.9. "Licensable"
|
||||
means having the right to grant, to the maximum extent possible,
|
||||
whether at the time of the initial grant or subsequently, any and
|
||||
all of the rights conveyed by this License.
|
||||
|
||||
1.10. "Modifications"
|
||||
means any of the following:
|
||||
|
||||
(a) any file in Source Code Form that results from an addition to,
|
||||
deletion from, or modification of the contents of Covered
|
||||
Software; or
|
||||
|
||||
(b) any new file in Source Code Form that contains any Covered
|
||||
Software.
|
||||
|
||||
1.11. "Patent Claims" of a Contributor
|
||||
means any patent claim(s), including without limitation, method,
|
||||
process, and apparatus claims, in any patent Licensable by such
|
||||
Contributor that would be infringed, but for the grant of the
|
||||
License, by the making, using, selling, offering for sale, having
|
||||
made, import, or transfer of either its Contributions or its
|
||||
Contributor Version.
|
||||
|
||||
1.12. "Secondary License"
|
||||
means either the GNU General Public License, Version 2.0, the GNU
|
||||
Lesser General Public License, Version 2.1, the GNU Affero General
|
||||
Public License, Version 3.0, or any later versions of those
|
||||
licenses.
|
||||
|
||||
1.13. "Source Code Form"
|
||||
means the form of the work preferred for making modifications.
|
||||
|
||||
1.14. "You" (or "Your")
|
||||
means an individual or a legal entity exercising rights under this
|
||||
License. For legal entities, "You" includes any entity that
|
||||
controls, is controlled by, or is under common control with You. For
|
||||
purposes of this definition, "control" means (a) the power, direct
|
||||
or indirect, to cause the direction or management of such entity,
|
||||
whether by contract or otherwise, or (b) ownership of more than
|
||||
fifty percent (50%) of the outstanding shares or beneficial
|
||||
ownership of such entity.
|
||||
|
||||
2. License Grants and Conditions
|
||||
--------------------------------
|
||||
|
||||
2.1. Grants
|
||||
|
||||
Each Contributor hereby grants You a world-wide, royalty-free,
|
||||
non-exclusive license:
|
||||
|
||||
(a) under intellectual property rights (other than patent or trademark)
|
||||
Licensable by such Contributor to use, reproduce, make available,
|
||||
modify, display, perform, distribute, and otherwise exploit its
|
||||
Contributions, either on an unmodified basis, with Modifications, or
|
||||
as part of a Larger Work; and
|
||||
|
||||
(b) under Patent Claims of such Contributor to make, use, sell, offer
|
||||
for sale, have made, import, and otherwise transfer either its
|
||||
Contributions or its Contributor Version.
|
||||
|
||||
2.2. Effective Date
|
||||
|
||||
The licenses granted in Section 2.1 with respect to any Contribution
|
||||
become effective for each Contribution on the date the Contributor first
|
||||
distributes such Contribution.
|
||||
|
||||
2.3. Limitations on Grant Scope
|
||||
|
||||
The licenses granted in this Section 2 are the only rights granted under
|
||||
this License. No additional rights or licenses will be implied from the
|
||||
distribution or licensing of Covered Software under this License.
|
||||
Notwithstanding Section 2.1(b) above, no patent license is granted by a
|
||||
Contributor:
|
||||
|
||||
(a) for any code that a Contributor has removed from Covered Software;
|
||||
or
|
||||
|
||||
(b) for infringements caused by: (i) Your and any other third party's
|
||||
modifications of Covered Software, or (ii) the combination of its
|
||||
Contributions with other software (except as part of its Contributor
|
||||
Version); or
|
||||
|
||||
(c) under Patent Claims infringed by Covered Software in the absence of
|
||||
its Contributions.
|
||||
|
||||
This License does not grant any rights in the trademarks, service marks,
|
||||
or logos of any Contributor (except as may be necessary to comply with
|
||||
the notice requirements in Section 3.4).
|
||||
|
||||
2.4. Subsequent Licenses
|
||||
|
||||
No Contributor makes additional grants as a result of Your choice to
|
||||
distribute the Covered Software under a subsequent version of this
|
||||
License (see Section 10.2) or under the terms of a Secondary License (if
|
||||
permitted under the terms of Section 3.3).
|
||||
|
||||
2.5. Representation
|
||||
|
||||
Each Contributor represents that the Contributor believes its
|
||||
Contributions are its original creation(s) or it has sufficient rights
|
||||
to grant the rights to its Contributions conveyed by this License.
|
||||
|
||||
2.6. Fair Use
|
||||
|
||||
This License is not intended to limit any rights You have under
|
||||
applicable copyright doctrines of fair use, fair dealing, or other
|
||||
equivalents.
|
||||
|
||||
2.7. Conditions
|
||||
|
||||
Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted
|
||||
in Section 2.1.
|
||||
|
||||
3. Responsibilities
|
||||
-------------------
|
||||
|
||||
3.1. Distribution of Source Form
|
||||
|
||||
All distribution of Covered Software in Source Code Form, including any
|
||||
Modifications that You create or to which You contribute, must be under
|
||||
the terms of this License. You must inform recipients that the Source
|
||||
Code Form of the Covered Software is governed by the terms of this
|
||||
License, and how they can obtain a copy of this License. You may not
|
||||
attempt to alter or restrict the recipients' rights in the Source Code
|
||||
Form.
|
||||
|
||||
3.2. Distribution of Executable Form
|
||||
|
||||
If You distribute Covered Software in Executable Form then:
|
||||
|
||||
(a) such Covered Software must also be made available in Source Code
|
||||
Form, as described in Section 3.1, and You must inform recipients of
|
||||
the Executable Form how they can obtain a copy of such Source Code
|
||||
Form by reasonable means in a timely manner, at a charge no more
|
||||
than the cost of distribution to the recipient; and
|
||||
|
||||
(b) You may distribute such Executable Form under the terms of this
|
||||
License, or sublicense it under different terms, provided that the
|
||||
license for the Executable Form does not attempt to limit or alter
|
||||
the recipients' rights in the Source Code Form under this License.
|
||||
|
||||
3.3. Distribution of a Larger Work
|
||||
|
||||
You may create and distribute a Larger Work under terms of Your choice,
|
||||
provided that You also comply with the requirements of this License for
|
||||
the Covered Software. If the Larger Work is a combination of Covered
|
||||
Software with a work governed by one or more Secondary Licenses, and the
|
||||
Covered Software is not Incompatible With Secondary Licenses, this
|
||||
License permits You to additionally distribute such Covered Software
|
||||
under the terms of such Secondary License(s), so that the recipient of
|
||||
the Larger Work may, at their option, further distribute the Covered
|
||||
Software under the terms of either this License or such Secondary
|
||||
License(s).
|
||||
|
||||
3.4. Notices
|
||||
|
||||
You may not remove or alter the substance of any license notices
|
||||
(including copyright notices, patent notices, disclaimers of warranty,
|
||||
or limitations of liability) contained within the Source Code Form of
|
||||
the Covered Software, except that You may alter any license notices to
|
||||
the extent required to remedy known factual inaccuracies.
|
||||
|
||||
3.5. Application of Additional Terms
|
||||
|
||||
You may choose to offer, and to charge a fee for, warranty, support,
|
||||
indemnity or liability obligations to one or more recipients of Covered
|
||||
Software. However, You may do so only on Your own behalf, and not on
|
||||
behalf of any Contributor. You must make it absolutely clear that any
|
||||
such warranty, support, indemnity, or liability obligation is offered by
|
||||
You alone, and You hereby agree to indemnify every Contributor for any
|
||||
liability incurred by such Contributor as a result of warranty, support,
|
||||
indemnity or liability terms You offer. You may include additional
|
||||
disclaimers of warranty and limitations of liability specific to any
|
||||
jurisdiction.
|
||||
|
||||
4. Inability to Comply Due to Statute or Regulation
|
||||
---------------------------------------------------
|
||||
|
||||
If it is impossible for You to comply with any of the terms of this
|
||||
License with respect to some or all of the Covered Software due to
|
||||
statute, judicial order, or regulation then You must: (a) comply with
|
||||
the terms of this License to the maximum extent possible; and (b)
|
||||
describe the limitations and the code they affect. Such description must
|
||||
be placed in a text file included with all distributions of the Covered
|
||||
Software under this License. Except to the extent prohibited by statute
|
||||
or regulation, such description must be sufficiently detailed for a
|
||||
recipient of ordinary skill to be able to understand it.
|
||||
|
||||
5. Termination
|
||||
--------------
|
||||
|
||||
5.1. The rights granted under this License will terminate automatically
|
||||
if You fail to comply with any of its terms. However, if You become
|
||||
compliant, then the rights granted under this License from a particular
|
||||
Contributor are reinstated (a) provisionally, unless and until such
|
||||
Contributor explicitly and finally terminates Your grants, and (b) on an
|
||||
ongoing basis, if such Contributor fails to notify You of the
|
||||
non-compliance by some reasonable means prior to 60 days after You have
|
||||
come back into compliance. Moreover, Your grants from a particular
|
||||
Contributor are reinstated on an ongoing basis if such Contributor
|
||||
notifies You of the non-compliance by some reasonable means, this is the
|
||||
first time You have received notice of non-compliance with this License
|
||||
from such Contributor, and You become compliant prior to 30 days after
|
||||
Your receipt of the notice.
|
||||
|
||||
5.2. If You initiate litigation against any entity by asserting a patent
|
||||
infringement claim (excluding declaratory judgment actions,
|
||||
counter-claims, and cross-claims) alleging that a Contributor Version
|
||||
directly or indirectly infringes any patent, then the rights granted to
|
||||
You by any and all Contributors for the Covered Software under Section
|
||||
2.1 of this License shall terminate.
|
||||
|
||||
5.3. In the event of termination under Sections 5.1 or 5.2 above, all
|
||||
end user license agreements (excluding distributors and resellers) which
|
||||
have been validly granted by You or Your distributors under this License
|
||||
prior to termination shall survive termination.
|
||||
|
||||
************************************************************************
|
||||
* *
|
||||
* 6. Disclaimer of Warranty *
|
||||
* ------------------------- *
|
||||
* *
|
||||
* Covered Software is provided under this License on an "as is" *
|
||||
* basis, without warranty of any kind, either expressed, implied, or *
|
||||
* statutory, including, without limitation, warranties that the *
|
||||
* Covered Software is free of defects, merchantable, fit for a *
|
||||
* particular purpose or non-infringing. The entire risk as to the *
|
||||
* quality and performance of the Covered Software is with You. *
|
||||
* Should any Covered Software prove defective in any respect, You *
|
||||
* (not any Contributor) assume the cost of any necessary servicing, *
|
||||
* repair, or correction. This disclaimer of warranty constitutes an *
|
||||
* essential part of this License. No use of any Covered Software is *
|
||||
* authorized under this License except under this disclaimer. *
|
||||
* *
|
||||
************************************************************************
|
||||
|
||||
************************************************************************
|
||||
* *
|
||||
* 7. Limitation of Liability *
|
||||
* -------------------------- *
|
||||
* *
|
||||
* Under no circumstances and under no legal theory, whether tort *
|
||||
* (including negligence), contract, or otherwise, shall any *
|
||||
* Contributor, or anyone who distributes Covered Software as *
|
||||
* permitted above, be liable to You for any direct, indirect, *
|
||||
* special, incidental, or consequential damages of any character *
|
||||
* including, without limitation, damages for lost profits, loss of *
|
||||
* goodwill, work stoppage, computer failure or malfunction, or any *
|
||||
* and all other commercial damages or losses, even if such party *
|
||||
* shall have been informed of the possibility of such damages. This *
|
||||
* limitation of liability shall not apply to liability for death or *
|
||||
* personal injury resulting from such party's negligence to the *
|
||||
* extent applicable law prohibits such limitation. Some *
|
||||
* jurisdictions do not allow the exclusion or limitation of *
|
||||
* incidental or consequential damages, so this exclusion and *
|
||||
* limitation may not apply to You. *
|
||||
* *
|
||||
************************************************************************
|
||||
|
||||
8. Litigation
|
||||
-------------
|
||||
|
||||
Any litigation relating to this License may be brought only in the
|
||||
courts of a jurisdiction where the defendant maintains its principal
|
||||
place of business and such litigation shall be governed by laws of that
|
||||
jurisdiction, without reference to its conflict-of-law provisions.
|
||||
Nothing in this Section shall prevent a party's ability to bring
|
||||
cross-claims or counter-claims.
|
||||
|
||||
9. Miscellaneous
|
||||
----------------
|
||||
|
||||
This License represents the complete agreement concerning the subject
|
||||
matter hereof. If any provision of this License is held to be
|
||||
unenforceable, such provision shall be reformed only to the extent
|
||||
necessary to make it enforceable. Any law or regulation which provides
|
||||
that the language of a contract shall be construed against the drafter
|
||||
shall not be used to construe this License against a Contributor.
|
||||
|
||||
10. Versions of the License
|
||||
---------------------------
|
||||
|
||||
10.1. New Versions
|
||||
|
||||
Mozilla Foundation is the license steward. Except as provided in Section
|
||||
10.3, no one other than the license steward has the right to modify or
|
||||
publish new versions of this License. Each version will be given a
|
||||
distinguishing version number.
|
||||
|
||||
10.2. Effect of New Versions
|
||||
|
||||
You may distribute the Covered Software under the terms of the version
|
||||
of the License under which You originally received the Covered Software,
|
||||
or under the terms of any subsequent version published by the license
|
||||
steward.
|
||||
|
||||
10.3. Modified Versions
|
||||
|
||||
If you create software not governed by this License, and you want to
|
||||
create a new license for such software, you may create and use a
|
||||
modified version of this License if you rename the license and remove
|
||||
any references to the name of the license steward (except to note that
|
||||
such modified license differs from this License).
|
||||
|
||||
10.4. Distributing Source Code Form that is Incompatible With Secondary
|
||||
Licenses
|
||||
|
||||
If You choose to distribute Source Code Form that is Incompatible With
|
||||
Secondary Licenses under the terms of this version of the License, the
|
||||
notice described in Exhibit B of this License must be attached.
|
||||
|
||||
Exhibit A - Source Code Form License Notice
|
||||
-------------------------------------------
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
If it is not possible or desirable to put the notice in a particular
|
||||
file, then You may include the notice in a location (such as a LICENSE
|
||||
file in a relevant directory) where a recipient would be likely to look
|
||||
for such a notice.
|
||||
|
||||
You may add additional accurate notices of copyright ownership.
|
||||
|
||||
Exhibit B - "Incompatible With Secondary Licenses" Notice
|
||||
---------------------------------------------------------
|
||||
|
||||
This Source Code Form is "Incompatible With Secondary Licenses", as
|
||||
defined by the Mozilla Public License, v. 2.0.
|
||||
@@ -0,0 +1 @@
|
||||
You may find the source code of this program at https://github.com/hyblocker/OpenVR-SpaceCalibrator . You should also have a LICENSE file alongside this one.
|
||||
@@ -0,0 +1,55 @@
|
||||
<picture>
|
||||
<source media="(prefers-color-scheme: dark)" srcset="https://github.com/hyblocker/OpenVR-SpaceCalibrator/blob/develop/.github/logo_light.png?raw=true">
|
||||
<source media="(prefers-color-scheme: light)" srcset="https://github.com/hyblocker/OpenVR-SpaceCalibrator/blob/develop/.github/logo_dark.png?raw=true">
|
||||
<img alt="Space Calibrator" src="https://github.com/hyblocker/OpenVR-SpaceCalibrator/blob/develop/.github/logo.png?raw=true">
|
||||
</picture>
|
||||
|
||||
This program is designed to allow you to synchronise multiple playspaces with one another in SteamVR. This fork of Space Calibrator (spacecal) also supports [continuous calibration](#continuous-calibration).
|
||||
|
||||
Continuous calibration is a tracking mode which automatically aligns playspaces together, using a tracker on the headset.
|
||||
|
||||
## Installing
|
||||
|
||||
### Steam
|
||||
|
||||
> [!NOTE]
|
||||
> **Space Calibrator is also available to Steam.**
|
||||
|
||||
You may find [Space Calibrator on Steam here](https://s.team/a/3368750).
|
||||
|
||||
### From GitHub
|
||||
|
||||
To install Space Calibrator, please get the latest installer from the downloads page, and install it. Make sure that you have:
|
||||
- Installed [Visual C++ Redistributable](https://aka.ms/vs/17/release/vc_redist.x64.exe).
|
||||
- Installed SteamVR and run it at least once with a VR headset connected.
|
||||
- SteamVR is not running before you run the installer. If SteamVR is running the installer will not be able to install Space Calibrator correctly.
|
||||
|
||||
## Calibration
|
||||
|
||||
If you do not wish to use continuous calibration, you will have to use regular calibration. This means that every so often you will have to sync your headset's playspace with your tracker's playspace.
|
||||
|
||||
To calibrate:
|
||||
1. Copy the chaperone/guardian bounds from your HMD's play space
|
||||
> You will only have to do this once. Connect your VR headset and start SteamVR. Then go to space calibrator's window (it will be minimised), and click the "Copy Chaperone" button.
|
||||
|
||||
2. Open the SteamVR dashboard. At the bottom, click on the Space Calibrator icon.
|
||||
3. In the Space Calibrator overlay, you'll see two lists at the top. On the left `Reference Space` column, select the controller you'll be calibrating along (e.g. Quest controller, Pico controller). On the right `Target Space`, select your SteamVR tracker (e.g. Vive Ultimate Tracker, Vive Tracker 3.0, Vive Ultimate Tracker). You can use the Identify button to make the controllers blink and tracker LEDs flash to see if you've selected the correct ones.
|
||||
4. Click the "Start calibration" button, and start calibrating.
|
||||
|
||||
## Continuous Calibration
|
||||
|
||||
> [!IMPORTANT]
|
||||
> **A tracker attached on your headset is required for this.**
|
||||
|
||||
To enable continuous calibration mode, first select your headset on the left column, then the tracker on your headset on the right column. Once you've done so, click `Start Calibration`, and click cancel. Then click `Continuous Calibration` to enable continuous calibration.
|
||||
|
||||
1. Start SteamVR with the VR headset you wish to use.
|
||||
2. Turn on **ONLY** the tracker which is attached on the VR headset.
|
||||
3. Select the VR headset and tracker and calibrate.
|
||||
4. Turn on your other devices.
|
||||
5. You should see them line up with you as you after moving around your playspace for a bit for an initial calibration.
|
||||
|
||||
|
||||
## Help
|
||||
|
||||
If you need help with setting up this program, please check the [wiki](https://github.com/pushrax/OpenVR-SpaceCalibrator/wiki), or join the [Discord server](https://discord.gg/ja3WgNjC3z).
|
||||
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"alwaysActivate": true,
|
||||
"name" : "01spacecalibrator",
|
||||
"directory" : "",
|
||||
"resourceOnly" : false,
|
||||
"activateOtherDriversWhenEnabled" : true
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"jsonid" : "vrresources",
|
||||
"statusicons" : {
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"driver_01spacecalibrator": {
|
||||
"loadPriority": 9999
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,207 @@
|
||||
;--------------------------------
|
||||
;Include Modern UI
|
||||
|
||||
!include "MUI2.nsh"
|
||||
|
||||
;--------------------------------
|
||||
;General
|
||||
|
||||
!define OVERLAY_BASEDIR "..\client_overlay\bin\win64"
|
||||
!define ARTIFACTS_BASEDIR "..\bin\artifacts\Release"
|
||||
!define DRIVER_RESDIR "..\bin\driver_01spacecalibrator"
|
||||
|
||||
Name "Space Calibrator"
|
||||
OutFile "SpaceCalibrator.exe"
|
||||
InstallDir "$PROGRAMFILES64\SpaceCalibrator"
|
||||
InstallDirRegKey HKLM "Software\SpaceCalibrator\Main" ""
|
||||
RequestExecutionLevel admin
|
||||
ShowInstDetails show
|
||||
|
||||
; Define the version number
|
||||
!define VERSION "1.5.1.0"
|
||||
; Set version information
|
||||
VIProductVersion "${VERSION}"
|
||||
VIAddVersionKey /LANG=1033 "ProductName" "Space Calibrator"
|
||||
VIAddVersionKey /LANG=1033 "FileDescription" "Space Calibrator Installer"
|
||||
VIAddVersionKey /LANG=1033 "LegalCopyright" "Open source at https://github.com/hyblocker/OpenVR-SpaceCalibrator"
|
||||
VIAddVersionKey /LANG=1033 "FileVersion" "${VERSION}"
|
||||
VIAddVersionKey /LANG=1033 "ProductVersion" "${VERSION}"
|
||||
|
||||
;--------------------------------
|
||||
;Variables
|
||||
|
||||
VAR upgradeInstallation
|
||||
|
||||
;--------------------------------
|
||||
;Interface Settings
|
||||
|
||||
!define MUI_ABORTWARNING
|
||||
|
||||
;--------------------------------
|
||||
;Pages
|
||||
|
||||
!insertmacro MUI_PAGE_LICENSE "..\LICENSE"
|
||||
!define MUI_PAGE_CUSTOMFUNCTION_PRE dirPre
|
||||
!insertmacro MUI_PAGE_DIRECTORY
|
||||
!insertmacro MUI_PAGE_INSTFILES
|
||||
|
||||
!insertmacro MUI_UNPAGE_CONFIRM
|
||||
!insertmacro MUI_UNPAGE_INSTFILES
|
||||
|
||||
;--------------------------------
|
||||
;Languages
|
||||
|
||||
!insertmacro MUI_LANGUAGE "English"
|
||||
|
||||
;--------------------------------
|
||||
;Macros
|
||||
|
||||
;--------------------------------
|
||||
;Functions
|
||||
|
||||
Function dirPre
|
||||
StrCmp $upgradeInstallation "true" 0 +2
|
||||
Abort
|
||||
FunctionEnd
|
||||
|
||||
Function .onInit
|
||||
StrCpy $upgradeInstallation "false"
|
||||
|
||||
ReadRegStr $R0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenVRSpaceCalibrator" "UninstallString"
|
||||
StrCmp $R0 "" done
|
||||
|
||||
|
||||
; If SteamVR is already running, display a warning message and exit
|
||||
FindWindow $0 "Qt5QWindowIcon" "SteamVR Status"
|
||||
StrCmp $0 0 +3
|
||||
MessageBox MB_OK|MB_ICONEXCLAMATION \
|
||||
"SteamVR is still running. Cannot install this software.$\nPlease close SteamVR and try again."
|
||||
Abort
|
||||
|
||||
|
||||
MessageBox MB_OKCANCEL|MB_ICONEXCLAMATION \
|
||||
"Space Calibrator is already installed. $\n$\nClick `OK` to upgrade the \
|
||||
existing installation or `Cancel` to cancel this upgrade." \
|
||||
IDOK upgrade
|
||||
Abort
|
||||
|
||||
upgrade:
|
||||
StrCpy $upgradeInstallation "true"
|
||||
done:
|
||||
FunctionEnd
|
||||
|
||||
;--------------------------------
|
||||
;Installer Sections
|
||||
|
||||
Section "Install" SecInstall
|
||||
|
||||
StrCmp $upgradeInstallation "true" 0 noupgrade
|
||||
DetailPrint "Uninstall previous version..."
|
||||
ExecWait '"$INSTDIR\Uninstall.exe" /S _?=$INSTDIR'
|
||||
Delete $INSTDIR\Uninstall.exe
|
||||
Goto afterupgrade
|
||||
|
||||
noupgrade:
|
||||
|
||||
afterupgrade:
|
||||
|
||||
SetOutPath "$INSTDIR"
|
||||
|
||||
File "${ARTIFACTS_BASEDIR}\LICENSE"
|
||||
File "${ARTIFACTS_BASEDIR}\README"
|
||||
File "${ARTIFACTS_BASEDIR}\SpaceCalibrator.exe"
|
||||
File "${ARTIFACTS_BASEDIR}\openvr_api.dll"
|
||||
File "${ARTIFACTS_BASEDIR}\manifest.vrmanifest"
|
||||
File "${ARTIFACTS_BASEDIR}\icon.png"
|
||||
File "${ARTIFACTS_BASEDIR}\taskbar_icon.png"
|
||||
|
||||
ExecWait '"$INSTDIR\vcredist_x64.exe" /install /quiet'
|
||||
|
||||
Var /GLOBAL vrRuntimePath
|
||||
nsExec::ExecToStack '"$INSTDIR\SpaceCalibrator.exe" -openvrpath'
|
||||
Pop $0
|
||||
Pop $vrRuntimePath
|
||||
DetailPrint "VR runtime path: $vrRuntimePath"
|
||||
|
||||
; Old beta driver
|
||||
StrCmp $upgradeInstallation "true" 0 nocleanupbeta
|
||||
Delete "$vrRuntimePath\drivers\000spacecalibrator\driver.vrdrivermanifest"
|
||||
Delete "$vrRuntimePath\drivers\000spacecalibrator\resources\driver.vrresources"
|
||||
Delete "$vrRuntimePath\drivers\000spacecalibrator\resources\settings\default.vrsettings"
|
||||
Delete "$vrRuntimePath\drivers\000spacecalibrator\bin\win64\driver_000spacecalibrator.dll"
|
||||
Delete "$vrRuntimePath\drivers\000spacecalibrator\bin\win64\space_calibrator_driver.log"
|
||||
RMdir "$vrRuntimePath\drivers\000spacecalibrator\resources\settings"
|
||||
RMdir "$vrRuntimePath\drivers\000spacecalibrator\resources\"
|
||||
RMdir "$vrRuntimePath\drivers\000spacecalibrator\bin\win64\"
|
||||
RMdir "$vrRuntimePath\drivers\000spacecalibrator\bin\"
|
||||
RMdir "$vrRuntimePath\drivers\000spacecalibrator\"
|
||||
nocleanupbeta:
|
||||
|
||||
SetOutPath "$vrRuntimePath\drivers\01spacecalibrator"
|
||||
File "${DRIVER_RESDIR}\driver.vrdrivermanifest"
|
||||
SetOutPath "$vrRuntimePath\drivers\01spacecalibrator\resources"
|
||||
File "${DRIVER_RESDIR}\resources\driver.vrresources"
|
||||
SetOutPath "$vrRuntimePath\drivers\01spacecalibrator\resources\settings"
|
||||
File "${DRIVER_RESDIR}\resources\settings\default.vrsettings"
|
||||
SetOutPath "$vrRuntimePath\drivers\01spacecalibrator\bin\win64"
|
||||
File "${DRIVER_RESDIR}\bin\win64\driver_01spacecalibrator.dll"
|
||||
|
||||
WriteRegStr HKLM "Software\SpaceCalibrator\Main" "" $INSTDIR
|
||||
WriteRegStr HKLM "Software\SpaceCalibrator\Driver" "" $vrRuntimePath
|
||||
|
||||
WriteUninstaller "$INSTDIR\Uninstall.exe"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenVRSpaceCalibrator" "DisplayName" "Space Calibrator"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenVRSpaceCalibrator" "UninstallString" "$\"$INSTDIR\Uninstall.exe$\""
|
||||
|
||||
CreateShortCut "$SMPROGRAMS\Space Calibrator.lnk" "$INSTDIR\SpaceCalibrator.exe"
|
||||
|
||||
SetOutPath "$INSTDIR"
|
||||
nsExec::ExecToLog '"$INSTDIR\SpaceCalibrator.exe" -installmanifest'
|
||||
nsExec::ExecToLog '"$INSTDIR\SpaceCalibrator.exe" -activatemultipledrivers'
|
||||
|
||||
SectionEnd
|
||||
|
||||
;--------------------------------
|
||||
;Uninstaller Section
|
||||
|
||||
Section "Uninstall"
|
||||
; If SteamVR is already running, display a warning message and exit
|
||||
FindWindow $0 "Qt5QWindowIcon" "SteamVR Status"
|
||||
StrCmp $0 0 +3
|
||||
MessageBox MB_OK|MB_ICONEXCLAMATION \
|
||||
"SteamVR is still running. Cannot uninstall this software.$\nPlease close SteamVR and try again."
|
||||
Abort
|
||||
|
||||
SetOutPath "$INSTDIR"
|
||||
nsExec::ExecToLog '"$INSTDIR\SpaceCalibrator.exe" -removemanifest'
|
||||
|
||||
Var /GLOBAL vrRuntimePath2
|
||||
ReadRegStr $vrRuntimePath2 HKLM "Software\SpaceCalibrator\Driver" ""
|
||||
DetailPrint "VR runtime path: $vrRuntimePath2"
|
||||
Delete "$vrRuntimePath2\drivers\01spacecalibrator\driver.vrdrivermanifest"
|
||||
Delete "$vrRuntimePath2\drivers\01spacecalibrator\resources\driver.vrresources"
|
||||
Delete "$vrRuntimePath2\drivers\01spacecalibrator\resources\settings\default.vrsettings"
|
||||
Delete "$vrRuntimePath2\drivers\01spacecalibrator\bin\win64\driver_01spacecalibrator.dll"
|
||||
Delete "$vrRuntimePath2\drivers\01spacecalibrator\bin\win64\space_calibrator_driver.log"
|
||||
RMdir "$vrRuntimePath2\drivers\01spacecalibrator\resources\settings"
|
||||
RMdir "$vrRuntimePath2\drivers\01spacecalibrator\resources\"
|
||||
RMdir "$vrRuntimePath2\drivers\01spacecalibrator\bin\win64\"
|
||||
RMdir "$vrRuntimePath2\drivers\01spacecalibrator\bin\"
|
||||
RMdir "$vrRuntimePath2\drivers\01spacecalibrator\"
|
||||
|
||||
Delete "$INSTDIR\LICENSE"
|
||||
Delete "$INSTDIR\README"
|
||||
Delete "$INSTDIR\SpaceCalibrator.exe"
|
||||
Delete "$INSTDIR\openvr_api.dll"
|
||||
Delete "$INSTDIR\manifest.vrmanifest"
|
||||
Delete "$INSTDIR\icon.png"
|
||||
Delete "$INSTDIR\taskbar_icon.png"
|
||||
|
||||
DeleteRegKey HKLM "Software\SpaceCalibrator\Main"
|
||||
DeleteRegKey HKLM "Software\SpaceCalibrator\Driver"
|
||||
DeleteRegKey HKLM "Software\SpaceCalibrator"
|
||||
DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\OpenVRSpaceCalibrator"
|
||||
|
||||
Delete "$SMPROGRAMS\Space Calibrator.lnk"
|
||||
SectionEnd
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
# SteamVR Overlay
|
||||
add_subdirectory ("overlay")
|
||||
|
||||
# SteamVR Driver
|
||||
add_subdirectory ("driver")
|
||||
@@ -0,0 +1 @@
|
||||
#pragma once
|
||||
@@ -0,0 +1,153 @@
|
||||
cmake_minimum_required (VERSION 3.8)
|
||||
|
||||
project(SpaceCalibratorDriver CXX)
|
||||
message("SpaceCalibrator - Driver")
|
||||
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||
set(CMAKE_CXX_EXTENSIONS OFF)
|
||||
|
||||
# This is your project name
|
||||
set(TARGET_NAME 01spacecalibrator)
|
||||
|
||||
# This is the name that the binary will be called (driver_01spacecalibrator)
|
||||
set(DRIVER_NAME "driver_${TARGET_NAME}")
|
||||
|
||||
foreach(config_type RELEASE RELWITHDEBINFO MINSIZEREL)
|
||||
set(CMAKE_CXX_FLAGS_${config_type} "${CMAKE_CXX_FLAGS_${config_type}} /Ob2 /Zc:inline")
|
||||
set(CMAKE_SHARED_LINKER_FLAGS_${config_type} "${CMAKE_SHARED_LINKER_FLAGS_${config_type}} /LTCG /OPT:REF /OPT:ICF")
|
||||
endforeach()
|
||||
|
||||
function(GroupSourcesByFolder target)
|
||||
set(SOURCE_GROUP_DELIMITER "/")
|
||||
set(last_dir "")
|
||||
set(files "")
|
||||
|
||||
get_target_property(sources ${target} SOURCES)
|
||||
|
||||
foreach(file ${sources})
|
||||
file(RELATIVE_PATH relative_file "${PROJECT_SOURCE_DIR}" ${file})
|
||||
get_filename_component(dir "${relative_file}" PATH)
|
||||
if(NOT "${dir}" STREQUAL "${last_dir}")
|
||||
if(files)
|
||||
source_group("${last_dir}" FILES ${files})
|
||||
endif()
|
||||
set(files "")
|
||||
endif()
|
||||
set(files ${files} ${file})
|
||||
set(last_dir "${dir}")
|
||||
endforeach()
|
||||
|
||||
if(files)
|
||||
source_group("${last_dir}" FILES ${files})
|
||||
endif()
|
||||
endfunction()
|
||||
|
||||
|
||||
set(OPENVR_LIB_DIR ${CMAKE_SOURCE_DIR}/vendor/openvr)
|
||||
|
||||
# If not set, determine the platform architecture
|
||||
if (NOT PLATFORM)
|
||||
if (CMAKE_SIZEOF_VOID_P MATCHES 8)
|
||||
set(PLATFORM 64)
|
||||
else ()
|
||||
set(PLATFORM 32)
|
||||
endif ()
|
||||
endif ()
|
||||
message(STATUS "Compilation set for ${PLATFORM}bits architectures.")
|
||||
|
||||
# OpenVR compatibility checking
|
||||
if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
|
||||
add_definitions(-DLINUX -DPOSIX)
|
||||
set(ARCH_TARGET linux64)
|
||||
|
||||
if (${PLATFORM} MATCHES 32)
|
||||
message(WARNING "OpenVR x86 binaries not provided on GNU/Linux.")
|
||||
endif ()
|
||||
elseif (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
|
||||
set(CMAKE_MACOSX_RPATH 0)
|
||||
add_definitions(-DOSX -DPOSIX)
|
||||
set(ARCH_TARGET osx32)
|
||||
|
||||
elseif (${CMAKE_SYSTEM_NAME} MATCHES "Windows")
|
||||
add_definitions(-D_WIN32)
|
||||
set(ARCH_TARGET win${PLATFORM})
|
||||
|
||||
# Binaries path for thirdparties are not generics so we try to guess their suffixes.
|
||||
set(WINDOWS_PATH_SUFFIXES win${PLATFORM} Win${PLATFORM} x${PLATFORM})
|
||||
endif ()
|
||||
|
||||
find_library(OPENVR_LIBRARIES
|
||||
NAMES
|
||||
openvr_api
|
||||
PATHS
|
||||
${OPENVR_LIB_DIR}/bin
|
||||
${OPENVR_LIB_DIR}/lib
|
||||
PATH_SUFFIXES
|
||||
osx${PLATFORM}
|
||||
linux${PLATFORM}
|
||||
win${PLATFORM}
|
||||
NO_DEFAULT_PATH
|
||||
NO_CMAKE_FIND_ROOT_PATH
|
||||
)
|
||||
|
||||
# Add source files
|
||||
file(GLOB_RECURSE SOURCES_API ${CMAKE_SOURCE_DIR}/src/driver "*.c" "*.h" "*.hpp" "*.cpp")
|
||||
file(GLOB_RECURSE SOURCES_HEADERS ${CMAKE_SOURCE_DIR}/src/common "*.h" "*.hpp")
|
||||
|
||||
foreach(SOURCE IN ITEMS ${SOURCES_API})
|
||||
get_filename_component(SOURCE_PATH "${SOURCE}" PATH)
|
||||
string(REPLACE "${CMAKE_CURRENT_SOURCE_DIR}" "" GROUP_PATH "${SOURCE_PATH}")
|
||||
string(REPLACE "/" "\\" GROUP_PATH "${GROUP_PATH}")
|
||||
source_group("${GROUP_PATH}" FILES "${SOURCE}")
|
||||
endforeach()
|
||||
|
||||
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY $<1:${CMAKE_BINARY_DIR}/${DRIVER_NAME}/bin/${ARCH_TARGET}>)
|
||||
|
||||
add_library(SpaceCalibratorDriver SHARED ${SOURCES_API} ${SOURCES_HEADERS})
|
||||
GroupSourcesByFolder(SpaceCalibratorDriver)
|
||||
|
||||
set_target_properties(SpaceCalibratorDriver PROPERTIES
|
||||
LINK_FLAGS_DEBUG "/SUBSYSTEM:CONSOLE"
|
||||
LINK_FLAGS_MINSIZEREL "/SUBSYSTEM:WINDOWS"
|
||||
LINK_FLAGS_RELEASE "/SUBSYSTEM:WINDOWS"
|
||||
LINK_FLAGS_RELWITHDEBINFO "/SUBSYSTEM:WINDOWS")
|
||||
|
||||
target_include_directories(SpaceCalibratorDriver
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/src/common
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/src/driver
|
||||
PRIVATE ${OPENVR_LIB_DIR}
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/vendor/openvr/headers
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/vendor/minhook/include
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/vendor
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/vendor/Eigen)
|
||||
|
||||
target_link_libraries(SpaceCalibratorDriver
|
||||
PRIVATE ${OPENVR_LIBRARIES}
|
||||
PRIVATE minhook
|
||||
PRIVATE kernel32 user32 gdi32 winspool comdlg32 advapi32 shell32 ole32 oleaut32 uuid odbc32 odbccp32
|
||||
)
|
||||
|
||||
target_compile_definitions(SpaceCalibratorDriver
|
||||
PRIVATE $<$<CONFIG:Debug>:_DEBUG>
|
||||
PRIVATE $<$<CONFIG:Release>:NDEBUG>
|
||||
PRIVATE _WINDOWS
|
||||
PRIVATE _USRDLL
|
||||
PRIVATE NOMINMAX
|
||||
PRIVATE UNICODE
|
||||
PRIVATE EIGEN_HAS_STD_RESULT_OF=0
|
||||
PRIVATE OPENVRSPACECALIBRATORDRIVER_EXPORTS
|
||||
)
|
||||
set_target_properties(SpaceCalibratorDriver PROPERTIES OUTPUT_NAME ${DRIVER_NAME})
|
||||
|
||||
set_target_properties(SpaceCalibratorOverlay PROPERTIES LINK_FLAGS "/SUBSYSTEM:WINDOWS")
|
||||
|
||||
# Copy driver assets to output folder
|
||||
add_custom_command(
|
||||
TARGET SpaceCalibratorDriver
|
||||
PRE_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory
|
||||
${CMAKE_SOURCE_DIR}/${DRIVER_NAME}
|
||||
${CMAKE_BINARY_DIR}/${DRIVER_NAME}
|
||||
)
|
||||
@@ -0,0 +1,6 @@
|
||||
#include <stdio.h>
|
||||
|
||||
int main() {
|
||||
printf("Hello World!\n");
|
||||
return 0;
|
||||
}
|
||||
@@ -0,0 +1,150 @@
|
||||
cmake_minimum_required (VERSION 3.8)
|
||||
|
||||
project(SpaceCalibratorOverlay CXX)
|
||||
message("SpaceCalibrator - Overlay")
|
||||
|
||||
foreach(config_type RELEASE RELWITHDEBINFO MINSIZEREL)
|
||||
set(CMAKE_CXX_FLAGS_${config_type} "${CMAKE_CXX_FLAGS_${config_type}} /Ob2 /Zc:inline")
|
||||
set(CMAKE_SHARED_LINKER_FLAGS_${config_type} "${CMAKE_SHARED_LINKER_FLAGS_${config_type}} /LTCG /OPT:REF /OPT:ICF")
|
||||
endforeach()
|
||||
|
||||
function(GroupSourcesByFolder target)
|
||||
set(SOURCE_GROUP_DELIMITER "/")
|
||||
set(last_dir "")
|
||||
set(files "")
|
||||
|
||||
get_target_property(sources ${target} SOURCES)
|
||||
|
||||
foreach(file ${sources})
|
||||
file(RELATIVE_PATH relative_file "${PROJECT_SOURCE_DIR}" ${file})
|
||||
get_filename_component(dir "${relative_file}" PATH)
|
||||
if(NOT "${dir}" STREQUAL "${last_dir}")
|
||||
if(files)
|
||||
source_group("${last_dir}" FILES ${files})
|
||||
endif()
|
||||
set(files "")
|
||||
endif()
|
||||
set(files ${files} ${file})
|
||||
set(last_dir "${dir}")
|
||||
endforeach()
|
||||
|
||||
if(files)
|
||||
source_group("${last_dir}" FILES ${files})
|
||||
endif()
|
||||
endfunction()
|
||||
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||
set(CMAKE_CXX_EXTENSIONS OFF)
|
||||
|
||||
if (${CMAKE_SYSTEM_NAME} MATCHES "Windows")
|
||||
enable_language("RC")
|
||||
set (WIN32_RESOURCES ${CMAKE_SOURCE_DIR}/src/overlay/SpaceCalibrator.rc)
|
||||
endif()
|
||||
|
||||
# Add source files
|
||||
file(GLOB_RECURSE SOURCES_API ${CMAKE_SOURCE_DIR}/src/overlay "*.c" "*.h" "*.hpp" "*.cpp")
|
||||
file(GLOB_RECURSE SOURCES_HEADERS ${CMAKE_SOURCE_DIR}/src/common "*.h" "*.hpp")
|
||||
|
||||
foreach(SOURCE IN ITEMS ${SOURCES_API})
|
||||
get_filename_component(SOURCE_PATH "${SOURCE}" PATH)
|
||||
string(REPLACE "${CMAKE_CURRENT_SOURCE_DIR}" "" GROUP_PATH "${SOURCE_PATH}")
|
||||
string(REPLACE "/" "\\" GROUP_PATH "${GROUP_PATH}")
|
||||
source_group("${GROUP_PATH}" FILES "${SOURCE}")
|
||||
endforeach()
|
||||
|
||||
set(IMGUI_FILES
|
||||
${CMAKE_SOURCE_DIR}/vendor/imgui/backends/imgui_impl_opengl3.cpp
|
||||
${CMAKE_SOURCE_DIR}/vendor/imgui/backends/imgui_impl_glfw.cpp)
|
||||
|
||||
add_executable(SpaceCalibratorOverlay ${SOURCES_API} ${SOURCES_HEADERS} ${IMGUI_FILES} ${WIN32_RESOURCES})
|
||||
GroupSourcesByFolder(SpaceCalibratorOverlay)
|
||||
# Disable console window
|
||||
set_target_properties(SpaceCalibratorOverlay PROPERTIES
|
||||
LINK_FLAGS_DEBUG "/SUBSYSTEM:CONSOLE /ENTRY:wWinMainCRTStartup /NODEFAULTLIB:library"
|
||||
LINK_FLAGS_MINSIZEREL "/SUBSYSTEM:WINDOWS /ENTRY:wWinMainCRTStartup /NODEFAULTLIB:library"
|
||||
LINK_FLAGS_RELEASE "/SUBSYSTEM:WINDOWS /ENTRY:wWinMainCRTStartup /NODEFAULTLIB:library"
|
||||
LINK_FLAGS_RELWITHDEBINFO "/SUBSYSTEM:WINDOWS /ENTRY:wWinMainCRTStartup /NODEFAULTLIB:library")
|
||||
|
||||
target_include_directories(SpaceCalibratorOverlay
|
||||
PUBLIC ${CMAKE_SOURCE_DIR}
|
||||
PUBLIC ${CMAKE_SOURCE_DIR}/src/common
|
||||
PUBLIC ${CMAKE_SOURCE_DIR}/src/overlay
|
||||
PUBLIC ${CMAKE_SOURCE_DIR}/vendor
|
||||
PUBLIC ${CMAKE_SOURCE_DIR}/vendor/openvr/headers
|
||||
PUBLIC ${CMAKE_SOURCE_DIR}/vendor/imgui/backends
|
||||
PUBLIC ${CMAKE_SOURCE_DIR}/vendor/Eigen
|
||||
)
|
||||
|
||||
target_link_libraries(SpaceCalibratorOverlay
|
||||
PRIVATE opengl32.lib
|
||||
PRIVATE dwmapi.lib
|
||||
PRIVATE imgui
|
||||
PRIVATE glfw
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/vendor/openvr/lib/win64/openvr_api.lib)
|
||||
|
||||
target_compile_definitions(SpaceCalibratorOverlay
|
||||
PRIVATE NOMINMAX
|
||||
PRIVATE UNICODE
|
||||
PRIVATE IMGUI_DEFINE_MATH_OPERATORS
|
||||
)
|
||||
|
||||
# Object files are too big with spacecal sooooo
|
||||
if (MSVC)
|
||||
target_compile_options(SpaceCalibratorOverlay PRIVATE /bigobj)
|
||||
else ()
|
||||
target_compile_options(SpaceCalibratorOverlay PRIVATE -Wa,-mbig-obj)
|
||||
endif ()
|
||||
|
||||
# Copy vrmanifest
|
||||
add_custom_command(
|
||||
TARGET SpaceCalibratorOverlay POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy
|
||||
${CMAKE_SOURCE_DIR}/src/overlay/manifest.vrmanifest
|
||||
${CMAKE_BINARY_DIR}/artifacts/$<CONFIG>/manifest.vrmanifest
|
||||
)
|
||||
|
||||
# Copy dashboard icon
|
||||
add_custom_command(
|
||||
TARGET SpaceCalibratorOverlay POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy
|
||||
${CMAKE_SOURCE_DIR}/src/overlay/icon.png
|
||||
${CMAKE_BINARY_DIR}/artifacts/$<CONFIG>/icon.png
|
||||
)
|
||||
|
||||
# Copy taskbar icon
|
||||
add_custom_command(
|
||||
TARGET SpaceCalibratorOverlay POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy
|
||||
${CMAKE_SOURCE_DIR}/src/overlay/taskbar_icon.png
|
||||
${CMAKE_BINARY_DIR}/artifacts/$<CONFIG>/taskbar_icon.png
|
||||
)
|
||||
|
||||
# Copy LICENSE
|
||||
add_custom_command(
|
||||
TARGET SpaceCalibratorOverlay POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy
|
||||
${CMAKE_SOURCE_DIR}/LICENSE
|
||||
${CMAKE_BINARY_DIR}/artifacts/$<CONFIG>/LICENSE
|
||||
)
|
||||
|
||||
# Copy NOTICE
|
||||
add_custom_command(
|
||||
TARGET SpaceCalibratorOverlay POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy
|
||||
${CMAKE_SOURCE_DIR}/NOTICE
|
||||
${CMAKE_BINARY_DIR}/artifacts/$<CONFIG>/README
|
||||
)
|
||||
|
||||
# Copy openvr_api.dll
|
||||
add_custom_command(
|
||||
TARGET SpaceCalibratorOverlay POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy
|
||||
${CMAKE_SOURCE_DIR}/vendor/openvr/bin/win64/openvr_api.dll
|
||||
${CMAKE_BINARY_DIR}/artifacts/$<CONFIG>/openvr_api.dll
|
||||
)
|
||||
|
||||
# Set as startup project
|
||||
set_property(DIRECTORY ${CMAKE_SOURCE_DIR} PROPERTY VS_STARTUP_PROJECT SpaceCalibratorOverlay)
|
||||
set_property(TARGET SpaceCalibratorOverlay PROPERTY VS_DEBUGGER_WORKING_DIRECTORY "${CMAKE_BINARY_DIR}/artifacts/$<CONFIG>")
|
||||
set_target_properties(SpaceCalibratorOverlay PROPERTIES OUTPUT_NAME "SpaceCalibrator")
|
||||
|
After Width: | Height: | Size: 70 KiB |
|
After Width: | Height: | Size: 161 KiB |
@@ -0,0 +1,8 @@
|
||||
#include <stdio.h>
|
||||
#include <windows.h>
|
||||
|
||||
int APIENTRY wWinMain(_In_ HINSTANCE hInstance, _In_opt_ HINSTANCE hPrevInstance, _In_ LPWSTR lpCmdLine, _In_ int nCmdShow)
|
||||
{
|
||||
printf("Hello World!\n");
|
||||
return 0;
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
{
|
||||
"source" : "builtin",
|
||||
"applications": [{
|
||||
"app_key": "steam.overlay.3368750",
|
||||
"launch_type": "binary",
|
||||
"binary_path_windows": "SpaceCalibrator.exe",
|
||||
"is_dashboard_overlay": true,
|
||||
|
||||
"strings": {
|
||||
"en_us": {
|
||||
"name": "Space Calibrator",
|
||||
"description": "Space Calibrator Overlay"
|
||||
}
|
||||
}
|
||||
}]
|
||||
}
|
||||
|
After Width: | Height: | Size: 70 KiB |
@@ -0,0 +1,8 @@
|
||||
#pragma once
|
||||
|
||||
// Including SDKDDKVer.h defines the highest available Windows platform.
|
||||
|
||||
// If you wish to build your application for a previous Windows platform, include WinSDKVer.h and
|
||||
// set the _WIN32_WINNT macro to the platform you wish to support before including SDKDDKVer.h.
|
||||
|
||||
#include <SDKDDKVer.h>
|
||||
|
After Width: | Height: | Size: 60 KiB |
@@ -0,0 +1,37 @@
|
||||
cmake_minimum_required (VERSION 3.24)
|
||||
|
||||
project("vendor")
|
||||
|
||||
# Includes all 3rd party libraries here
|
||||
|
||||
# Minhook library
|
||||
message("Adding minhook...")
|
||||
add_subdirectory ("minhook")
|
||||
|
||||
# GLFW
|
||||
message("Adding GLFW...")
|
||||
set(GLFW_BUILD_TESTS OFF)
|
||||
set(GLFW_BUILD_EXAMPLES OFF)
|
||||
set(GLFW_BUILD_DOCS OFF)
|
||||
set(GLFW_INSTALL OFF)
|
||||
set(BUILD_SHARED_LIBS OFF)
|
||||
add_subdirectory(glfw)
|
||||
|
||||
# Dear ImGui
|
||||
message("Adding ImGui...")
|
||||
add_library(imgui STATIC
|
||||
${CMAKE_SOURCE_DIR}/vendor/imgui/imgui.cpp
|
||||
${CMAKE_SOURCE_DIR}/vendor/imgui/imgui_demo.cpp
|
||||
${CMAKE_SOURCE_DIR}/vendor/imgui/imgui_draw.cpp
|
||||
${CMAKE_SOURCE_DIR}/vendor/imgui/imgui_tables.cpp
|
||||
${CMAKE_SOURCE_DIR}/vendor/imgui/imgui_widgets.cpp)
|
||||
target_include_directories(imgui PUBLIC ${CMAKE_SOURCE_DIR}/vendor/imgui)
|
||||
target_compile_definitions(imgui PRIVATE IMGUI_DEFINE_MATH_OPERATORS)
|
||||
|
||||
# Assign solution dirs
|
||||
set_property(TARGET minhook PROPERTY FOLDER "lib")
|
||||
|
||||
set_property(TARGET glfw PROPERTY FOLDER "vendor/glfw")
|
||||
set_property(TARGET update_mappings PROPERTY FOLDER "vendor/glfw")
|
||||
|
||||
set_property(TARGET imgui PROPERTY FOLDER "vendor")
|
||||