├── LICENSE
├── MANIFEST.in
├── README.md
├── examples
├── humanoid.xml
├── slider.xml
├── test_pymujoco.py
└── test_slider.py
├── glfw3static.lib
├── mujoco210.dll
├── mujoco210.lib
├── python
├── include
│ ├── glfw3.h
│ ├── mjdata.h
│ ├── mjmodel.h
│ ├── mjrender.h
│ ├── mjui.h
│ ├── mjvisualize.h
│ ├── mjxmacro.h
│ ├── mujoco.h
│ ├── uitools.c
│ └── uitools.h
├── pymujoco.cc
├── pymujoco.inl
├── pymujoco_includes.h
├── pymujoco_renderer.cpp
└── pymujoco_renderer.h
├── setup.py
└── third_party
├── glew_win32
├── GL
│ ├── freeglut.h
│ ├── freeglut_ext.h
│ ├── freeglut_std.h
│ ├── glew.h
│ ├── glext.h
│ ├── glut.h
│ ├── glxew.h
│ ├── glxext.h
│ ├── wglew.h
│ └── wglext.h
├── glew32s.lib
└── glew64s.lib
├── glfw
├── .mailmap
├── CMake
│ ├── GenerateMappings.cmake
│ ├── Info.plist.in
│ ├── cmake_uninstall.cmake.in
│ ├── glfw3.pc.in
│ ├── glfw3Config.cmake.in
│ ├── i686-w64-mingw32-clang.cmake
│ ├── i686-w64-mingw32.cmake
│ ├── modules
│ │ ├── FindEpollShim.cmake
│ │ └── FindOSMesa.cmake
│ ├── x86_64-w64-mingw32-clang.cmake
│ └── x86_64-w64-mingw32.cmake
├── CMakeLists.txt
├── LICENSE.md
├── README.md
├── deps
│ ├── getopt.c
│ ├── getopt.h
│ ├── glad
│ │ ├── gl.h
│ │ ├── gles2.h
│ │ └── vulkan.h
│ ├── linmath.h
│ ├── mingw
│ │ ├── _mingw_dxhelper.h
│ │ ├── dinput.h
│ │ └── xinput.h
│ ├── nuklear.h
│ ├── nuklear_glfw_gl2.h
│ ├── stb_image_write.h
│ ├── tinycthread.c
│ ├── tinycthread.h
│ └── vs2008
│ │ └── stdint.h
├── docs
│ ├── CMakeLists.txt
│ ├── CODEOWNERS
│ ├── CONTRIBUTING.md
│ ├── Doxyfile.in
│ ├── DoxygenLayout.xml
│ ├── SUPPORT.md
│ ├── build.dox
│ ├── compat.dox
│ ├── compile.dox
│ ├── context.dox
│ ├── extra.css
│ ├── extra.css.map
│ ├── extra.scss
│ ├── footer.html
│ ├── header.html
│ ├── input.dox
│ ├── internal.dox
│ ├── intro.dox
│ ├── main.dox
│ ├── monitor.dox
│ ├── moving.dox
│ ├── news.dox
│ ├── quick.dox
│ ├── spaces.svg
│ ├── vulkan.dox
│ └── window.dox
├── examples
│ ├── CMakeLists.txt
│ ├── boing.c
│ ├── gears.c
│ ├── glfw.icns
│ ├── glfw.ico
│ ├── glfw.rc
│ ├── heightmap.c
│ ├── offscreen.c
│ ├── particles.c
│ ├── sharing.c
│ ├── splitview.c
│ ├── triangle-opengl.c
│ ├── triangle-opengles.c
│ ├── wave.c
│ └── windows.c
├── include
│ └── GLFW
│ │ ├── glfw3.h
│ │ └── glfw3native.h
├── src
│ ├── CMakeLists.txt
│ ├── cocoa_init.m
│ ├── cocoa_joystick.h
│ ├── cocoa_joystick.m
│ ├── cocoa_monitor.m
│ ├── cocoa_platform.h
│ ├── cocoa_time.c
│ ├── cocoa_time.h
│ ├── cocoa_window.m
│ ├── context.c
│ ├── egl_context.c
│ ├── glfw.rc.in
│ ├── glx_context.c
│ ├── init.c
│ ├── input.c
│ ├── internal.h
│ ├── linux_joystick.c
│ ├── linux_joystick.h
│ ├── mappings.h
│ ├── mappings.h.in
│ ├── monitor.c
│ ├── nsgl_context.m
│ ├── null_init.c
│ ├── null_joystick.c
│ ├── null_joystick.h
│ ├── null_monitor.c
│ ├── null_platform.h
│ ├── null_window.c
│ ├── osmesa_context.c
│ ├── platform.c
│ ├── platform.h
│ ├── posix_module.c
│ ├── posix_thread.c
│ ├── posix_thread.h
│ ├── posix_time.c
│ ├── posix_time.h
│ ├── vulkan.c
│ ├── wgl_context.c
│ ├── win32_init.c
│ ├── win32_joystick.c
│ ├── win32_joystick.h
│ ├── win32_module.c
│ ├── win32_monitor.c
│ ├── win32_platform.h
│ ├── win32_thread.c
│ ├── win32_thread.h
│ ├── win32_time.c
│ ├── win32_time.h
│ ├── win32_window.c
│ ├── window.c
│ ├── wl_init.c
│ ├── wl_monitor.c
│ ├── wl_platform.h
│ ├── wl_window.c
│ ├── x11_init.c
│ ├── x11_monitor.c
│ ├── x11_platform.h
│ ├── x11_window.c
│ ├── xkb_unicode.c
│ └── xkb_unicode.h
└── tests
│ ├── CMakeLists.txt
│ ├── allocator.c
│ ├── clipboard.c
│ ├── cursor.c
│ ├── empty.c
│ ├── events.c
│ ├── gamma.c
│ ├── glfwinfo.c
│ ├── icon.c
│ ├── iconify.c
│ ├── inputlag.c
│ ├── joysticks.c
│ ├── monitors.c
│ ├── msaa.c
│ ├── reopen.c
│ ├── tearing.c
│ ├── threads.c
│ ├── timeout.c
│ ├── title.c
│ ├── triangle-vulkan.c
│ └── window.c
└── pybind11
└── include
└── pybind11
├── attr.h
├── buffer_info.h
├── cast.h
├── chrono.h
├── common.h
├── complex.h
├── detail
├── class.h
├── common.h
├── descr.h
├── init.h
├── internals.h
└── typeid.h
├── eigen.h
├── embed.h
├── eval.h
├── functional.h
├── iostream.h
├── numpy.h
├── operators.h
├── options.h
├── pybind11.h
├── pytypes.h
├── stl.h
└── stl_bind.h
/MANIFEST.in:
--------------------------------------------------------------------------------
1 | include MANIFEST.in *.txt
2 | include *.*
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # pymujoco [](https://www.apache.org/licenses/LICENSE-2.0)
2 |
3 | `pymujoco`-python bindings for [MuJoCo](http://mujoco.org/) simulator generated using pybind11.
4 |
5 | There is also a preliminary [colab](https://colab.research.google.com/drive/1jJfwcBDRcY3oXLawX2HLDFTDOIyHNdKQ?usp=sharing) that allows headless rendering using EGL (cannot restart the EGL context at the moment).
6 |
7 | ## Usage
8 |
9 | ```
10 | from pymujoco import *
11 | r = mjv_create_renderer()
12 |
13 | #help(p)
14 | m = mj_loadXML("humanoid.xml")
15 | #print(m.qpos0)
16 | #print(m.nq)
17 | #print(m.nv)
18 | d = mj_makeData(m)
19 |
20 | exit_requested=False
21 | while not exit_requested:
22 | mj_step(m,d)
23 |
24 | print(d.qpos)
25 | exit_requested = r.render(m,d)
26 |
27 | names = ''.join([row.tostring().decode('UTF-8') for row in m.names]).split('\x00')
28 | print("names=",names)
29 | mj_printModel(m, "humanoid2.txt")
30 | mj_deleteData(d)
31 | mj_deleteModel(m)
32 |
33 | mjv_delete_renderer(r)
34 | ```
35 |
--------------------------------------------------------------------------------
/examples/slider.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
9 |
10 |
11 |
12 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
25 |
26 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
--------------------------------------------------------------------------------
/examples/test_pymujoco.py:
--------------------------------------------------------------------------------
1 | from pymujoco import *
2 | r = mjv_create_renderer()
3 | import numpy as np
4 | np.set_printoptions(suppress=True, precision=3)
5 | #help(p)
6 | m = mj_loadXML("humanoid.xml")
7 | #print(m.qpos0)
8 | #print(m.nq)
9 | #print(m.nv)
10 | d = mj_makeData(m)
11 |
12 | exit_requested=False
13 | while not exit_requested:
14 | mj_step(m,d)
15 |
16 | #print(d.qpos)
17 | print("number of contacts:",d.ncon)
18 | for c in range(int(d.ncon[0])):
19 | ct = d.get_contact(c)
20 | print("contact[",c,"].dist=",ct.dist)
21 | print("contact[",c,"].pos=",ct.pos)
22 |
23 | exit_requested = r.render(m,d)
24 |
25 | names = ''.join([row.tostring().decode('UTF-8') for row in m.names]).split('\x00')
26 | print("names=",names)
27 | mj_printModel(m, "humanoid2.txt")
28 | mj_deleteData(d)
29 | mj_deleteModel(m)
30 |
31 | mjv_delete_renderer(r)
--------------------------------------------------------------------------------
/examples/test_slider.py:
--------------------------------------------------------------------------------
1 | from pymujoco import *
2 | r = mjv_create_renderer()
3 |
4 | #help(p)
5 | m = mj_loadXML("slider.xml")
6 | #print(m.qpos0)
7 | #print(m.nq)
8 | #print(m.nv)
9 | d = mj_makeData(m)
10 |
11 | exit_requested=False
12 | while not exit_requested:
13 | mj_step(m,d)
14 |
15 | print(d.qpos)
16 | exit_requested = r.render(m,d)
17 |
18 | names = ''.join([row.tostring().decode('UTF-8') for row in m.names]).split('\x00')
19 | print("names=",names)
20 | mj_printModel(m, "slider.txt")
21 | mj_deleteData(d)
22 | mj_deleteModel(m)
23 |
24 | mjv_delete_renderer(r)
--------------------------------------------------------------------------------
/glfw3static.lib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/erwincoumans/pymujoco/33871d4412bb0c5de80555928f1877c670919d8d/glfw3static.lib
--------------------------------------------------------------------------------
/mujoco210.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/erwincoumans/pymujoco/33871d4412bb0c5de80555928f1877c670919d8d/mujoco210.dll
--------------------------------------------------------------------------------
/mujoco210.lib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/erwincoumans/pymujoco/33871d4412bb0c5de80555928f1877c670919d8d/mujoco210.lib
--------------------------------------------------------------------------------
/python/include/uitools.h:
--------------------------------------------------------------------------------
1 | // Copyright 2021 DeepMind Technologies Limited
2 | //
3 | // Licensed under the Apache License, Version 2.0 (the "License");
4 | // you may not use this file except in compliance with the License.
5 | // You may obtain a copy of the License at
6 | //
7 | // http://www.apache.org/licenses/LICENSE-2.0
8 | //
9 | // Unless required by applicable law or agreed to in writing, software
10 | // distributed under the License is distributed on an "AS IS" BASIS,
11 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 | // See the License for the specific language governing permissions and
13 | // limitations under the License.
14 |
15 | #ifndef MUJOCO_UITOOLS_H_
16 | #define MUJOCO_UITOOLS_H_
17 |
18 |
19 | #include "mujoco.h"
20 | #include "glfw3.h"
21 |
22 |
23 | // this is a C-API
24 | #if defined(__cplusplus)
25 | extern "C"
26 | {
27 | #endif
28 |
29 |
30 | // User-supplied callback function types.
31 | typedef void (*uiEventFn)(mjuiState* state);
32 | typedef void (*uiLayoutFn)(mjuiState* state);
33 |
34 | // Container for GLFW window pointer.
35 | struct _uiUserPointer
36 | {
37 | mjuiState* state;
38 | uiEventFn uiEvent;
39 | uiLayoutFn uiLayout;
40 | double buffer2window;
41 | };
42 | typedef struct _uiUserPointer uiUserPointer;
43 |
44 | // Set internal and user-supplied UI callbacks in GLFW window.
45 | void uiSetCallback(GLFWwindow* wnd, mjuiState* state,
46 | uiEventFn uiEvent, uiLayoutFn uiLayout);
47 |
48 | // Clear UI callbacks in GLFW window.
49 | void uiClearCallback(GLFWwindow* wnd);
50 |
51 | // Compute suitable font scale.
52 | int uiFontScale(GLFWwindow* wnd);
53 |
54 | // Modify UI structure.
55 | void uiModify(GLFWwindow* wnd, mjUI* ui, mjuiState* state, mjrContext* con);
56 |
57 |
58 | #if defined(__cplusplus)
59 | }
60 | #endif
61 |
62 | #endif // MUJOCO_UITOOLS_H_
63 |
--------------------------------------------------------------------------------
/python/pymujoco_includes.h:
--------------------------------------------------------------------------------
1 |
2 | #include
3 | #include
4 | #include
5 | #include
6 | #include
7 | #include "mujoco.h"
8 |
9 |
10 | #ifdef _WIN32
11 | #undef min
12 | #undef max
13 | #endif
14 |
--------------------------------------------------------------------------------
/python/pymujoco_renderer.h:
--------------------------------------------------------------------------------
1 | #ifndef PY_MUJOCO_RENDERER_H
2 | #define PY_MUJOCO_RENDERER_H
3 |
4 | struct _mjModel;
5 | typedef struct _mjModel mjModel;
6 | struct _mjData;
7 | typedef struct _mjData mjData;
8 |
9 | void py_mjv_init();
10 | void py_mjv_exit();
11 | bool py_mjv_render(mjModel* model, mjData* data);
12 |
13 | #endif //PY_MUJOCO_RENDERER_H
--------------------------------------------------------------------------------
/third_party/glew_win32/GL/freeglut.h:
--------------------------------------------------------------------------------
1 | #ifndef __FREEGLUT_H__
2 | #define __FREEGLUT_H__
3 |
4 | /*
5 | * freeglut.h
6 | *
7 | * The freeglut library include file
8 | *
9 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
10 | * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
11 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
12 | * PAWEL W. OLSZTA BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
13 | * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
14 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
15 | */
16 |
17 | #include "freeglut_std.h"
18 | #include "freeglut_ext.h"
19 |
20 | /*** END OF FILE ***/
21 |
22 | #endif /* __FREEGLUT_H__ */
23 |
--------------------------------------------------------------------------------
/third_party/glew_win32/GL/glut.h:
--------------------------------------------------------------------------------
1 | #ifndef __GLUT_H__
2 | #define __GLUT_H__
3 |
4 | #define FREEGLUT_STATIC 1
5 | /*
6 | * glut.h
7 | *
8 | * The freeglut library include file
9 | *
10 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
11 | * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
12 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
13 | * PAWEL W. OLSZTA BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
14 | * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
15 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
16 | */
17 |
18 | #include "freeglut_std.h"
19 |
20 | /*** END OF FILE ***/
21 |
22 | #endif /* __GLUT_H__ */
23 |
--------------------------------------------------------------------------------
/third_party/glew_win32/glew32s.lib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/erwincoumans/pymujoco/33871d4412bb0c5de80555928f1877c670919d8d/third_party/glew_win32/glew32s.lib
--------------------------------------------------------------------------------
/third_party/glew_win32/glew64s.lib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/erwincoumans/pymujoco/33871d4412bb0c5de80555928f1877c670919d8d/third_party/glew_win32/glew64s.lib
--------------------------------------------------------------------------------
/third_party/glfw/.mailmap:
--------------------------------------------------------------------------------
1 | Camilla Löwy
2 | Camilla Löwy
3 | Camilla Löwy
4 |
5 | Emmanuel Gil Peyrot
6 |
7 | Marcus Geelnard
8 | Marcus Geelnard
9 | Marcus Geelnard
10 |
11 |
--------------------------------------------------------------------------------
/third_party/glfw/CMake/GenerateMappings.cmake:
--------------------------------------------------------------------------------
1 | # Usage:
2 | # cmake -P GenerateMappings.cmake
3 |
4 | set(source_url "https://raw.githubusercontent.com/gabomdq/SDL_GameControllerDB/master/gamecontrollerdb.txt")
5 | set(source_path "${CMAKE_CURRENT_BINARY_DIR}/gamecontrollerdb.txt")
6 | set(template_path "${CMAKE_ARGV3}")
7 | set(target_path "${CMAKE_ARGV4}")
8 |
9 | if (NOT EXISTS "${template_path}")
10 | message(FATAL_ERROR "Failed to find template file ${template_path}")
11 | endif()
12 |
13 | file(DOWNLOAD "${source_url}" "${source_path}"
14 | STATUS download_status
15 | TLS_VERIFY on)
16 |
17 | list(GET download_status 0 status_code)
18 | list(GET download_status 1 status_message)
19 |
20 | if (status_code)
21 | message(FATAL_ERROR "Failed to download ${source_url}: ${status_message}")
22 | endif()
23 |
24 | file(STRINGS "${source_path}" lines)
25 | foreach(line ${lines})
26 | if (line MATCHES "^[0-9a-fA-F]")
27 | if (line MATCHES "platform:Windows")
28 | if (GLFW_WIN32_MAPPINGS)
29 | string(APPEND GLFW_WIN32_MAPPINGS "\n")
30 | endif()
31 | string(APPEND GLFW_WIN32_MAPPINGS "\"${line}\",")
32 | elseif (line MATCHES "platform:Mac OS X")
33 | if (GLFW_COCOA_MAPPINGS)
34 | string(APPEND GLFW_COCOA_MAPPINGS "\n")
35 | endif()
36 | string(APPEND GLFW_COCOA_MAPPINGS "\"${line}\",")
37 | elseif (line MATCHES "platform:Linux")
38 | if (GLFW_LINUX_MAPPINGS)
39 | string(APPEND GLFW_LINUX_MAPPINGS "\n")
40 | endif()
41 | string(APPEND GLFW_LINUX_MAPPINGS "\"${line}\",")
42 | endif()
43 | endif()
44 | endforeach()
45 |
46 | configure_file("${template_path}" "${target_path}" @ONLY NEWLINE_STYLE UNIX)
47 | file(REMOVE "${source_path}")
48 |
49 |
--------------------------------------------------------------------------------
/third_party/glfw/CMake/Info.plist.in:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | English
7 | CFBundleExecutable
8 | ${MACOSX_BUNDLE_EXECUTABLE_NAME}
9 | CFBundleGetInfoString
10 | ${MACOSX_BUNDLE_INFO_STRING}
11 | CFBundleIconFile
12 | ${MACOSX_BUNDLE_ICON_FILE}
13 | CFBundleIdentifier
14 | ${MACOSX_BUNDLE_GUI_IDENTIFIER}
15 | CFBundleInfoDictionaryVersion
16 | 6.0
17 | CFBundleLongVersionString
18 | ${MACOSX_BUNDLE_LONG_VERSION_STRING}
19 | CFBundleName
20 | ${MACOSX_BUNDLE_BUNDLE_NAME}
21 | CFBundlePackageType
22 | APPL
23 | CFBundleShortVersionString
24 | ${MACOSX_BUNDLE_SHORT_VERSION_STRING}
25 | CFBundleSignature
26 | ????
27 | CFBundleVersion
28 | ${MACOSX_BUNDLE_BUNDLE_VERSION}
29 | CSResourcesFileMapped
30 |
31 | LSRequiresCarbon
32 |
33 | NSHumanReadableCopyright
34 | ${MACOSX_BUNDLE_COPYRIGHT}
35 | NSHighResolutionCapable
36 |
37 |
38 |
39 |
--------------------------------------------------------------------------------
/third_party/glfw/CMake/cmake_uninstall.cmake.in:
--------------------------------------------------------------------------------
1 |
2 | if (NOT EXISTS "@GLFW_BINARY_DIR@/install_manifest.txt")
3 | message(FATAL_ERROR "Cannot find install manifest: \"@GLFW_BINARY_DIR@/install_manifest.txt\"")
4 | endif()
5 |
6 | file(READ "@GLFW_BINARY_DIR@/install_manifest.txt" files)
7 | string(REGEX REPLACE "\n" ";" files "${files}")
8 |
9 | foreach (file ${files})
10 | message(STATUS "Uninstalling \"$ENV{DESTDIR}${file}\"")
11 | if (EXISTS "$ENV{DESTDIR}${file}")
12 | exec_program("@CMAKE_COMMAND@" ARGS "-E remove \"$ENV{DESTDIR}${file}\""
13 | OUTPUT_VARIABLE rm_out
14 | RETURN_VALUE rm_retval)
15 | if (NOT "${rm_retval}" STREQUAL 0)
16 | MESSAGE(FATAL_ERROR "Problem when removing \"$ENV{DESTDIR}${file}\"")
17 | endif()
18 | elseif (IS_SYMLINK "$ENV{DESTDIR}${file}")
19 | EXEC_PROGRAM("@CMAKE_COMMAND@" ARGS "-E remove \"$ENV{DESTDIR}${file}\""
20 | OUTPUT_VARIABLE rm_out
21 | RETURN_VALUE rm_retval)
22 | if (NOT "${rm_retval}" STREQUAL 0)
23 | message(FATAL_ERROR "Problem when removing symlink \"$ENV{DESTDIR}${file}\"")
24 | endif()
25 | else()
26 | message(STATUS "File \"$ENV{DESTDIR}${file}\" does not exist.")
27 | endif()
28 | endforeach()
29 |
30 |
--------------------------------------------------------------------------------
/third_party/glfw/CMake/glfw3.pc.in:
--------------------------------------------------------------------------------
1 | prefix=@CMAKE_INSTALL_PREFIX@
2 | exec_prefix=${prefix}
3 | includedir=@CMAKE_INSTALL_FULL_INCLUDEDIR@
4 | libdir=@CMAKE_INSTALL_FULL_LIBDIR@
5 |
6 | Name: GLFW
7 | Description: A multi-platform library for OpenGL, window and input
8 | Version: @GLFW_VERSION@
9 | URL: https://www.glfw.org/
10 | Requires.private: @GLFW_PKG_CONFIG_REQUIRES_PRIVATE@
11 | Libs: -L${libdir} -l@GLFW_LIB_NAME@
12 | Libs.private: @GLFW_PKG_CONFIG_LIBS_PRIVATE@
13 | Cflags: -I${includedir}
14 |
--------------------------------------------------------------------------------
/third_party/glfw/CMake/glfw3Config.cmake.in:
--------------------------------------------------------------------------------
1 | include(CMakeFindDependencyMacro)
2 | find_dependency(Threads)
3 | include("${CMAKE_CURRENT_LIST_DIR}/glfw3Targets.cmake")
4 |
--------------------------------------------------------------------------------
/third_party/glfw/CMake/i686-w64-mingw32-clang.cmake:
--------------------------------------------------------------------------------
1 | # Define the environment for cross-compiling with 32-bit MinGW-w64 Clang
2 | SET(CMAKE_SYSTEM_NAME Windows) # Target system name
3 | SET(CMAKE_SYSTEM_VERSION 1)
4 | SET(CMAKE_C_COMPILER "i686-w64-mingw32-clang")
5 | SET(CMAKE_CXX_COMPILER "i686-w64-mingw32-clang++")
6 | SET(CMAKE_RC_COMPILER "i686-w64-mingw32-windres")
7 | SET(CMAKE_RANLIB "i686-w64-mingw32-ranlib")
8 |
9 | # Configure the behaviour of the find commands
10 | SET(CMAKE_FIND_ROOT_PATH "/usr/i686-w64-mingw32")
11 | SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
12 | SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
13 | SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
14 |
--------------------------------------------------------------------------------
/third_party/glfw/CMake/i686-w64-mingw32.cmake:
--------------------------------------------------------------------------------
1 | # Define the environment for cross-compiling with 32-bit MinGW-w64 GCC
2 | SET(CMAKE_SYSTEM_NAME Windows) # Target system name
3 | SET(CMAKE_SYSTEM_VERSION 1)
4 | SET(CMAKE_C_COMPILER "i686-w64-mingw32-gcc")
5 | SET(CMAKE_CXX_COMPILER "i686-w64-mingw32-g++")
6 | SET(CMAKE_RC_COMPILER "i686-w64-mingw32-windres")
7 | SET(CMAKE_RANLIB "i686-w64-mingw32-ranlib")
8 |
9 | # Configure the behaviour of the find commands
10 | SET(CMAKE_FIND_ROOT_PATH "/usr/i686-w64-mingw32")
11 | SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
12 | SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
13 | SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
14 |
--------------------------------------------------------------------------------
/third_party/glfw/CMake/modules/FindEpollShim.cmake:
--------------------------------------------------------------------------------
1 | # Find EpollShim
2 | # Once done, this will define
3 | #
4 | # EPOLLSHIM_FOUND - System has EpollShim
5 | # EPOLLSHIM_INCLUDE_DIRS - The EpollShim include directories
6 | # EPOLLSHIM_LIBRARIES - The libraries needed to use EpollShim
7 |
8 | find_path(EPOLLSHIM_INCLUDE_DIRS NAMES sys/epoll.h sys/timerfd.h HINTS /usr/local/include/libepoll-shim)
9 | find_library(EPOLLSHIM_LIBRARIES NAMES epoll-shim libepoll-shim HINTS /usr/local/lib)
10 |
11 | if (EPOLLSHIM_INCLUDE_DIRS AND EPOLLSHIM_LIBRARIES)
12 | set(EPOLLSHIM_FOUND TRUE)
13 | endif (EPOLLSHIM_INCLUDE_DIRS AND EPOLLSHIM_LIBRARIES)
14 |
15 | include(FindPackageHandleStandardArgs)
16 | find_package_handle_standard_args(EpollShim DEFAULT_MSG EPOLLSHIM_LIBRARIES EPOLLSHIM_INCLUDE_DIRS)
17 | mark_as_advanced(EPOLLSHIM_INCLUDE_DIRS EPOLLSHIM_LIBRARIES)
18 |
--------------------------------------------------------------------------------
/third_party/glfw/CMake/modules/FindOSMesa.cmake:
--------------------------------------------------------------------------------
1 | # Try to find OSMesa on a Unix system
2 | #
3 | # This will define:
4 | #
5 | # OSMESA_LIBRARIES - Link these to use OSMesa
6 | # OSMESA_INCLUDE_DIR - Include directory for OSMesa
7 | #
8 | # Copyright (c) 2014 Brandon Schaefer
9 |
10 | if (NOT WIN32)
11 |
12 | find_package (PkgConfig)
13 | pkg_check_modules (PKG_OSMESA QUIET osmesa)
14 |
15 | set (OSMESA_INCLUDE_DIR ${PKG_OSMESA_INCLUDE_DIRS})
16 | set (OSMESA_LIBRARIES ${PKG_OSMESA_LIBRARIES})
17 |
18 | endif ()
19 |
--------------------------------------------------------------------------------
/third_party/glfw/CMake/x86_64-w64-mingw32-clang.cmake:
--------------------------------------------------------------------------------
1 | # Define the environment for cross-compiling with 64-bit MinGW-w64 Clang
2 | SET(CMAKE_SYSTEM_NAME Windows) # Target system name
3 | SET(CMAKE_SYSTEM_VERSION 1)
4 | SET(CMAKE_C_COMPILER "x86_64-w64-mingw32-clang")
5 | SET(CMAKE_CXX_COMPILER "x86_64-w64-mingw32-clang++")
6 | SET(CMAKE_RC_COMPILER "x86_64-w64-mingw32-windres")
7 | SET(CMAKE_RANLIB "x86_64-w64-mingw32-ranlib")
8 |
9 | # Configure the behaviour of the find commands
10 | SET(CMAKE_FIND_ROOT_PATH "/usr/x86_64-w64-mingw32")
11 | SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
12 | SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
13 | SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
14 |
--------------------------------------------------------------------------------
/third_party/glfw/CMake/x86_64-w64-mingw32.cmake:
--------------------------------------------------------------------------------
1 | # Define the environment for cross-compiling with 64-bit MinGW-w64 GCC
2 | SET(CMAKE_SYSTEM_NAME Windows) # Target system name
3 | SET(CMAKE_SYSTEM_VERSION 1)
4 | SET(CMAKE_C_COMPILER "x86_64-w64-mingw32-gcc")
5 | SET(CMAKE_CXX_COMPILER "x86_64-w64-mingw32-g++")
6 | SET(CMAKE_RC_COMPILER "x86_64-w64-mingw32-windres")
7 | SET(CMAKE_RANLIB "x86_64-w64-mingw32-ranlib")
8 |
9 | # Configure the behaviour of the find commands
10 | SET(CMAKE_FIND_ROOT_PATH "/usr/x86_64-w64-mingw32")
11 | SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
12 | SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
13 | SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
14 |
--------------------------------------------------------------------------------
/third_party/glfw/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | cmake_minimum_required(VERSION 3.4...3.20 FATAL_ERROR)
2 |
3 | project(GLFW VERSION 3.4.0 LANGUAGES C)
4 |
5 | set(CMAKE_LEGACY_CYGWIN_WIN32 OFF)
6 |
7 | if (POLICY CMP0054)
8 | cmake_policy(SET CMP0054 NEW)
9 | endif()
10 |
11 | if (POLICY CMP0069)
12 | cmake_policy(SET CMP0069 NEW)
13 | endif()
14 |
15 | if (POLICY CMP0077)
16 | cmake_policy(SET CMP0077 NEW)
17 | endif()
18 |
19 | set_property(GLOBAL PROPERTY USE_FOLDERS ON)
20 |
21 | if (CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
22 | set(GLFW_STANDALONE TRUE)
23 | endif()
24 |
25 | option(BUILD_SHARED_LIBS "Build shared libraries" OFF)
26 | option(GLFW_BUILD_EXAMPLES "Build the GLFW example programs" ${GLFW_STANDALONE})
27 | option(GLFW_BUILD_TESTS "Build the GLFW test programs" ${GLFW_STANDALONE})
28 | option(GLFW_BUILD_DOCS "Build the GLFW documentation" ON)
29 | option(GLFW_INSTALL "Generate installation target" ON)
30 | option(GLFW_VULKAN_STATIC "Assume the Vulkan loader is linked with the application" OFF)
31 |
32 | include(GNUInstallDirs)
33 | include(CMakeDependentOption)
34 |
35 | if (GLFW_USE_OSMESA)
36 | message(FATAL_ERROR "GLFW_USE_OSMESA has been removed; set the GLFW_PLATFORM init hint")
37 | endif()
38 |
39 | cmake_dependent_option(GLFW_BUILD_WIN32 "Build support for Win32" ON "WIN32" OFF)
40 | cmake_dependent_option(GLFW_BUILD_COCOA "Build support for Cocoa" ON "APPLE" OFF)
41 | cmake_dependent_option(GLFW_BUILD_X11 "Build support for X11" ON "UNIX;NOT APPLE" OFF)
42 | cmake_dependent_option(GLFW_BUILD_WAYLAND "Build support for Wayland"
43 | "${GLFW_USE_WAYLAND}" "UNIX;NOT APPLE" OFF)
44 |
45 | cmake_dependent_option(GLFW_USE_HYBRID_HPG "Force use of high-performance GPU on hybrid systems" OFF
46 | "WIN32" OFF)
47 | cmake_dependent_option(USE_MSVC_RUNTIME_LIBRARY_DLL "Use MSVC runtime library DLL" ON
48 | "MSVC" OFF)
49 |
50 | set(GLFW_LIBRARY_TYPE "${GLFW_LIBRARY_TYPE}" CACHE STRING
51 | "Library type override for GLFW (SHARED, STATIC, OBJECT, or empty to follow BUILD_SHARED_LIBS)")
52 |
53 | if (GLFW_LIBRARY_TYPE)
54 | if (GLFW_LIBRARY_TYPE STREQUAL "SHARED")
55 | set(GLFW_BUILD_SHARED_LIBRARY TRUE)
56 | else()
57 | set(GLFW_BUILD_SHARED_LIBRARY FALSE)
58 | endif()
59 | else()
60 | set(GLFW_BUILD_SHARED_LIBRARY ${BUILD_SHARED_LIBS})
61 | endif()
62 |
63 | list(APPEND CMAKE_MODULE_PATH "${GLFW_SOURCE_DIR}/CMake/modules")
64 |
65 | find_package(Threads REQUIRED)
66 |
67 | if (GLFW_BUILD_DOCS)
68 | set(DOXYGEN_SKIP_DOT TRUE)
69 | find_package(Doxygen)
70 | endif()
71 |
72 | #--------------------------------------------------------------------
73 | # Report backend selection
74 | #--------------------------------------------------------------------
75 | if (GLFW_BUILD_WIN32)
76 | message(STATUS "Including Win32 support")
77 | endif()
78 | if (GLFW_BUILD_COCOA)
79 | message(STATUS "Including Cocoa support")
80 | endif()
81 | if (GLFW_BUILD_WAYLAND)
82 | message(STATUS "Including Wayland support")
83 | endif()
84 | if (GLFW_BUILD_X11)
85 | message(STATUS "Including X11 support")
86 | endif()
87 |
88 | #--------------------------------------------------------------------
89 | # Apply Microsoft C runtime library option
90 | # This is here because it also applies to tests and examples
91 | #--------------------------------------------------------------------
92 | if (MSVC AND NOT USE_MSVC_RUNTIME_LIBRARY_DLL)
93 | if (CMAKE_VERSION VERSION_LESS 3.15)
94 | foreach (flag CMAKE_C_FLAGS
95 | CMAKE_C_FLAGS_DEBUG
96 | CMAKE_C_FLAGS_RELEASE
97 | CMAKE_C_FLAGS_MINSIZEREL
98 | CMAKE_C_FLAGS_RELWITHDEBINFO)
99 |
100 | if (flag MATCHES "/MD")
101 | string(REGEX REPLACE "/MD" "/MT" ${flag} "${${flag}}")
102 | endif()
103 | if (flag MATCHES "/MDd")
104 | string(REGEX REPLACE "/MDd" "/MTd" ${flag} "${${flag}}")
105 | endif()
106 |
107 | endforeach()
108 | else()
109 | set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$:Debug>")
110 | endif()
111 | endif()
112 |
113 | #--------------------------------------------------------------------
114 | # Create generated files
115 | #--------------------------------------------------------------------
116 | include(CMakePackageConfigHelpers)
117 |
118 | set(GLFW_CONFIG_PATH "${CMAKE_INSTALL_LIBDIR}/cmake/glfw3")
119 |
120 | configure_package_config_file(CMake/glfw3Config.cmake.in
121 | src/glfw3Config.cmake
122 | INSTALL_DESTINATION "${GLFW_CONFIG_PATH}"
123 | NO_CHECK_REQUIRED_COMPONENTS_MACRO)
124 |
125 | write_basic_package_version_file(src/glfw3ConfigVersion.cmake
126 | VERSION ${GLFW_VERSION}
127 | COMPATIBILITY SameMajorVersion)
128 |
129 | #--------------------------------------------------------------------
130 | # Add subdirectories
131 | #--------------------------------------------------------------------
132 | add_subdirectory(src)
133 |
134 | if (GLFW_BUILD_EXAMPLES)
135 | add_subdirectory(examples)
136 | endif()
137 |
138 | if (GLFW_BUILD_TESTS)
139 | add_subdirectory(tests)
140 | endif()
141 |
142 | if (DOXYGEN_FOUND AND GLFW_BUILD_DOCS)
143 | add_subdirectory(docs)
144 | endif()
145 |
146 | #--------------------------------------------------------------------
147 | # Install files other than the library
148 | # The library is installed by src/CMakeLists.txt
149 | #--------------------------------------------------------------------
150 | if (GLFW_INSTALL)
151 | install(DIRECTORY include/GLFW DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}
152 | FILES_MATCHING PATTERN glfw3.h PATTERN glfw3native.h)
153 |
154 | install(FILES "${GLFW_BINARY_DIR}/src/glfw3Config.cmake"
155 | "${GLFW_BINARY_DIR}/src/glfw3ConfigVersion.cmake"
156 | DESTINATION "${GLFW_CONFIG_PATH}")
157 |
158 | install(EXPORT glfwTargets FILE glfw3Targets.cmake
159 | EXPORT_LINK_INTERFACE_LIBRARIES
160 | DESTINATION "${GLFW_CONFIG_PATH}")
161 | install(FILES "${GLFW_BINARY_DIR}/src/glfw3.pc"
162 | DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig")
163 |
164 | if (DOXYGEN_FOUND AND GLFW_BUILD_DOCS)
165 | install(DIRECTORY "${GLFW_BINARY_DIR}/docs/html"
166 | DESTINATION "${CMAKE_INSTALL_DOCDIR}")
167 | endif()
168 |
169 | # Only generate this target if no higher-level project already has
170 | if (NOT TARGET uninstall)
171 | configure_file(CMake/cmake_uninstall.cmake.in
172 | cmake_uninstall.cmake IMMEDIATE @ONLY)
173 |
174 | add_custom_target(uninstall
175 | "${CMAKE_COMMAND}" -P
176 | "${GLFW_BINARY_DIR}/cmake_uninstall.cmake")
177 | set_target_properties(uninstall PROPERTIES FOLDER "GLFW3")
178 | endif()
179 | endif()
180 |
181 |
--------------------------------------------------------------------------------
/third_party/glfw/LICENSE.md:
--------------------------------------------------------------------------------
1 | Copyright (c) 2002-2006 Marcus Geelnard
2 |
3 | Copyright (c) 2006-2019 Camilla Löwy
4 |
5 | This software is provided 'as-is', without any express or implied
6 | warranty. In no event will the authors be held liable for any damages
7 | arising from the use of this software.
8 |
9 | Permission is granted to anyone to use this software for any purpose,
10 | including commercial applications, and to alter it and redistribute it
11 | freely, subject to the following restrictions:
12 |
13 | 1. The origin of this software must not be misrepresented; you must not
14 | claim that you wrote the original software. If you use this software
15 | in a product, an acknowledgment in the product documentation would
16 | be appreciated but is not required.
17 |
18 | 2. Altered source versions must be plainly marked as such, and must not
19 | be misrepresented as being the original software.
20 |
21 | 3. This notice may not be removed or altered from any source
22 | distribution.
23 |
24 |
--------------------------------------------------------------------------------
/third_party/glfw/deps/getopt.h:
--------------------------------------------------------------------------------
1 | /* Copyright (c) 2012, Kim Gräsman
2 | * All rights reserved.
3 | *
4 | * Redistribution and use in source and binary forms, with or without
5 | * modification, are permitted provided that the following conditions are met:
6 | * * Redistributions of source code must retain the above copyright notice,
7 | * this list of conditions and the following disclaimer.
8 | * * Redistributions in binary form must reproduce the above copyright notice,
9 | * this list of conditions and the following disclaimer in the documentation
10 | * and/or other materials provided with the distribution.
11 | * * Neither the name of Kim Gräsman nor the names of contributors may be used
12 | * to endorse or promote products derived from this software without specific
13 | * prior written permission.
14 | *
15 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
16 | * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
17 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
18 | * ARE DISCLAIMED. IN NO EVENT SHALL KIM GRÄSMAN BE LIABLE FOR ANY DIRECT,
19 | * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
20 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
21 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
22 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
24 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 | */
26 |
27 | #ifndef INCLUDED_GETOPT_PORT_H
28 | #define INCLUDED_GETOPT_PORT_H
29 |
30 | #if defined(__cplusplus)
31 | extern "C" {
32 | #endif
33 |
34 | extern const int no_argument;
35 | extern const int required_argument;
36 | extern const int optional_argument;
37 |
38 | extern char* optarg;
39 | extern int optind, opterr, optopt;
40 |
41 | struct option {
42 | const char* name;
43 | int has_arg;
44 | int* flag;
45 | int val;
46 | };
47 |
48 | int getopt(int argc, char* const argv[], const char* optstring);
49 |
50 | int getopt_long(int argc, char* const argv[],
51 | const char* optstring, const struct option* longopts, int* longindex);
52 |
53 | #if defined(__cplusplus)
54 | }
55 | #endif
56 |
57 | #endif // INCLUDED_GETOPT_PORT_H
58 |
--------------------------------------------------------------------------------
/third_party/glfw/deps/mingw/_mingw_dxhelper.h:
--------------------------------------------------------------------------------
1 | /**
2 | * This file has no copyright assigned and is placed in the Public Domain.
3 | * This file is part of the mingw-w64 runtime package.
4 | * No warranty is given; refer to the file DISCLAIMER within this package.
5 | */
6 |
7 | #if defined(_MSC_VER) && !defined(_MSC_EXTENSIONS)
8 | #define NONAMELESSUNION 1
9 | #endif
10 | #if defined(NONAMELESSSTRUCT) && \
11 | !defined(NONAMELESSUNION)
12 | #define NONAMELESSUNION 1
13 | #endif
14 | #if defined(NONAMELESSUNION) && \
15 | !defined(NONAMELESSSTRUCT)
16 | #define NONAMELESSSTRUCT 1
17 | #endif
18 | #if !defined(__GNU_EXTENSION)
19 | #if defined(__GNUC__) || defined(__GNUG__)
20 | #define __GNU_EXTENSION __extension__
21 | #else
22 | #define __GNU_EXTENSION
23 | #endif
24 | #endif /* __extension__ */
25 |
26 | #ifndef __ANONYMOUS_DEFINED
27 | #define __ANONYMOUS_DEFINED
28 | #if defined(__GNUC__) || defined(__GNUG__)
29 | #define _ANONYMOUS_UNION __extension__
30 | #define _ANONYMOUS_STRUCT __extension__
31 | #else
32 | #define _ANONYMOUS_UNION
33 | #define _ANONYMOUS_STRUCT
34 | #endif
35 | #ifndef NONAMELESSUNION
36 | #define _UNION_NAME(x)
37 | #define _STRUCT_NAME(x)
38 | #else /* NONAMELESSUNION */
39 | #define _UNION_NAME(x) x
40 | #define _STRUCT_NAME(x) x
41 | #endif
42 | #endif /* __ANONYMOUS_DEFINED */
43 |
44 | #ifndef DUMMYUNIONNAME
45 | # ifdef NONAMELESSUNION
46 | # define DUMMYUNIONNAME u
47 | # define DUMMYUNIONNAME1 u1 /* Wine uses this variant */
48 | # define DUMMYUNIONNAME2 u2
49 | # define DUMMYUNIONNAME3 u3
50 | # define DUMMYUNIONNAME4 u4
51 | # define DUMMYUNIONNAME5 u5
52 | # define DUMMYUNIONNAME6 u6
53 | # define DUMMYUNIONNAME7 u7
54 | # define DUMMYUNIONNAME8 u8
55 | # define DUMMYUNIONNAME9 u9
56 | # else /* NONAMELESSUNION */
57 | # define DUMMYUNIONNAME
58 | # define DUMMYUNIONNAME1 /* Wine uses this variant */
59 | # define DUMMYUNIONNAME2
60 | # define DUMMYUNIONNAME3
61 | # define DUMMYUNIONNAME4
62 | # define DUMMYUNIONNAME5
63 | # define DUMMYUNIONNAME6
64 | # define DUMMYUNIONNAME7
65 | # define DUMMYUNIONNAME8
66 | # define DUMMYUNIONNAME9
67 | # endif
68 | #endif /* DUMMYUNIONNAME */
69 |
70 | #if !defined(DUMMYUNIONNAME1) /* MinGW does not define this one */
71 | # ifdef NONAMELESSUNION
72 | # define DUMMYUNIONNAME1 u1 /* Wine uses this variant */
73 | # else
74 | # define DUMMYUNIONNAME1 /* Wine uses this variant */
75 | # endif
76 | #endif /* DUMMYUNIONNAME1 */
77 |
78 | #ifndef DUMMYSTRUCTNAME
79 | # ifdef NONAMELESSUNION
80 | # define DUMMYSTRUCTNAME s
81 | # define DUMMYSTRUCTNAME1 s1 /* Wine uses this variant */
82 | # define DUMMYSTRUCTNAME2 s2
83 | # define DUMMYSTRUCTNAME3 s3
84 | # define DUMMYSTRUCTNAME4 s4
85 | # define DUMMYSTRUCTNAME5 s5
86 | # else
87 | # define DUMMYSTRUCTNAME
88 | # define DUMMYSTRUCTNAME1 /* Wine uses this variant */
89 | # define DUMMYSTRUCTNAME2
90 | # define DUMMYSTRUCTNAME3
91 | # define DUMMYSTRUCTNAME4
92 | # define DUMMYSTRUCTNAME5
93 | # endif
94 | #endif /* DUMMYSTRUCTNAME */
95 |
96 | /* These are for compatibility with the Wine source tree */
97 |
98 | #ifndef WINELIB_NAME_AW
99 | # ifdef __MINGW_NAME_AW
100 | # define WINELIB_NAME_AW __MINGW_NAME_AW
101 | # else
102 | # ifdef UNICODE
103 | # define WINELIB_NAME_AW(func) func##W
104 | # else
105 | # define WINELIB_NAME_AW(func) func##A
106 | # endif
107 | # endif
108 | #endif /* WINELIB_NAME_AW */
109 |
110 | #ifndef DECL_WINELIB_TYPE_AW
111 | # ifdef __MINGW_TYPEDEF_AW
112 | # define DECL_WINELIB_TYPE_AW __MINGW_TYPEDEF_AW
113 | # else
114 | # define DECL_WINELIB_TYPE_AW(type) typedef WINELIB_NAME_AW(type) type;
115 | # endif
116 | #endif /* DECL_WINELIB_TYPE_AW */
117 |
118 |
--------------------------------------------------------------------------------
/third_party/glfw/docs/CMakeLists.txt:
--------------------------------------------------------------------------------
1 |
2 | # NOTE: The order of this list determines the order of items in the Guides
3 | # (i.e. Pages) list in the generated documentation
4 | set(source_files
5 | main.dox
6 | news.dox
7 | quick.dox
8 | moving.dox
9 | compile.dox
10 | build.dox
11 | intro.dox
12 | context.dox
13 | monitor.dox
14 | window.dox
15 | input.dox
16 | vulkan.dox
17 | compat.dox
18 | internal.dox)
19 |
20 | set(extra_files DoxygenLayout.xml header.html footer.html extra.css spaces.svg)
21 |
22 | set(header_paths
23 | "${GLFW_SOURCE_DIR}/include/GLFW/glfw3.h"
24 | "${GLFW_SOURCE_DIR}/include/GLFW/glfw3native.h")
25 |
26 | # Format the source list into a Doxyfile INPUT value that Doxygen can parse
27 | foreach(path IN LISTS header_paths)
28 | string(APPEND GLFW_DOXYGEN_INPUT " \\\n\"${path}\"")
29 | endforeach()
30 | foreach(file IN LISTS source_files)
31 | string(APPEND GLFW_DOXYGEN_INPUT " \\\n\"${CMAKE_CURRENT_SOURCE_DIR}/${file}\"")
32 | endforeach()
33 |
34 | configure_file(Doxyfile.in Doxyfile @ONLY)
35 |
36 | add_custom_command(OUTPUT "html/index.html"
37 | COMMAND "${DOXYGEN_EXECUTABLE}"
38 | WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}"
39 | MAIN_DEPENDENCY Doxyfile
40 | DEPENDS ${header_paths} ${source_files} ${extra_files}
41 | COMMENT "Generating HTML documentation"
42 | VERBATIM)
43 |
44 | add_custom_target(docs ALL SOURCES "html/index.html")
45 | set_target_properties(docs PROPERTIES FOLDER "GLFW3")
46 |
47 |
--------------------------------------------------------------------------------
/third_party/glfw/docs/CODEOWNERS:
--------------------------------------------------------------------------------
1 |
2 | * @elmindreda
3 |
4 | src/wl_* @linkmauve
5 |
6 | docs/*.css @glfw/webdev
7 | docs/*.scss @glfw/webdev
8 | docs/*.html @glfw/webdev
9 | docs/*.xml @glfw/webdev
10 |
11 |
--------------------------------------------------------------------------------
/third_party/glfw/docs/DoxygenLayout.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
--------------------------------------------------------------------------------
/third_party/glfw/docs/SUPPORT.md:
--------------------------------------------------------------------------------
1 | # Support resources
2 |
3 | See the [latest documentation](https://www.glfw.org/docs/latest/) for tutorials,
4 | guides and the API reference.
5 |
6 | If you have questions about using GLFW, we have a
7 | [forum](https://discourse.glfw.org/), and the `#glfw` IRC channel on
8 | [Libera.Chat](https://libera.chat/).
9 |
10 | Bugs are reported to our [issue tracker](https://github.com/glfw/glfw/issues).
11 | Please check the [contribution
12 | guide](https://github.com/glfw/glfw/blob/master/docs/CONTRIBUTING.md) for
13 | information on what to include when reporting a bug.
14 |
15 |
--------------------------------------------------------------------------------
/third_party/glfw/docs/extra.css:
--------------------------------------------------------------------------------
1 | .sm-dox,.sm-dox a,.sm-dox a:focus,.sm-dox a:active,.sm-dox a:hover,.sm-dox a.highlighted,.sm-dox ul a:hover{background:none;text-shadow:none}.sm-dox a span.sub-arrow{border-color:#f2f2f2 transparent transparent transparent}.sm-dox a span.sub-arrow:active,.sm-dox a span.sub-arrow:focus,.sm-dox a span.sub-arrow:hover,.sm-dox a:hover span.sub-arrow{border-color:#f60 transparent transparent transparent}.sm-dox ul a span.sub-arrow:active,.sm-dox ul a span.sub-arrow:focus,.sm-dox ul a span.sub-arrow:hover,.sm-dox ul a:hover span.sub-arrow{border-color:transparent transparent transparent #f60}.sm-dox ul a:hover{background:#666;text-shadow:none}.sm-dox ul.sm-nowrap a{color:#4d4d4d;text-shadow:none}#main-nav,#main-menu,#main-menu a,#main-menu a:visited,#main-menu a:hover,#main-menu li,.memdoc,dl.reflist dd,div.toc li,.ah,span.lineno,span.lineno a,span.lineno a:hover,.note code,.pre code,.post code,.invariant code,.warning code,.attention code,.deprecated code,.bug code,.todo code,.test code,.doxtable code,.markdownTable code{background:none}#titlearea,.footer,.contents,div.header,.memdoc,table.doxtable td,table.doxtable th,table.markdownTable td,table.markdownTable th,hr,.memSeparator{border:none}#main-menu a,#main-menu a:visited,#main-menu a:hover,#main-menu li,.reflist dt a.el,.levels span,.directory .levels span{text-shadow:none}.memdoc,dl.reflist dd{box-shadow:none}div.headertitle,.note code,.pre code,.post code,.invariant code,.warning code,.attention code,.deprecated code,.bug code,.todo code,.test code,table.doxtable code,table.markdownTable code{padding:0}#nav-path,.directory .levels,span.lineno{display:none}html,#titlearea,.footer,tr.even,.directory tr.even,.doxtable tr:nth-child(even),tr.markdownTableBody:nth-child(even),.mdescLeft,.mdescRight,.memItemLeft,.memItemRight,code,.markdownTableRowEven{background:#f2f2f2}body{color:#4d4d4d}h1,h2,h2.groupheader,h3,div.toc h3,h4,h5,h6,strong,em{color:#1a1a1a;border-bottom:none}h1{padding-top:.5em;font-size:180%}h2{padding-top:.5em;margin-bottom:0;font-size:140%}h3{padding-top:.5em;margin-bottom:0;font-size:110%}.glfwheader{font-size:16px;min-height:64px;max-width:920px;padding:0 32px;margin:0 auto;display:flex;flex-direction:row;flex-wrap:wrap;justify-content:flex-start;align-items:center;align-content:stretch}#glfwhome{line-height:64px;padding-right:48px;color:#666;font-size:2.5em;background:url("https://www.glfw.org/css/arrow.png") no-repeat right}.glfwnavbar{list-style-type:none;margin:0 0 0 auto;float:right}#glfwhome,.glfwnavbar li{float:left}.glfwnavbar a,.glfwnavbar a:visited{line-height:64px;margin-left:2em;display:block;color:#666}.glfwnavbar{padding-left:0}#glfwhome,.glfwnavbar a,.glfwnavbar a:visited{transition:.35s ease}#titlearea,.footer{color:#666}address.footer{text-align:center;padding:2em;margin-top:3em}#top{background:#666}#main-nav{max-width:960px;margin:0 auto;font-size:13px}#main-menu{max-width:920px;margin:0 auto;font-size:13px}.memtitle{display:none}.memproto,.memname{font-weight:bold;text-shadow:none}#main-menu{min-height:36px;display:flex;flex-direction:row;flex-wrap:wrap;justify-content:flex-start;align-items:center;align-content:stretch}#main-menu a,#main-menu a:visited,#main-menu a:hover,#main-menu li{color:#f2f2f2}#main-menu li ul.sm-nowrap li a{color:#4d4d4d}#main-menu li ul.sm-nowrap li a:hover{color:#f60}#main-menu>li:last-child{margin:0 0 0 auto}.contents{min-height:590px}div.contents,div.header{max-width:920px;margin:0 auto;padding:0 32px;background:#fff none}table.doxtable th,table.markdownTable th,dl.reflist dt{background:linear-gradient(to bottom, #ffa733 0%, #ff6600 100%);box-shadow:inset 0 0 32px #f60;text-shadow:0 -1px 1px #b34700;text-align:left;color:#fff}dl.reflist dt a.el{color:#f60;padding:.2em;border-radius:4px;background-color:#ffe0cc}div.toc{float:none;width:auto}div.toc h3{font-size:1.17em}div.toc ul{padding-left:1.5em}div.toc li{font-size:1em;padding-left:0;list-style-type:disc}div.toc,.memproto,div.qindex,div.ah{background:linear-gradient(to bottom, #f2f2f2 0%, #e6e6e6 100%);box-shadow:inset 0 0 32px #e6e6e6;text-shadow:0 1px 1px #fff;color:#1a1a1a;border:2px solid #e6e6e6;border-radius:4px}.paramname{color:#803300}dl.reflist dt{border:2px solid #f60;border-top-left-radius:4px;border-top-right-radius:4px;border-bottom:none}dl.reflist dd{border:2px solid #f60;border-bottom-right-radius:4px;border-bottom-left-radius:4px;border-top:none}table.doxtable,table.markdownTable{border-collapse:inherit;border-spacing:0;border:2px solid #f60;border-radius:4px}a,a:hover,a:visited,a:visited:hover,.contents a:visited,.el,a.el:visited,#glfwhome:hover,#main-menu a:hover,span.lineno a:hover{color:#f60;text-decoration:none}div.directory{border-collapse:inherit;border-spacing:0;border:2px solid #f60;border-radius:4px}hr,.memSeparator{height:2px;background:linear-gradient(to right, #f2f2f2 0%, #d9d9d9 50%, #f2f2f2 100%)}dl.note,dl.pre,dl.post,dl.invariant{background:linear-gradient(to bottom, #ddfad1 0%, #cbf7ba 100%);box-shadow:inset 0 0 32px #baf5a3;color:#1e5309;border:2px solid #afe699}dl.warning,dl.attention{background:linear-gradient(to bottom, #fae8d1 0%, #f7ddba 100%);box-shadow:inset 0 0 32px #f5d1a3;color:#533309;border:2px solid #e6c499}dl.deprecated,dl.bug{background:linear-gradient(to bottom, #fad1e3 0%, #f7bad6 100%);box-shadow:inset 0 0 32px #f5a3c8;color:#53092a;border:2px solid #e699bb}dl.todo,dl.test{background:linear-gradient(to bottom, #d1ecfa 0%, #bae3f7 100%);box-shadow:inset 0 0 32px #a3daf5;color:#093a53;border:2px solid #99cce6}dl.note,dl.pre,dl.post,dl.invariant,dl.warning,dl.attention,dl.deprecated,dl.bug,dl.todo,dl.test{border-radius:4px;padding:1em;text-shadow:0 1px 1px #fff;margin:1em 0}.note a,.pre a,.post a,.invariant a,.warning a,.attention a,.deprecated a,.bug a,.todo a,.test a,.note a:visited,.pre a:visited,.post a:visited,.invariant a:visited,.warning a:visited,.attention a:visited,.deprecated a:visited,.bug a:visited,.todo a:visited,.test a:visited{color:inherit}div.line{line-height:inherit}div.fragment,pre.fragment{background:#f2f2f2;border-radius:4px;border:none;padding:1em;overflow:auto;border-left:4px solid #ccc;margin:1em 0}.lineno a,.lineno a:visited,.line,pre.fragment{color:#4d4d4d}span.preprocessor,span.comment{color:#007899}a.code,a.code:visited{color:#e64500}span.keyword,span.keywordtype,span.keywordflow{color:#404040;font-weight:bold}span.stringliteral{color:#360099}code{padding:.1em;border-radius:4px}/*# sourceMappingURL=extra.css.map */
2 |
--------------------------------------------------------------------------------
/third_party/glfw/docs/extra.css.map:
--------------------------------------------------------------------------------
1 | {"version":3,"sourceRoot":"","sources":["extra.scss"],"names":[],"mappings":"AA8EA,4GACI,gBACA,iBAGJ,yBACC,yDAGD,6HACC,sDAGD,yIACC,sDAGD,mBACI,WA9EuB,KA+EvB,iBAGJ,uBACC,MAzFoB,QA0FjB,iBAGJ,6UACC,gBAGD,mJACC,YAGD,yHACC,iBAGD,sBACC,gBAGD,4LACC,UAGD,yCACC,aAGD,kMACC,WAnHgC,QAsHjC,KACC,MA1HoB,QA6HrB,sDACC,MA/Ge,QAgHf,mBAGD,GACE,iBACA,eAGF,GACE,iBACA,gBACA,eAGF,GACE,iBACA,gBACA,eAGF,YACC,eACA,gBACA,gBACA,eACA,cAEA,aACA,mBACA,eACA,2BACA,mBACA,sBAGD,UACC,iBACA,mBACA,MA/J0B,KAgK1B,gBACA,qEAGD,YACC,qBACA,kBACA,YAGD,yBACC,WAGD,oCACC,iBACA,gBACA,cACA,MAlL0B,KAqL3B,YACC,eAGD,8CACC,qBAGD,mBACC,MA9L0B,KAiM3B,eACC,kBACA,YACA,eAGD,KACC,WAxM0B,KA2M3B,UACC,gBACA,cACA,eAGD,WACC,gBACA,cACA,eAGD,UACI,aAGJ,mBACI,iBACA,iBAGJ,WACC,gBACA,aACA,mBACA,eACA,2BACA,mBACA,sBAGD,mEACC,MA9OgC,QAiPjC,gCACC,MArPoB,QAwPrB,sCACC,MAjOoB,KAoOrB,yBACC,kBAGD,UACC,iBAGD,wBACC,gBACA,cACA,eACA,qBAGD,uDACC,gEACA,+BACA,+BACA,gBACA,MArPgB,KAwPjB,mBACC,MA5PoB,KA6PpB,aACA,kBACA,yBAGD,QACC,WACA,WAGD,WACC,iBAGD,WACC,mBAGD,WACC,cACA,eACA,qBAGD,oCACC,gEACA,kCACA,2BACA,MAlSe,QAmSf,yBACA,kBAGD,WACC,MA3QuB,QA8QxB,cACC,sBACA,2BACA,4BACA,mBAGD,cACC,sBACA,+BACA,8BACA,gBAGD,mCACC,wBACA,iBACA,sBACA,kBAGD,gIACC,MAxToB,KAyTpB,qBAGD,cACC,wBACA,iBACA,sBACA,kBAGD,iBACC,WACA,4EAGD,oCApSC,gEACA,kCACA,cACA,yBAqSD,wBAxSC,gEACA,kCACA,cACA,yBAySD,qBA5SC,gEACA,kCACA,cACA,yBA6SD,gBAhTC,gEACA,kCACA,cACA,yBAiTD,iGACC,kBACA,YACA,2BACA,aAGD,kRACC,cAGD,SACC,oBAGD,0BACC,mBACA,kBACA,YACA,YACA,cACA,2BACA,aAGD,+CACC,MA1YoB,QA6YrB,+BACC,cAGD,sBACC,cAGD,+CACC,cACA,iBAGD,mBACC,cAGD,KACC,aACA","file":"extra.css"}
--------------------------------------------------------------------------------
/third_party/glfw/docs/footer.html:
--------------------------------------------------------------------------------
1 |
6 |