├── .gitattributes ├── .github ├── FUNDING.yml └── workflows │ └── build.yml ├── .gitignore ├── .vscode ├── launch.json └── settings.json ├── Bin └── I18n │ └── en_us.json ├── CMakeLists.txt ├── LICENSE ├── README.md ├── Win11SysCheck.code-workspace ├── assets ├── preview.gif └── preview.png ├── build └── .gitkeep ├── extern ├── d3d9 │ ├── lib_x64 │ │ ├── DxErr.lib │ │ ├── d3d9.lib │ │ ├── d3dx9.lib │ │ └── dinput8.lib │ └── lib_x86 │ │ ├── DxErr.lib │ │ ├── d3d9.lib │ │ ├── d3dx9.lib │ │ └── dinput8.lib ├── fmt-7.1.3 │ └── fmt │ │ ├── chrono.h │ │ ├── color.h │ │ ├── compile.h │ │ ├── core.h │ │ ├── format-inl.h │ │ ├── format.h │ │ ├── locale.h │ │ ├── os.h │ │ ├── ostream.h │ │ ├── posix.h │ │ ├── printf.h │ │ └── ranges.h ├── imgui-1.83 │ ├── .editorconfig │ ├── .gitattributes │ ├── .github │ │ ├── FUNDING.yml │ │ ├── issue_template.md │ │ ├── pull_request_template.md │ │ └── workflows │ │ │ ├── build.yml │ │ │ ├── scheduled.yml │ │ │ └── static-analysis.yml │ ├── .gitignore │ ├── LICENSE.txt │ ├── backends │ │ ├── imgui_impl_allegro5.cpp │ │ ├── imgui_impl_allegro5.h │ │ ├── imgui_impl_android.cpp │ │ ├── imgui_impl_android.h │ │ ├── imgui_impl_dx10.cpp │ │ ├── imgui_impl_dx10.h │ │ ├── imgui_impl_dx11.cpp │ │ ├── imgui_impl_dx11.h │ │ ├── imgui_impl_dx12.cpp │ │ ├── imgui_impl_dx12.h │ │ ├── imgui_impl_dx9.cpp │ │ ├── imgui_impl_dx9.h │ │ ├── imgui_impl_glfw.cpp │ │ ├── imgui_impl_glfw.h │ │ ├── imgui_impl_glut.cpp │ │ ├── imgui_impl_glut.h │ │ ├── imgui_impl_marmalade.cpp │ │ ├── imgui_impl_marmalade.h │ │ ├── imgui_impl_metal.h │ │ ├── imgui_impl_metal.mm │ │ ├── imgui_impl_opengl2.cpp │ │ ├── imgui_impl_opengl2.h │ │ ├── imgui_impl_opengl3.cpp │ │ ├── imgui_impl_opengl3.h │ │ ├── imgui_impl_osx.h │ │ ├── imgui_impl_osx.mm │ │ ├── imgui_impl_sdl.cpp │ │ ├── imgui_impl_sdl.h │ │ ├── imgui_impl_vulkan.cpp │ │ ├── imgui_impl_vulkan.h │ │ ├── imgui_impl_wgpu.cpp │ │ ├── imgui_impl_wgpu.h │ │ ├── imgui_impl_win32.cpp │ │ ├── imgui_impl_win32.h │ │ └── vulkan │ │ │ ├── generate_spv.sh │ │ │ ├── glsl_shader.frag │ │ │ └── glsl_shader.vert │ ├── docs │ │ ├── BACKENDS.md │ │ ├── CHANGELOG.txt │ │ ├── EXAMPLES.md │ │ ├── FAQ.md │ │ ├── FONTS.md │ │ ├── README.md │ │ └── TODO.txt │ ├── examples │ │ ├── README.txt │ │ ├── example_allegro5 │ │ │ ├── README.md │ │ │ ├── example_allegro5.vcxproj │ │ │ ├── example_allegro5.vcxproj.filters │ │ │ ├── imconfig_allegro5.h │ │ │ └── main.cpp │ │ ├── example_android_opengl3 │ │ │ ├── CMakeLists.txt │ │ │ ├── android │ │ │ │ ├── .gitignore │ │ │ │ ├── app │ │ │ │ │ ├── build.gradle │ │ │ │ │ └── src │ │ │ │ │ │ └── main │ │ │ │ │ │ ├── AndroidManifest.xml │ │ │ │ │ │ └── java │ │ │ │ │ │ └── MainActivity.kt │ │ │ │ ├── build.gradle │ │ │ │ └── settings.gradle │ │ │ └── main.cpp │ │ ├── example_apple_metal │ │ │ ├── README.md │ │ │ ├── example_apple_metal.xcodeproj │ │ │ │ └── project.pbxproj │ │ │ ├── iOS │ │ │ │ ├── Info-iOS.plist │ │ │ │ └── LaunchScreen.storyboard │ │ │ ├── macOS │ │ │ │ ├── Info-macOS.plist │ │ │ │ └── MainMenu.storyboard │ │ │ └── main.mm │ │ ├── example_apple_opengl2 │ │ │ ├── example_apple_opengl2.xcodeproj │ │ │ │ └── project.pbxproj │ │ │ └── main.mm │ │ ├── example_emscripten_opengl3 │ │ │ ├── Makefile │ │ │ ├── README.md │ │ │ ├── main.cpp │ │ │ └── shell_minimal.html │ │ ├── example_emscripten_wgpu │ │ │ ├── Makefile │ │ │ ├── README.md │ │ │ └── main.cpp │ │ ├── example_glfw_metal │ │ │ ├── Makefile │ │ │ └── main.mm │ │ ├── example_glfw_opengl2 │ │ │ ├── Makefile │ │ │ ├── build_win32.bat │ │ │ ├── example_glfw_opengl2.vcxproj │ │ │ ├── example_glfw_opengl2.vcxproj.filters │ │ │ └── main.cpp │ │ ├── example_glfw_opengl3 │ │ │ ├── Makefile │ │ │ ├── build_win32.bat │ │ │ ├── example_glfw_opengl3.vcxproj │ │ │ ├── example_glfw_opengl3.vcxproj.filters │ │ │ └── main.cpp │ │ ├── example_glfw_vulkan │ │ │ ├── CMakeLists.txt │ │ │ ├── build_win32.bat │ │ │ ├── build_win64.bat │ │ │ ├── example_glfw_vulkan.vcxproj │ │ │ ├── example_glfw_vulkan.vcxproj.filters │ │ │ └── main.cpp │ │ ├── example_glut_opengl2 │ │ │ ├── Makefile │ │ │ ├── example_glut_opengl2.vcxproj │ │ │ ├── example_glut_opengl2.vcxproj.filters │ │ │ └── main.cpp │ │ ├── example_marmalade │ │ │ ├── data │ │ │ │ └── app.icf │ │ │ ├── main.cpp │ │ │ └── marmalade_example.mkb │ │ ├── example_null │ │ │ ├── Makefile │ │ │ ├── build_win32.bat │ │ │ └── main.cpp │ │ ├── example_sdl_directx11 │ │ │ ├── build_win32.bat │ │ │ ├── example_sdl_directx11.vcxproj │ │ │ ├── example_sdl_directx11.vcxproj.filters │ │ │ └── main.cpp │ │ ├── example_sdl_metal │ │ │ ├── Makefile │ │ │ └── main.mm │ │ ├── example_sdl_opengl2 │ │ │ ├── Makefile │ │ │ ├── README.md │ │ │ ├── build_win32.bat │ │ │ ├── example_sdl_opengl2.vcxproj │ │ │ ├── example_sdl_opengl2.vcxproj.filters │ │ │ └── main.cpp │ │ ├── example_sdl_opengl3 │ │ │ ├── Makefile │ │ │ ├── README.md │ │ │ ├── build_win32.bat │ │ │ ├── example_sdl_opengl3.vcxproj │ │ │ ├── example_sdl_opengl3.vcxproj.filters │ │ │ └── main.cpp │ │ ├── example_sdl_vulkan │ │ │ ├── build_win32.bat │ │ │ ├── example_sdl_vulkan.vcxproj │ │ │ ├── example_sdl_vulkan.vcxproj.filters │ │ │ └── main.cpp │ │ ├── example_win32_directx10 │ │ │ ├── build_win32.bat │ │ │ ├── example_win32_directx10.vcxproj │ │ │ ├── example_win32_directx10.vcxproj.filters │ │ │ └── main.cpp │ │ ├── example_win32_directx11 │ │ │ ├── build_win32.bat │ │ │ ├── example_win32_directx11.vcxproj │ │ │ ├── example_win32_directx11.vcxproj.filters │ │ │ └── main.cpp │ │ ├── example_win32_directx12 │ │ │ ├── build_win32.bat │ │ │ ├── example_win32_directx12.vcxproj │ │ │ ├── example_win32_directx12.vcxproj.filters │ │ │ └── main.cpp │ │ ├── example_win32_directx9 │ │ │ ├── build_win32.bat │ │ │ ├── example_win32_directx9.vcxproj │ │ │ ├── example_win32_directx9.vcxproj.filters │ │ │ └── main.cpp │ │ ├── imgui_examples.sln │ │ └── libs │ │ │ ├── gl3w │ │ │ └── GL │ │ │ │ ├── gl3w.c │ │ │ │ ├── gl3w.h │ │ │ │ └── glcorearb.h │ │ │ ├── glfw │ │ │ ├── COPYING.txt │ │ │ └── include │ │ │ │ └── GLFW │ │ │ │ ├── glfw3.h │ │ │ │ └── glfw3native.h │ │ │ └── usynergy │ │ │ ├── README.txt │ │ │ ├── uSynergy.c │ │ │ └── uSynergy.h │ ├── imconfig.h │ ├── imgui.cpp │ ├── imgui.h │ ├── imgui_demo.cpp │ ├── imgui_draw.cpp │ ├── imgui_internal.h │ ├── imgui_tables.cpp │ ├── imgui_widgets.cpp │ ├── imstb_rectpack.h │ ├── imstb_textedit.h │ ├── imstb_truetype.h │ └── misc │ │ ├── README.txt │ │ ├── cpp │ │ ├── README.txt │ │ ├── imgui_stdlib.cpp │ │ └── imgui_stdlib.h │ │ ├── debuggers │ │ ├── README.txt │ │ ├── imgui.gdb │ │ ├── imgui.natstepfilter │ │ └── imgui.natvis │ │ ├── fonts │ │ ├── Cousine-Regular.ttf │ │ ├── DroidSans.ttf │ │ ├── Karla-Regular.ttf │ │ ├── ProggyClean.ttf │ │ ├── ProggyTiny.ttf │ │ ├── Roboto-Medium.ttf │ │ └── binary_to_compressed_c.cpp │ │ ├── freetype │ │ ├── README.md │ │ ├── imgui_freetype.cpp │ │ └── imgui_freetype.h │ │ └── single_file │ │ └── imgui_single_file.h ├── imgui-notify │ ├── notify.h │ └── notify │ │ ├── fa-solid-900.h │ │ ├── font_awesome_5.h │ │ └── notify.h ├── mINI │ └── mini │ │ └── ini.h ├── rapidjson │ └── rapidjson │ │ ├── allocators.h │ │ ├── cursorstreamwrapper.h │ │ ├── document.h │ │ ├── encodedstream.h │ │ ├── encodings.h │ │ ├── error │ │ ├── en.h │ │ └── error.h │ │ ├── filereadstream.h │ │ ├── filewritestream.h │ │ ├── fwd.h │ │ ├── internal │ │ ├── biginteger.h │ │ ├── clzll.h │ │ ├── diyfp.h │ │ ├── dtoa.h │ │ ├── ieee754.h │ │ ├── itoa.h │ │ ├── meta.h │ │ ├── pow10.h │ │ ├── regex.h │ │ ├── stack.h │ │ ├── strfunc.h │ │ ├── strtod.h │ │ └── swap.h │ │ ├── istreamwrapper.h │ │ ├── memorybuffer.h │ │ ├── memorystream.h │ │ ├── msinttypes │ │ ├── inttypes.h │ │ └── stdint.h │ │ ├── ostreamwrapper.h │ │ ├── pointer.h │ │ ├── prettywriter.h │ │ ├── rapidjson.h │ │ ├── reader.h │ │ ├── schema.h │ │ ├── stream.h │ │ ├── stringbuffer.h │ │ └── writer.h └── spdlog-1.8.5 │ └── spdlog │ ├── async.h │ ├── async_logger-inl.h │ ├── async_logger.h │ ├── cfg │ ├── argv.h │ ├── env.h │ ├── helpers-inl.h │ └── helpers.h │ ├── common-inl.h │ ├── common.h │ ├── details │ ├── backtracer-inl.h │ ├── backtracer.h │ ├── circular_q.h │ ├── console_globals.h │ ├── file_helper-inl.h │ ├── file_helper.h │ ├── fmt_helper.h │ ├── log_msg-inl.h │ ├── log_msg.h │ ├── log_msg_buffer-inl.h │ ├── log_msg_buffer.h │ ├── mpmc_blocking_q.h │ ├── null_mutex.h │ ├── os-inl.h │ ├── os.h │ ├── periodic_worker-inl.h │ ├── periodic_worker.h │ ├── registry-inl.h │ ├── registry.h │ ├── synchronous_factory.h │ ├── tcp_client-windows.h │ ├── tcp_client.h │ ├── thread_pool-inl.h │ ├── thread_pool.h │ └── windows_include.h │ ├── fmt │ ├── bin_to_hex.h │ ├── chrono.h │ ├── fmt.h │ └── ostr.h │ ├── formatter.h │ ├── fwd.h │ ├── logger-inl.h │ ├── logger.h │ ├── pattern_formatter-inl.h │ ├── pattern_formatter.h │ ├── sinks │ ├── android_sink.h │ ├── ansicolor_sink-inl.h │ ├── ansicolor_sink.h │ ├── base_sink-inl.h │ ├── base_sink.h │ ├── basic_file_sink-inl.h │ ├── basic_file_sink.h │ ├── daily_file_sink.h │ ├── dist_sink.h │ ├── dup_filter_sink.h │ ├── hourly_file_sink.h │ ├── msvc_sink.h │ ├── null_sink.h │ ├── ostream_sink.h │ ├── ringbuffer_sink.h │ ├── rotating_file_sink-inl.h │ ├── rotating_file_sink.h │ ├── sink-inl.h │ ├── sink.h │ ├── stdout_color_sinks-inl.h │ ├── stdout_color_sinks.h │ ├── stdout_sinks-inl.h │ ├── stdout_sinks.h │ ├── syslog_sink.h │ ├── systemd_sink.h │ ├── tcp_sink.h │ ├── win_eventlog_sink.h │ ├── wincolor_sink-inl.h │ └── wincolor_sink.h │ ├── spdlog-inl.h │ ├── spdlog.h │ ├── stopwatch.h │ ├── tweakme.h │ └── version.h ├── include ├── abstract_singleton.hpp ├── application.hpp ├── basic_log.hpp ├── d3d_impl.hpp ├── error_handler.hpp ├── fa-brands-400.h ├── fa-solid-900.h ├── i18n.hpp ├── log_helper.hpp ├── main_ui.hpp ├── pch.hpp ├── simple_timer.hpp ├── sys_check.hpp ├── ui_types.hpp ├── widget.hpp └── window.hpp └── src ├── application.cpp ├── d3d_impl.cpp ├── entry.cpp ├── i18n.cpp ├── log_helper.cpp ├── main_ui.cpp ├── pch.cpp ├── sys_check.cpp ├── ui_types.cpp ├── widget.cpp └── window.cpp /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | -------------------------------------------------------------------------------- /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | ko_fi: mq1n4 2 | -------------------------------------------------------------------------------- /.github/workflows/build.yml: -------------------------------------------------------------------------------- 1 | name: build 2 | 3 | on: 4 | push: 5 | branches: 6 | - experimental_ui 7 | 8 | jobs: 9 | 10 | windows: 11 | strategy: 12 | matrix: 13 | os: [windows-2019] 14 | include: 15 | - os: windows-2019 16 | generator: Visual Studio 16 2019 17 | 18 | runs-on: ${{ matrix.os }} 19 | 20 | steps: 21 | - uses: actions/checkout@v1 22 | with: 23 | token: ${{ secrets.ACCESS_TOKEN }} 24 | - name: Compile tests 25 | working-directory: build 26 | run: | 27 | cmake .. -A x64 -DCMAKE_CXX_FLAGS=/W1 -G"${{ matrix.generator }}" 28 | cmake --build . -j 6 29 | - name: Collect outputs 30 | run: | 31 | mkdir _output 32 | mkdir _output\\I18n 33 | copy Bin\\*.exe _output 34 | copy Bin\\I18n\\*.json _output\\I18n 35 | - name: Upload 36 | uses: actions/upload-artifact@v1 37 | with: 38 | name: output 39 | path: _output 40 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Prerequisites 2 | *.d 3 | 4 | # Compiled Object files 5 | *.slo 6 | *.lo 7 | *.o 8 | *.obj 9 | 10 | # Precompiled Headers 11 | *.gch 12 | *.pch 13 | 14 | # Compiled Dynamic libraries 15 | *.so 16 | *.dylib 17 | *.dll 18 | 19 | # Fortran module files 20 | *.mod 21 | *.smod 22 | 23 | # Compiled Static libraries 24 | *.lai 25 | *.la 26 | *.a 27 | *.lib 28 | !/extern/d3d9/lib_x86/*.lib 29 | !/extern/d3d9/lib_x64/*.lib 30 | 31 | # Executables 32 | *.exe 33 | *.out 34 | *.app 35 | 36 | # Project folders 37 | /.vs_proj 38 | /build/* 39 | !/build/.gitkeep 40 | 41 | # Debug symbols 42 | *.pdb 43 | 44 | # Config/Log files 45 | *.cfg 46 | *.ini 47 | *.log -------------------------------------------------------------------------------- /.vscode/launch.json: -------------------------------------------------------------------------------- 1 | { 2 | // Use IntelliSense to learn about possible attributes. 3 | // Hover to view descriptions of existing attributes. 4 | // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 5 | "version": "0.2.0", 6 | "configurations": [ 7 | { 8 | "name": "Attach", 9 | "type": "cppvsdbg", 10 | "request": "attach", 11 | "processId": "${command:pickProcess}" 12 | }, 13 | { 14 | "name": "Launch", 15 | "type": "cppvsdbg", 16 | "request": "launch", 17 | "program": "${workspaceFolder}\\Bin\\Win11SysCheck.exe", 18 | "args": [], 19 | "stopAtEntry": false, 20 | "cwd": "${workspaceFolder}\\Bin", 21 | "environment": [], 22 | "console": "internalConsole" 23 | } 24 | ] 25 | } -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "workbench.colorCustomizations": { 3 | "activityBar.background": "#013618", 4 | "titleBar.activeBackground": "#014B22", 5 | "titleBar.activeForeground": "#ECFFF4" 6 | }, 7 | "files.associations": { 8 | "iostream": "cpp" 9 | } 10 | } -------------------------------------------------------------------------------- /Bin/I18n/en_us.json: -------------------------------------------------------------------------------- 1 | { 2 | // Common 3 | "1": { 4 | "1": "Unknown", 5 | "2": "Initializing...", 6 | "3": "Compatible!", 7 | "4": "NOT Compatible!", 8 | "5": "Status", 9 | "6": "Details", 10 | "7": "Export", 11 | "8": "Dark Mode", 12 | "9": "Capable", 13 | "10": "Enabled", 14 | "11": "disabled", 15 | "12": "Version", 16 | "13": "Build", 17 | "14": "Result", 18 | "15": "System can upgradable to Windows 11", 19 | "16": "System can NOT upgradable to Windows 11", 20 | "17": "Result data succesfully exported to: %s", 21 | "18": "Result data export failed!", 22 | "19": "# More on Windows 11", 23 | "20": "# System specifications", 24 | "21": "\t> Supported CPU List:" 25 | }, 26 | // Menu 27 | "2": { 28 | "1": "Summary", 29 | "2": "OS", 30 | "3": "Boot", 31 | "4": "CPU", 32 | "5": "RAM", 33 | "6": "Disk", 34 | "7": "Display", 35 | "8": "Internet" 36 | }, 37 | // System details 38 | "3": { 39 | "1": "OS Version", 40 | "2": "OS Service pack", 41 | "3": "OS Build", 42 | "4": "OS Platform", 43 | "5": "OS Product Type", 44 | "6": "Boot Firmware", 45 | "7": "Secure Boot status", 46 | "8": "TPM", 47 | "9": "Processor name", 48 | "10": "Processor details", 49 | "11": "Processor architecture", 50 | "12": "Active processor count", 51 | "13": "Processor count", 52 | "14": "Total Memory" 53 | } 54 | } -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | [![Build Status](https://img.shields.io/github/workflow/status/mq1n/Win11SysCheck/build)](https://github.com/mq1n/Win11SysCheck/actions) 2 | [![Download](https://img.shields.io/github/v/release/mq1n/Win11SysCheck)](https://github.com/mq1n/Win11SysCheck/releases/latest/) 3 | [![Ko-fi](https://img.shields.io/badge/Support%20me%20on-Ko--fi-FF5E5B.svg?logo=ko-fi)](https://ko-fi.com/mq1n4) 4 | 5 | # Win11SysCheck 6 | Windows 11 compability check software with user friendly output 7 | 8 | ![image](assets/preview.png) 9 |
10 | 11 | GUI available as experimental release in experimental_ui branch 12 | 13 | 14 |
15 | 16 | ---- 17 | 18 | ## Contributing 19 | * Fork it(https://github.com/mq1n/Win11SysCheck/fork) 20 | * Create your feature branch: "git checkout -b my-new-feature". 21 | * Commit your changes: "git commit -am 'Add some feature'". 22 | * Push to the branch: "git push origin my-new-feature". 23 | * Submit a pull request. 24 | 25 | ## License 26 | 27 | Win11SysCheck is free and open source software, it is using the [GPL-3.0 license](https://github.com/mq1n/Win11SysCheck/blob/main/LICENSE) 28 | -------------------------------------------------------------------------------- /Win11SysCheck.code-workspace: -------------------------------------------------------------------------------- 1 | { 2 | "folders": [ 3 | { 4 | "path": "." 5 | } 6 | ], 7 | "settings": { 8 | "workbench.colorCustomizations": { 9 | "activityBar.background": "#203123", 10 | "titleBar.activeBackground": "#2D4531", 11 | "titleBar.activeForeground": "#F9FBFA" 12 | } 13 | } 14 | } -------------------------------------------------------------------------------- /assets/preview.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/assets/preview.gif -------------------------------------------------------------------------------- /assets/preview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/assets/preview.png -------------------------------------------------------------------------------- /build/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/build/.gitkeep -------------------------------------------------------------------------------- /extern/d3d9/lib_x64/DxErr.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/extern/d3d9/lib_x64/DxErr.lib -------------------------------------------------------------------------------- /extern/d3d9/lib_x64/d3d9.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/extern/d3d9/lib_x64/d3d9.lib -------------------------------------------------------------------------------- /extern/d3d9/lib_x64/d3dx9.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/extern/d3d9/lib_x64/d3dx9.lib -------------------------------------------------------------------------------- /extern/d3d9/lib_x64/dinput8.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/extern/d3d9/lib_x64/dinput8.lib -------------------------------------------------------------------------------- /extern/d3d9/lib_x86/DxErr.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/extern/d3d9/lib_x86/DxErr.lib -------------------------------------------------------------------------------- /extern/d3d9/lib_x86/d3d9.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/extern/d3d9/lib_x86/d3d9.lib -------------------------------------------------------------------------------- /extern/d3d9/lib_x86/d3dx9.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/extern/d3d9/lib_x86/d3dx9.lib -------------------------------------------------------------------------------- /extern/d3d9/lib_x86/dinput8.lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/extern/d3d9/lib_x86/dinput8.lib -------------------------------------------------------------------------------- /extern/fmt-7.1.3/fmt/locale.h: -------------------------------------------------------------------------------- 1 | // Formatting library for C++ - std::locale support 2 | // 3 | // Copyright (c) 2012 - present, Victor Zverovich 4 | // All rights reserved. 5 | // 6 | // For the license information refer to format.h. 7 | 8 | #ifndef FMT_LOCALE_H_ 9 | #define FMT_LOCALE_H_ 10 | 11 | #include 12 | 13 | #include "format.h" 14 | 15 | FMT_BEGIN_NAMESPACE 16 | 17 | namespace detail { 18 | template 19 | std::basic_string vformat( 20 | const std::locale& loc, basic_string_view format_str, 21 | basic_format_args>> args) { 22 | basic_memory_buffer buffer; 23 | detail::vformat_to(buffer, format_str, args, detail::locale_ref(loc)); 24 | return fmt::to_string(buffer); 25 | } 26 | } // namespace detail 27 | 28 | template > 29 | inline std::basic_string vformat( 30 | const std::locale& loc, const S& format_str, 31 | basic_format_args>> args) { 32 | return detail::vformat(loc, to_string_view(format_str), args); 33 | } 34 | 35 | template > 36 | inline std::basic_string format(const std::locale& loc, 37 | const S& format_str, Args&&... args) { 38 | return detail::vformat(loc, to_string_view(format_str), 39 | fmt::make_args_checked(format_str, args...)); 40 | } 41 | 42 | template , 44 | FMT_ENABLE_IF(detail::is_output_iterator::value)> 45 | inline OutputIt vformat_to( 46 | OutputIt out, const std::locale& loc, const S& format_str, 47 | basic_format_args>> args) { 48 | decltype(detail::get_buffer(out)) buf(detail::get_buffer_init(out)); 49 | vformat_to(buf, to_string_view(format_str), args, detail::locale_ref(loc)); 50 | return detail::get_iterator(buf); 51 | } 52 | 53 | template >::value> 55 | inline auto format_to(OutputIt out, const std::locale& loc, 56 | const S& format_str, Args&&... args) -> 57 | typename std::enable_if::type { 58 | const auto& vargs = fmt::make_args_checked(format_str, args...); 59 | return vformat_to(out, loc, to_string_view(format_str), vargs); 60 | } 61 | 62 | FMT_END_NAMESPACE 63 | 64 | #endif // FMT_LOCALE_H_ 65 | -------------------------------------------------------------------------------- /extern/fmt-7.1.3/fmt/posix.h: -------------------------------------------------------------------------------- 1 | #include "os.h" 2 | #warning "fmt/posix.h is deprecated; use fmt/os.h instead" 3 | -------------------------------------------------------------------------------- /extern/imgui-1.83/.editorconfig: -------------------------------------------------------------------------------- 1 | # See http://editorconfig.org to read about the EditorConfig format. 2 | # - In theory automatically supported by VS2017+ and most common IDE or text editors. 3 | # - In practice VS2019 stills gets trailing whitespaces wrong :( 4 | # - Suggest install to trim whitespaces: https://marketplace.visualstudio.com/items?itemName=MadsKristensen.TrailingWhitespaceVisualizer 5 | # - Alternative for older VS2010 to VS2015: https://marketplace.visualstudio.com/items?itemName=EditorConfigTeam.EditorConfig 6 | 7 | # top-most EditorConfig file 8 | root = true 9 | 10 | # Default settings: 11 | # Use 4 spaces as indentation 12 | [*] 13 | indent_style = space 14 | indent_size = 4 15 | insert_final_newline = true 16 | trim_trailing_whitespace = true 17 | 18 | [imstb_*] 19 | indent_size = 3 20 | trim_trailing_whitespace = false 21 | 22 | [Makefile] 23 | indent_style = tab 24 | indent_size = 4 25 | -------------------------------------------------------------------------------- /extern/imgui-1.83/.gitattributes: -------------------------------------------------------------------------------- 1 | * text=auto 2 | 3 | *.c text 4 | *.cpp text 5 | *.h text 6 | *.m text 7 | *.mm text 8 | *.md text 9 | *.txt text 10 | *.html text 11 | *.bat text 12 | *.frag text 13 | *.vert text 14 | *.mkb text 15 | *.icf text 16 | 17 | *.sln text eol=crlf 18 | *.vcxproj text eol=crlf 19 | *.vcxproj.filters text eol=crlf 20 | *.natvis text eol=crlf 21 | 22 | Makefile text eol=lf 23 | *.sh text eol=lf 24 | *.pbxproj text eol=lf 25 | *.storyboard text eol=lf 26 | *.plist text eol=lf 27 | 28 | *.png binary 29 | *.ttf binary 30 | *.lib binary 31 | -------------------------------------------------------------------------------- /extern/imgui-1.83/.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | custom: ['https://github.com/ocornut/imgui/wiki/Sponsors'] 2 | -------------------------------------------------------------------------------- /extern/imgui-1.83/.github/issue_template.md: -------------------------------------------------------------------------------- 1 | (Click "Preview" above ^ to turn URL into clickable links) 2 | 3 | 1. PLEASE CAREFULLY READ: [FAQ](https://github.com/ocornut/imgui/blob/master/docs/FAQ.md) 4 | 5 | 2. PLEASE CAREFULLY READ: [Issue Submitting Guidelines](https://github.com/ocornut/imgui/issues/2261) 6 | 7 | 3. FOR FIRST-TIME USERS ISSUES COMPILING/LINKING/RUNNING/LOADING FONTS, please use [GitHub Discussions](https://github.com/ocornut/imgui/discussions). 8 | 9 | 4. PLEASE MAKE SURE that you have: read the FAQ; explored the contents of `ShowDemoWindow()` including the Examples menu; searched among Issues; used your IDE to search for keywords in all sources and text files; and read the link provided in (1) (2). 10 | 11 | 5. Be mindful that messages are being sent to the e-mail box of "Watching" users. Try to proof-read your messages before sending them. Edits are not seen by those users. 12 | 13 | 6. Delete points 1-6 and PLEASE FILL THE TEMPLATE BELOW before submitting your issue. 14 | 15 | Thank you! 16 | 17 | ---- 18 | 19 | _(you may also go to Demo>About Window, and click "Config/Build Information" to obtain a bunch of detailed information that you can paste here)_ 20 | 21 | **Version/Branch of Dear ImGui:** 22 | 23 | Version: XXX 24 | Branch: XXX _(master/viewport/docking/etc.)_ 25 | 26 | **Back-end/Renderer/Compiler/OS** 27 | 28 | Back-ends: imgui_impl_XXX.cpp + imgui_impl_XXX.cpp _(or specify if using a custom engine/back-end)_ 29 | Compiler: XXX _(if the question is related to building or platform specific features)_ 30 | Operating System: XXX 31 | 32 | **My Issue/Question:** 33 | 34 | XXX _(please provide as much context as possible)_ 35 | 36 | **Screenshots/Video** 37 | 38 | XXX _(you can drag files here)_ 39 | 40 | **Standalone, minimal, complete and verifiable example:** _(see https://github.com/ocornut/imgui/issues/2261)_ 41 | ``` 42 | // Here's some code anyone can copy and paste to reproduce your issue 43 | ImGui::Begin("Example Bug"); 44 | MoreCodeToExplainMyIssue(); 45 | ImGui::End(); 46 | ``` 47 | -------------------------------------------------------------------------------- /extern/imgui-1.83/.github/pull_request_template.md: -------------------------------------------------------------------------------- 1 | (Click "Preview" to turn any http URL into a clickable link) 2 | 3 | PLEASE CAREFULLY READ: 4 | https://github.com/ocornut/imgui/issues/2261 5 | 6 | (Clear this template before submitting your PR) 7 | -------------------------------------------------------------------------------- /extern/imgui-1.83/.github/workflows/scheduled.yml: -------------------------------------------------------------------------------- 1 | # 2 | # This is a dummy workflow used to trigger scheduled builds. Forked repositories most likely should disable this 3 | # workflow to avoid daily builds of inactive repositories. 4 | # 5 | name: scheduled 6 | 7 | on: 8 | schedule: 9 | - cron: '0 9 * * *' 10 | 11 | jobs: 12 | scheduled: 13 | runs-on: ubuntu-latest 14 | steps: 15 | - run: exit 0 16 | -------------------------------------------------------------------------------- /extern/imgui-1.83/.gitignore: -------------------------------------------------------------------------------- 1 | ## OSX artifacts 2 | .DS_Store 3 | 4 | ## Dear ImGui artifacts 5 | imgui.ini 6 | 7 | ## General build artifacts 8 | *.o 9 | *.obj 10 | *.exe 11 | examples/build/* 12 | examples/*/Debug/* 13 | examples/*/Release/* 14 | examples/*/x64/* 15 | 16 | ## Visual Studio artifacts 17 | .vs 18 | ipch 19 | *.opensdf 20 | *.log 21 | *.pdb 22 | *.ilk 23 | *.user 24 | *.sdf 25 | *.suo 26 | *.VC.db 27 | *.VC.VC.opendb 28 | 29 | ## Commonly used CMake directories 30 | /build*/ 31 | 32 | ## Xcode artifacts 33 | project.xcworkspace 34 | xcuserdata 35 | 36 | ## Emscripten artifacts 37 | examples/*.o.tmp 38 | examples/*.out.js 39 | examples/*.out.wasm 40 | examples/example_emscripten_opengl3/web/* 41 | examples/example_emscripten_wgpu/web/* 42 | 43 | ## JetBrains IDE artifacts 44 | .idea 45 | cmake-build-* 46 | 47 | ## Unix executables from our example Makefiles 48 | examples/example_glfw_opengl2/example_glfw_opengl2 49 | examples/example_glfw_opengl3/example_glfw_opengl3 50 | examples/example_glut_opengl2/example_glut_opengl2 51 | examples/example_null/example_null 52 | examples/example_sdl_opengl2/example_sdl_opengl2 53 | examples/example_sdl_opengl3/example_sdl_opengl3 54 | -------------------------------------------------------------------------------- /extern/imgui-1.83/LICENSE.txt: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014-2021 Omar Cornut 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/imgui_impl_allegro5.h: -------------------------------------------------------------------------------- 1 | // dear imgui: Renderer + Platform Backend for Allegro 5 2 | // (Info: Allegro 5 is a cross-platform general purpose library for handling windows, inputs, graphics, etc.) 3 | 4 | // Implemented features: 5 | // [X] Renderer: User texture binding. Use 'ALLEGRO_BITMAP*' as ImTextureID. Read the FAQ about ImTextureID! 6 | // [X] Platform: Clipboard support (from Allegro 5.1.12) 7 | // [X] Platform: Mouse cursor shape and visibility. Disable with 'io.ConfigFlags |= ImGuiConfigFlags_NoMouseCursorChange'. 8 | // Issues: 9 | // [ ] Renderer: The renderer is suboptimal as we need to unindex our buffers and convert vertices manually. 10 | // [ ] Platform: Missing gamepad support. 11 | 12 | // You can copy and use unmodified imgui_impl_* files in your project. See examples/ folder for examples of using this. 13 | // If you are new to Dear ImGui, read documentation from the docs/ folder + read the top of imgui.cpp. 14 | // Read online: https://github.com/ocornut/imgui/tree/master/docs 15 | 16 | #pragma once 17 | #include "imgui.h" // IMGUI_IMPL_API 18 | 19 | struct ALLEGRO_DISPLAY; 20 | union ALLEGRO_EVENT; 21 | 22 | IMGUI_IMPL_API bool ImGui_ImplAllegro5_Init(ALLEGRO_DISPLAY* display); 23 | IMGUI_IMPL_API void ImGui_ImplAllegro5_Shutdown(); 24 | IMGUI_IMPL_API void ImGui_ImplAllegro5_NewFrame(); 25 | IMGUI_IMPL_API void ImGui_ImplAllegro5_RenderDrawData(ImDrawData* draw_data); 26 | IMGUI_IMPL_API bool ImGui_ImplAllegro5_ProcessEvent(ALLEGRO_EVENT* event); 27 | 28 | // Use if you want to reset your rendering device without losing Dear ImGui state. 29 | IMGUI_IMPL_API bool ImGui_ImplAllegro5_CreateDeviceObjects(); 30 | IMGUI_IMPL_API void ImGui_ImplAllegro5_InvalidateDeviceObjects(); 31 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/imgui_impl_android.h: -------------------------------------------------------------------------------- 1 | // dear imgui: Platform Binding for Android native app 2 | // This needs to be used along with the OpenGL 3 Renderer (imgui_impl_opengl3) 3 | 4 | // Implemented features: 5 | // [X] Platform: Keyboard arrays indexed using AKEYCODE_* codes, e.g. ImGui::IsKeyPressed(AKEYCODE_SPACE). 6 | // Missing features: 7 | // [ ] Platform: Clipboard support. 8 | // [ ] Platform: Gamepad support. Enable with 'io.ConfigFlags |= ImGuiConfigFlags_NavEnableGamepad'. 9 | // [ ] Platform: Mouse cursor shape and visibility. Disable with 'io.ConfigFlags |= ImGuiConfigFlags_NoMouseCursorChange'. FIXME: Check if this is even possible with Android. 10 | // Important: 11 | // - FIXME: On-screen keyboard currently needs to be enabled by the application (see examples/ and issue #3446) 12 | // - FIXME: Unicode character inputs needs to be passed by Dear ImGui by the application (see examples/ and issue #3446) 13 | 14 | // You can copy and use unmodified imgui_impl_* files in your project. See main.cpp for an example of using this. 15 | // If you are new to dear imgui, read examples/README.txt and read the documentation at the top of imgui.cpp. 16 | // https://github.com/ocornut/imgui 17 | 18 | #pragma once 19 | 20 | struct ANativeWindow; 21 | struct AInputEvent; 22 | 23 | IMGUI_IMPL_API bool ImGui_ImplAndroid_Init(ANativeWindow* window); 24 | IMGUI_IMPL_API int32_t ImGui_ImplAndroid_HandleInputEvent(AInputEvent* input_event); 25 | IMGUI_IMPL_API void ImGui_ImplAndroid_Shutdown(); 26 | IMGUI_IMPL_API void ImGui_ImplAndroid_NewFrame(); 27 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/imgui_impl_dx10.h: -------------------------------------------------------------------------------- 1 | // dear imgui: Renderer Backend for DirectX10 2 | // This needs to be used along with a Platform Backend (e.g. Win32) 3 | 4 | // Implemented features: 5 | // [X] Renderer: User texture backend. Use 'ID3D10ShaderResourceView*' as ImTextureID. Read the FAQ about ImTextureID! 6 | // [X] Renderer: Support for large meshes (64k+ vertices) with 16-bit indices. 7 | 8 | // You can copy and use unmodified imgui_impl_* files in your project. See examples/ folder for examples of using this. 9 | // If you are new to Dear ImGui, read documentation from the docs/ folder + read the top of imgui.cpp. 10 | // Read online: https://github.com/ocornut/imgui/tree/master/docs 11 | 12 | #pragma once 13 | #include "imgui.h" // IMGUI_IMPL_API 14 | 15 | struct ID3D10Device; 16 | 17 | IMGUI_IMPL_API bool ImGui_ImplDX10_Init(ID3D10Device* device); 18 | IMGUI_IMPL_API void ImGui_ImplDX10_Shutdown(); 19 | IMGUI_IMPL_API void ImGui_ImplDX10_NewFrame(); 20 | IMGUI_IMPL_API void ImGui_ImplDX10_RenderDrawData(ImDrawData* draw_data); 21 | 22 | // Use if you want to reset your rendering device without losing Dear ImGui state. 23 | IMGUI_IMPL_API void ImGui_ImplDX10_InvalidateDeviceObjects(); 24 | IMGUI_IMPL_API bool ImGui_ImplDX10_CreateDeviceObjects(); 25 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/imgui_impl_dx11.h: -------------------------------------------------------------------------------- 1 | // dear imgui: Renderer Backend for DirectX11 2 | // This needs to be used along with a Platform Backend (e.g. Win32) 3 | 4 | // Implemented features: 5 | // [X] Renderer: User texture binding. Use 'ID3D11ShaderResourceView*' as ImTextureID. Read the FAQ about ImTextureID! 6 | // [X] Renderer: Support for large meshes (64k+ vertices) with 16-bit indices. 7 | 8 | // You can copy and use unmodified imgui_impl_* files in your project. See examples/ folder for examples of using this. 9 | // If you are new to Dear ImGui, read documentation from the docs/ folder + read the top of imgui.cpp. 10 | // Read online: https://github.com/ocornut/imgui/tree/master/docs 11 | 12 | #pragma once 13 | #include "imgui.h" // IMGUI_IMPL_API 14 | 15 | struct ID3D11Device; 16 | struct ID3D11DeviceContext; 17 | 18 | IMGUI_IMPL_API bool ImGui_ImplDX11_Init(ID3D11Device* device, ID3D11DeviceContext* device_context); 19 | IMGUI_IMPL_API void ImGui_ImplDX11_Shutdown(); 20 | IMGUI_IMPL_API void ImGui_ImplDX11_NewFrame(); 21 | IMGUI_IMPL_API void ImGui_ImplDX11_RenderDrawData(ImDrawData* draw_data); 22 | 23 | // Use if you want to reset your rendering device without losing Dear ImGui state. 24 | IMGUI_IMPL_API void ImGui_ImplDX11_InvalidateDeviceObjects(); 25 | IMGUI_IMPL_API bool ImGui_ImplDX11_CreateDeviceObjects(); 26 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/imgui_impl_dx9.h: -------------------------------------------------------------------------------- 1 | // dear imgui: Renderer Backend for DirectX9 2 | // This needs to be used along with a Platform Backend (e.g. Win32) 3 | 4 | // Implemented features: 5 | // [X] Renderer: User texture binding. Use 'LPDIRECT3DTEXTURE9' as ImTextureID. Read the FAQ about ImTextureID! 6 | // [X] Renderer: Support for large meshes (64k+ vertices) with 16-bit indices. 7 | 8 | // You can copy and use unmodified imgui_impl_* files in your project. See examples/ folder for examples of using this. 9 | // If you are new to Dear ImGui, read documentation from the docs/ folder + read the top of imgui.cpp. 10 | // Read online: https://github.com/ocornut/imgui/tree/master/docs 11 | 12 | #pragma once 13 | #include "imgui.h" // IMGUI_IMPL_API 14 | 15 | struct IDirect3DDevice9; 16 | 17 | IMGUI_IMPL_API bool ImGui_ImplDX9_Init(IDirect3DDevice9* device); 18 | IMGUI_IMPL_API void ImGui_ImplDX9_Shutdown(); 19 | IMGUI_IMPL_API void ImGui_ImplDX9_NewFrame(); 20 | IMGUI_IMPL_API void ImGui_ImplDX9_RenderDrawData(ImDrawData* draw_data); 21 | 22 | // Use if you want to reset your rendering device without losing Dear ImGui state. 23 | IMGUI_IMPL_API bool ImGui_ImplDX9_CreateDeviceObjects(); 24 | IMGUI_IMPL_API void ImGui_ImplDX9_InvalidateDeviceObjects(); 25 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/imgui_impl_glfw.h: -------------------------------------------------------------------------------- 1 | // dear imgui: Platform Backend for GLFW 2 | // This needs to be used along with a Renderer (e.g. OpenGL3, Vulkan, WebGPU..) 3 | // (Info: GLFW is a cross-platform general purpose library for handling windows, inputs, OpenGL/Vulkan graphics context creation, etc.) 4 | 5 | // Implemented features: 6 | // [X] Platform: Clipboard support. 7 | // [X] Platform: Gamepad support. Enable with 'io.ConfigFlags |= ImGuiConfigFlags_NavEnableGamepad'. 8 | // [x] Platform: Mouse cursor shape and visibility. Disable with 'io.ConfigFlags |= ImGuiConfigFlags_NoMouseCursorChange'. FIXME: 3 cursors types are missing from GLFW. 9 | // [X] Platform: Keyboard arrays indexed using GLFW_KEY_* codes, e.g. ImGui::IsKeyPressed(GLFW_KEY_SPACE). 10 | 11 | // You can copy and use unmodified imgui_impl_* files in your project. See examples/ folder for examples of using this. 12 | // If you are new to Dear ImGui, read documentation from the docs/ folder + read the top of imgui.cpp. 13 | // Read online: https://github.com/ocornut/imgui/tree/master/docs 14 | 15 | // About GLSL version: 16 | // The 'glsl_version' initialization parameter defaults to "#version 150" if NULL. 17 | // Only override if your GL version doesn't handle this GLSL version. Keep NULL if unsure! 18 | 19 | #pragma once 20 | #include "imgui.h" // IMGUI_IMPL_API 21 | 22 | struct GLFWwindow; 23 | 24 | IMGUI_IMPL_API bool ImGui_ImplGlfw_InitForOpenGL(GLFWwindow* window, bool install_callbacks); 25 | IMGUI_IMPL_API bool ImGui_ImplGlfw_InitForVulkan(GLFWwindow* window, bool install_callbacks); 26 | IMGUI_IMPL_API bool ImGui_ImplGlfw_InitForOther(GLFWwindow* window, bool install_callbacks); 27 | IMGUI_IMPL_API void ImGui_ImplGlfw_Shutdown(); 28 | IMGUI_IMPL_API void ImGui_ImplGlfw_NewFrame(); 29 | 30 | // GLFW callbacks 31 | // - When calling Init with 'install_callbacks=true': GLFW callbacks will be installed for you. They will call user's previously installed callbacks, if any. 32 | // - When calling Init with 'install_callbacks=false': GLFW callbacks won't be installed. You will need to call those function yourself from your own GLFW callbacks. 33 | IMGUI_IMPL_API void ImGui_ImplGlfw_MouseButtonCallback(GLFWwindow* window, int button, int action, int mods); 34 | IMGUI_IMPL_API void ImGui_ImplGlfw_ScrollCallback(GLFWwindow* window, double xoffset, double yoffset); 35 | IMGUI_IMPL_API void ImGui_ImplGlfw_KeyCallback(GLFWwindow* window, int key, int scancode, int action, int mods); 36 | IMGUI_IMPL_API void ImGui_ImplGlfw_CharCallback(GLFWwindow* window, unsigned int c); 37 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/imgui_impl_glut.h: -------------------------------------------------------------------------------- 1 | // dear imgui: Platform Backend for GLUT/FreeGLUT 2 | // This needs to be used along with a Renderer (e.g. OpenGL2) 3 | 4 | // !!! GLUT/FreeGLUT IS OBSOLETE PREHISTORIC SOFTWARE. Using GLUT is not recommended unless you really miss the 90's. !!! 5 | // !!! If someone or something is teaching you GLUT today, you are being abused. Please show some resistance. !!! 6 | // !!! Nowadays, prefer using GLFW or SDL instead! 7 | 8 | // Issues: 9 | // [ ] Platform: GLUT is unable to distinguish e.g. Backspace from CTRL+H or TAB from CTRL+I 10 | // [ ] Platform: Missing mouse cursor shape/visibility support. 11 | // [ ] Platform: Missing clipboard support (not supported by Glut). 12 | // [ ] Platform: Missing gamepad support. 13 | 14 | // You can copy and use unmodified imgui_impl_* files in your project. See examples/ folder for examples of using this. 15 | // If you are new to Dear ImGui, read documentation from the docs/ folder + read the top of imgui.cpp. 16 | // Read online: https://github.com/ocornut/imgui/tree/master/docs 17 | 18 | #pragma once 19 | #include "imgui.h" // IMGUI_IMPL_API 20 | 21 | IMGUI_IMPL_API bool ImGui_ImplGLUT_Init(); 22 | IMGUI_IMPL_API void ImGui_ImplGLUT_InstallFuncs(); 23 | IMGUI_IMPL_API void ImGui_ImplGLUT_Shutdown(); 24 | IMGUI_IMPL_API void ImGui_ImplGLUT_NewFrame(); 25 | 26 | // You can call ImGui_ImplGLUT_InstallFuncs() to get all those functions installed automatically, 27 | // or call them yourself from your own GLUT handlers. We are using the same weird names as GLUT for consistency.. 28 | //---------------------------------------- GLUT name --------------------------------------------- Decent Name --------- 29 | IMGUI_IMPL_API void ImGui_ImplGLUT_ReshapeFunc(int w, int h); // ~ ResizeFunc 30 | IMGUI_IMPL_API void ImGui_ImplGLUT_MotionFunc(int x, int y); // ~ MouseMoveFunc 31 | IMGUI_IMPL_API void ImGui_ImplGLUT_MouseFunc(int button, int state, int x, int y); // ~ MouseButtonFunc 32 | IMGUI_IMPL_API void ImGui_ImplGLUT_MouseWheelFunc(int button, int dir, int x, int y); // ~ MouseWheelFunc 33 | IMGUI_IMPL_API void ImGui_ImplGLUT_KeyboardFunc(unsigned char c, int x, int y); // ~ CharPressedFunc 34 | IMGUI_IMPL_API void ImGui_ImplGLUT_KeyboardUpFunc(unsigned char c, int x, int y); // ~ CharReleasedFunc 35 | IMGUI_IMPL_API void ImGui_ImplGLUT_SpecialFunc(int key, int x, int y); // ~ KeyPressedFunc 36 | IMGUI_IMPL_API void ImGui_ImplGLUT_SpecialUpFunc(int key, int x, int y); // ~ KeyReleasedFunc 37 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/imgui_impl_marmalade.h: -------------------------------------------------------------------------------- 1 | // dear imgui: Renderer + Platform Backend for Marmalade + IwGx 2 | // Marmalade code: Copyright (C) 2015 by Giovanni Zito (this file is part of Dear ImGui) 3 | 4 | // Implemented features: 5 | // [X] Renderer: User texture binding. Use 'CIwTexture*' as ImTextureID. Read the FAQ about ImTextureID! 6 | 7 | // You can copy and use unmodified imgui_impl_* files in your project. See examples/ folder for examples of using this. 8 | // If you are new to Dear ImGui, read documentation from the docs/ folder + read the top of imgui.cpp. 9 | // Read online: https://github.com/ocornut/imgui/tree/master/docs 10 | 11 | #pragma once 12 | #include "imgui.h" // IMGUI_IMPL_API 13 | 14 | IMGUI_IMPL_API bool ImGui_Marmalade_Init(bool install_callbacks); 15 | IMGUI_IMPL_API void ImGui_Marmalade_Shutdown(); 16 | IMGUI_IMPL_API void ImGui_Marmalade_NewFrame(); 17 | IMGUI_IMPL_API void ImGui_Marmalade_RenderDrawData(ImDrawData* draw_data); 18 | 19 | // Use if you want to reset your rendering device without losing Dear ImGui state. 20 | IMGUI_IMPL_API void ImGui_Marmalade_InvalidateDeviceObjects(); 21 | IMGUI_IMPL_API bool ImGui_Marmalade_CreateDeviceObjects(); 22 | 23 | // Callbacks (installed by default if you enable 'install_callbacks' during initialization) 24 | // You can also handle inputs yourself and use those as a reference. 25 | IMGUI_IMPL_API int32 ImGui_Marmalade_PointerButtonEventCallback(void* system_data, void* user_data); 26 | IMGUI_IMPL_API int32 ImGui_Marmalade_KeyCallback(void* system_data, void* user_data); 27 | IMGUI_IMPL_API int32 ImGui_Marmalade_CharCallback(void* system_data, void* user_data); 28 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/imgui_impl_metal.h: -------------------------------------------------------------------------------- 1 | // dear imgui: Renderer Backend for Metal 2 | // This needs to be used along with a Platform Backend (e.g. OSX) 3 | 4 | // Implemented features: 5 | // [X] Renderer: User texture binding. Use 'MTLTexture' as ImTextureID. Read the FAQ about ImTextureID! 6 | // [X] Renderer: Support for large meshes (64k+ vertices) with 16-bit indices. 7 | 8 | // You can copy and use unmodified imgui_impl_* files in your project. See examples/ folder for examples of using this. 9 | // If you are new to Dear ImGui, read documentation from the docs/ folder + read the top of imgui.cpp. 10 | // Read online: https://github.com/ocornut/imgui/tree/master/docs 11 | 12 | #include "imgui.h" // IMGUI_IMPL_API 13 | 14 | @class MTLRenderPassDescriptor; 15 | @protocol MTLDevice, MTLCommandBuffer, MTLRenderCommandEncoder; 16 | 17 | IMGUI_IMPL_API bool ImGui_ImplMetal_Init(id device); 18 | IMGUI_IMPL_API void ImGui_ImplMetal_Shutdown(); 19 | IMGUI_IMPL_API void ImGui_ImplMetal_NewFrame(MTLRenderPassDescriptor* renderPassDescriptor); 20 | IMGUI_IMPL_API void ImGui_ImplMetal_RenderDrawData(ImDrawData* draw_data, 21 | id commandBuffer, 22 | id commandEncoder); 23 | 24 | // Called by Init/NewFrame/Shutdown 25 | IMGUI_IMPL_API bool ImGui_ImplMetal_CreateFontsTexture(id device); 26 | IMGUI_IMPL_API void ImGui_ImplMetal_DestroyFontsTexture(); 27 | IMGUI_IMPL_API bool ImGui_ImplMetal_CreateDeviceObjects(id device); 28 | IMGUI_IMPL_API void ImGui_ImplMetal_DestroyDeviceObjects(); 29 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/imgui_impl_opengl2.h: -------------------------------------------------------------------------------- 1 | // dear imgui: Renderer Backend for OpenGL2 (legacy OpenGL, fixed pipeline) 2 | // This needs to be used along with a Platform Backend (e.g. GLFW, SDL, Win32, custom..) 3 | 4 | // Implemented features: 5 | // [X] Renderer: User texture binding. Use 'GLuint' OpenGL texture identifier as void*/ImTextureID. Read the FAQ about ImTextureID! 6 | 7 | // You can copy and use unmodified imgui_impl_* files in your project. See examples/ folder for examples of using this. 8 | // If you are new to Dear ImGui, read documentation from the docs/ folder + read the top of imgui.cpp. 9 | // Read online: https://github.com/ocornut/imgui/tree/master/docs 10 | 11 | // **DO NOT USE THIS CODE IF YOUR CODE/ENGINE IS USING MODERN OPENGL (SHADERS, VBO, VAO, etc.)** 12 | // **Prefer using the code in imgui_impl_opengl3.cpp** 13 | // This code is mostly provided as a reference to learn how ImGui integration works, because it is shorter to read. 14 | // If your code is using GL3+ context or any semi modern OpenGL calls, using this is likely to make everything more 15 | // complicated, will require your code to reset every single OpenGL attributes to their initial state, and might 16 | // confuse your GPU driver. 17 | // The GL2 code is unable to reset attributes or even call e.g. "glUseProgram(0)" because they don't exist in that API. 18 | 19 | #pragma once 20 | #include "imgui.h" // IMGUI_IMPL_API 21 | 22 | IMGUI_IMPL_API bool ImGui_ImplOpenGL2_Init(); 23 | IMGUI_IMPL_API void ImGui_ImplOpenGL2_Shutdown(); 24 | IMGUI_IMPL_API void ImGui_ImplOpenGL2_NewFrame(); 25 | IMGUI_IMPL_API void ImGui_ImplOpenGL2_RenderDrawData(ImDrawData* draw_data); 26 | 27 | // Called by Init/NewFrame/Shutdown 28 | IMGUI_IMPL_API bool ImGui_ImplOpenGL2_CreateFontsTexture(); 29 | IMGUI_IMPL_API void ImGui_ImplOpenGL2_DestroyFontsTexture(); 30 | IMGUI_IMPL_API bool ImGui_ImplOpenGL2_CreateDeviceObjects(); 31 | IMGUI_IMPL_API void ImGui_ImplOpenGL2_DestroyDeviceObjects(); 32 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/imgui_impl_osx.h: -------------------------------------------------------------------------------- 1 | // dear imgui: Platform Backend for OSX / Cocoa 2 | // This needs to be used along with a Renderer (e.g. OpenGL2, OpenGL3, Vulkan, Metal..) 3 | // [ALPHA] Early backend, not well tested. If you want a portable application, prefer using the GLFW or SDL platform Backends on Mac. 4 | 5 | // Implemented features: 6 | // [X] Platform: Mouse cursor shape and visibility. Disable with 'io.ConfigFlags |= ImGuiConfigFlags_NoMouseCursorChange'. 7 | // [X] Platform: OSX clipboard is supported within core Dear ImGui (no specific code in this backend). 8 | // Issues: 9 | // [ ] Platform: Keys are all generally very broken. Best using [event keycode] and not [event characters].. 10 | 11 | // You can copy and use unmodified imgui_impl_* files in your project. See examples/ folder for examples of using this. 12 | // If you are new to Dear ImGui, read documentation from the docs/ folder + read the top of imgui.cpp. 13 | // Read online: https://github.com/ocornut/imgui/tree/master/docs 14 | 15 | #include "imgui.h" // IMGUI_IMPL_API 16 | 17 | @class NSEvent; 18 | @class NSView; 19 | 20 | IMGUI_IMPL_API bool ImGui_ImplOSX_Init(); 21 | IMGUI_IMPL_API void ImGui_ImplOSX_Shutdown(); 22 | IMGUI_IMPL_API void ImGui_ImplOSX_NewFrame(NSView* _Nullable view); 23 | IMGUI_IMPL_API bool ImGui_ImplOSX_HandleEvent(NSEvent* _Nonnull event, NSView* _Nullable view); 24 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/imgui_impl_sdl.h: -------------------------------------------------------------------------------- 1 | // dear imgui: Platform Backend for SDL2 2 | // This needs to be used along with a Renderer (e.g. DirectX11, OpenGL3, Vulkan..) 3 | // (Info: SDL2 is a cross-platform general purpose library for handling windows, inputs, graphics context creation, etc.) 4 | 5 | // Implemented features: 6 | // [X] Platform: Mouse cursor shape and visibility. Disable with 'io.ConfigFlags |= ImGuiConfigFlags_NoMouseCursorChange'. 7 | // [X] Platform: Clipboard support. 8 | // [X] Platform: Keyboard arrays indexed using SDL_SCANCODE_* codes, e.g. ImGui::IsKeyPressed(SDL_SCANCODE_SPACE). 9 | // [X] Platform: Gamepad support. Enabled with 'io.ConfigFlags |= ImGuiConfigFlags_NavEnableGamepad'. 10 | // Missing features: 11 | // [ ] Platform: SDL2 handling of IME under Windows appears to be broken and it explicitly disable the regular Windows IME. You can restore Windows IME by compiling SDL with SDL_DISABLE_WINDOWS_IME. 12 | 13 | // You can copy and use unmodified imgui_impl_* files in your project. See examples/ folder for examples of using this. 14 | // If you are new to Dear ImGui, read documentation from the docs/ folder + read the top of imgui.cpp. 15 | // Read online: https://github.com/ocornut/imgui/tree/master/docs 16 | 17 | #pragma once 18 | #include "imgui.h" // IMGUI_IMPL_API 19 | 20 | struct SDL_Window; 21 | typedef union SDL_Event SDL_Event; 22 | 23 | IMGUI_IMPL_API bool ImGui_ImplSDL2_InitForOpenGL(SDL_Window* window, void* sdl_gl_context); 24 | IMGUI_IMPL_API bool ImGui_ImplSDL2_InitForVulkan(SDL_Window* window); 25 | IMGUI_IMPL_API bool ImGui_ImplSDL2_InitForD3D(SDL_Window* window); 26 | IMGUI_IMPL_API bool ImGui_ImplSDL2_InitForMetal(SDL_Window* window); 27 | IMGUI_IMPL_API void ImGui_ImplSDL2_Shutdown(); 28 | IMGUI_IMPL_API void ImGui_ImplSDL2_NewFrame(SDL_Window* window); 29 | IMGUI_IMPL_API bool ImGui_ImplSDL2_ProcessEvent(const SDL_Event* event); 30 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/imgui_impl_wgpu.h: -------------------------------------------------------------------------------- 1 | // dear imgui: Renderer for WebGPU 2 | // This needs to be used along with a Platform Binding (e.g. GLFW) 3 | // (Please note that WebGPU is currently experimental, will not run on non-beta browsers, and may break.) 4 | 5 | // Implemented features: 6 | // [X] Renderer: User texture binding. Use 'WGPUTextureView' as ImTextureID. Read the FAQ about ImTextureID! 7 | // [X] Renderer: Support for large meshes (64k+ vertices) with 16-bit indices. 8 | 9 | // You can copy and use unmodified imgui_impl_* files in your project. See examples/ folder for examples of using this. 10 | // If you are new to Dear ImGui, read documentation from the docs/ folder + read the top of imgui.cpp. 11 | // Read online: https://github.com/ocornut/imgui/tree/master/docs 12 | 13 | #pragma once 14 | #include "imgui.h" // IMGUI_IMPL_API 15 | #include 16 | 17 | IMGUI_IMPL_API bool ImGui_ImplWGPU_Init(WGPUDevice device, int num_frames_in_flight, WGPUTextureFormat rt_format); 18 | IMGUI_IMPL_API void ImGui_ImplWGPU_Shutdown(); 19 | IMGUI_IMPL_API void ImGui_ImplWGPU_NewFrame(); 20 | IMGUI_IMPL_API void ImGui_ImplWGPU_RenderDrawData(ImDrawData* draw_data, WGPURenderPassEncoder pass_encoder); 21 | 22 | // Use if you want to reset your rendering device without losing Dear ImGui state. 23 | IMGUI_IMPL_API void ImGui_ImplWGPU_InvalidateDeviceObjects(); 24 | IMGUI_IMPL_API bool ImGui_ImplWGPU_CreateDeviceObjects(); 25 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/vulkan/generate_spv.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | ## -V: create SPIR-V binary 3 | ## -x: save binary output as text-based 32-bit hexadecimal numbers 4 | ## -o: output file 5 | glslangValidator -V -x -o glsl_shader.frag.u32 glsl_shader.frag 6 | glslangValidator -V -x -o glsl_shader.vert.u32 glsl_shader.vert 7 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/vulkan/glsl_shader.frag: -------------------------------------------------------------------------------- 1 | #version 450 core 2 | layout(location = 0) out vec4 fColor; 3 | 4 | layout(set=0, binding=0) uniform sampler2D sTexture; 5 | 6 | layout(location = 0) in struct { 7 | vec4 Color; 8 | vec2 UV; 9 | } In; 10 | 11 | void main() 12 | { 13 | fColor = In.Color * texture(sTexture, In.UV.st); 14 | } 15 | -------------------------------------------------------------------------------- /extern/imgui-1.83/backends/vulkan/glsl_shader.vert: -------------------------------------------------------------------------------- 1 | #version 450 core 2 | layout(location = 0) in vec2 aPos; 3 | layout(location = 1) in vec2 aUV; 4 | layout(location = 2) in vec4 aColor; 5 | 6 | layout(push_constant) uniform uPushConstant { 7 | vec2 uScale; 8 | vec2 uTranslate; 9 | } pc; 10 | 11 | out gl_PerVertex { 12 | vec4 gl_Position; 13 | }; 14 | 15 | layout(location = 0) out struct { 16 | vec4 Color; 17 | vec2 UV; 18 | } Out; 19 | 20 | void main() 21 | { 22 | Out.Color = aColor; 23 | Out.UV = aUV; 24 | gl_Position = vec4(aPos * pc.uScale + pc.uTranslate, 0, 1); 25 | } 26 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/README.txt: -------------------------------------------------------------------------------- 1 | See BACKENDS and EXAMPLES files in the docs/ folder. 2 | 3 | Backends = Helper code to facilitate integration with platforms/graphics api (used by Examples + should be used by your app). 4 | Examples = Standalone applications showcasing integration with platforms/graphics api. 5 | 6 | Once Dear ImGui is running (in either examples or your own application/game/engine), 7 | run and refer to ImGui::ShowDemoWindow() in imgui_demo.cpp for the end-user API. 8 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_allegro5/README.md: -------------------------------------------------------------------------------- 1 | 2 | # Configuration 3 | 4 | Dear ImGui outputs 16-bit vertex indices by default. 5 | Allegro doesn't support them natively, so we have two solutions: convert the indices manually in imgui_impl_allegro5.cpp, or compile dear imgui with 32-bit indices. 6 | You can either modify imconfig.h that comes with Dear ImGui (easier), or set a C++ preprocessor option IMGUI_USER_CONFIG to find to a filename. 7 | We are providing `imconfig_allegro5.h` that enables 32-bit indices. 8 | Note that the backend supports _BOTH_ 16-bit and 32-bit indices, but 32-bit indices will be slightly faster as they won't require a manual conversion. 9 | 10 | # How to Build 11 | 12 | ### On Ubuntu 14.04+ and macOS 13 | 14 | ```bash 15 | g++ -DIMGUI_USER_CONFIG=\"examples/example_allegro5/imconfig_allegro5.h\" -I .. -I ../.. main.cpp ../../backends/imgui_impl_allegro5.cpp ../../imgui*.cpp -lallegro -lallegro_main -lallegro_primitives -o allegro5_example 16 | ``` 17 | 18 | On macOS, install Allegro with homebrew: `brew install allegro`. 19 | 20 | ### On Windows with Visual Studio's CLI 21 | 22 | You may install Allegro using vcpkg: 23 | ``` 24 | git clone https://github.com/Microsoft/vcpkg 25 | cd vcpkg 26 | .\bootstrap-vcpkg.bat 27 | .\vcpkg install allegro5 28 | .\vcpkg integrate install ; optional, automatically register include/libs in Visual Studio 29 | ``` 30 | 31 | Build: 32 | ``` 33 | set ALLEGRODIR=path_to_your_allegro5_folder 34 | cl /Zi /MD /I %ALLEGRODIR%\include /DIMGUI_USER_CONFIG=\"examples/example_allegro5/imconfig_allegro5.h\" /I .. /I ..\.. main.cpp ..\..\backends\imgui_impl_allegro5.cpp ..\..\imgui*.cpp /link /LIBPATH:%ALLEGRODIR%\lib allegro-5.0.10-monolith-md.lib user32.lib 35 | ``` 36 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_allegro5/example_allegro5.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {20b90ce4-7fcb-4731-b9a0-075f875de82d} 6 | 7 | 8 | {f18ab499-84e1-499f-8eff-9754361e0e52} 9 | cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx 10 | 11 | 12 | 13 | 14 | imgui 15 | 16 | 17 | imgui 18 | 19 | 20 | imgui 21 | 22 | 23 | sources 24 | 25 | 26 | sources 27 | 28 | 29 | sources 30 | 31 | 32 | imgui 33 | 34 | 35 | imgui 36 | 37 | 38 | 39 | 40 | imgui 41 | 42 | 43 | imgui 44 | 45 | 46 | imgui 47 | 48 | 49 | sources 50 | 51 | 52 | 53 | 54 | 55 | sources 56 | 57 | 58 | 59 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_allegro5/imconfig_allegro5.h: -------------------------------------------------------------------------------- 1 | //----------------------------------------------------------------------------- 2 | // COMPILE-TIME OPTIONS FOR DEAR IMGUI ALLEGRO 5 EXAMPLE 3 | // See imconfig.h for the full template 4 | // Because Allegro doesn't support 16-bit vertex indices, we enable the compile-time option of imgui to use 32-bit indices 5 | //----------------------------------------------------------------------------- 6 | 7 | #pragma once 8 | 9 | // Use 32-bit vertex indices because Allegro doesn't support 16-bit ones 10 | // This allows us to avoid converting vertices format at runtime 11 | #define ImDrawIdx int 12 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_android_opengl3/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.6) 2 | 3 | project(ImGuiExample) 4 | 5 | set(CMAKE_CXX_STANDARD 11) 6 | set(CMAKE_CXX_STANDARD_REQUIRED ON) 7 | set(CMAKE_CXX_EXTENSIONS OFF) 8 | 9 | add_library(${CMAKE_PROJECT_NAME} SHARED 10 | ${CMAKE_CURRENT_SOURCE_DIR}/main.cpp 11 | ${CMAKE_CURRENT_SOURCE_DIR}/../../imgui.cpp 12 | ${CMAKE_CURRENT_SOURCE_DIR}/../../imgui_demo.cpp 13 | ${CMAKE_CURRENT_SOURCE_DIR}/../../imgui_draw.cpp 14 | ${CMAKE_CURRENT_SOURCE_DIR}/../../imgui_tables.cpp 15 | ${CMAKE_CURRENT_SOURCE_DIR}/../../imgui_widgets.cpp 16 | ${CMAKE_CURRENT_SOURCE_DIR}/../../backends/imgui_impl_android.cpp 17 | ${CMAKE_CURRENT_SOURCE_DIR}/../../backends/imgui_impl_opengl3.cpp 18 | ${ANDROID_NDK}/sources/android/native_app_glue/android_native_app_glue.c 19 | ) 20 | 21 | set(CMAKE_SHARED_LINKER_FLAGS 22 | "${CMAKE_SHARED_LINKER_FLAGS} -u ANativeActivity_onCreate" 23 | ) 24 | 25 | target_compile_definitions(${CMAKE_PROJECT_NAME} PRIVATE 26 | IMGUI_IMPL_OPENGL_ES3 27 | ) 28 | 29 | target_include_directories(${CMAKE_PROJECT_NAME} PRIVATE 30 | ${CMAKE_CURRENT_SOURCE_DIR}/../.. 31 | ${CMAKE_CURRENT_SOURCE_DIR}/../../backends 32 | ${ANDROID_NDK}/sources/android/native_app_glue 33 | ) 34 | 35 | target_link_libraries(${CMAKE_PROJECT_NAME} PRIVATE 36 | android 37 | EGL 38 | GLESv3 39 | log 40 | ) 41 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_android_opengl3/android/.gitignore: -------------------------------------------------------------------------------- 1 | .cxx 2 | .externalNativeBuild 3 | build/ 4 | *.iml 5 | 6 | .idea 7 | .gradle 8 | local.properties 9 | 10 | # Android Studio puts a Gradle wrapper here, that we don't want: 11 | gradle/ 12 | gradlew* 13 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_android_opengl3/android/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | apply plugin: 'kotlin-android' 3 | 4 | android { 5 | compileSdkVersion 29 6 | buildToolsVersion "30.0.3" 7 | ndkVersion "21.4.7075529" 8 | defaultConfig { 9 | applicationId "imgui.example.android" 10 | minSdkVersion 23 11 | targetSdkVersion 29 12 | versionCode 1 13 | versionName "1.0" 14 | } 15 | 16 | buildTypes { 17 | release { 18 | minifyEnabled false 19 | proguardFiles getDefaultProguardFile('proguard-android-optimize.txt') 20 | } 21 | } 22 | 23 | externalNativeBuild { 24 | cmake { 25 | path "../../CMakeLists.txt" 26 | } 27 | } 28 | } 29 | repositories { 30 | mavenCentral() 31 | } 32 | dependencies { 33 | implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" 34 | } 35 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_android_opengl3/android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 10 | 11 | 15 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_android_opengl3/android/app/src/main/java/MainActivity.kt: -------------------------------------------------------------------------------- 1 | package imgui.example.android 2 | 3 | import android.app.NativeActivity 4 | import android.os.Bundle 5 | import android.content.Context 6 | import android.view.inputmethod.InputMethodManager 7 | import android.view.KeyEvent 8 | import java.util.concurrent.LinkedBlockingQueue 9 | 10 | class MainActivity : NativeActivity() { 11 | public override fun onCreate(savedInstanceState: Bundle?) { 12 | super.onCreate(savedInstanceState) 13 | } 14 | 15 | fun showSoftInput() { 16 | val inputMethodManager = getSystemService(Context.INPUT_METHOD_SERVICE) as InputMethodManager 17 | inputMethodManager.showSoftInput(this.window.decorView, 0) 18 | } 19 | 20 | fun hideSoftInput() { 21 | val inputMethodManager = getSystemService(Context.INPUT_METHOD_SERVICE) as InputMethodManager 22 | inputMethodManager.hideSoftInputFromWindow(this.window.decorView.windowToken, 0) 23 | } 24 | 25 | // Queue for the Unicode characters to be polled from native code (via pollUnicodeChar()) 26 | private var unicodeCharacterQueue: LinkedBlockingQueue = LinkedBlockingQueue() 27 | 28 | // We assume dispatchKeyEvent() of the NativeActivity is actually called for every 29 | // KeyEvent and not consumed by any View before it reaches here 30 | override fun dispatchKeyEvent(event: KeyEvent): Boolean { 31 | if (event.action == KeyEvent.ACTION_DOWN) { 32 | unicodeCharacterQueue.offer(event.getUnicodeChar(event.metaState)) 33 | } 34 | return super.dispatchKeyEvent(event) 35 | } 36 | 37 | fun pollUnicodeChar(): Int { 38 | return unicodeCharacterQueue.poll() ?: 0 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_android_opengl3/android/build.gradle: -------------------------------------------------------------------------------- 1 | buildscript { 2 | ext.kotlin_version = '1.4.31' 3 | repositories { 4 | google() 5 | mavenCentral() 6 | 7 | } 8 | dependencies { 9 | classpath 'com.android.tools.build:gradle:4.1.0' 10 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" 11 | 12 | } 13 | } 14 | 15 | allprojects { 16 | repositories { 17 | google() 18 | mavenCentral() 19 | } 20 | } 21 | 22 | task clean(type: Delete) { 23 | delete rootProject.buildDir 24 | } 25 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_android_opengl3/android/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_apple_metal/README.md: -------------------------------------------------------------------------------- 1 | # iOS / OSX Metal example 2 | 3 | ## Introduction 4 | 5 | This example shows how to integrate Dear ImGui with Metal. It is based on the "cross-platform" game template provided with Xcode as of Xcode 9. 6 | 7 | Consider basing your work off the example_glfw_metal/ or example_sdl_metal/ examples. They are better supported and will be portable unlike this one. 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_apple_metal/iOS/Info-iOS.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | imgui 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1 21 | LSRequiresIPhoneOS 22 | 23 | UILaunchStoryboardName 24 | LaunchScreen 25 | UIRequiredDeviceCapabilities 26 | 27 | armv7 28 | metal 29 | 30 | UIRequiresFullScreen 31 | 32 | UIStatusBarHidden 33 | 34 | UISupportedInterfaceOrientations 35 | 36 | UIInterfaceOrientationPortrait 37 | UIInterfaceOrientationLandscapeLeft 38 | UIInterfaceOrientationLandscapeRight 39 | UIInterfaceOrientationPortraitUpsideDown 40 | 41 | UISupportedInterfaceOrientations~ipad 42 | 43 | UIInterfaceOrientationPortrait 44 | UIInterfaceOrientationPortraitUpsideDown 45 | UIInterfaceOrientationLandscapeLeft 46 | UIInterfaceOrientationLandscapeRight 47 | 48 | 49 | 50 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_apple_metal/iOS/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 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 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_apple_metal/macOS/Info-macOS.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIconFile 10 | 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | imgui 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | 1.0 21 | CFBundleVersion 22 | 1 23 | LSMinimumSystemVersion 24 | $(MACOSX_DEPLOYMENT_TARGET) 25 | NSMainStoryboardFile 26 | MainMenu 27 | NSPrincipalClass 28 | NSApplication 29 | 30 | 31 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_emscripten_opengl3/README.md: -------------------------------------------------------------------------------- 1 | ## How to Build 2 | 3 | - You need to install Emscripten from https://emscripten.org/docs/getting_started/downloads.html, and have the environment variables set, as described in https://emscripten.org/docs/getting_started/downloads.html#installation-instructions 4 | - You may also refer to our [Continuous Integration setup](https://github.com/ocornut/imgui/tree/master/.github/workflows) for Emscripten setup. 5 | - Depending on your configuration, in Windows you may need to run `emsdk/emsdk_env.bat` in your console to access the Emscripten command-line tools. 6 | - Then build using `make` while in the `example_emscripten_opengl3/` directory. 7 | 8 | ## How to Run 9 | 10 | To run on a local machine: 11 | - `make serve` will use Python3 to spawn a local webserver, you can then browse http://localhost:8000 to access your build. 12 | - Otherwise, generally you will need a local webserver: 13 | - Quoting [https://emscripten.org/docs/getting_started](https://emscripten.org/docs/getting_started/Tutorial.html#generating-html):
14 | _"Unfortunately several browsers (including Chrome, Safari, and Internet Explorer) do not support file:// [XHR](https://emscripten.org/docs/site/glossary.html#term-xhr) requests, and can’t load extra files needed by the HTML (like a .wasm file, or packaged file data as mentioned lower down). For these browsers you’ll need to serve the files using a [local webserver](https://emscripten.org/docs/getting_started/FAQ.html#faq-local-webserver) and then open http://localhost:8000/hello.html."_ 15 | - Emscripten SDK has a handy `emrun` command: `emrun web/example_emscripten_opengl3.html --browser firefox` which will spawn a temporary local webserver (in Firefox). See https://emscripten.org/docs/compiling/Running-html-files-with-emrun.html for details. 16 | - You may use Python 3 builtin webserver: `python -m http.server -d web` (this is what `make serve` uses). 17 | - You may use Python 2 builtin webserver: `cd web && python -m SimpleHTTPServer`. 18 | 19 | ## Obsolete features: 20 | 21 | - Emscripten 2.0 (August 2020) obsoleted the fastcomp backend, only llvm is supported. 22 | - Emscripten 1.39.0 (October 2019) obsoleted the `BINARYEN_TRAP_MODE=clamp` compilation flag which was required with version older than 1.39.0 to avoid rendering artefacts. See [#2877](https://github.com/ocornut/imgui/issues/2877) for details. If you use an older version, uncomment this line in the Makefile: `#EMS += -s BINARYEN_TRAP_MODE=clamp` 23 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_emscripten_opengl3/shell_minimal.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Dear ImGui Emscripten example 7 | 29 | 30 | 31 | 32 | 62 | {{{ SCRIPT }}} 63 | 64 | 65 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_emscripten_wgpu/README.md: -------------------------------------------------------------------------------- 1 | 2 | # How to Build 3 | 4 | - You need to install Emscripten from https://emscripten.org/docs/getting_started/downloads.html, and have the environment variables set, as described in https://emscripten.org/docs/getting_started/downloads.html#installation-instructions 5 | 6 | - Depending on your configuration, in Windows you may need to run `emsdk/emsdk_env.bat` in your console to access the Emscripten command-line tools. 7 | 8 | - Then build using `make` while in the `example_emscripten_wgpu/` directory. 9 | 10 | - Requires Emscripten 2.0.10 (December 2020) due to GLFW adaptations 11 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_glfw_metal/Makefile: -------------------------------------------------------------------------------- 1 | # 2 | # You will need GLFW (http://www.glfw.org): 3 | # brew install glfw 4 | # 5 | 6 | #CXX = g++ 7 | #CXX = clang++ 8 | 9 | EXE = example_glfw_metal 10 | IMGUI_DIR = ../.. 11 | SOURCES = main.mm 12 | SOURCES += $(IMGUI_DIR)/imgui.cpp $(IMGUI_DIR)/imgui_demo.cpp $(IMGUI_DIR)/imgui_draw.cpp $(IMGUI_DIR)/imgui_tables.cpp $(IMGUI_DIR)/imgui_widgets.cpp 13 | SOURCES += $(IMGUI_DIR)/backends/imgui_impl_glfw.cpp $(IMGUI_DIR)/backends/imgui_impl_metal.mm 14 | OBJS = $(addsuffix .o, $(basename $(notdir $(SOURCES)))) 15 | 16 | LIBS = -framework Metal -framework MetalKit -framework Cocoa -framework IOKit -framework CoreVideo -framework QuartzCore 17 | LIBS += -L/usr/local/lib -L/opt/homebrew/lib 18 | LIBS += -lglfw 19 | 20 | CXXFLAGS = -I$(IMGUI_DIR) -I$(IMGUI_DIR)/backends -I/usr/local/include -I/opt/homebrew/include 21 | CXXFLAGS += -Wall -Wformat 22 | CFLAGS = $(CXXFLAGS) 23 | 24 | %.o:%.cpp 25 | $(CXX) $(CXXFLAGS) -c -o $@ $< 26 | 27 | %.o:$(IMGUI_DIR)/%.cpp 28 | $(CXX) $(CXXFLAGS) -c -o $@ $< 29 | 30 | %.o:$(IMGUI_DIR)/backends/%.cpp 31 | $(CXX) $(CXXFLAGS) -c -o $@ $< 32 | 33 | %.o:%.mm 34 | $(CXX) $(CXXFLAGS) -ObjC++ -fobjc-weak -fobjc-arc -c -o $@ $< 35 | 36 | %.o:$(IMGUI_DIR)/backends/%.mm 37 | $(CXX) $(CXXFLAGS) -ObjC++ -fobjc-weak -fobjc-arc -c -o $@ $< 38 | 39 | all: $(EXE) 40 | @echo Build complete 41 | 42 | $(EXE): $(OBJS) 43 | $(CXX) -o $@ $^ $(CXXFLAGS) $(LIBS) 44 | 45 | clean: 46 | rm -f $(EXE) $(OBJS) 47 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_glfw_opengl2/Makefile: -------------------------------------------------------------------------------- 1 | # 2 | # Cross Platform Makefile 3 | # Compatible with MSYS2/MINGW, Ubuntu 14.04.1 and Mac OS X 4 | # 5 | # You will need GLFW (http://www.glfw.org): 6 | # Linux: 7 | # apt-get install libglfw-dev 8 | # Mac OS X: 9 | # brew install glfw 10 | # MSYS2: 11 | # pacman -S --noconfirm --needed mingw-w64-x86_64-toolchain mingw-w64-x86_64-glfw 12 | # 13 | 14 | #CXX = g++ 15 | #CXX = clang++ 16 | 17 | EXE = example_glfw_opengl2 18 | IMGUI_DIR = ../.. 19 | SOURCES = main.cpp 20 | SOURCES += $(IMGUI_DIR)/imgui.cpp $(IMGUI_DIR)/imgui_demo.cpp $(IMGUI_DIR)/imgui_draw.cpp $(IMGUI_DIR)/imgui_tables.cpp $(IMGUI_DIR)/imgui_widgets.cpp 21 | SOURCES += $(IMGUI_DIR)/backends/imgui_impl_glfw.cpp $(IMGUI_DIR)/backends/imgui_impl_opengl2.cpp 22 | OBJS = $(addsuffix .o, $(basename $(notdir $(SOURCES)))) 23 | UNAME_S := $(shell uname -s) 24 | 25 | CXXFLAGS = -I$(IMGUI_DIR) -I$(IMGUI_DIR)/backends 26 | CXXFLAGS += -g -Wall -Wformat 27 | LIBS = 28 | 29 | ##--------------------------------------------------------------------- 30 | ## BUILD FLAGS PER PLATFORM 31 | ##--------------------------------------------------------------------- 32 | 33 | ifeq ($(UNAME_S), Linux) #LINUX 34 | ECHO_MESSAGE = "Linux" 35 | LIBS += -lGL `pkg-config --static --libs glfw3` 36 | 37 | CXXFLAGS += `pkg-config --cflags glfw3` 38 | CFLAGS = $(CXXFLAGS) 39 | endif 40 | 41 | ifeq ($(UNAME_S), Darwin) #APPLE 42 | ECHO_MESSAGE = "Mac OS X" 43 | LIBS += -framework OpenGL -framework Cocoa -framework IOKit -framework CoreVideo 44 | LIBS += -L/usr/local/lib -L/opt/local/lib -L/opt/homebrew/lib 45 | #LIBS += -lglfw3 46 | LIBS += -lglfw 47 | 48 | CXXFLAGS += -I/usr/local/include -I/opt/local/include -I/opt/homebrew/include 49 | CFLAGS = $(CXXFLAGS) 50 | endif 51 | 52 | ifeq ($(OS), Windows_NT) 53 | ECHO_MESSAGE = "MinGW" 54 | LIBS += -lglfw3 -lgdi32 -lopengl32 -limm32 55 | 56 | CXXFLAGS += `pkg-config --cflags glfw3` 57 | CFLAGS = $(CXXFLAGS) 58 | endif 59 | 60 | ##--------------------------------------------------------------------- 61 | ## BUILD RULES 62 | ##--------------------------------------------------------------------- 63 | 64 | %.o:%.cpp 65 | $(CXX) $(CXXFLAGS) -c -o $@ $< 66 | 67 | %.o:$(IMGUI_DIR)/%.cpp 68 | $(CXX) $(CXXFLAGS) -c -o $@ $< 69 | 70 | %.o:$(IMGUI_DIR)/backends/%.cpp 71 | $(CXX) $(CXXFLAGS) -c -o $@ $< 72 | 73 | all: $(EXE) 74 | @echo Build complete for $(ECHO_MESSAGE) 75 | 76 | $(EXE): $(OBJS) 77 | $(CXX) -o $@ $^ $(CXXFLAGS) $(LIBS) 78 | 79 | clean: 80 | rm -f $(EXE) $(OBJS) 81 | 82 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_glfw_opengl2/build_win32.bat: -------------------------------------------------------------------------------- 1 | @REM Build for Visual Studio compiler. Run your copy of vcvars32.bat or vcvarsall.bat to setup command-line compiler. 2 | @set OUT_DIR=Debug 3 | @set OUT_EXE=example_glfw_opengl2 4 | @set INCLUDES=/I..\.. /I..\..\backends /I..\libs\glfw\include 5 | @set SOURCES=main.cpp ..\..\backends\imgui_impl_opengl2.cpp ..\..\backends\imgui_impl_glfw.cpp ..\..\imgui*.cpp 6 | @set LIBS=/LIBPATH:..\libs\glfw\lib-vc2010-32 glfw3.lib opengl32.lib gdi32.lib shell32.lib 7 | mkdir %OUT_DIR% 8 | cl /nologo /Zi /MD %INCLUDES% %SOURCES% /Fe%OUT_DIR%/%OUT_EXE%.exe /Fo%OUT_DIR%/ /link %LIBS% 9 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_glfw_opengl2/example_glfw_opengl2.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {c336cfe3-f0c4-464c-9ef0-a9e17a7ff222} 6 | 7 | 8 | {4FC737F1-C7A5-4376-A066-2A32D752A2FF} 9 | cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx 10 | 11 | 12 | 13 | 14 | sources 15 | 16 | 17 | imgui 18 | 19 | 20 | imgui 21 | 22 | 23 | imgui 24 | 25 | 26 | imgui 27 | 28 | 29 | imgui 30 | 31 | 32 | sources 33 | 34 | 35 | sources 36 | 37 | 38 | 39 | 40 | imgui 41 | 42 | 43 | imgui 44 | 45 | 46 | imgui 47 | 48 | 49 | sources 50 | 51 | 52 | sources 53 | 54 | 55 | 56 | 57 | 58 | sources 59 | 60 | 61 | 62 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_glfw_opengl3/build_win32.bat: -------------------------------------------------------------------------------- 1 | @REM Build for Visual Studio compiler. Run your copy of vcvars32.bat or vcvarsall.bat to setup command-line compiler. 2 | @set OUT_DIR=Debug 3 | @set OUT_EXE=example_glfw_opengl3 4 | @set INCLUDES=/I..\.. /I..\..\backends /I..\libs\glfw\include /I..\libs\gl3w 5 | @set SOURCES=main.cpp ..\..\backends\imgui_impl_glfw.cpp ..\..\backends\imgui_impl_opengl3.cpp ..\..\imgui*.cpp ..\libs\gl3w\GL\gl3w.c 6 | @set LIBS=/LIBPATH:..\libs\glfw\lib-vc2010-32 glfw3.lib opengl32.lib gdi32.lib shell32.lib 7 | mkdir %OUT_DIR% 8 | cl /nologo /Zi /MD %INCLUDES% %SOURCES% /Fe%OUT_DIR%/%OUT_EXE%.exe /Fo%OUT_DIR%/ /link %LIBS% 9 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_glfw_vulkan/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Example usage: 2 | # mkdir build 3 | # cd build 4 | # cmake -g "Visual Studio 14 2015" .. 5 | 6 | cmake_minimum_required(VERSION 2.8) 7 | project(imgui_example_glfw_vulkan C CXX) 8 | 9 | if(NOT CMAKE_BUILD_TYPE) 10 | set(CMAKE_BUILD_TYPE Debug CACHE STRING "" FORCE) 11 | endif() 12 | 13 | set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DVK_PROTOTYPES") 14 | set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DVK_PROTOTYPES") 15 | 16 | # GLFW 17 | set(GLFW_DIR ../../../glfw) # Set this to point to an up-to-date GLFW repo 18 | option(GLFW_BUILD_EXAMPLES "Build the GLFW example programs" OFF) 19 | option(GLFW_BUILD_TESTS "Build the GLFW test programs" OFF) 20 | option(GLFW_BUILD_DOCS "Build the GLFW documentation" OFF) 21 | option(GLFW_INSTALL "Generate installation target" OFF) 22 | option(GLFW_DOCUMENT_INTERNALS "Include internals in documentation" OFF) 23 | add_subdirectory(${GLFW_DIR} binary_dir EXCLUDE_FROM_ALL) 24 | include_directories(${GLFW_DIR}/include) 25 | 26 | # Dear ImGui 27 | set(IMGUI_DIR ../../) 28 | include_directories(${IMGUI_DIR} ${IMGUI_DIR}/backends ..) 29 | 30 | # Libraries 31 | find_package(Vulkan REQUIRED) 32 | #find_library(VULKAN_LIBRARY 33 | #NAMES vulkan vulkan-1) 34 | #set(LIBRARIES "glfw;${VULKAN_LIBRARY}") 35 | set(LIBRARIES "glfw;Vulkan::Vulkan") 36 | 37 | # Use vulkan headers from glfw: 38 | include_directories(${GLFW_DIR}/deps) 39 | 40 | file(GLOB sources *.cpp) 41 | 42 | add_executable(example_glfw_vulkan ${sources} ${IMGUI_DIR}/backends/imgui_impl_glfw.cpp ${IMGUI_DIR}/backends/imgui_impl_vulkan.cpp ${IMGUI_DIR}/imgui.cpp ${IMGUI_DIR}/imgui_draw.cpp ${IMGUI_DIR}/imgui_demo.cpp ${IMGUI_DIR}/imgui_tables.cpp ${IMGUI_DIR}/imgui_widgets.cpp) 43 | target_link_libraries(example_glfw_vulkan ${LIBRARIES}) 44 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_glfw_vulkan/build_win32.bat: -------------------------------------------------------------------------------- 1 | @REM Build for Visual Studio compiler. Run your copy of vcvars32.bat or vcvarsall.bat to setup command-line compiler. 2 | 3 | @set OUT_EXE=example_glfw_vulkan 4 | @set INCLUDES=/I..\.. /I..\..\backends /I..\libs\glfw\include /I %VULKAN_SDK%\include 5 | @set SOURCES=main.cpp ..\..\backends\imgui_impl_vulkan.cpp ..\..\backends\imgui_impl_glfw.cpp ..\..\imgui*.cpp 6 | @set LIBS=/LIBPATH:..\libs\glfw\lib-vc2010-32 /libpath:%VULKAN_SDK%\lib32 glfw3.lib opengl32.lib gdi32.lib shell32.lib vulkan-1.lib 7 | 8 | @set OUT_DIR=Debug 9 | mkdir %OUT_DIR% 10 | cl /nologo /Zi /MD %INCLUDES% %SOURCES% /Fe%OUT_DIR%/%OUT_EXE%.exe /Fo%OUT_DIR%/ /link %LIBS% 11 | 12 | @set OUT_DIR=Release 13 | mkdir %OUT_DIR% 14 | cl /nologo /Zi /MD /Ox /Oi %INCLUDES% %SOURCES% /Fe%OUT_DIR%/%OUT_EXE%.exe /Fo%OUT_DIR%/ /link %LIBS% 15 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_glfw_vulkan/build_win64.bat: -------------------------------------------------------------------------------- 1 | @REM Build for Visual Studio compiler. Run your copy of amd64/vcvars32.bat to setup 64-bit command-line compiler. 2 | 3 | @set INCLUDES=/I..\.. /I..\..\backends /I..\libs\glfw\include /I %VULKAN_SDK%\include 4 | @set SOURCES=main.cpp ..\..\backends\imgui_impl_vulkan.cpp ..\..\backends\imgui_impl_glfw.cpp ..\..\imgui*.cpp 5 | @set LIBS=/LIBPATH:..\libs\glfw\lib-vc2010-64 /libpath:%VULKAN_SDK%\lib glfw3.lib opengl32.lib gdi32.lib shell32.lib vulkan-1.lib 6 | 7 | @set OUT_DIR=Debug 8 | mkdir %OUT_DIR% 9 | cl /nologo /Zi /MD %INCLUDES% %SOURCES% /Fe%OUT_DIR%/%OUT_EXE%.exe /Fo%OUT_DIR%/ /link %LIBS% 10 | 11 | @set OUT_DIR=Release 12 | mkdir %OUT_DIR% 13 | cl /nologo /Zi /MD /Ox /Oi %INCLUDES% %SOURCES% /Fe%OUT_DIR%/%OUT_EXE%.exe /Fo%OUT_DIR%/ /link %LIBS% 14 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_glfw_vulkan/example_glfw_vulkan.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {20b90ce4-7fcb-4731-b9a0-075f875de82d} 6 | 7 | 8 | {f18ab499-84e1-499f-8eff-9754361e0e52} 9 | cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx 10 | 11 | 12 | 13 | 14 | sources 15 | 16 | 17 | imgui 18 | 19 | 20 | imgui 21 | 22 | 23 | imgui 24 | 25 | 26 | imgui 27 | 28 | 29 | imgui 30 | 31 | 32 | sources 33 | 34 | 35 | sources 36 | 37 | 38 | 39 | 40 | imgui 41 | 42 | 43 | imgui 44 | 45 | 46 | imgui 47 | 48 | 49 | sources 50 | 51 | 52 | sources 53 | 54 | 55 | 56 | 57 | 58 | sources 59 | 60 | 61 | 62 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_glut_opengl2/Makefile: -------------------------------------------------------------------------------- 1 | # 2 | # Cross Platform Makefile 3 | # Compatible with MSYS2/MINGW, Ubuntu 14.04.1 and Mac OS X 4 | # 5 | # Linux: 6 | # apt-get install freeglut3-dev 7 | # 8 | 9 | #CXX = g++ 10 | #CXX = clang++ 11 | 12 | EXE = example_glut_opengl2 13 | IMGUI_DIR = ../.. 14 | SOURCES = main.cpp 15 | SOURCES += $(IMGUI_DIR)/imgui.cpp $(IMGUI_DIR)/imgui_demo.cpp $(IMGUI_DIR)/imgui_draw.cpp $(IMGUI_DIR)/imgui_tables.cpp $(IMGUI_DIR)/imgui_widgets.cpp 16 | SOURCES += $(IMGUI_DIR)/backends/imgui_impl_glut.cpp $(IMGUI_DIR)/backends/imgui_impl_opengl2.cpp 17 | OBJS = $(addsuffix .o, $(basename $(notdir $(SOURCES)))) 18 | UNAME_S := $(shell uname -s) 19 | 20 | CXXFLAGS = -I$(IMGUI_DIR) -I$(IMGUI_DIR)/backends 21 | CXXFLAGS += -g -Wall -Wformat 22 | LIBS = 23 | 24 | ##--------------------------------------------------------------------- 25 | ## BUILD FLAGS PER PLATFORM 26 | ##--------------------------------------------------------------------- 27 | 28 | ifeq ($(UNAME_S), Linux) #LINUX 29 | ECHO_MESSAGE = "Linux" 30 | LIBS += -lGL -lglut 31 | CFLAGS = $(CXXFLAGS) 32 | endif 33 | 34 | ifeq ($(UNAME_S), Darwin) #APPLE 35 | ECHO_MESSAGE = "Mac OS X" 36 | LIBS += -framework OpenGL -framework GLUT 37 | LIBS += -L/usr/local/lib -L/opt/local/lib 38 | 39 | CXXFLAGS += -I/usr/local/include -I/opt/local/include 40 | CFLAGS = $(CXXFLAGS) 41 | endif 42 | 43 | ifeq ($(OS), Windows_NT) 44 | ECHO_MESSAGE = "MinGW" 45 | LIBS += -lgdi32 -lopengl32 -limm32 46 | ifeq ($(shell pkg-config freeglut --exists 2> /dev/null && echo yes || echo no),yes) 47 | CXXFLAGS += $(shell pkg-config freeglut --cflags) 48 | LIBS += $(shell pkg-config freeglut --libs) 49 | else 50 | LIBS += -lglut 51 | endif 52 | CFLAGS = $(CXXFLAGS) 53 | endif 54 | 55 | ##--------------------------------------------------------------------- 56 | ## BUILD RULES 57 | ##--------------------------------------------------------------------- 58 | 59 | %.o:%.cpp 60 | $(CXX) $(CXXFLAGS) -c -o $@ $< 61 | 62 | %.o:$(IMGUI_DIR)/%.cpp 63 | $(CXX) $(CXXFLAGS) -c -o $@ $< 64 | 65 | %.o:$(IMGUI_DIR)/backends/%.cpp 66 | $(CXX) $(CXXFLAGS) -c -o $@ $< 67 | 68 | all: $(EXE) 69 | @echo Build complete for $(ECHO_MESSAGE) 70 | 71 | $(EXE): $(OBJS) 72 | $(CXX) -o $@ $^ $(CXXFLAGS) $(LIBS) 73 | 74 | clean: 75 | rm -f $(EXE) $(OBJS) 76 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_glut_opengl2/example_glut_opengl2.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {c336cfe3-f0c4-464c-9ef0-a9e17a7ff222} 6 | 7 | 8 | {4FC737F1-C7A5-4376-A066-2A32D752A2FF} 9 | cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx 10 | 11 | 12 | 13 | 14 | sources 15 | 16 | 17 | imgui 18 | 19 | 20 | imgui 21 | 22 | 23 | imgui 24 | 25 | 26 | imgui 27 | 28 | 29 | imgui 30 | 31 | 32 | sources 33 | 34 | 35 | sources 36 | 37 | 38 | 39 | 40 | imgui 41 | 42 | 43 | imgui 44 | 45 | 46 | imgui 47 | 48 | 49 | sources 50 | 51 | 52 | sources 53 | 54 | 55 | 56 | 57 | 58 | sources 59 | 60 | 61 | 62 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_marmalade/data/app.icf: -------------------------------------------------------------------------------- 1 | # This file is for configuration settings for your 2 | # application. 3 | # 4 | # The syntax is similar to windows .ini files ie 5 | # 6 | # [GroupName] 7 | # Setting = Value 8 | # 9 | # Which can be read by your application using 10 | # e.g s3eConfigGetString("GroupName", "Setting", string) 11 | # 12 | # All settings must be documented in .config.txt files. 13 | # New settings specific to this application should be 14 | # documented in app.config.txt 15 | # 16 | # Some conditional operations are also permitted, see the 17 | # S3E documentation for details. 18 | 19 | [S3E] 20 | MemSize=6000000 21 | MemSizeDebug=6000000 22 | DispFixRot=FixedLandscape 23 | 24 | # emulate iphone 5 resolution, change these settings to emulate other display resolution 25 | WinWidth=1136 26 | WinHeight=640 27 | 28 | [GX] 29 | DataCacheSize=131070 30 | 31 | [Util] 32 | #MemoryBreakpoint=1282 33 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_marmalade/marmalade_example.mkb: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env mkb 2 | 3 | # ImGui - standalone example application for Marmalade 4 | # Copyright (C) 2015 by Giovanni Zito 5 | # This file is part of ImGui 6 | # https://github.com/ocornut/imgui 7 | 8 | define IMGUI_DISABLE_INCLUDE_IMCONFIG_H 9 | define IMGUI_DISABLE_WIN32_DEFAULT_CLIPBOARD_FUNCS 10 | define IMGUI_DISABLE_WIN32_DEFAULT_IME_FUNCS 11 | define _snprintf=snprintf 12 | 13 | options 14 | { 15 | optimise-speed=1 16 | } 17 | 18 | includepaths 19 | { 20 | ../.. 21 | ../../backends 22 | } 23 | 24 | subprojects 25 | { 26 | iwgx 27 | } 28 | 29 | files 30 | { 31 | (.) 32 | ["imgui"] 33 | ../../imgui.cpp 34 | ../../imgui_demo.cpp 35 | ../../imgui_draw.cpp 36 | ../../imgui_tables.cpp 37 | ../../imgui_widgets.cpp 38 | ../../imconfig.h 39 | ../../imgui.h 40 | ../../imgui_internal.h 41 | 42 | ["imgui","Marmalade backend"] 43 | ../../backends/imgui_impl_marmalade.h 44 | ../../backends/imgui_impl_marmalade.cpp 45 | main.cpp 46 | 47 | } 48 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_null/build_win32.bat: -------------------------------------------------------------------------------- 1 | @REM Build for Visual Studio compiler. Run your copy of vcvars32.bat or vcvarsall.bat to setup command-line compiler. 2 | mkdir Debug 3 | cl /nologo /Zi /MD /I ..\.. %* *.cpp ..\..\*.cpp /FeDebug/example_null.exe /FoDebug/ /link gdi32.lib shell32.lib imm32.lib 4 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_null/main.cpp: -------------------------------------------------------------------------------- 1 | // dear imgui: "null" example application 2 | // (compile and link imgui, create context, run headless with NO INPUTS, NO GRAPHICS OUTPUT) 3 | // This is useful to test building, but you cannot interact with anything here! 4 | #include "imgui.h" 5 | #include 6 | 7 | int main(int, char**) 8 | { 9 | IMGUI_CHECKVERSION(); 10 | ImGui::CreateContext(); 11 | ImGuiIO& io = ImGui::GetIO(); 12 | 13 | // Build atlas 14 | unsigned char* tex_pixels = NULL; 15 | int tex_w, tex_h; 16 | io.Fonts->GetTexDataAsRGBA32(&tex_pixels, &tex_w, &tex_h); 17 | 18 | for (int n = 0; n < 20; n++) 19 | { 20 | printf("NewFrame() %d\n", n); 21 | io.DisplaySize = ImVec2(1920, 1080); 22 | io.DeltaTime = 1.0f / 60.0f; 23 | ImGui::NewFrame(); 24 | 25 | static float f = 0.0f; 26 | ImGui::Text("Hello, world!"); 27 | ImGui::SliderFloat("float", &f, 0.0f, 1.0f); 28 | ImGui::Text("Application average %.3f ms/frame (%.1f FPS)", 1000.0f / io.Framerate, io.Framerate); 29 | ImGui::ShowDemoWindow(NULL); 30 | 31 | ImGui::Render(); 32 | } 33 | 34 | printf("DestroyContext()\n"); 35 | ImGui::DestroyContext(); 36 | return 0; 37 | } 38 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_sdl_directx11/build_win32.bat: -------------------------------------------------------------------------------- 1 | @REM Build for Visual Studio compiler. Run your copy of vcvars32.bat or vcvarsall.bat to setup command-line compiler. 2 | @set OUT_DIR=Debug 3 | @set OUT_EXE=example_sdl_directx11 4 | @set INCLUDES=/I..\.. /I..\..\backends /I%SDL2_DIR%\include /I "%WindowsSdkDir%Include\um" /I "%WindowsSdkDir%Include\shared" /I "%DXSDK_DIR%Include" 5 | @set SOURCES=main.cpp ..\..\backends\imgui_impl_sdl.cpp ..\..\backends\imgui_impl_dx11.cpp ..\..\imgui*.cpp 6 | @set LIBS=/LIBPATH:%SDL2_DIR%\lib\x86 SDL2.lib SDL2main.lib /LIBPATH:"%DXSDK_DIR%/Lib/x86" d3d11.lib d3dcompiler.lib shell32.lib 7 | mkdir %OUT_DIR% 8 | cl /nologo /Zi /MD %INCLUDES% %SOURCES% /Fe%OUT_DIR%/%OUT_EXE%.exe /Fo%OUT_DIR%/ /link %LIBS% /subsystem:console 9 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_sdl_directx11/example_sdl_directx11.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {0587d7a3-f2ce-4d56-b84f-a0005d3bfce6} 6 | 7 | 8 | {08e36723-ce4f-4cff-9662-c40801cf1acf} 9 | 10 | 11 | 12 | 13 | imgui 14 | 15 | 16 | imgui 17 | 18 | 19 | imgui 20 | 21 | 22 | sources 23 | 24 | 25 | sources 26 | 27 | 28 | 29 | 30 | imgui 31 | 32 | 33 | sources 34 | 35 | 36 | imgui 37 | 38 | 39 | imgui 40 | 41 | 42 | imgui 43 | 44 | 45 | imgui 46 | 47 | 48 | sources 49 | 50 | 51 | sources 52 | 53 | 54 | 55 | 56 | 57 | sources 58 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_sdl_metal/Makefile: -------------------------------------------------------------------------------- 1 | # 2 | # You will need SDL2 (http://www.libsdl.org): 3 | # brew install sdl2 4 | # 5 | 6 | #CXX = g++ 7 | #CXX = clang++ 8 | 9 | EXE = example_sdl_metal 10 | IMGUI_DIR = ../.. 11 | SOURCES = main.mm 12 | SOURCES += $(IMGUI_DIR)/imgui.cpp $(IMGUI_DIR)/imgui_demo.cpp $(IMGUI_DIR)/imgui_draw.cpp $(IMGUI_DIR)/imgui_tables.cpp $(IMGUI_DIR)/imgui_widgets.cpp 13 | SOURCES += $(IMGUI_DIR)/backends/imgui_impl_sdl.cpp $(IMGUI_DIR)/backends/imgui_impl_metal.mm 14 | OBJS = $(addsuffix .o, $(basename $(notdir $(SOURCES)))) 15 | 16 | LIBS = -framework Metal -framework MetalKit -framework Cocoa -framework IOKit -framework CoreVideo -framework QuartzCore 17 | LIBS += `sdl2-config --libs` 18 | LIBS += -L/usr/local/lib 19 | 20 | CXXFLAGS = -I$(IMGUI_DIR) -I$(IMGUI_DIR)/backends -I/usr/local/include 21 | CXXFLAGS += `sdl2-config --cflags` 22 | CXXFLAGS += -Wall -Wformat 23 | CFLAGS = $(CXXFLAGS) 24 | 25 | %.o:%.cpp 26 | $(CXX) $(CXXFLAGS) -c -o $@ $< 27 | 28 | %.o:$(IMGUI_DIR)/%.cpp 29 | $(CXX) $(CXXFLAGS) -c -o $@ $< 30 | 31 | %.o:$(IMGUI_DIR)/backends/%.cpp 32 | $(CXX) $(CXXFLAGS) -c -o $@ $< 33 | 34 | %.o:%.mm 35 | $(CXX) $(CXXFLAGS) -ObjC++ -fobjc-weak -fobjc-arc -c -o $@ $< 36 | 37 | %.o:$(IMGUI_DIR)/backends/%.mm 38 | $(CXX) $(CXXFLAGS) -ObjC++ -fobjc-weak -fobjc-arc -c -o $@ $< 39 | 40 | all: $(EXE) 41 | @echo Build complete 42 | 43 | $(EXE): $(OBJS) 44 | $(CXX) -o $@ $^ $(CXXFLAGS) $(LIBS) 45 | 46 | clean: 47 | rm -f $(EXE) $(OBJS) 48 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_sdl_opengl2/Makefile: -------------------------------------------------------------------------------- 1 | # 2 | # Cross Platform Makefile 3 | # Compatible with MSYS2/MINGW, Ubuntu 14.04.1 and Mac OS X 4 | # 5 | # You will need SDL2 (http://www.libsdl.org): 6 | # Linux: 7 | # apt-get install libsdl2-dev 8 | # Mac OS X: 9 | # brew install sdl2 10 | # MSYS2: 11 | # pacman -S mingw-w64-i686-SDL2 12 | # 13 | 14 | #CXX = g++ 15 | #CXX = clang++ 16 | 17 | EXE = example_sdl_opengl2 18 | IMGUI_DIR = ../.. 19 | SOURCES = main.cpp 20 | SOURCES += $(IMGUI_DIR)/imgui.cpp $(IMGUI_DIR)/imgui_demo.cpp $(IMGUI_DIR)/imgui_draw.cpp $(IMGUI_DIR)/imgui_tables.cpp $(IMGUI_DIR)/imgui_widgets.cpp 21 | SOURCES += $(IMGUI_DIR)/backends/imgui_impl_sdl.cpp $(IMGUI_DIR)/backends/imgui_impl_opengl2.cpp 22 | OBJS = $(addsuffix .o, $(basename $(notdir $(SOURCES)))) 23 | UNAME_S := $(shell uname -s) 24 | 25 | CXXFLAGS = -I$(IMGUI_DIR) -I$(IMGUI_DIR)/backends 26 | CXXFLAGS += -g -Wall -Wformat 27 | LIBS = 28 | 29 | ##--------------------------------------------------------------------- 30 | ## BUILD FLAGS PER PLATFORM 31 | ##--------------------------------------------------------------------- 32 | 33 | ifeq ($(UNAME_S), Linux) #LINUX 34 | ECHO_MESSAGE = "Linux" 35 | LIBS += -lGL -ldl `sdl2-config --libs` 36 | 37 | CXXFLAGS += `sdl2-config --cflags` 38 | CFLAGS = $(CXXFLAGS) 39 | endif 40 | 41 | ifeq ($(UNAME_S), Darwin) #APPLE 42 | ECHO_MESSAGE = "Mac OS X" 43 | LIBS += -framework OpenGL -framework Cocoa -framework IOKit -framework CoreVideo `sdl2-config --libs` 44 | LIBS += -L/usr/local/lib -L/opt/local/lib 45 | 46 | CXXFLAGS += `sdl2-config --cflags` 47 | CXXFLAGS += -I/usr/local/include -I/opt/local/include 48 | CFLAGS = $(CXXFLAGS) 49 | endif 50 | 51 | ifeq ($(OS), Windows_NT) 52 | ECHO_MESSAGE = "MinGW" 53 | LIBS += -lgdi32 -lopengl32 -limm32 `pkg-config --static --libs sdl2` 54 | 55 | CXXFLAGS += `pkg-config --cflags sdl2` 56 | CFLAGS = $(CXXFLAGS) 57 | endif 58 | 59 | ##--------------------------------------------------------------------- 60 | ## BUILD RULES 61 | ##--------------------------------------------------------------------- 62 | 63 | %.o:%.cpp 64 | $(CXX) $(CXXFLAGS) -c -o $@ $< 65 | 66 | %.o:$(IMGUI_DIR)/%.cpp 67 | $(CXX) $(CXXFLAGS) -c -o $@ $< 68 | 69 | %.o:$(IMGUI_DIR)/backends/%.cpp 70 | $(CXX) $(CXXFLAGS) -c -o $@ $< 71 | 72 | all: $(EXE) 73 | @echo Build complete for $(ECHO_MESSAGE) 74 | 75 | $(EXE): $(OBJS) 76 | $(CXX) -o $@ $^ $(CXXFLAGS) $(LIBS) 77 | 78 | clean: 79 | rm -f $(EXE) $(OBJS) 80 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_sdl_opengl2/README.md: -------------------------------------------------------------------------------- 1 | 2 | # How to Build 3 | 4 | - On Windows with Visual Studio's CLI 5 | 6 | ``` 7 | set SDL2_DIR=path_to_your_sdl2_folder 8 | cl /Zi /MD /I.. /I..\.. /I%SDL2_DIR%\include main.cpp ..\..\backends\imgui_impl_sdl.cpp ..\..\backends\imgui_impl_opengl2.cpp ..\..\imgui*.cpp /FeDebug/example_sdl_opengl2.exe /FoDebug/ /link /libpath:%SDL2_DIR%\lib\x86 SDL2.lib SDL2main.lib opengl32.lib /subsystem:console 9 | # ^^ include paths ^^ source files ^^ output exe ^^ output dir ^^ libraries 10 | # or for 64-bit: 11 | cl /Zi /MD /I.. /I..\.. /I%SDL2_DIR%\include main.cpp ..\..\backends\imgui_impl_sdl.cpp ..\..\backends\imgui_impl_opengl2.cpp ..\..\imgui*.cpp /FeDebug/example_sdl_opengl2.exe /FoDebug/ /link /libpath:%SDL2_DIR%\lib\x64 SDL2.lib SDL2main.lib opengl32.lib /subsystem:console 12 | ``` 13 | 14 | - On Linux and similar Unixes 15 | 16 | ``` 17 | c++ `sdl2-config --cflags` -I .. -I ../.. -I ../../backends main.cpp ../../backends/imgui_impl_sdl.cpp ../../backends/imgui_impl_opengl2.cpp ../../imgui*.cpp `sdl2-config --libs` -lGL 18 | ``` 19 | 20 | - On Mac OS X 21 | 22 | ``` 23 | brew install sdl2 24 | c++ `sdl2-config --cflags` -I .. -I ../.. -I ../../backends main.cpp ../../backends/imgui_impl_sdl.cpp ../../backends/imgui_impl_opengl2.cpp ../../imgui*.cpp `sdl2-config --libs` -framework OpenGl 25 | ``` 26 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_sdl_opengl2/build_win32.bat: -------------------------------------------------------------------------------- 1 | @REM Build for Visual Studio compiler. Run your copy of vcvars32.bat or vcvarsall.bat to setup command-line compiler. 2 | @set OUT_DIR=Debug 3 | @set OUT_EXE=example_sdl_opengl2 4 | @set INCLUDES=/I..\.. /I..\..\backends /I%SDL2_DIR%\include 5 | @set SOURCES=main.cpp ..\..\backends\imgui_impl_sdl.cpp ..\..\backends\imgui_impl_opengl2.cpp ..\..\imgui*.cpp 6 | @set LIBS=/LIBPATH:%SDL2_DIR%\lib\x86 SDL2.lib SDL2main.lib opengl32.lib shell32.lib 7 | mkdir %OUT_DIR% 8 | cl /nologo /Zi /MD %INCLUDES% %SOURCES% /Fe%OUT_DIR%/%OUT_EXE%.exe /Fo%OUT_DIR%/ /link %LIBS% /subsystem:console 9 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_sdl_opengl2/example_sdl_opengl2.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {20b90ce4-7fcb-4731-b9a0-075f875de82d} 6 | 7 | 8 | {f18ab499-84e1-499f-8eff-9754361e0e52} 9 | cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx 10 | 11 | 12 | 13 | 14 | imgui 15 | 16 | 17 | imgui 18 | 19 | 20 | imgui 21 | 22 | 23 | sources 24 | 25 | 26 | imgui 27 | 28 | 29 | imgui 30 | 31 | 32 | sources 33 | 34 | 35 | sources 36 | 37 | 38 | 39 | 40 | imgui 41 | 42 | 43 | imgui 44 | 45 | 46 | imgui 47 | 48 | 49 | sources 50 | 51 | 52 | sources 53 | 54 | 55 | 56 | 57 | 58 | sources 59 | 60 | 61 | 62 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_sdl_opengl3/README.md: -------------------------------------------------------------------------------- 1 | 2 | # How to Build 3 | 4 | - On Windows with Visual Studio's CLI 5 | 6 | ``` 7 | set SDL2_DIR=path_to_your_sdl2_folder 8 | cl /Zi /MD /I.. /I..\.. /I%SDL2_DIR%\include /I..\libs\gl3w main.cpp ..\..\backends\imgui_impl_sdl.cpp ..\..\backends\imgui_impl_opengl3.cpp ..\..\imgui*.cpp ..\libs\gl3w\GL\gl3w.c /FeDebug/example_sdl_opengl3.exe /FoDebug/ /link /libpath:%SDL2_DIR%\lib\x86 SDL2.lib SDL2main.lib opengl32.lib /subsystem:console 9 | # ^^ include paths ^^ source files ^^ output exe ^^ output dir ^^ libraries 10 | # or for 64-bit: 11 | cl /Zi /MD /I.. /I..\.. /I%SDL2_DIR%\include /I..\libs\gl3w main.cpp ..\..\backends\imgui_impl_sdl.cpp ..\..\backends\imgui_impl_opengl3.cpp ..\..\imgui*.cpp ..\libs\gl3w\GL\gl3w.c /FeDebug/example_sdl_opengl3.exe /FoDebug/ /link /libpath:%SDL2_DIR%\lib\x64 SDL2.lib SDL2main.lib opengl32.lib /subsystem:console 12 | ``` 13 | 14 | - On Linux and similar Unixes 15 | 16 | ``` 17 | c++ `sdl2-config --cflags` -I .. -I ../.. -I ../../backends -I ../libs/gl3w main.cpp ../../backends/imgui_impl_sdl.cpp ../../backends/imgui_impl_opengl3.cpp ../../imgui*.cpp ../libs/gl3w/GL/gl3w.c `sdl2-config --libs` -lGL -ldl 18 | ``` 19 | 20 | - On Mac OS X 21 | 22 | ``` 23 | brew install sdl2 24 | c++ `sdl2-config --cflags` -I .. -I ../.. -I ../../backends -I ../libs/gl3w main.cpp ../../backends/imgui_impl_sdl.cpp ../../backends/imgui_impl_opengl3.cpp ../../imgui*.cpp ../libs/gl3w/GL/gl3w.c `sdl2-config --libs` -framework OpenGl -framework CoreFoundation 25 | ``` 26 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_sdl_opengl3/build_win32.bat: -------------------------------------------------------------------------------- 1 | @REM Build for Visual Studio compiler. Run your copy of vcvars32.bat or vcvarsall.bat to setup command-line compiler. 2 | @set OUT_DIR=Debug 3 | @set OUT_EXE=example_sdl_opengl3 4 | @set INCLUDES=/I..\.. /I..\..\backends /I%SDL2_DIR%\include /I..\libs\gl3w 5 | @set SOURCES=main.cpp ..\..\backends\imgui_impl_sdl.cpp ..\..\backends\imgui_impl_opengl3.cpp ..\..\imgui*.cpp ..\libs\gl3w\GL\gl3w.c 6 | @set LIBS=/LIBPATH:%SDL2_DIR%\lib\x86 SDL2.lib SDL2main.lib opengl32.lib shell32.lib 7 | mkdir %OUT_DIR% 8 | cl /nologo /Zi /MD %INCLUDES% %SOURCES% /Fe%OUT_DIR%/%OUT_EXE%.exe /Fo%OUT_DIR%/ /link %LIBS% /subsystem:console 9 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_sdl_vulkan/build_win32.bat: -------------------------------------------------------------------------------- 1 | @REM Build for Visual Studio compiler. Run your copy of vcvars32.bat or vcvarsall.bat to setup command-line compiler. 2 | 3 | @set OUT_EXE=example_sdl_vulkan 4 | @set INCLUDES=/I..\.. /I..\..\backends /I%SDL2_DIR%\include /I %VULKAN_SDK%\include 5 | @set SOURCES=main.cpp ..\..\backends\imgui_impl_sdl.cpp ..\..\backends\imgui_impl_vulkan.cpp ..\..\imgui*.cpp 6 | @set LIBS=/LIBPATH:%SDL2_DIR%\lib\x86 /libpath:%VULKAN_SDK%\lib32 SDL2.lib SDL2main.lib shell32.lib vulkan-1.lib 7 | 8 | @set OUT_DIR=Debug 9 | mkdir %OUT_DIR% 10 | cl /nologo /Zi /MD %INCLUDES% %SOURCES% /Fe%OUT_DIR%/%OUT_EXE%.exe /Fo%OUT_DIR%/ /link %LIBS% /subsystem:console 11 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_sdl_vulkan/example_sdl_vulkan.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {20b90ce4-7fcb-4731-b9a0-075f875de82d} 6 | 7 | 8 | {f18ab499-84e1-499f-8eff-9754361e0e52} 9 | cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx 10 | 11 | 12 | 13 | 14 | imgui 15 | 16 | 17 | imgui 18 | 19 | 20 | imgui 21 | 22 | 23 | sources 24 | 25 | 26 | sources 27 | 28 | 29 | sources 30 | 31 | 32 | imgui 33 | 34 | 35 | 36 | 37 | imgui 38 | 39 | 40 | imgui 41 | 42 | 43 | imgui 44 | 45 | 46 | sources 47 | 48 | 49 | sources 50 | 51 | 52 | 53 | 54 | 55 | sources 56 | 57 | 58 | 59 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_win32_directx10/build_win32.bat: -------------------------------------------------------------------------------- 1 | @REM Build for Visual Studio compiler. Run your copy of vcvars32.bat or vcvarsall.bat to setup command-line compiler. 2 | @set OUT_DIR=Debug 3 | @set OUT_EXE=example_win32_directx10 4 | @set INCLUDES=/I..\.. /I..\..\backends /I "%WindowsSdkDir%Include\um" /I "%WindowsSdkDir%Include\shared" /I "%DXSDK_DIR%Include" 5 | @set SOURCES=main.cpp ..\..\backends\imgui_impl_win32.cpp ..\..\backends\imgui_impl_dx10.cpp ..\..\imgui*.cpp 6 | @set LIBS=/LIBPATH:"%DXSDK_DIR%/Lib/x86" d3d10.lib d3dcompiler.lib 7 | mkdir %OUT_DIR% 8 | cl /nologo /Zi /MD %INCLUDES% /D UNICODE /D _UNICODE %SOURCES% /Fe%OUT_DIR%/%OUT_EXE%.exe /Fo%OUT_DIR%/ /link %LIBS% 9 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_win32_directx10/example_win32_directx10.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {0587d7a3-f2ce-4d56-b84f-a0005d3bfce6} 6 | 7 | 8 | {08e36723-ce4f-4cff-9662-c40801cf1acf} 9 | 10 | 11 | 12 | 13 | imgui 14 | 15 | 16 | imgui 17 | 18 | 19 | imgui 20 | 21 | 22 | sources 23 | 24 | 25 | sources 26 | 27 | 28 | 29 | 30 | imgui 31 | 32 | 33 | sources 34 | 35 | 36 | imgui 37 | 38 | 39 | imgui 40 | 41 | 42 | sources 43 | 44 | 45 | sources 46 | 47 | 48 | imgui 49 | 50 | 51 | imgui 52 | 53 | 54 | 55 | 56 | 57 | sources 58 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_win32_directx11/build_win32.bat: -------------------------------------------------------------------------------- 1 | @REM Build for Visual Studio compiler. Run your copy of vcvars32.bat or vcvarsall.bat to setup command-line compiler. 2 | @set OUT_DIR=Debug 3 | @set OUT_EXE=example_win32_directx11 4 | @set INCLUDES=/I..\.. /I..\..\backends /I "%WindowsSdkDir%Include\um" /I "%WindowsSdkDir%Include\shared" /I "%DXSDK_DIR%Include" 5 | @set SOURCES=main.cpp ..\..\backends\imgui_impl_dx11.cpp ..\..\backends\imgui_impl_win32.cpp ..\..\imgui*.cpp 6 | @set LIBS=/LIBPATH:"%DXSDK_DIR%/Lib/x86" d3d11.lib d3dcompiler.lib 7 | mkdir %OUT_DIR% 8 | cl /nologo /Zi /MD %INCLUDES% /D UNICODE /D _UNICODE %SOURCES% /Fe%OUT_DIR%/%OUT_EXE%.exe /Fo%OUT_DIR%/ /link %LIBS% 9 | 10 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_win32_directx11/example_win32_directx11.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {0587d7a3-f2ce-4d56-b84f-a0005d3bfce6} 6 | 7 | 8 | {08e36723-ce4f-4cff-9662-c40801cf1acf} 9 | 10 | 11 | 12 | 13 | imgui 14 | 15 | 16 | imgui 17 | 18 | 19 | imgui 20 | 21 | 22 | sources 23 | 24 | 25 | sources 26 | 27 | 28 | 29 | 30 | imgui 31 | 32 | 33 | sources 34 | 35 | 36 | imgui 37 | 38 | 39 | imgui 40 | 41 | 42 | imgui 43 | 44 | 45 | sources 46 | 47 | 48 | sources 49 | 50 | 51 | imgui 52 | 53 | 54 | 55 | 56 | 57 | sources 58 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_win32_directx12/build_win32.bat: -------------------------------------------------------------------------------- 1 | @REM Build for Visual Studio compiler. Run your copy of vcvars32.bat or vcvarsall.bat to setup command-line compiler. 2 | @REM Important: to build on 32-bit systems, the DX12 backends needs '#define ImTextureID ImU64', so we pass it here. 3 | @set OUT_DIR=Debug 4 | @set OUT_EXE=example_win32_directx12 5 | @set INCLUDES=/I..\.. /I..\..\backends /I "%WindowsSdkDir%Include\um" /I "%WindowsSdkDir%Include\shared" 6 | @set SOURCES=main.cpp ..\..\backends\imgui_impl_dx12.cpp ..\..\backends\imgui_impl_win32.cpp ..\..\imgui*.cpp 7 | @set LIBS=d3d12.lib d3dcompiler.lib dxgi.lib 8 | mkdir Debug 9 | cl /nologo /Zi /MD %INCLUDES% /D ImTextureID=ImU64 /D UNICODE /D _UNICODE %SOURCES% /Fe%OUT_DIR%/%OUT_EXE%.exe /Fo%OUT_DIR%/ /link %LIBS% 10 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_win32_directx12/example_win32_directx12.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {fb3d294f-51ec-478e-a627-25831c80fefd} 6 | 7 | 8 | {4f33ddea-9910-456d-b868-4267eb3c2b19} 9 | 10 | 11 | 12 | 13 | imgui 14 | 15 | 16 | imgui 17 | 18 | 19 | imgui 20 | 21 | 22 | sources 23 | 24 | 25 | sources 26 | 27 | 28 | 29 | 30 | imgui 31 | 32 | 33 | sources 34 | 35 | 36 | imgui 37 | 38 | 39 | imgui 40 | 41 | 42 | sources 43 | 44 | 45 | sources 46 | 47 | 48 | imgui 49 | 50 | 51 | imgui 52 | 53 | 54 | 55 | 56 | 57 | 58 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_win32_directx9/build_win32.bat: -------------------------------------------------------------------------------- 1 | @REM Build for Visual Studio compiler. Run your copy of vcvars32.bat or vcvarsall.bat to setup command-line compiler. 2 | @set OUT_DIR=Debug 3 | @set OUT_EXE=example_win32_directx9 4 | @set INCLUDES=/I..\.. /I..\..\backends /I "%DXSDK_DIR%/Include" 5 | @set SOURCES=main.cpp ..\..\backends\imgui_impl_dx9.cpp ..\..\backends\imgui_impl_win32.cpp ..\..\imgui*.cpp 6 | @set LIBS=/LIBPATH:"%DXSDK_DIR%/Lib/x86" d3d9.lib 7 | mkdir %OUT_DIR% 8 | cl /nologo /Zi /MD %INCLUDES% /D UNICODE /D _UNICODE %SOURCES% /Fe%OUT_DIR%/%OUT_EXE%.exe /Fo%OUT_DIR%/ /link %LIBS% 9 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/example_win32_directx9/example_win32_directx9.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {4FC737F1-C7A5-4376-A066-2A32D752A2FF} 6 | cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx 7 | 8 | 9 | {a82cba23-9de0-45c2-b1e3-2eb1666702de} 10 | 11 | 12 | 13 | 14 | sources 15 | 16 | 17 | imgui 18 | 19 | 20 | imgui 21 | 22 | 23 | imgui 24 | 25 | 26 | sources 27 | 28 | 29 | sources 30 | 31 | 32 | imgui 33 | 34 | 35 | imgui 36 | 37 | 38 | 39 | 40 | imgui 41 | 42 | 43 | imgui 44 | 45 | 46 | imgui 47 | 48 | 49 | sources 50 | 51 | 52 | sources 53 | 54 | 55 | 56 | 57 | 58 | sources 59 | 60 | 61 | 62 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/libs/glfw/COPYING.txt: -------------------------------------------------------------------------------- 1 | Copyright (c) 2002-2006 Marcus Geelnard 2 | Copyright (c) 2006-2010 Camilla Berglund 3 | 4 | This software is provided 'as-is', without any express or implied 5 | warranty. In no event will the authors be held liable for any damages 6 | arising from the use of this software. 7 | 8 | Permission is granted to anyone to use this software for any purpose, 9 | including commercial applications, and to alter it and redistribute it 10 | freely, subject to the following restrictions: 11 | 12 | 1. The origin of this software must not be misrepresented; you must not 13 | claim that you wrote the original software. If you use this software 14 | in a product, an acknowledgment in the product documentation would 15 | be appreciated but is not required. 16 | 17 | 2. Altered source versions must be plainly marked as such, and must not 18 | be misrepresented as being the original software. 19 | 20 | 3. This notice may not be removed or altered from any source 21 | distribution. 22 | 23 | -------------------------------------------------------------------------------- /extern/imgui-1.83/examples/libs/usynergy/README.txt: -------------------------------------------------------------------------------- 1 | 2 | uSynergy client -- Implementation for the embedded Synergy client library 3 | version 1.0.0, July 7th, 2012 4 | Copyright (c) 2012 Alex Evans 5 | 6 | This is a copy of the files once found at: 7 | https://github.com/symless/synergy-core/tree/790d108a56ada9caad8e56ff777d444485a69da9/src/micro 8 | 9 | -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/README.txt: -------------------------------------------------------------------------------- 1 | 2 | misc/cpp/ 3 | InputText() wrappers for C++ standard library (STL) type: std::string. 4 | This is also an example of how you may wrap your own similar types. 5 | 6 | misc/debuggers/ 7 | Helper files for popular debuggers. 8 | With the .natvis file, types like ImVector<> will be displayed nicely in Visual Studio debugger. 9 | 10 | misc/fonts/ 11 | Fonts loading/merging instructions (e.g. How to handle glyph ranges, how to merge icons fonts). 12 | Command line tool "binary_to_compressed_c" to create compressed arrays to embed data in source code. 13 | Suggested fonts and links. 14 | 15 | misc/freetype/ 16 | Font atlas builder/rasterizer using FreeType instead of stb_truetype. 17 | Benefit from better FreeType rasterization, in particular for small fonts. 18 | 19 | misc/single_file/ 20 | Single-file header stub. 21 | We use this to validate compiling all *.cpp files in a same compilation unit. 22 | Users of that technique (also called "Unity builds") can generally provide this themselves, 23 | so we don't really recommend you use this in your projects. 24 | -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/cpp/README.txt: -------------------------------------------------------------------------------- 1 | 2 | imgui_stdlib.h + imgui_stdlib.cpp 3 | InputText() wrappers for C++ standard library (STL) type: std::string. 4 | This is also an example of how you may wrap your own similar types. 5 | 6 | imgui_scoped.h 7 | [Experimental, not currently in main repository] 8 | Additional header file with some RAII-style wrappers for common Dear ImGui functions. 9 | Try by merging: https://github.com/ocornut/imgui/pull/2197 10 | Discuss at: https://github.com/ocornut/imgui/issues/2096 11 | -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/cpp/imgui_stdlib.h: -------------------------------------------------------------------------------- 1 | // dear imgui: wrappers for C++ standard library (STL) types (std::string, etc.) 2 | // This is also an example of how you may wrap your own similar types. 3 | 4 | // Compatibility: 5 | // - std::string support is only guaranteed to work from C++11. 6 | // If you try to use it pre-C++11, please share your findings (w/ info about compiler/architecture) 7 | 8 | // Changelog: 9 | // - v0.10: Initial version. Added InputText() / InputTextMultiline() calls with std::string 10 | 11 | #pragma once 12 | 13 | #include 14 | 15 | namespace ImGui 16 | { 17 | // ImGui::InputText() with std::string 18 | // Because text input needs dynamic resizing, we need to setup a callback to grow the capacity 19 | IMGUI_API bool InputText(const char* label, std::string* str, ImGuiInputTextFlags flags = 0, ImGuiInputTextCallback callback = NULL, void* user_data = NULL); 20 | IMGUI_API bool InputTextMultiline(const char* label, std::string* str, const ImVec2& size = ImVec2(0, 0), ImGuiInputTextFlags flags = 0, ImGuiInputTextCallback callback = NULL, void* user_data = NULL); 21 | IMGUI_API bool InputTextWithHint(const char* label, const char* hint, std::string* str, ImGuiInputTextFlags flags = 0, ImGuiInputTextCallback callback = NULL, void* user_data = NULL); 22 | } 23 | -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/debuggers/README.txt: -------------------------------------------------------------------------------- 1 | 2 | HELPER FILES FOR POPULAR DEBUGGERS 3 | 4 | imgui.gdb 5 | GDB: disable stepping into trivial functions. 6 | (read comments inside file for details) 7 | 8 | imgui.natstepfilter 9 | Visual Studio Debugger: disable stepping into trivial functions. 10 | (read comments inside file for details) 11 | 12 | imgui.natvis 13 | Visual Studio Debugger: describe Dear ImGui types for better display. 14 | With this, types like ImVector<> will be displayed nicely in the debugger. 15 | (read comments inside file for details) 16 | 17 | -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/debuggers/imgui.gdb: -------------------------------------------------------------------------------- 1 | # GDB configuration to aid debugging experience 2 | 3 | # To enable these customizations edit $HOME/.gdbinit (or ./.gdbinit if local gdbinit is enabled) and add: 4 | # add-auto-load-safe-path /path/to/imgui.gdb 5 | # source /path/to/imgui.gdb 6 | # 7 | # More Information at: 8 | # * https://sourceware.org/gdb/current/onlinedocs/gdb/gdbinit-man.html 9 | # * https://sourceware.org/gdb/current/onlinedocs/gdb/Init-File-in-the-Current-Directory.html#Init-File-in-the-Current-Directory 10 | 11 | # Disable stepping into trivial functions 12 | skip -rfunction Im(Vec2|Vec4|Strv|Vector|Span)::.+ 13 | -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/debuggers/imgui.natstepfilter: -------------------------------------------------------------------------------- 1 | 2 | 17 | 18 | 19 | 20 | 21 | 22 | (ImVec2|ImVec4|ImStrv)::.+ 23 | NoStepInto 24 | 25 | 26 | (ImVector|ImSpan).*::operator.+ 27 | NoStepInto 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/debuggers/imgui.natvis: -------------------------------------------------------------------------------- 1 | 2 | 13 | 14 | 15 | 16 | 17 | {{Size={Size} Capacity={Capacity}}} 18 | 19 | 20 | Size 21 | Data 22 | 23 | 24 | 25 | 26 | 27 | {{Size={DataEnd-Data} }} 28 | 29 | 30 | DataEnd-Data 31 | Data 32 | 33 | 34 | 35 | 36 | 37 | {{x={x,g} y={y,g}}} 38 | 39 | 40 | 41 | {{x={x,g} y={y,g} z={z,g} w={w,g}}} 42 | 43 | 44 | 45 | {{Min=({Min.x,g} {Min.y,g}) Max=({Max.x,g} {Max.y,g}) Size=({Max.x-Min.x,g} {Max.y-Min.y,g})}} 46 | 47 | Min 48 | Max 49 | Max.x - Min.x 50 | Max.y - Min.y 51 | 52 | 53 | 54 | 55 | {{Name {Name,s} Active {(Active||WasActive)?1:0,d} Child {(Flags & 0x01000000)?1:0,d} Popup {(Flags & 0x04000000)?1:0,d} Hidden {(Hidden)?1:0,d}} 56 | 57 | 58 | 59 | -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/fonts/Cousine-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/extern/imgui-1.83/misc/fonts/Cousine-Regular.ttf -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/fonts/DroidSans.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/extern/imgui-1.83/misc/fonts/DroidSans.ttf -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/fonts/Karla-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/extern/imgui-1.83/misc/fonts/Karla-Regular.ttf -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/fonts/ProggyClean.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/extern/imgui-1.83/misc/fonts/ProggyClean.ttf -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/fonts/ProggyTiny.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/extern/imgui-1.83/misc/fonts/ProggyTiny.ttf -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/fonts/Roboto-Medium.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/extern/imgui-1.83/misc/fonts/Roboto-Medium.ttf -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/freetype/README.md: -------------------------------------------------------------------------------- 1 | # imgui_freetype 2 | 3 | Build font atlases using FreeType instead of stb_truetype (which is the default font rasterizer). 4 |
by @vuhdo, @mikesart, @ocornut. 5 | 6 | ### Usage 7 | 8 | 1. Get latest FreeType binaries or build yourself (under Windows you may use vcpkg with `vcpkg install freetype`, `vcpkg integrate install`). 9 | 2. Add imgui_freetype.h/cpp alongside your project files. 10 | 3. Add `#define IMGUI_ENABLE_FREETYPE` in your [imconfig.h](https://github.com/ocornut/imgui/blob/master/imconfig.h) file 11 | 12 | ### About Gamma Correct Blending 13 | 14 | FreeType assumes blending in linear space rather than gamma space. 15 | See FreeType note for [FT_Render_Glyph](https://www.freetype.org/freetype2/docs/reference/ft2-base_interface.html#FT_Render_Glyph). 16 | For correct results you need to be using sRGB and convert to linear space in the pixel shader output. 17 | The default Dear ImGui styles will be impacted by this change (alpha values will need tweaking). 18 | 19 | ### Testbed for toying with settings (for developers) 20 | 21 | See https://gist.github.com/ocornut/b3a9ecf13502fd818799a452969649ad 22 | 23 | ### Known issues 24 | 25 | - Oversampling settins are ignored but also not so much necessary with the higher quality rendering. 26 | 27 | ### Comparaison 28 | 29 | Small, thin anti-aliased fonts are typically benefiting a lots from Freetype's hinting: 30 | ![comparing_font_rasterizers](https://user-images.githubusercontent.com/8225057/107550178-fef87f00-6bd0-11eb-8d09-e2edb2f0ccfc.gif) 31 | 32 | ### Colorful glyphs/emojis 33 | 34 | You can use the `ImGuiFreeTypeBuilderFlags_LoadColor` flag to load certain colorful glyphs. See 35 | ["Using Colorful Glyphs/Emojis"](https://github.com/ocornut/imgui/edit/master/docs/FONTS.md#using-colorful-glyphsemojis) section of FONTS.md. 36 | 37 | ![colored glyphs](https://user-images.githubusercontent.com/8225057/106171241-9dc4ba80-6191-11eb-8a69-ca1467b206d1.png) 38 | -------------------------------------------------------------------------------- /extern/imgui-1.83/misc/single_file/imgui_single_file.h: -------------------------------------------------------------------------------- 1 | // dear imgui: single-file wrapper include 2 | // We use this to validate compiling all *.cpp files in a same compilation unit. 3 | // Users of that technique (also called "Unity builds") can generally provide this themselves, 4 | // so we don't really recommend you use this in your projects. 5 | 6 | // Do this: 7 | // #define IMGUI_IMPLEMENTATION 8 | // Before you include this file in *one* C++ file to create the implementation. 9 | // Using this in your project will leak the contents of imgui_internal.h and ImVec2 operators in this compilation unit. 10 | #include "../../imgui.h" 11 | 12 | #ifdef IMGUI_IMPLEMENTATION 13 | #include "../../imgui.cpp" 14 | #include "../../imgui_demo.cpp" 15 | #include "../../imgui_draw.cpp" 16 | #include "../../imgui_tables.cpp" 17 | #include "../../imgui_widgets.cpp" 18 | #endif 19 | -------------------------------------------------------------------------------- /extern/rapidjson/rapidjson/cursorstreamwrapper.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making RapidJSON available. 2 | // 3 | // Copyright (C) 2015 THL A29 Limited, a Tencent company, and Milo Yip. All rights reserved. 4 | // 5 | // Licensed under the MIT License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // http://opensource.org/licenses/MIT 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef RAPIDJSON_CURSORSTREAMWRAPPER_H_ 16 | #define RAPIDJSON_CURSORSTREAMWRAPPER_H_ 17 | 18 | #include "stream.h" 19 | 20 | #if defined(__GNUC__) 21 | RAPIDJSON_DIAG_PUSH 22 | RAPIDJSON_DIAG_OFF(effc++) 23 | #endif 24 | 25 | #if defined(_MSC_VER) && _MSC_VER <= 1800 26 | RAPIDJSON_DIAG_PUSH 27 | RAPIDJSON_DIAG_OFF(4702) // unreachable code 28 | RAPIDJSON_DIAG_OFF(4512) // assignment operator could not be generated 29 | #endif 30 | 31 | RAPIDJSON_NAMESPACE_BEGIN 32 | 33 | 34 | //! Cursor stream wrapper for counting line and column number if error exists. 35 | /*! 36 | \tparam InputStream Any stream that implements Stream Concept 37 | */ 38 | template > 39 | class CursorStreamWrapper : public GenericStreamWrapper { 40 | public: 41 | typedef typename Encoding::Ch Ch; 42 | 43 | CursorStreamWrapper(InputStream& is): 44 | GenericStreamWrapper(is), line_(1), col_(0) {} 45 | 46 | // counting line and column number 47 | Ch Take() { 48 | Ch ch = this->is_.Take(); 49 | if(ch == '\n') { 50 | line_ ++; 51 | col_ = 0; 52 | } else { 53 | col_ ++; 54 | } 55 | return ch; 56 | } 57 | 58 | //! Get the error line number, if error exists. 59 | size_t GetLine() const { return line_; } 60 | //! Get the error column number, if error exists. 61 | size_t GetColumn() const { return col_; } 62 | 63 | private: 64 | size_t line_; //!< Current Line 65 | size_t col_; //!< Current Column 66 | }; 67 | 68 | #if defined(_MSC_VER) && _MSC_VER <= 1800 69 | RAPIDJSON_DIAG_POP 70 | #endif 71 | 72 | #if defined(__GNUC__) 73 | RAPIDJSON_DIAG_POP 74 | #endif 75 | 76 | RAPIDJSON_NAMESPACE_END 77 | 78 | #endif // RAPIDJSON_CURSORSTREAMWRAPPER_H_ 79 | -------------------------------------------------------------------------------- /extern/rapidjson/rapidjson/internal/clzll.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making RapidJSON available. 2 | // 3 | // Copyright (C) 2015 THL A29 Limited, a Tencent company, and Milo Yip. All rights reserved. 4 | // 5 | // Licensed under the MIT License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // http://opensource.org/licenses/MIT 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef RAPIDJSON_CLZLL_H_ 16 | #define RAPIDJSON_CLZLL_H_ 17 | 18 | #include "../rapidjson.h" 19 | 20 | #if defined(_MSC_VER) && !defined(UNDER_CE) 21 | #include 22 | #if defined(_WIN64) 23 | #pragma intrinsic(_BitScanReverse64) 24 | #else 25 | #pragma intrinsic(_BitScanReverse) 26 | #endif 27 | #endif 28 | 29 | RAPIDJSON_NAMESPACE_BEGIN 30 | namespace internal { 31 | 32 | inline uint32_t clzll(uint64_t x) { 33 | // Passing 0 to __builtin_clzll is UB in GCC and results in an 34 | // infinite loop in the software implementation. 35 | RAPIDJSON_ASSERT(x != 0); 36 | 37 | #if defined(_MSC_VER) && !defined(UNDER_CE) 38 | unsigned long r = 0; 39 | #if defined(_WIN64) 40 | _BitScanReverse64(&r, x); 41 | #else 42 | // Scan the high 32 bits. 43 | if (_BitScanReverse(&r, static_cast(x >> 32))) 44 | return 63 - (r + 32); 45 | 46 | // Scan the low 32 bits. 47 | _BitScanReverse(&r, static_cast(x & 0xFFFFFFFF)); 48 | #endif // _WIN64 49 | 50 | return 63 - r; 51 | #elif (defined(__GNUC__) && __GNUC__ >= 4) || RAPIDJSON_HAS_BUILTIN(__builtin_clzll) 52 | // __builtin_clzll wrapper 53 | return static_cast(__builtin_clzll(x)); 54 | #else 55 | // naive version 56 | uint32_t r = 0; 57 | while (!(x & (static_cast(1) << 63))) { 58 | x <<= 1; 59 | ++r; 60 | } 61 | 62 | return r; 63 | #endif // _MSC_VER 64 | } 65 | 66 | #define RAPIDJSON_CLZLL RAPIDJSON_NAMESPACE::internal::clzll 67 | 68 | } // namespace internal 69 | RAPIDJSON_NAMESPACE_END 70 | 71 | #endif // RAPIDJSON_CLZLL_H_ 72 | -------------------------------------------------------------------------------- /extern/rapidjson/rapidjson/internal/strfunc.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making RapidJSON available. 2 | // 3 | // Copyright (C) 2015 THL A29 Limited, a Tencent company, and Milo Yip. All rights reserved. 4 | // 5 | // Licensed under the MIT License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // http://opensource.org/licenses/MIT 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef RAPIDJSON_INTERNAL_STRFUNC_H_ 16 | #define RAPIDJSON_INTERNAL_STRFUNC_H_ 17 | 18 | #include "../stream.h" 19 | #include 20 | 21 | RAPIDJSON_NAMESPACE_BEGIN 22 | namespace internal { 23 | 24 | //! Custom strlen() which works on different character types. 25 | /*! \tparam Ch Character type (e.g. char, wchar_t, short) 26 | \param s Null-terminated input string. 27 | \return Number of characters in the string. 28 | \note This has the same semantics as strlen(), the return value is not number of Unicode codepoints. 29 | */ 30 | template 31 | inline SizeType StrLen(const Ch* s) { 32 | RAPIDJSON_ASSERT(s != 0); 33 | const Ch* p = s; 34 | while (*p) ++p; 35 | return SizeType(p - s); 36 | } 37 | 38 | template <> 39 | inline SizeType StrLen(const char* s) { 40 | return SizeType(std::strlen(s)); 41 | } 42 | 43 | template <> 44 | inline SizeType StrLen(const wchar_t* s) { 45 | return SizeType(std::wcslen(s)); 46 | } 47 | 48 | //! Returns number of code points in a encoded string. 49 | template 50 | bool CountStringCodePoint(const typename Encoding::Ch* s, SizeType length, SizeType* outCount) { 51 | RAPIDJSON_ASSERT(s != 0); 52 | RAPIDJSON_ASSERT(outCount != 0); 53 | GenericStringStream is(s); 54 | const typename Encoding::Ch* end = s + length; 55 | SizeType count = 0; 56 | while (is.src_ < end) { 57 | unsigned codepoint; 58 | if (!Encoding::Decode(is, &codepoint)) 59 | return false; 60 | count++; 61 | } 62 | *outCount = count; 63 | return true; 64 | } 65 | 66 | } // namespace internal 67 | RAPIDJSON_NAMESPACE_END 68 | 69 | #endif // RAPIDJSON_INTERNAL_STRFUNC_H_ 70 | -------------------------------------------------------------------------------- /extern/rapidjson/rapidjson/internal/swap.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making RapidJSON available. 2 | // 3 | // Copyright (C) 2015 THL A29 Limited, a Tencent company, and Milo Yip. All rights reserved. 4 | // 5 | // Licensed under the MIT License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // http://opensource.org/licenses/MIT 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef RAPIDJSON_INTERNAL_SWAP_H_ 16 | #define RAPIDJSON_INTERNAL_SWAP_H_ 17 | 18 | #include "../rapidjson.h" 19 | 20 | #if defined(__clang__) 21 | RAPIDJSON_DIAG_PUSH 22 | RAPIDJSON_DIAG_OFF(c++98-compat) 23 | #endif 24 | 25 | RAPIDJSON_NAMESPACE_BEGIN 26 | namespace internal { 27 | 28 | //! Custom swap() to avoid dependency on C++ header 29 | /*! \tparam T Type of the arguments to swap, should be instantiated with primitive C++ types only. 30 | \note This has the same semantics as std::swap(). 31 | */ 32 | template 33 | inline void Swap(T& a, T& b) RAPIDJSON_NOEXCEPT { 34 | T tmp = a; 35 | a = b; 36 | b = tmp; 37 | } 38 | 39 | } // namespace internal 40 | RAPIDJSON_NAMESPACE_END 41 | 42 | #if defined(__clang__) 43 | RAPIDJSON_DIAG_POP 44 | #endif 45 | 46 | #endif // RAPIDJSON_INTERNAL_SWAP_H_ 47 | -------------------------------------------------------------------------------- /extern/rapidjson/rapidjson/ostreamwrapper.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making RapidJSON available. 2 | // 3 | // Copyright (C) 2015 THL A29 Limited, a Tencent company, and Milo Yip. All rights reserved. 4 | // 5 | // Licensed under the MIT License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // http://opensource.org/licenses/MIT 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef RAPIDJSON_OSTREAMWRAPPER_H_ 16 | #define RAPIDJSON_OSTREAMWRAPPER_H_ 17 | 18 | #include "stream.h" 19 | #include 20 | 21 | #ifdef __clang__ 22 | RAPIDJSON_DIAG_PUSH 23 | RAPIDJSON_DIAG_OFF(padded) 24 | #endif 25 | 26 | RAPIDJSON_NAMESPACE_BEGIN 27 | 28 | //! Wrapper of \c std::basic_ostream into RapidJSON's Stream concept. 29 | /*! 30 | The classes can be wrapped including but not limited to: 31 | 32 | - \c std::ostringstream 33 | - \c std::stringstream 34 | - \c std::wpstringstream 35 | - \c std::wstringstream 36 | - \c std::ifstream 37 | - \c std::fstream 38 | - \c std::wofstream 39 | - \c std::wfstream 40 | 41 | \tparam StreamType Class derived from \c std::basic_ostream. 42 | */ 43 | 44 | template 45 | class BasicOStreamWrapper { 46 | public: 47 | typedef typename StreamType::char_type Ch; 48 | BasicOStreamWrapper(StreamType& stream) : stream_(stream) {} 49 | 50 | void Put(Ch c) { 51 | stream_.put(c); 52 | } 53 | 54 | void Flush() { 55 | stream_.flush(); 56 | } 57 | 58 | // Not implemented 59 | char Peek() const { RAPIDJSON_ASSERT(false); return 0; } 60 | char Take() { RAPIDJSON_ASSERT(false); return 0; } 61 | size_t Tell() const { RAPIDJSON_ASSERT(false); return 0; } 62 | char* PutBegin() { RAPIDJSON_ASSERT(false); return 0; } 63 | size_t PutEnd(char*) { RAPIDJSON_ASSERT(false); return 0; } 64 | 65 | private: 66 | BasicOStreamWrapper(const BasicOStreamWrapper&); 67 | BasicOStreamWrapper& operator=(const BasicOStreamWrapper&); 68 | 69 | StreamType& stream_; 70 | }; 71 | 72 | typedef BasicOStreamWrapper OStreamWrapper; 73 | typedef BasicOStreamWrapper WOStreamWrapper; 74 | 75 | #ifdef __clang__ 76 | RAPIDJSON_DIAG_POP 77 | #endif 78 | 79 | RAPIDJSON_NAMESPACE_END 80 | 81 | #endif // RAPIDJSON_OSTREAMWRAPPER_H_ 82 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/async_logger.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | // Fast asynchronous logger. 7 | // Uses pre allocated queue. 8 | // Creates a single back thread to pop messages from the queue and log them. 9 | // 10 | // Upon each log write the logger: 11 | // 1. Checks if its log level is enough to log the message 12 | // 2. Push a new copy of the message to a queue (or block the caller until 13 | // space is available in the queue) 14 | // Upon destruction, logs all remaining messages in the queue before 15 | // destructing.. 16 | 17 | #include 18 | 19 | namespace spdlog { 20 | 21 | // Async overflow policy - block by default. 22 | enum class async_overflow_policy 23 | { 24 | block, // Block until message can be enqueued 25 | overrun_oldest // Discard oldest message in the queue if full when trying to 26 | // add new item. 27 | }; 28 | 29 | namespace details { 30 | class thread_pool; 31 | } 32 | 33 | class SPDLOG_API async_logger final : public std::enable_shared_from_this, public logger 34 | { 35 | friend class details::thread_pool; 36 | 37 | public: 38 | template 39 | async_logger(std::string logger_name, It begin, It end, std::weak_ptr tp, 40 | async_overflow_policy overflow_policy = async_overflow_policy::block) 41 | : logger(std::move(logger_name), begin, end) 42 | , thread_pool_(std::move(tp)) 43 | , overflow_policy_(overflow_policy) 44 | {} 45 | 46 | async_logger(std::string logger_name, sinks_init_list sinks_list, std::weak_ptr tp, 47 | async_overflow_policy overflow_policy = async_overflow_policy::block); 48 | 49 | async_logger(std::string logger_name, sink_ptr single_sink, std::weak_ptr tp, 50 | async_overflow_policy overflow_policy = async_overflow_policy::block); 51 | 52 | std::shared_ptr clone(std::string new_name) override; 53 | 54 | protected: 55 | void sink_it_(const details::log_msg &msg) override; 56 | void flush_() override; 57 | void backend_sink_it_(const details::log_msg &incoming_log_msg); 58 | void backend_flush_(); 59 | 60 | private: 61 | std::weak_ptr thread_pool_; 62 | async_overflow_policy overflow_policy_; 63 | }; 64 | } // namespace spdlog 65 | 66 | #ifdef SPDLOG_HEADER_ONLY 67 | #include "async_logger-inl.h" 68 | #endif 69 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/cfg/argv.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | #include 6 | #include 7 | 8 | // 9 | // Init log levels using each argv entry that starts with "SPDLOG_LEVEL=" 10 | // 11 | // set all loggers to debug level: 12 | // example.exe "SPDLOG_LEVEL=debug" 13 | 14 | // set logger1 to trace level 15 | // example.exe "SPDLOG_LEVEL=logger1=trace" 16 | 17 | // turn off all logging except for logger1 and logger2: 18 | // example.exe "SPDLOG_LEVEL=off,logger1=debug,logger2=info" 19 | 20 | namespace spdlog { 21 | namespace cfg { 22 | 23 | // search for SPDLOG_LEVEL= in the args and use it to init the levels 24 | inline void load_argv_levels(int argc, const char **argv) 25 | { 26 | const std::string spdlog_level_prefix = "SPDLOG_LEVEL="; 27 | for (int i = 1; i < argc; i++) 28 | { 29 | std::string arg = argv[i]; 30 | if (arg.find(spdlog_level_prefix) == 0) 31 | { 32 | auto levels_string = arg.substr(spdlog_level_prefix.size()); 33 | helpers::load_levels(levels_string); 34 | } 35 | } 36 | } 37 | 38 | inline void load_argv_levels(int argc, char **argv) 39 | { 40 | load_argv_levels(argc, const_cast(argv)); 41 | } 42 | 43 | } // namespace cfg 44 | } // namespace spdlog 45 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/cfg/env.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | #include 6 | #include 7 | #include 8 | 9 | // 10 | // Init levels and patterns from env variables SPDLOG_LEVEL 11 | // Inspired from Rust's "env_logger" crate (https://crates.io/crates/env_logger). 12 | // Note - fallback to "info" level on unrecognized levels 13 | // 14 | // Examples: 15 | // 16 | // set global level to debug: 17 | // export SPDLOG_LEVEL=debug 18 | // 19 | // turn off all logging except for logger1: 20 | // export SPDLOG_LEVEL="*=off,logger1=debug" 21 | // 22 | 23 | // turn off all logging except for logger1 and logger2: 24 | // export SPDLOG_LEVEL="off,logger1=debug,logger2=info" 25 | 26 | namespace spdlog { 27 | namespace cfg { 28 | inline void load_env_levels() 29 | { 30 | auto env_val = details::os::getenv("SPDLOG_LEVEL"); 31 | if (!env_val.empty()) 32 | { 33 | helpers::load_levels(env_val); 34 | } 35 | } 36 | 37 | } // namespace cfg 38 | } // namespace spdlog 39 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/cfg/helpers.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | #include 8 | 9 | namespace spdlog { 10 | namespace cfg { 11 | namespace helpers { 12 | // 13 | // Init levels from given string 14 | // 15 | // Examples: 16 | // 17 | // set global level to debug: "debug" 18 | // turn off all logging except for logger1: "off,logger1=debug" 19 | // turn off all logging except for logger1 and logger2: "off,logger1=debug,logger2=info" 20 | // 21 | SPDLOG_API void load_levels(const std::string &txt); 22 | } // namespace helpers 23 | 24 | } // namespace cfg 25 | } // namespace spdlog 26 | 27 | #ifdef SPDLOG_HEADER_ONLY 28 | #include "helpers-inl.h" 29 | #endif // SPDLOG_HEADER_ONLY 30 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/common-inl.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #ifndef SPDLOG_HEADER_ONLY 7 | #include 8 | #endif 9 | 10 | namespace spdlog { 11 | namespace level { 12 | 13 | static string_view_t level_string_views[] SPDLOG_LEVEL_NAMES; 14 | 15 | static const char *short_level_names[] SPDLOG_SHORT_LEVEL_NAMES; 16 | 17 | SPDLOG_INLINE const string_view_t &to_string_view(spdlog::level::level_enum l) SPDLOG_NOEXCEPT 18 | { 19 | return level_string_views[l]; 20 | } 21 | 22 | SPDLOG_INLINE void set_string_view(spdlog::level::level_enum l, const string_view_t &s) SPDLOG_NOEXCEPT 23 | { 24 | level_string_views[l] = s; 25 | } 26 | 27 | SPDLOG_INLINE const char *to_short_c_str(spdlog::level::level_enum l) SPDLOG_NOEXCEPT 28 | { 29 | return short_level_names[l]; 30 | } 31 | 32 | SPDLOG_INLINE spdlog::level::level_enum from_str(const std::string &name) SPDLOG_NOEXCEPT 33 | { 34 | int level = 0; 35 | for (const auto &level_str : level_string_views) 36 | { 37 | if (level_str == name) 38 | { 39 | return static_cast(level); 40 | } 41 | level++; 42 | } 43 | // check also for "warn" and "err" before giving up.. 44 | if (name == "warn") 45 | { 46 | return level::warn; 47 | } 48 | if (name == "err") 49 | { 50 | return level::err; 51 | } 52 | return level::off; 53 | } 54 | } // namespace level 55 | 56 | SPDLOG_INLINE spdlog_ex::spdlog_ex(std::string msg) 57 | : msg_(std::move(msg)) 58 | {} 59 | 60 | SPDLOG_INLINE spdlog_ex::spdlog_ex(const std::string &msg, int last_errno) 61 | { 62 | memory_buf_t outbuf; 63 | fmt::format_system_error(outbuf, last_errno, msg); 64 | msg_ = fmt::to_string(outbuf); 65 | } 66 | 67 | SPDLOG_INLINE const char *spdlog_ex::what() const SPDLOG_NOEXCEPT 68 | { 69 | return msg_.c_str(); 70 | } 71 | 72 | SPDLOG_INLINE void throw_spdlog_ex(const std::string &msg, int last_errno) 73 | { 74 | SPDLOG_THROW(spdlog_ex(msg, last_errno)); 75 | } 76 | 77 | SPDLOG_INLINE void throw_spdlog_ex(std::string msg) 78 | { 79 | SPDLOG_THROW(spdlog_ex(std::move(msg))); 80 | } 81 | 82 | } // namespace spdlog 83 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/details/backtracer-inl.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #ifndef SPDLOG_HEADER_ONLY 7 | #include 8 | #endif 9 | namespace spdlog { 10 | namespace details { 11 | SPDLOG_INLINE backtracer::backtracer(const backtracer &other) 12 | { 13 | std::lock_guard lock(other.mutex_); 14 | enabled_ = other.enabled(); 15 | messages_ = other.messages_; 16 | } 17 | 18 | SPDLOG_INLINE backtracer::backtracer(backtracer &&other) SPDLOG_NOEXCEPT 19 | { 20 | std::lock_guard lock(other.mutex_); 21 | enabled_ = other.enabled(); 22 | messages_ = std::move(other.messages_); 23 | } 24 | 25 | SPDLOG_INLINE backtracer &backtracer::operator=(backtracer other) 26 | { 27 | std::lock_guard lock(mutex_); 28 | enabled_ = other.enabled(); 29 | messages_ = std::move(other.messages_); 30 | return *this; 31 | } 32 | 33 | SPDLOG_INLINE void backtracer::enable(size_t size) 34 | { 35 | std::lock_guard lock{mutex_}; 36 | enabled_.store(true, std::memory_order_relaxed); 37 | messages_ = circular_q{size}; 38 | } 39 | 40 | SPDLOG_INLINE void backtracer::disable() 41 | { 42 | std::lock_guard lock{mutex_}; 43 | enabled_.store(false, std::memory_order_relaxed); 44 | } 45 | 46 | SPDLOG_INLINE bool backtracer::enabled() const 47 | { 48 | return enabled_.load(std::memory_order_relaxed); 49 | } 50 | 51 | SPDLOG_INLINE void backtracer::push_back(const log_msg &msg) 52 | { 53 | std::lock_guard lock{mutex_}; 54 | messages_.push_back(log_msg_buffer{msg}); 55 | } 56 | 57 | // pop all items in the q and apply the given fun on each of them. 58 | SPDLOG_INLINE void backtracer::foreach_pop(std::function fun) 59 | { 60 | std::lock_guard lock{mutex_}; 61 | while (!messages_.empty()) 62 | { 63 | auto &front_msg = messages_.front(); 64 | fun(front_msg); 65 | messages_.pop_front(); 66 | } 67 | } 68 | } // namespace details 69 | } // namespace spdlog 70 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/details/backtracer.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | #include 8 | 9 | #include 10 | #include 11 | #include 12 | 13 | // Store log messages in circular buffer. 14 | // Useful for storing debug data in case of error/warning happens. 15 | 16 | namespace spdlog { 17 | namespace details { 18 | class SPDLOG_API backtracer 19 | { 20 | mutable std::mutex mutex_; 21 | std::atomic enabled_{false}; 22 | circular_q messages_; 23 | 24 | public: 25 | backtracer() = default; 26 | backtracer(const backtracer &other); 27 | 28 | backtracer(backtracer &&other) SPDLOG_NOEXCEPT; 29 | backtracer &operator=(backtracer other); 30 | 31 | void enable(size_t size); 32 | void disable(); 33 | bool enabled() const; 34 | void push_back(const log_msg &msg); 35 | 36 | // pop all items in the q and apply the given fun on each of them. 37 | void foreach_pop(std::function fun); 38 | }; 39 | 40 | } // namespace details 41 | } // namespace spdlog 42 | 43 | #ifdef SPDLOG_HEADER_ONLY 44 | #include "backtracer-inl.h" 45 | #endif -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/details/console_globals.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | #include 8 | 9 | namespace spdlog { 10 | namespace details { 11 | 12 | struct console_mutex 13 | { 14 | using mutex_t = std::mutex; 15 | static mutex_t &mutex() 16 | { 17 | static mutex_t s_mutex; 18 | return s_mutex; 19 | } 20 | }; 21 | 22 | struct console_nullmutex 23 | { 24 | using mutex_t = null_mutex; 25 | static mutex_t &mutex() 26 | { 27 | static mutex_t s_mutex; 28 | return s_mutex; 29 | } 30 | }; 31 | } // namespace details 32 | } // namespace spdlog 33 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/details/file_helper.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | #include 8 | 9 | namespace spdlog { 10 | namespace details { 11 | 12 | // Helper class for file sinks. 13 | // When failing to open a file, retry several times(5) with a delay interval(10 ms). 14 | // Throw spdlog_ex exception on errors. 15 | 16 | class SPDLOG_API file_helper 17 | { 18 | public: 19 | explicit file_helper() = default; 20 | 21 | file_helper(const file_helper &) = delete; 22 | file_helper &operator=(const file_helper &) = delete; 23 | ~file_helper(); 24 | 25 | void open(const filename_t &fname, bool truncate = false); 26 | void reopen(bool truncate); 27 | void flush(); 28 | void close(); 29 | void write(const memory_buf_t &buf); 30 | size_t size() const; 31 | const filename_t &filename() const; 32 | 33 | // 34 | // return file path and its extension: 35 | // 36 | // "mylog.txt" => ("mylog", ".txt") 37 | // "mylog" => ("mylog", "") 38 | // "mylog." => ("mylog.", "") 39 | // "/dir1/dir2/mylog.txt" => ("/dir1/dir2/mylog", ".txt") 40 | // 41 | // the starting dot in filenames is ignored (hidden files): 42 | // 43 | // ".mylog" => (".mylog". "") 44 | // "my_folder/.mylog" => ("my_folder/.mylog", "") 45 | // "my_folder/.mylog.txt" => ("my_folder/.mylog", ".txt") 46 | static std::tuple split_by_extension(const filename_t &fname); 47 | 48 | private: 49 | const int open_tries_ = 5; 50 | const int open_interval_ = 10; 51 | std::FILE *fd_{nullptr}; 52 | filename_t filename_; 53 | }; 54 | } // namespace details 55 | } // namespace spdlog 56 | 57 | #ifdef SPDLOG_HEADER_ONLY 58 | #include "file_helper-inl.h" 59 | #endif 60 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/details/log_msg-inl.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #ifndef SPDLOG_HEADER_ONLY 7 | #include 8 | #endif 9 | 10 | #include 11 | 12 | namespace spdlog { 13 | namespace details { 14 | 15 | SPDLOG_INLINE log_msg::log_msg(spdlog::log_clock::time_point log_time, spdlog::source_loc loc, string_view_t a_logger_name, 16 | spdlog::level::level_enum lvl, spdlog::string_view_t msg) 17 | : logger_name(a_logger_name) 18 | , level(lvl) 19 | , time(log_time) 20 | #ifndef SPDLOG_NO_THREAD_ID 21 | , thread_id(os::thread_id()) 22 | #endif 23 | , source(loc) 24 | , payload(msg) 25 | {} 26 | 27 | SPDLOG_INLINE log_msg::log_msg( 28 | spdlog::source_loc loc, string_view_t a_logger_name, spdlog::level::level_enum lvl, spdlog::string_view_t msg) 29 | : log_msg(os::now(), loc, a_logger_name, lvl, msg) 30 | {} 31 | 32 | SPDLOG_INLINE log_msg::log_msg(string_view_t a_logger_name, spdlog::level::level_enum lvl, spdlog::string_view_t msg) 33 | : log_msg(os::now(), source_loc{}, a_logger_name, lvl, msg) 34 | {} 35 | 36 | } // namespace details 37 | } // namespace spdlog 38 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/details/log_msg.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | #include 8 | 9 | namespace spdlog { 10 | namespace details { 11 | struct SPDLOG_API log_msg 12 | { 13 | log_msg() = default; 14 | log_msg(log_clock::time_point log_time, source_loc loc, string_view_t logger_name, level::level_enum lvl, string_view_t msg); 15 | log_msg(source_loc loc, string_view_t logger_name, level::level_enum lvl, string_view_t msg); 16 | log_msg(string_view_t logger_name, level::level_enum lvl, string_view_t msg); 17 | log_msg(const log_msg &other) = default; 18 | 19 | string_view_t logger_name; 20 | level::level_enum level{level::off}; 21 | log_clock::time_point time; 22 | size_t thread_id{0}; 23 | 24 | // wrapping the formatted text with color (updated by pattern_formatter). 25 | mutable size_t color_range_start{0}; 26 | mutable size_t color_range_end{0}; 27 | 28 | source_loc source; 29 | string_view_t payload; 30 | }; 31 | } // namespace details 32 | } // namespace spdlog 33 | 34 | #ifdef SPDLOG_HEADER_ONLY 35 | #include "log_msg-inl.h" 36 | #endif 37 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/details/log_msg_buffer-inl.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #ifndef SPDLOG_HEADER_ONLY 7 | #include 8 | #endif 9 | 10 | namespace spdlog { 11 | namespace details { 12 | 13 | SPDLOG_INLINE log_msg_buffer::log_msg_buffer(const log_msg &orig_msg) 14 | : log_msg{orig_msg} 15 | { 16 | buffer.append(logger_name.begin(), logger_name.end()); 17 | buffer.append(payload.begin(), payload.end()); 18 | update_string_views(); 19 | } 20 | 21 | SPDLOG_INLINE log_msg_buffer::log_msg_buffer(const log_msg_buffer &other) 22 | : log_msg{other} 23 | { 24 | buffer.append(logger_name.begin(), logger_name.end()); 25 | buffer.append(payload.begin(), payload.end()); 26 | update_string_views(); 27 | } 28 | 29 | SPDLOG_INLINE log_msg_buffer::log_msg_buffer(log_msg_buffer &&other) SPDLOG_NOEXCEPT 30 | : log_msg{other} 31 | , buffer{std::move(other.buffer)} 32 | { 33 | update_string_views(); 34 | } 35 | 36 | SPDLOG_INLINE log_msg_buffer &log_msg_buffer::operator=(const log_msg_buffer &other) 37 | { 38 | log_msg::operator=(other); 39 | buffer.clear(); 40 | buffer.append(other.buffer.data(), other.buffer.data() + other.buffer.size()); 41 | update_string_views(); 42 | return *this; 43 | } 44 | 45 | SPDLOG_INLINE log_msg_buffer &log_msg_buffer::operator=(log_msg_buffer &&other) SPDLOG_NOEXCEPT 46 | { 47 | log_msg::operator=(other); 48 | buffer = std::move(other.buffer); 49 | update_string_views(); 50 | return *this; 51 | } 52 | 53 | SPDLOG_INLINE void log_msg_buffer::update_string_views() 54 | { 55 | logger_name = string_view_t{buffer.data(), logger_name.size()}; 56 | payload = string_view_t{buffer.data() + logger_name.size(), payload.size()}; 57 | } 58 | 59 | } // namespace details 60 | } // namespace spdlog 61 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/details/log_msg_buffer.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | 8 | namespace spdlog { 9 | namespace details { 10 | 11 | // Extend log_msg with internal buffer to store its payload. 12 | // This is needed since log_msg holds string_views that points to stack data. 13 | 14 | class SPDLOG_API log_msg_buffer : public log_msg 15 | { 16 | memory_buf_t buffer; 17 | void update_string_views(); 18 | 19 | public: 20 | log_msg_buffer() = default; 21 | explicit log_msg_buffer(const log_msg &orig_msg); 22 | log_msg_buffer(const log_msg_buffer &other); 23 | log_msg_buffer(log_msg_buffer &&other) SPDLOG_NOEXCEPT; 24 | log_msg_buffer &operator=(const log_msg_buffer &other); 25 | log_msg_buffer &operator=(log_msg_buffer &&other) SPDLOG_NOEXCEPT; 26 | }; 27 | 28 | } // namespace details 29 | } // namespace spdlog 30 | 31 | #ifdef SPDLOG_HEADER_ONLY 32 | #include "log_msg_buffer-inl.h" 33 | #endif 34 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/details/null_mutex.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | #include 8 | // null, no cost dummy "mutex" and dummy "atomic" int 9 | 10 | namespace spdlog { 11 | namespace details { 12 | struct null_mutex 13 | { 14 | void lock() const {} 15 | void unlock() const {} 16 | bool try_lock() const 17 | { 18 | return true; 19 | } 20 | }; 21 | 22 | struct null_atomic_int 23 | { 24 | int value; 25 | null_atomic_int() = default; 26 | 27 | explicit null_atomic_int(int new_value) 28 | : value(new_value) 29 | {} 30 | 31 | int load(std::memory_order = std::memory_order_relaxed) const 32 | { 33 | return value; 34 | } 35 | 36 | void store(int new_value, std::memory_order = std::memory_order_relaxed) 37 | { 38 | value = new_value; 39 | } 40 | 41 | int exchange(int new_value, std::memory_order = std::memory_order_relaxed) 42 | { 43 | std::swap(new_value, value); 44 | return new_value; // return value before the call 45 | } 46 | }; 47 | 48 | } // namespace details 49 | } // namespace spdlog 50 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/details/periodic_worker-inl.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #ifndef SPDLOG_HEADER_ONLY 7 | #include 8 | #endif 9 | 10 | namespace spdlog { 11 | namespace details { 12 | 13 | SPDLOG_INLINE periodic_worker::periodic_worker(const std::function &callback_fun, std::chrono::seconds interval) 14 | { 15 | active_ = (interval > std::chrono::seconds::zero()); 16 | if (!active_) 17 | { 18 | return; 19 | } 20 | 21 | worker_thread_ = std::thread([this, callback_fun, interval]() { 22 | for (;;) 23 | { 24 | std::unique_lock lock(this->mutex_); 25 | if (this->cv_.wait_for(lock, interval, [this] { return !this->active_; })) 26 | { 27 | return; // active_ == false, so exit this thread 28 | } 29 | callback_fun(); 30 | } 31 | }); 32 | } 33 | 34 | // stop the worker thread and join it 35 | SPDLOG_INLINE periodic_worker::~periodic_worker() 36 | { 37 | if (worker_thread_.joinable()) 38 | { 39 | { 40 | std::lock_guard lock(mutex_); 41 | active_ = false; 42 | } 43 | cv_.notify_one(); 44 | worker_thread_.join(); 45 | } 46 | } 47 | 48 | } // namespace details 49 | } // namespace spdlog 50 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/details/periodic_worker.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | // periodic worker thread - periodically executes the given callback function. 7 | // 8 | // RAII over the owned thread: 9 | // creates the thread on construction. 10 | // stops and joins the thread on destruction (if the thread is executing a callback, wait for it to finish first). 11 | 12 | #include 13 | #include 14 | #include 15 | #include 16 | #include 17 | namespace spdlog { 18 | namespace details { 19 | 20 | class SPDLOG_API periodic_worker 21 | { 22 | public: 23 | periodic_worker(const std::function &callback_fun, std::chrono::seconds interval); 24 | periodic_worker(const periodic_worker &) = delete; 25 | periodic_worker &operator=(const periodic_worker &) = delete; 26 | // stop the worker thread and join it 27 | ~periodic_worker(); 28 | 29 | private: 30 | bool active_; 31 | std::thread worker_thread_; 32 | std::mutex mutex_; 33 | std::condition_variable cv_; 34 | }; 35 | } // namespace details 36 | } // namespace spdlog 37 | 38 | #ifdef SPDLOG_HEADER_ONLY 39 | #include "periodic_worker-inl.h" 40 | #endif 41 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/details/synchronous_factory.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include "registry.h" 7 | 8 | namespace spdlog { 9 | 10 | // Default logger factory- creates synchronous loggers 11 | class logger; 12 | 13 | struct synchronous_factory 14 | { 15 | template 16 | static std::shared_ptr create(std::string logger_name, SinkArgs &&...args) 17 | { 18 | auto sink = std::make_shared(std::forward(args)...); 19 | auto new_logger = std::make_shared(std::move(logger_name), std::move(sink)); 20 | details::registry::instance().initialize_logger(new_logger); 21 | return new_logger; 22 | } 23 | }; 24 | } // namespace spdlog -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/details/windows_include.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #ifndef NOMINMAX 4 | #define NOMINMAX // prevent windows redefining min/max 5 | #endif 6 | 7 | #ifndef WIN32_LEAN_AND_MEAN 8 | #define WIN32_LEAN_AND_MEAN 9 | #endif 10 | 11 | #include 12 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/fmt/chrono.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright(c) 2016 Gabi Melman. 3 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 4 | // 5 | 6 | #pragma once 7 | // 8 | // include bundled or external copy of fmtlib's chrono support 9 | // 10 | 11 | #if !defined(SPDLOG_FMT_EXTERNAL) 12 | #ifdef SPDLOG_HEADER_ONLY 13 | #ifndef FMT_HEADER_ONLY 14 | #define FMT_HEADER_ONLY 15 | #endif 16 | #endif 17 | #include 18 | #else 19 | #include 20 | #endif 21 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/fmt/fmt.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright(c) 2016-2018 Gabi Melman. 3 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 4 | // 5 | 6 | #pragma once 7 | 8 | // 9 | // Include a bundled header-only copy of fmtlib or an external one. 10 | // By default spdlog include its own copy. 11 | // 12 | 13 | #if 0 // !defined(SPDLOG_FMT_EXTERNAL) 14 | #if !defined(SPDLOG_COMPILED_LIB) && !defined(FMT_HEADER_ONLY) 15 | #define FMT_HEADER_ONLY 16 | #endif 17 | #ifndef FMT_USE_WINDOWS_H 18 | #define FMT_USE_WINDOWS_H 0 19 | #endif 20 | // enable the 'n' flag in for backward compatibility with fmt 6.x 21 | #define FMT_DEPRECATED_N_SPECIFIER 22 | #include 23 | #include 24 | #else // SPDLOG_FMT_EXTERNAL is defined - use external fmtlib 25 | #include 26 | #include 27 | #endif -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/fmt/ostr.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright(c) 2016 Gabi Melman. 3 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 4 | // 5 | 6 | #pragma once 7 | // 8 | // include bundled or external copy of fmtlib's ostream support 9 | // 10 | 11 | #if 0 // !defined(SPDLOG_FMT_EXTERNAL) 12 | #ifdef SPDLOG_HEADER_ONLY 13 | #ifndef FMT_HEADER_ONLY 14 | #define FMT_HEADER_ONLY 15 | #endif 16 | #endif 17 | #include 18 | #else 19 | #include 20 | #endif 21 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/formatter.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | #include 8 | 9 | namespace spdlog { 10 | 11 | class formatter 12 | { 13 | public: 14 | virtual ~formatter() = default; 15 | virtual void format(const details::log_msg &msg, memory_buf_t &dest) = 0; 16 | virtual std::unique_ptr clone() const = 0; 17 | }; 18 | } // namespace spdlog 19 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/fwd.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | namespace spdlog { 7 | class logger; 8 | class formatter; 9 | 10 | namespace sinks { 11 | class sink; 12 | } 13 | 14 | } // namespace spdlog 15 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/sinks/base_sink-inl.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #ifndef SPDLOG_HEADER_ONLY 7 | #include 8 | #endif 9 | 10 | #include 11 | #include 12 | 13 | #include 14 | 15 | template 16 | SPDLOG_INLINE spdlog::sinks::base_sink::base_sink() 17 | : formatter_{details::make_unique()} 18 | {} 19 | 20 | template 21 | SPDLOG_INLINE spdlog::sinks::base_sink::base_sink(std::unique_ptr formatter) 22 | : formatter_{std::move(formatter)} 23 | {} 24 | 25 | template 26 | void SPDLOG_INLINE spdlog::sinks::base_sink::log(const details::log_msg &msg) 27 | { 28 | std::lock_guard lock(mutex_); 29 | sink_it_(msg); 30 | } 31 | 32 | template 33 | void SPDLOG_INLINE spdlog::sinks::base_sink::flush() 34 | { 35 | std::lock_guard lock(mutex_); 36 | flush_(); 37 | } 38 | 39 | template 40 | void SPDLOG_INLINE spdlog::sinks::base_sink::set_pattern(const std::string &pattern) 41 | { 42 | std::lock_guard lock(mutex_); 43 | set_pattern_(pattern); 44 | } 45 | 46 | template 47 | void SPDLOG_INLINE spdlog::sinks::base_sink::set_formatter(std::unique_ptr sink_formatter) 48 | { 49 | std::lock_guard lock(mutex_); 50 | set_formatter_(std::move(sink_formatter)); 51 | } 52 | 53 | template 54 | void SPDLOG_INLINE spdlog::sinks::base_sink::set_pattern_(const std::string &pattern) 55 | { 56 | set_formatter_(details::make_unique(pattern)); 57 | } 58 | 59 | template 60 | void SPDLOG_INLINE spdlog::sinks::base_sink::set_formatter_(std::unique_ptr sink_formatter) 61 | { 62 | formatter_ = std::move(sink_formatter); 63 | } 64 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/sinks/base_sink.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | // 6 | // base sink templated over a mutex (either dummy or real) 7 | // concrete implementation should override the sink_it_() and flush_() methods. 8 | // locking is taken care of in this class - no locking needed by the 9 | // implementers.. 10 | // 11 | 12 | #include 13 | #include 14 | #include 15 | 16 | namespace spdlog { 17 | namespace sinks { 18 | template 19 | class base_sink : public sink 20 | { 21 | public: 22 | base_sink(); 23 | explicit base_sink(std::unique_ptr formatter); 24 | ~base_sink() override = default; 25 | 26 | base_sink(const base_sink &) = delete; 27 | base_sink(base_sink &&) = delete; 28 | 29 | base_sink &operator=(const base_sink &) = delete; 30 | base_sink &operator=(base_sink &&) = delete; 31 | 32 | void log(const details::log_msg &msg) final; 33 | void flush() final; 34 | void set_pattern(const std::string &pattern) final; 35 | void set_formatter(std::unique_ptr sink_formatter) final; 36 | 37 | protected: 38 | // sink formatter 39 | std::unique_ptr formatter_; 40 | Mutex mutex_; 41 | 42 | virtual void sink_it_(const details::log_msg &msg) = 0; 43 | virtual void flush_() = 0; 44 | virtual void set_pattern_(const std::string &pattern); 45 | virtual void set_formatter_(std::unique_ptr sink_formatter); 46 | }; 47 | } // namespace sinks 48 | } // namespace spdlog 49 | 50 | #ifdef SPDLOG_HEADER_ONLY 51 | #include "base_sink-inl.h" 52 | #endif 53 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/sinks/basic_file_sink-inl.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #ifndef SPDLOG_HEADER_ONLY 7 | #include 8 | #endif 9 | 10 | #include 11 | #include 12 | 13 | namespace spdlog { 14 | namespace sinks { 15 | 16 | template 17 | SPDLOG_INLINE basic_file_sink::basic_file_sink(const filename_t &filename, bool truncate) 18 | { 19 | file_helper_.open(filename, truncate); 20 | } 21 | 22 | template 23 | SPDLOG_INLINE const filename_t &basic_file_sink::filename() const 24 | { 25 | return file_helper_.filename(); 26 | } 27 | 28 | template 29 | SPDLOG_INLINE void basic_file_sink::sink_it_(const details::log_msg &msg) 30 | { 31 | memory_buf_t formatted; 32 | base_sink::formatter_->format(msg, formatted); 33 | file_helper_.write(formatted); 34 | } 35 | 36 | template 37 | SPDLOG_INLINE void basic_file_sink::flush_() 38 | { 39 | file_helper_.flush(); 40 | } 41 | 42 | } // namespace sinks 43 | } // namespace spdlog 44 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/sinks/basic_file_sink.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | #include 8 | #include 9 | #include 10 | 11 | #include 12 | #include 13 | 14 | namespace spdlog { 15 | namespace sinks { 16 | /* 17 | * Trivial file sink with single file as target 18 | */ 19 | template 20 | class basic_file_sink final : public base_sink 21 | { 22 | public: 23 | explicit basic_file_sink(const filename_t &filename, bool truncate = false); 24 | const filename_t &filename() const; 25 | 26 | protected: 27 | void sink_it_(const details::log_msg &msg) override; 28 | void flush_() override; 29 | 30 | private: 31 | details::file_helper file_helper_; 32 | }; 33 | 34 | using basic_file_sink_mt = basic_file_sink; 35 | using basic_file_sink_st = basic_file_sink; 36 | 37 | } // namespace sinks 38 | 39 | // 40 | // factory functions 41 | // 42 | template 43 | inline std::shared_ptr basic_logger_mt(const std::string &logger_name, const filename_t &filename, bool truncate = false) 44 | { 45 | return Factory::template create(logger_name, filename, truncate); 46 | } 47 | 48 | template 49 | inline std::shared_ptr basic_logger_st(const std::string &logger_name, const filename_t &filename, bool truncate = false) 50 | { 51 | return Factory::template create(logger_name, filename, truncate); 52 | } 53 | 54 | } // namespace spdlog 55 | 56 | #ifdef SPDLOG_HEADER_ONLY 57 | #include "basic_file_sink-inl.h" 58 | #endif -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/sinks/msvc_sink.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2016 Alexander Dalshov. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #if defined(_WIN32) 7 | 8 | #include 9 | #include 10 | 11 | #include 12 | #include 13 | 14 | 15 | // Avoid including windows.h (https://stackoverflow.com/a/30741042) 16 | extern "C" __declspec(dllimport) void __stdcall OutputDebugStringA(const char *lpOutputString); 17 | 18 | namespace spdlog { 19 | namespace sinks { 20 | /* 21 | * MSVC sink (logging using OutputDebugStringA) 22 | */ 23 | template 24 | class msvc_sink : public base_sink 25 | { 26 | public: 27 | msvc_sink() = default; 28 | 29 | protected: 30 | void sink_it_(const details::log_msg &msg) override 31 | { 32 | memory_buf_t formatted; 33 | base_sink::formatter_->format(msg, formatted); 34 | OutputDebugStringA(fmt::to_string(formatted).c_str()); 35 | } 36 | 37 | void flush_() override {} 38 | }; 39 | 40 | using msvc_sink_mt = msvc_sink; 41 | using msvc_sink_st = msvc_sink; 42 | 43 | using windebug_sink_mt = msvc_sink_mt; 44 | using windebug_sink_st = msvc_sink_st; 45 | 46 | } // namespace sinks 47 | } // namespace spdlog 48 | 49 | #endif 50 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/sinks/null_sink.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | #include 8 | #include 9 | 10 | #include 11 | 12 | namespace spdlog { 13 | namespace sinks { 14 | 15 | template 16 | class null_sink : public base_sink 17 | { 18 | protected: 19 | void sink_it_(const details::log_msg &) override {} 20 | void flush_() override {} 21 | }; 22 | 23 | using null_sink_mt = null_sink; 24 | using null_sink_st = null_sink; 25 | 26 | } // namespace sinks 27 | 28 | template 29 | inline std::shared_ptr null_logger_mt(const std::string &logger_name) 30 | { 31 | auto null_logger = Factory::template create(logger_name); 32 | null_logger->set_level(level::off); 33 | return null_logger; 34 | } 35 | 36 | template 37 | inline std::shared_ptr null_logger_st(const std::string &logger_name) 38 | { 39 | auto null_logger = Factory::template create(logger_name); 40 | null_logger->set_level(level::off); 41 | return null_logger; 42 | } 43 | 44 | } // namespace spdlog 45 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/sinks/ostream_sink.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | #include 8 | 9 | #include 10 | #include 11 | 12 | namespace spdlog { 13 | namespace sinks { 14 | template 15 | class ostream_sink final : public base_sink 16 | { 17 | public: 18 | explicit ostream_sink(std::ostream &os, bool force_flush = false) 19 | : ostream_(os) 20 | , force_flush_(force_flush) 21 | {} 22 | ostream_sink(const ostream_sink &) = delete; 23 | ostream_sink &operator=(const ostream_sink &) = delete; 24 | 25 | protected: 26 | void sink_it_(const details::log_msg &msg) override 27 | { 28 | memory_buf_t formatted; 29 | base_sink::formatter_->format(msg, formatted); 30 | ostream_.write(formatted.data(), static_cast(formatted.size())); 31 | if (force_flush_) 32 | { 33 | ostream_.flush(); 34 | } 35 | } 36 | 37 | void flush_() override 38 | { 39 | ostream_.flush(); 40 | } 41 | 42 | std::ostream &ostream_; 43 | bool force_flush_; 44 | }; 45 | 46 | using ostream_sink_mt = ostream_sink; 47 | using ostream_sink_st = ostream_sink; 48 | 49 | } // namespace sinks 50 | } // namespace spdlog 51 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/sinks/ringbuffer_sink.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include "spdlog/sinks/base_sink.h" 7 | #include "spdlog/details/circular_q.h" 8 | #include "spdlog/details/log_msg_buffer.h" 9 | #include "spdlog/details/null_mutex.h" 10 | 11 | #include 12 | #include 13 | #include 14 | 15 | namespace spdlog { 16 | namespace sinks { 17 | /* 18 | * Ring buffer sink 19 | */ 20 | template 21 | class ringbuffer_sink final : public base_sink 22 | { 23 | public: 24 | explicit ringbuffer_sink(size_t n_items) 25 | : q_{n_items} 26 | {} 27 | 28 | std::vector last_raw(size_t lim = 0) 29 | { 30 | std::lock_guard lock(base_sink::mutex_); 31 | auto items_available = q_.size(); 32 | auto n_items = lim > 0 ? (std::min)(lim, items_available) : items_available; 33 | std::vector ret; 34 | ret.reserve(n_items); 35 | for (size_t i = (items_available - n_items); i < items_available; i++) 36 | { 37 | ret.push_back(q_.at(i)); 38 | } 39 | return ret; 40 | } 41 | 42 | std::vector last_formatted(size_t lim = 0) 43 | { 44 | std::lock_guard lock(base_sink::mutex_); 45 | auto items_available = q_.size(); 46 | auto n_items = lim > 0 ? (std::min)(lim, items_available) : items_available; 47 | std::vector ret; 48 | ret.reserve(n_items); 49 | for (size_t i = (items_available - n_items); i < items_available; i++) 50 | { 51 | memory_buf_t formatted; 52 | base_sink::formatter_->format(q_.at(i), formatted); 53 | ret.push_back(fmt::to_string(formatted)); 54 | } 55 | return ret; 56 | } 57 | 58 | protected: 59 | void sink_it_(const details::log_msg &msg) override 60 | { 61 | q_.push_back(details::log_msg_buffer{msg}); 62 | } 63 | void flush_() override {} 64 | 65 | private: 66 | details::circular_q q_; 67 | }; 68 | 69 | using ringbuffer_sink_mt = ringbuffer_sink; 70 | using ringbuffer_sink_st = ringbuffer_sink; 71 | 72 | } // namespace sinks 73 | 74 | } // namespace spdlog 75 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/sinks/rotating_file_sink.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | #include 8 | #include 9 | #include 10 | 11 | #include 12 | #include 13 | #include 14 | 15 | namespace spdlog { 16 | namespace sinks { 17 | 18 | // 19 | // Rotating file sink based on size 20 | // 21 | template 22 | class rotating_file_sink final : public base_sink 23 | { 24 | public: 25 | rotating_file_sink(filename_t base_filename, std::size_t max_size, std::size_t max_files, bool rotate_on_open = false); 26 | static filename_t calc_filename(const filename_t &filename, std::size_t index); 27 | filename_t filename(); 28 | 29 | protected: 30 | void sink_it_(const details::log_msg &msg) override; 31 | void flush_() override; 32 | 33 | private: 34 | // Rotate files: 35 | // log.txt -> log.1.txt 36 | // log.1.txt -> log.2.txt 37 | // log.2.txt -> log.3.txt 38 | // log.3.txt -> delete 39 | void rotate_(); 40 | 41 | // delete the target if exists, and rename the src file to target 42 | // return true on success, false otherwise. 43 | bool rename_file_(const filename_t &src_filename, const filename_t &target_filename); 44 | 45 | filename_t base_filename_; 46 | std::size_t max_size_; 47 | std::size_t max_files_; 48 | std::size_t current_size_; 49 | details::file_helper file_helper_; 50 | }; 51 | 52 | using rotating_file_sink_mt = rotating_file_sink; 53 | using rotating_file_sink_st = rotating_file_sink; 54 | 55 | } // namespace sinks 56 | 57 | // 58 | // factory functions 59 | // 60 | 61 | template 62 | inline std::shared_ptr rotating_logger_mt( 63 | const std::string &logger_name, const filename_t &filename, size_t max_file_size, size_t max_files, bool rotate_on_open = false) 64 | { 65 | return Factory::template create(logger_name, filename, max_file_size, max_files, rotate_on_open); 66 | } 67 | 68 | template 69 | inline std::shared_ptr rotating_logger_st( 70 | const std::string &logger_name, const filename_t &filename, size_t max_file_size, size_t max_files, bool rotate_on_open = false) 71 | { 72 | return Factory::template create(logger_name, filename, max_file_size, max_files, rotate_on_open); 73 | } 74 | } // namespace spdlog 75 | 76 | #ifdef SPDLOG_HEADER_ONLY 77 | #include "rotating_file_sink-inl.h" 78 | #endif 79 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/sinks/sink-inl.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #ifndef SPDLOG_HEADER_ONLY 7 | #include 8 | #endif 9 | 10 | #include 11 | 12 | SPDLOG_INLINE bool spdlog::sinks::sink::should_log(spdlog::level::level_enum msg_level) const 13 | { 14 | return msg_level >= level_.load(std::memory_order_relaxed); 15 | } 16 | 17 | SPDLOG_INLINE void spdlog::sinks::sink::set_level(level::level_enum log_level) 18 | { 19 | level_.store(log_level, std::memory_order_relaxed); 20 | } 21 | 22 | SPDLOG_INLINE spdlog::level::level_enum spdlog::sinks::sink::level() const 23 | { 24 | return static_cast(level_.load(std::memory_order_relaxed)); 25 | } 26 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/sinks/sink.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | #include 8 | 9 | namespace spdlog { 10 | 11 | namespace sinks { 12 | class SPDLOG_API sink 13 | { 14 | public: 15 | virtual ~sink() = default; 16 | virtual void log(const details::log_msg &msg) = 0; 17 | virtual void flush() = 0; 18 | virtual void set_pattern(const std::string &pattern) = 0; 19 | virtual void set_formatter(std::unique_ptr sink_formatter) = 0; 20 | 21 | void set_level(level::level_enum log_level); 22 | level::level_enum level() const; 23 | bool should_log(level::level_enum msg_level) const; 24 | 25 | protected: 26 | // sink log level - default is all 27 | level_t level_{level::trace}; 28 | }; 29 | 30 | } // namespace sinks 31 | } // namespace spdlog 32 | 33 | #ifdef SPDLOG_HEADER_ONLY 34 | #include "sink-inl.h" 35 | #endif 36 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/sinks/stdout_color_sinks-inl.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #ifndef SPDLOG_HEADER_ONLY 7 | #include 8 | #endif 9 | 10 | #include 11 | #include 12 | 13 | namespace spdlog { 14 | 15 | template 16 | SPDLOG_INLINE std::shared_ptr stdout_color_mt(const std::string &logger_name, color_mode mode) 17 | { 18 | return Factory::template create(logger_name, mode); 19 | } 20 | 21 | template 22 | SPDLOG_INLINE std::shared_ptr stdout_color_st(const std::string &logger_name, color_mode mode) 23 | { 24 | return Factory::template create(logger_name, mode); 25 | } 26 | 27 | template 28 | SPDLOG_INLINE std::shared_ptr stderr_color_mt(const std::string &logger_name, color_mode mode) 29 | { 30 | return Factory::template create(logger_name, mode); 31 | } 32 | 33 | template 34 | SPDLOG_INLINE std::shared_ptr stderr_color_st(const std::string &logger_name, color_mode mode) 35 | { 36 | return Factory::template create(logger_name, mode); 37 | } 38 | } // namespace spdlog -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/sinks/stdout_color_sinks.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #ifdef _WIN32 7 | #include 8 | #else 9 | #include 10 | #endif 11 | 12 | #include 13 | 14 | namespace spdlog { 15 | namespace sinks { 16 | #ifdef _WIN32 17 | using stdout_color_sink_mt = wincolor_stdout_sink_mt; 18 | using stdout_color_sink_st = wincolor_stdout_sink_st; 19 | using stderr_color_sink_mt = wincolor_stderr_sink_mt; 20 | using stderr_color_sink_st = wincolor_stderr_sink_st; 21 | #else 22 | using stdout_color_sink_mt = ansicolor_stdout_sink_mt; 23 | using stdout_color_sink_st = ansicolor_stdout_sink_st; 24 | using stderr_color_sink_mt = ansicolor_stderr_sink_mt; 25 | using stderr_color_sink_st = ansicolor_stderr_sink_st; 26 | #endif 27 | } // namespace sinks 28 | 29 | template 30 | std::shared_ptr stdout_color_mt(const std::string &logger_name, color_mode mode = color_mode::automatic); 31 | 32 | template 33 | std::shared_ptr stdout_color_st(const std::string &logger_name, color_mode mode = color_mode::automatic); 34 | 35 | template 36 | std::shared_ptr stderr_color_mt(const std::string &logger_name, color_mode mode = color_mode::automatic); 37 | 38 | template 39 | std::shared_ptr stderr_color_st(const std::string &logger_name, color_mode mode = color_mode::automatic); 40 | 41 | } // namespace spdlog 42 | 43 | #ifdef SPDLOG_HEADER_ONLY 44 | #include "stdout_color_sinks-inl.h" 45 | #endif 46 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/sinks/tcp_sink.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | #include 8 | #include 9 | #ifdef _WIN32 10 | #include 11 | #else 12 | #include 13 | #endif 14 | 15 | #include 16 | #include 17 | #include 18 | #include 19 | 20 | #pragma once 21 | 22 | // Simple tcp client sink 23 | // Connects to remote address and send the formatted log. 24 | // Will attempt to reconnect if connection drops. 25 | // If more complicated behaviour is needed (i.e get responses), you can inherit it and override the sink_it_ method. 26 | 27 | namespace spdlog { 28 | namespace sinks { 29 | 30 | struct tcp_sink_config 31 | { 32 | std::string server_host; 33 | int server_port; 34 | bool lazy_connect = false; // if true connect on first log call instead of on construction 35 | 36 | tcp_sink_config(std::string host, int port) 37 | : server_host{std::move(host)} 38 | , server_port{port} 39 | {} 40 | }; 41 | 42 | template 43 | class tcp_sink : public spdlog::sinks::base_sink 44 | { 45 | public: 46 | // connect to tcp host/port or throw if failed 47 | // host can be hostname or ip address 48 | 49 | explicit tcp_sink(tcp_sink_config sink_config) 50 | : config_{std::move(sink_config)} 51 | { 52 | if (!config_.lazy_connect) 53 | { 54 | this->client_.connect(config_.server_host, config_.server_port); 55 | } 56 | } 57 | 58 | ~tcp_sink() override = default; 59 | 60 | protected: 61 | void sink_it_(const spdlog::details::log_msg &msg) override 62 | { 63 | spdlog::memory_buf_t formatted; 64 | spdlog::sinks::base_sink::formatter_->format(msg, formatted); 65 | if (!client_.is_connected()) 66 | { 67 | client_.connect(config_.server_host, config_.server_port); 68 | } 69 | client_.send(formatted.data(), formatted.size()); 70 | } 71 | 72 | void flush_() override {} 73 | tcp_sink_config config_; 74 | details::tcp_client client_; 75 | }; 76 | 77 | using tcp_sink_mt = tcp_sink; 78 | using tcp_sink_st = tcp_sink; 79 | 80 | } // namespace sinks 81 | } // namespace spdlog 82 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/stopwatch.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #include 7 | 8 | // Stopwatch support for spdlog (using std::chrono::steady_clock). 9 | // Displays elapsed seconds since construction as double. 10 | // 11 | // Usage: 12 | // 13 | // spdlog::stopwatch sw; 14 | // ... 15 | // spdlog::debug("Elapsed: {} seconds", sw); => "Elapsed 0.005116733 seconds" 16 | // spdlog::info("Elapsed: {:.6} seconds", sw); => "Elapsed 0.005163 seconds" 17 | // 18 | // 19 | // If other units are needed (e.g. millis instead of double), include "fmt/chrono.h" and use "duration_cast<..>(sw.elapsed())": 20 | // 21 | // #include 22 | //.. 23 | // using std::chrono::duration_cast; 24 | // using std::chrono::milliseconds; 25 | // spdlog::info("Elapsed {}", duration_cast(sw.elapsed())); => "Elapsed 5ms" 26 | 27 | namespace spdlog { 28 | class stopwatch 29 | { 30 | using clock = std::chrono::steady_clock; 31 | std::chrono::time_point start_tp_; 32 | 33 | public: 34 | stopwatch() 35 | : start_tp_{clock::now()} 36 | {} 37 | 38 | std::chrono::duration elapsed() const 39 | { 40 | return std::chrono::duration(clock::now() - start_tp_); 41 | } 42 | 43 | void reset() 44 | { 45 | start_tp_ = clock ::now(); 46 | } 47 | }; 48 | } // namespace spdlog 49 | 50 | // Support for fmt formatting (e.g. "{:012.9}" or just "{}") 51 | namespace fmt { 52 | template<> 53 | struct formatter : formatter 54 | { 55 | template 56 | auto format(const spdlog::stopwatch &sw, FormatContext &ctx) -> decltype(ctx.out()) 57 | { 58 | return formatter::format(sw.elapsed().count(), ctx); 59 | } 60 | }; 61 | } // namespace fmt 62 | -------------------------------------------------------------------------------- /extern/spdlog-1.8.5/spdlog/version.h: -------------------------------------------------------------------------------- 1 | // Copyright(c) 2015-present, Gabi Melman & spdlog contributors. 2 | // Distributed under the MIT License (http://opensource.org/licenses/MIT) 3 | 4 | #pragma once 5 | 6 | #define SPDLOG_VER_MAJOR 1 7 | #define SPDLOG_VER_MINOR 8 8 | #define SPDLOG_VER_PATCH 5 9 | 10 | #define SPDLOG_VERSION (SPDLOG_VER_MAJOR * 10000 + SPDLOG_VER_MINOR * 100 + SPDLOG_VER_PATCH) 11 | -------------------------------------------------------------------------------- /include/abstract_singleton.hpp: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | 5 | template 6 | class CSingleton 7 | { 8 | static T * ms_singleton; 9 | 10 | public: 11 | CSingleton() 12 | { 13 | if (ms_singleton) 14 | MessageBoxA(nullptr, typeid(T).name(), "CSingleton() DECLARED MORE THAN ONCE", MB_ICONEXCLAMATION | MB_OK); 15 | 16 | assert(!ms_singleton); 17 | ms_singleton = static_cast(this); 18 | } 19 | 20 | virtual ~CSingleton() 21 | { 22 | if (!ms_singleton) 23 | MessageBoxA(nullptr, typeid(T).name(), "~CSingleton() FREED AT RUNTIME", MB_ICONEXCLAMATION | MB_OK); 24 | 25 | assert(ms_singleton); 26 | ms_singleton = nullptr; 27 | } 28 | 29 | CSingleton(const CSingleton&) = delete; 30 | CSingleton(CSingleton&&) noexcept = delete; 31 | CSingleton& operator=(const CSingleton&) = delete; 32 | CSingleton& operator=(CSingleton&&) noexcept = delete; 33 | 34 | __forceinline static T & Instance() 35 | { 36 | if (!ms_singleton) 37 | MessageBoxA(nullptr, typeid(T).name(), "CSingleton::Instance() NEVER DECLARED", MB_ICONEXCLAMATION | MB_OK); 38 | 39 | assert(ms_singleton); 40 | return (*ms_singleton); 41 | } 42 | 43 | __forceinline static T * InstancePtr() 44 | { 45 | return (ms_singleton); 46 | } 47 | }; 48 | 49 | template 50 | T * CSingleton::ms_singleton = nullptr; 51 | -------------------------------------------------------------------------------- /include/application.hpp: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "abstract_singleton.hpp" 3 | #include "window.hpp" 4 | #include "main_ui.hpp" 5 | #include "sys_check.hpp" 6 | #include "i18n.hpp" 7 | #include 8 | 9 | namespace Win11SysCheck 10 | { 11 | class CApplication : public CSingleton 12 | { 13 | public: 14 | CApplication(int argc, char* argv[]); 15 | virtual ~CApplication(); 16 | 17 | void Destroy(); 18 | int MainRoutine(); 19 | 20 | bool OpenWebPage(const std::string& stAddress); 21 | 22 | auto GetWindow() const { return m_spWND.get(); }; 23 | auto GetUI() const { return m_spUI.get(); }; 24 | auto GetI18N() const { return m_spI18N.get(); }; 25 | auto GetSysCheck() const { return m_spSysCheck.get(); }; 26 | auto GetConfigFile() { return m_pConfigFile; }; 27 | auto& GetConfigContext() { return m_pConfigContext; }; 28 | 29 | private: 30 | std::shared_ptr m_spWND; 31 | std::shared_ptr m_spUI; 32 | std::shared_ptr m_spI18N; 33 | std::shared_ptr m_spSysCheck; 34 | mINI::INIFile m_pConfigFile; 35 | mINI::INIStructure m_pConfigContext; 36 | }; 37 | }; 38 | -------------------------------------------------------------------------------- /include/basic_log.hpp: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | #include 5 | #include 6 | 7 | namespace Win11SysCheck 8 | { 9 | static void FileLog(const std::string& stFileName, const std::string& stLogData) 10 | { 11 | std::ofstream f(stFileName.c_str(), std::ofstream::out | std::ofstream::app); 12 | f << stLogData.c_str() << std::endl; 13 | f.close(); 14 | } 15 | 16 | static void FileLogf(const std::string& stFileName, const char* c_szFormat, ...) 17 | { 18 | char szBuffer[8192] = { 0 }; 19 | 20 | va_list vaArgList; 21 | va_start(vaArgList, c_szFormat); 22 | vsprintf_s(szBuffer, c_szFormat, vaArgList); 23 | va_end(vaArgList); 24 | 25 | FileLog(stFileName.c_str(), szBuffer); 26 | } 27 | 28 | static void DebugLog(const char* c_szLogData) 29 | { 30 | OutputDebugStringA(c_szLogData); 31 | } 32 | 33 | static void DebugLogf(const char* c_szFormat, ...) 34 | { 35 | char szBuffer[8192] = { 0 }; 36 | 37 | va_list vaArgList; 38 | va_start(vaArgList, c_szFormat); 39 | vsprintf_s(szBuffer, c_szFormat, vaArgList); 40 | va_end(vaArgList); 41 | 42 | DebugLog(szBuffer); 43 | } 44 | 45 | static void ConsoleLog(const char* c_szLogData) 46 | { 47 | fputs(c_szLogData, stdout); 48 | } 49 | 50 | static void ConsoleLogf(const char* c_szFormat, ...) 51 | { 52 | char szBuffer[8192] = { 0 }; 53 | 54 | va_list vaArgList; 55 | va_start(vaArgList, c_szFormat); 56 | vsprintf_s(szBuffer, c_szFormat, vaArgList); 57 | va_end(vaArgList); 58 | 59 | ConsoleLog(szBuffer); 60 | } 61 | 62 | static void Logf(const std::string& stFileName, const char* c_szFormat, ...) 63 | { 64 | char szBuffer[8192] = { 0 }; 65 | 66 | va_list vaArgList; 67 | va_start(vaArgList, c_szFormat); 68 | vsprintf_s(szBuffer, c_szFormat, vaArgList); 69 | va_end(vaArgList); 70 | 71 | #ifdef _DEBUG 72 | DebugLog(szBuffer); 73 | #endif 74 | ConsoleLog(szBuffer); 75 | FileLog(stFileName.c_str(), szBuffer); 76 | } 77 | } 78 | -------------------------------------------------------------------------------- /include/d3d_impl.hpp: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "abstract_singleton.hpp" 3 | #include 4 | 5 | namespace Win11SysCheck 6 | { 7 | class CD3DManager : public CSingleton 8 | { 9 | public: 10 | CD3DManager(); 11 | virtual ~CD3DManager(); 12 | 13 | void CreateDevice(); 14 | void CleanupDevice(); 15 | void ResetDevice(); 16 | 17 | void SetupImGui(); 18 | void CleanupImGui(); 19 | 20 | void OnRenderFrame(); 21 | 22 | void SetWindow(HWND hWnd) { m_hWnd = hWnd; }; 23 | void SetPosition(int width, int height); 24 | 25 | auto GetD3D() const { return m_pD3DEx; }; 26 | auto GetDevice() const { return m_pD3DDevEx; }; 27 | auto GetParameters() const { return m_pD3DParams; }; 28 | auto GetWindowHandle() const { return m_hWnd; }; 29 | 30 | private: 31 | bool m_bInitialized; 32 | HWND m_hWnd; 33 | 34 | ImVec4 m_v4ClearColor; 35 | LPDIRECT3D9EX m_pD3DEx; 36 | LPDIRECT3DDEVICE9EX m_pD3DDevEx; 37 | D3DPRESENT_PARAMETERS m_pD3DParams; 38 | }; 39 | }; 40 | -------------------------------------------------------------------------------- /include/error_handler.hpp: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | 4 | namespace Win11SysCheck 5 | { 6 | class CErrorHandler 7 | { 8 | public: 9 | CErrorHandler(DWORD error_code = ::GetLastError()) : 10 | m_error_code(error_code), m_sys_err(std::system_error(std::error_code(m_error_code, std::system_category()))) {}; 11 | CErrorHandler(const std::string& message, DWORD error_code = GetLastError()) : 12 | m_error_code(error_code), m_message(message), m_sys_err(std::system_error(std::error_code(m_error_code, std::system_category()), m_message)) {}; 13 | ~CErrorHandler() = default; 14 | 15 | CErrorHandler(const CErrorHandler&) = delete; 16 | CErrorHandler(CErrorHandler&&) noexcept = delete; 17 | CErrorHandler& operator=(const CErrorHandler&) = delete; 18 | CErrorHandler& operator=(CErrorHandler&&) noexcept = delete; 19 | 20 | auto code() const { return m_error_code; }; 21 | auto msg() const { return m_message; }; 22 | auto what() const { return m_sys_err.what(); } 23 | 24 | private: 25 | DWORD m_error_code; 26 | std::string m_message; 27 | std::system_error m_sys_err; 28 | }; 29 | }; 30 | -------------------------------------------------------------------------------- /include/i18n.hpp: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "abstract_singleton.hpp" 3 | #include "pch.hpp" 4 | #include "sys_check.hpp" 5 | 6 | namespace Win11SysCheck 7 | { 8 | struct SI18nContext 9 | { 10 | uint8_t phase{ 0 }; 11 | uint32_t index{ 0 }; 12 | std::wstring context{ L"" }; 13 | }; 14 | 15 | enum class EPhase : uint8_t 16 | { 17 | PHASE_UNDEFINED, 18 | PHASE_COMMON, 19 | PHASE_MENU_TYPE, 20 | PHASE_SYSTEM_DETAIL 21 | }; 22 | 23 | enum class ECommonTextID : uint8_t 24 | { 25 | TEXT_ID_UNDEFINED, 26 | TEXT_ID_UNKNOWN, 27 | TEXT_ID_INITIALIZING, 28 | TEXT_ID_COMPATIBLE_OK, 29 | TEXT_ID_COMPATIBLE_FAIL, 30 | TEXT_ID_STATUS, 31 | TEXT_ID_DETAILS, 32 | TEXT_ID_SAVE_RESULT, 33 | TEXT_ID_DARK_MODE, 34 | TEXT_ID_CAPABLE, 35 | TEXT_ID_ENABLED, 36 | TEXT_ID_DISABLED, 37 | TEXT_ID_VERSION, 38 | TEXT_ID_BUILD, 39 | TEXT_ID_RESULT, 40 | TEXT_ID_CAN_UPGRADABLE, 41 | TEXT_ID_CAN_NOT_UPGRADABLE, 42 | TEXT_ID_EXPORT_SUCCESS, 43 | TEXT_ID_EXPORT_FAIL, 44 | TEXT_ID_ABOUT_WIN_11, 45 | TEXT_ID_SYSTEM_SPEC_LINK, 46 | TEXT_ID_SUPPORTED_CPU_TITLE 47 | }; 48 | enum class ESystemDetailID : uint8_t 49 | { 50 | SYSTEM_DETAIL_ID_UNDEFINED, 51 | SYSTEM_DETAIL_OS_VERSION, 52 | SYSTEM_DETAIL_OS_SP_VERSION, 53 | SYSTEM_DETAIL_OS_BUILD_VERSION, 54 | SYSTEM_DETAIL_OS_PLATFORM_ID, 55 | SYSTEM_DETAIL_OS_PRODUCT_TYPE, 56 | SYSTEM_DETAIL_BOOT_ENVIRONMENT, 57 | SYSTEM_DETAIL_BOOT_SECURE_BOOT, 58 | SYSTEM_DETAIL_BOOT_TPM, 59 | SYSTEM_DETAIL_CPU_NAME, 60 | SYSTEM_DETAIL_CPU_DETAILS, 61 | SYSTEM_DETAIL_CPU_ARCH, 62 | SYSTEM_DETAIL_CPU_ACTIVE_PROCESSOR_COUNT, 63 | SYSTEM_DETAIL_CPU_PROCESSOR_COUNT, 64 | SYSTEM_DETAIL_RAM_TOTAL 65 | }; 66 | 67 | class CI18N : public CSingleton 68 | { 69 | public: 70 | CI18N(); 71 | virtual ~CI18N(); 72 | 73 | bool Initialize(); 74 | void Destroy(); 75 | 76 | std::wstring GetLocalizedText(EPhase phase, uint8_t index); 77 | std::string GetCommonLocalizedText(ECommonTextID nID); 78 | std::string GetMenuTypeLocalizedText(EMenuType nType); 79 | std::string GetSystemDetailsLocalizedText(ESystemDetailID nID); 80 | 81 | protected: 82 | std::string __ToAnsi(const std::wstring& in); 83 | 84 | private: 85 | std::map m_mapStatuses; 86 | std::vector > m_vI18nData; 87 | }; 88 | }; 89 | -------------------------------------------------------------------------------- /include/log_helper.hpp: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "abstract_singleton.hpp" 3 | #include "basic_log.hpp" 4 | #include 5 | #include 6 | #include 7 | #include 8 | #include 9 | #include 10 | 11 | namespace Win11SysCheck 12 | { 13 | static constexpr auto CUSTOM_LOG_FILENAME = "Win11SysCheck.log"; 14 | static constexpr auto CUSTOM_LOG_ERROR_FILENAME = "Win11SysCheckError.log"; 15 | 16 | enum ELogLevels 17 | { 18 | LL_SYS, 19 | LL_ERR, 20 | LL_CRI, 21 | LL_WARN, 22 | LL_DEV, 23 | LL_TRACE 24 | }; 25 | 26 | class CLogHelper : public CSingleton 27 | { 28 | public: 29 | CLogHelper() = default; 30 | CLogHelper(const std::string& stLoggerName, const std::string& stFileName); 31 | 32 | void Log(int32_t nLevel, const std::string& stBuffer); 33 | void LogError(const std::string& stMessage, bool bFatal = true, bool bShowLastError = true); 34 | 35 | private: 36 | mutable std::recursive_mutex m_pkMtMutex; 37 | 38 | std::shared_ptr m_pkLoggerImpl; 39 | std::string m_stLoggerName; 40 | std::string m_stFileName; 41 | }; 42 | } 43 | -------------------------------------------------------------------------------- /include/main_ui.hpp: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "abstract_singleton.hpp" 3 | #include "sys_check.hpp" 4 | 5 | namespace Win11SysCheck::gui 6 | { 7 | class CMainUI : public CSingleton 8 | { 9 | public: 10 | CMainUI(); 11 | virtual ~CMainUI(); 12 | 13 | std::string GetMenuTypeIconText(EMenuType nType); 14 | 15 | void OnDraw(); 16 | 17 | auto IsOpenPtr() { return &m_bIsOpen; }; 18 | auto IsOpen() const { return m_bIsOpen; }; 19 | 20 | void SetDarkModeEnabled(const bool bEnabled) { m_bDarkModeEnabled = bEnabled; }; 21 | 22 | private: 23 | EMenuType m_nMenuType; 24 | bool m_bIsOpen; 25 | bool m_bDarkModeEnabled; 26 | }; 27 | }; 28 | -------------------------------------------------------------------------------- /include/pch.hpp: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #define _CRT_SECURE_NO_WARNINGS 3 | #include 4 | #include 5 | #include 6 | #include 7 | 8 | #define DIRECTINPUT_VERSION 0x0800 9 | #include 10 | #include 11 | #include 12 | #include 13 | #include 14 | #include 15 | #include 16 | #include 17 | #include 18 | #include 19 | #include 20 | #include 21 | #include 22 | #include 23 | #include 24 | #include 25 | #include 26 | #include 27 | #include 28 | #include 29 | #include 30 | 31 | #include 32 | #include 33 | using namespace std::string_literals; 34 | 35 | #include 36 | #include 37 | #include 38 | #include 39 | #include 40 | #include 41 | using namespace rapidjson; 42 | 43 | #define CONFIG_FILE_NAME "./config.ini" 44 | #define STATUS_SUCCESS ((NTSTATUS)0x00000000L) 45 | #define SystemBootEnvironmentInformation 90 46 | #define SystemSecureBootInformation 145 47 | #define SAFE_RELEASE(p) { if(p) { (p)->Release(); (p)=NULL; } } 48 | #ifndef PF_ARM_V81_ATOMIC_INSTRUCTIONS_AVAILABLE 49 | #define PF_ARM_V81_ATOMIC_INSTRUCTIONS_AVAILABLE 34 50 | #endif 51 | 52 | typedef struct _SYSTEM_BOOT_ENVIRONMENT_INFORMATION 53 | { 54 | GUID BootIdentifier; 55 | FIRMWARE_TYPE FirmwareType; 56 | ULONGLONG BootFlags; 57 | } SYSTEM_BOOT_ENVIRONMENT_INFORMATION, * PSYSTEM_BOOT_ENVIRONMENT_INFORMATION; 58 | typedef struct _SYSTEM_SECUREBOOT_INFORMATION 59 | { 60 | BOOLEAN SecureBootEnabled; 61 | BOOLEAN SecureBootCapable; 62 | } SYSTEM_SECUREBOOT_INFORMATION, * PSYSTEM_SECUREBOOT_INFORMATION; 63 | typedef struct _PROCESSOR_POWER_INFORMATION { 64 | ULONG Number; 65 | ULONG MaxMhz; 66 | ULONG CurrentMhz; 67 | ULONG MhzLimit; 68 | ULONG MaxIdleState; 69 | ULONG CurrentIdleState; 70 | } PROCESSOR_POWER_INFORMATION, * PPROCESSOR_POWER_INFORMATION; 71 | 72 | struct DISPLAY_DEVICE_INFORMATION 73 | { 74 | char szDescription[255]{ '\0' }; 75 | char szDriverModel[255]{ '\0' }; 76 | }; 77 | struct DIRECTX_VERSION_INFORMATION 78 | { 79 | int nMajorVersion{ 0 }; 80 | int nMinorVersion{ 0 }; 81 | }; 82 | -------------------------------------------------------------------------------- /include/simple_timer.hpp: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | 4 | template 5 | class CSimpleTimer 6 | { 7 | public: 8 | CSimpleTimer() 9 | { 10 | m_tStartPoint = std::chrono::high_resolution_clock::now(); 11 | } 12 | ~CSimpleTimer() = default; 13 | 14 | 15 | size_t diff() 16 | { 17 | return std::chrono::duration_cast(std::chrono::high_resolution_clock::now() - m_tStartPoint).count(); 18 | } 19 | 20 | void reset() 21 | { 22 | m_tStartPoint = std::chrono::high_resolution_clock::now(); 23 | } 24 | 25 | private: 26 | std::chrono::time_point m_tStartPoint; 27 | }; 28 | -------------------------------------------------------------------------------- /include/ui_types.hpp: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | 4 | namespace Win11SysCheck 5 | { 6 | namespace gui 7 | { 8 | class point 9 | { 10 | friend std::ostream& operator <<(std::ostream& stream, point const& pt); 11 | 12 | public: 13 | point(); 14 | point(int x, int y); 15 | 16 | void operator ()(int x, int y); 17 | operator const std::string() const; 18 | 19 | int x; 20 | int y; 21 | }; 22 | 23 | struct size 24 | { 25 | size(); 26 | size(int width, int height); 27 | 28 | int width; 29 | int height; 30 | }; 31 | 32 | struct rectangle : public point, public size 33 | { 34 | rectangle(); 35 | rectangle(int x, int y, int width, int height); 36 | }; 37 | }; 38 | }; 39 | -------------------------------------------------------------------------------- /include/widget.hpp: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include "ui_types.hpp" 4 | 5 | namespace Win11SysCheck 6 | { 7 | namespace gui 8 | { 9 | using TMessageFunction = std::function ; 10 | using TMessagePair = std::pair ; 11 | 12 | class CWidget 13 | { 14 | public: 15 | CWidget(HWND hParentWnd = nullptr, HINSTANCE hInstance = nullptr, bool bIsWindow = false); 16 | ~CWidget(); 17 | 18 | bool Create( 19 | const std::string& stClassName, const std::string& stWidgetName, rectangle& rcRectangle, 20 | DWORD style, DWORD ex_style = 0, HMENU hMenu = nullptr 21 | ); 22 | 23 | void AddMessageHandlers(const std::vector & vMessages); 24 | void RemoveMessageHandler(uint32_t message); 25 | 26 | bool SetText(const std::string& stText) const; 27 | void SetInstance(HINSTANCE hInstance); 28 | void SetVisible(bool bIsVisible); 29 | void SetPosition(int x, int y); 30 | void SetCenterPosition(); 31 | void Show(); 32 | void Hide(); 33 | 34 | HWND GetHandle() const; 35 | HINSTANCE GetInstance() const; 36 | bool IsVisible() const; 37 | int GetScreenWidth() const; 38 | int GetScreenHeight() const; 39 | void GetWindowRect(RECT* pRC); 40 | void GetClientRect(RECT* pRC); 41 | void GetMousePosition(POINT* pPT); 42 | auto GetRect() const { return m_rcCurrRect; }; 43 | 44 | public: 45 | static LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam); 46 | static std::unordered_map m_upWidgets; 47 | 48 | private: 49 | std::unordered_map m_umCustomMessages; 50 | HFONT m_hFont; 51 | HWND m_hWnd; 52 | HWND m_hParentWnd; 53 | HINSTANCE m_hInstance; 54 | rectangle m_rcCurrRect; 55 | WNDPROC m_pOriginalWndProc; 56 | bool m_bIsWindow; 57 | bool m_bVisible; 58 | }; 59 | } 60 | }; 61 | -------------------------------------------------------------------------------- /include/window.hpp: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #undef CreateWindow 3 | #include "abstract_singleton.hpp" 4 | #include "ui_types.hpp" 5 | #include "widget.hpp" 6 | 7 | namespace Win11SysCheck 8 | { 9 | namespace gui 10 | { 11 | class CWindow : public CSingleton , public CWidget 12 | { 13 | public: 14 | CWindow(); 15 | ~CWindow(); 16 | 17 | void Assemble(const std::string& stClassName, const std::string& stWindowName, rectangle rcRectangle, char* szIconName); 18 | void Destroy(); 19 | 20 | bool HasMessage() const; 21 | bool PeekSingleMessage(MSG& msg) const; 22 | void PeekMessageLoop(std::function cb); 23 | 24 | protected: 25 | bool CreateClass(const std::string& stClassName, char* szIconName); 26 | bool CreateWindow(const std::string& stClassName, const std::string& stWindowName, rectangle& rcRectangle); 27 | 28 | void SetMessageHandlers(); 29 | 30 | private: 31 | std::string m_stClassName; 32 | }; 33 | } 34 | }; 35 | -------------------------------------------------------------------------------- /src/entry.cpp: -------------------------------------------------------------------------------- 1 | #include "../include/pch.hpp" 2 | #include "../include/application.hpp" 3 | #include "../include/log_helper.hpp" 4 | #include "../include/d3d_impl.hpp" 5 | 6 | volatile bool g_vbInterrupted{ false }; 7 | 8 | static void OnInterruptHandle(int signal) 9 | { 10 | if (g_vbInterrupted) 11 | return; 12 | g_vbInterrupted = true; 13 | 14 | if (Win11SysCheck::CApplication::InstancePtr()) 15 | Win11SysCheck::CApplication::Instance().Destroy(); 16 | } 17 | 18 | int main(int, char**) 19 | { 20 | #ifndef _DEBUG 21 | ShowWindow(GetConsoleWindow(), SW_HIDE); 22 | #endif 23 | 24 | // Check ImGui version 25 | IMGUI_CHECKVERSION(); 26 | 27 | // Setup signal handlers 28 | std::signal(SIGINT, &OnInterruptHandle); 29 | std::signal(SIGABRT, &OnInterruptHandle); 30 | std::signal(SIGTERM, &OnInterruptHandle); 31 | 32 | // Initialize instances 33 | static Win11SysCheck::CLogHelper s_kLogManager("Win11SysCheck", Win11SysCheck::CUSTOM_LOG_FILENAME); 34 | static Win11SysCheck::CD3DManager s_kD3DManager; 35 | static Win11SysCheck::CApplication s_kApplication(__argc, __argv); 36 | 37 | // Start to main routine 38 | return s_kApplication.MainRoutine(); 39 | } 40 | -------------------------------------------------------------------------------- /src/pch.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mq1n/Win11SysCheck/07cbd77c76559a30e517d7fcdda33fcd77e83396/src/pch.cpp -------------------------------------------------------------------------------- /src/ui_types.cpp: -------------------------------------------------------------------------------- 1 | #include "../include/pch.hpp" 2 | #include "../include/ui_types.hpp" 3 | 4 | namespace Win11SysCheck 5 | { 6 | namespace gui 7 | { 8 | std::ostream& operator <<(std::ostream& stream, const point& pt) 9 | { 10 | stream << static_cast(pt); 11 | return stream; 12 | } 13 | 14 | point::point() : 15 | x(0), y(0) 16 | { 17 | } 18 | point::point(int x_, int y_) : 19 | x(x_), y(y_) 20 | { 21 | } 22 | void point::operator ()(int x_, int y_) 23 | { 24 | this->x = x_; 25 | this->y = y_; 26 | } 27 | point::operator const std::string() const 28 | { 29 | std::stringstream ss; 30 | ss << "(" << this->x << ", " << this->y << ")"; 31 | return ss.str(); 32 | } 33 | 34 | size::size() : 35 | width(0), height(0) 36 | { 37 | } 38 | size::size(int width, int height) : 39 | width(width), height(height) 40 | { 41 | } 42 | 43 | rectangle::rectangle() : 44 | point(0, 0), size(0, 0) 45 | { 46 | } 47 | rectangle::rectangle(int x, int y, int width, int height) : 48 | point(x, y), size(width, height) 49 | { 50 | } 51 | } 52 | }; 53 | --------------------------------------------------------------------------------