From 67f519a95e2e33f95eccaef80e470993bf9987a7 Mon Sep 17 00:00:00 2001 From: Aldrik Ramaekers Date: Sun, 10 Mar 2024 20:05:28 +0100 Subject: add glfw to dependencies list, close #4 --- misc/generated/glfw_LICENSE.h | 79 +++++++++++++++++++++++++++++++++++++++++++ misc/glfw_LICENSE.md | 23 +++++++++++++ src/definitions.cpp | 4 +++ src/definitions.h | 3 ++ src/main.cpp | 7 ++++ 5 files changed, 116 insertions(+) create mode 100644 misc/generated/glfw_LICENSE.h create mode 100644 misc/glfw_LICENSE.md diff --git a/misc/generated/glfw_LICENSE.h b/misc/generated/glfw_LICENSE.h new file mode 100644 index 0000000..26a907f --- /dev/null +++ b/misc/generated/glfw_LICENSE.h @@ -0,0 +1,79 @@ +unsigned char glfw_LICENSE[] = { + 0x43, 0x6f, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, 0x28, 0x63, + 0x29, 0x20, 0x32, 0x30, 0x30, 0x32, 0x2d, 0x32, 0x30, 0x30, 0x36, 0x20, + 0x4d, 0x61, 0x72, 0x63, 0x75, 0x73, 0x20, 0x47, 0x65, 0x65, 0x6c, 0x6e, + 0x61, 0x72, 0x64, 0x0a, 0x0a, 0x43, 0x6f, 0x70, 0x79, 0x72, 0x69, 0x67, + 0x68, 0x74, 0x20, 0x28, 0x63, 0x29, 0x20, 0x32, 0x30, 0x30, 0x36, 0x2d, + 0x32, 0x30, 0x31, 0x39, 0x20, 0x43, 0x61, 0x6d, 0x69, 0x6c, 0x6c, 0x61, + 0x20, 0x4c, 0xc3, 0xb6, 0x77, 0x79, 0x0a, 0x0a, 0x54, 0x68, 0x69, 0x73, + 0x20, 0x73, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, 0x20, 0x69, 0x73, + 0x20, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x64, 0x20, 0x27, 0x61, + 0x73, 0x2d, 0x69, 0x73, 0x27, 0x2c, 0x20, 0x77, 0x69, 0x74, 0x68, 0x6f, + 0x75, 0x74, 0x20, 0x61, 0x6e, 0x79, 0x20, 0x65, 0x78, 0x70, 0x72, 0x65, + 0x73, 0x73, 0x20, 0x6f, 0x72, 0x20, 0x69, 0x6d, 0x70, 0x6c, 0x69, 0x65, + 0x64, 0x0a, 0x77, 0x61, 0x72, 0x72, 0x61, 0x6e, 0x74, 0x79, 0x2e, 0x20, + 0x49, 0x6e, 0x20, 0x6e, 0x6f, 0x20, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x20, + 0x77, 0x69, 0x6c, 0x6c, 0x20, 0x74, 0x68, 0x65, 0x20, 0x61, 0x75, 0x74, + 0x68, 0x6f, 0x72, 0x73, 0x20, 0x62, 0x65, 0x20, 0x68, 0x65, 0x6c, 0x64, + 0x20, 0x6c, 0x69, 0x61, 0x62, 0x6c, 0x65, 0x20, 0x66, 0x6f, 0x72, 0x20, + 0x61, 0x6e, 0x79, 0x20, 0x64, 0x61, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x0a, + 0x61, 0x72, 0x69, 0x73, 0x69, 0x6e, 0x67, 0x20, 0x66, 0x72, 0x6f, 0x6d, + 0x20, 0x74, 0x68, 0x65, 0x20, 0x75, 0x73, 0x65, 0x20, 0x6f, 0x66, 0x20, + 0x74, 0x68, 0x69, 0x73, 0x20, 0x73, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, + 0x65, 0x2e, 0x0a, 0x0a, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, + 0x6f, 0x6e, 0x20, 0x69, 0x73, 0x20, 0x67, 0x72, 0x61, 0x6e, 0x74, 0x65, + 0x64, 0x20, 0x74, 0x6f, 0x20, 0x61, 0x6e, 0x79, 0x6f, 0x6e, 0x65, 0x20, + 0x74, 0x6f, 0x20, 0x75, 0x73, 0x65, 0x20, 0x74, 0x68, 0x69, 0x73, 0x20, + 0x73, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, 0x20, 0x66, 0x6f, 0x72, + 0x20, 0x61, 0x6e, 0x79, 0x20, 0x70, 0x75, 0x72, 0x70, 0x6f, 0x73, 0x65, + 0x2c, 0x0a, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x69, 0x6e, 0x67, 0x20, + 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x72, 0x63, 0x69, 0x61, 0x6c, 0x20, 0x61, + 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2c, + 0x20, 0x61, 0x6e, 0x64, 0x20, 0x74, 0x6f, 0x20, 0x61, 0x6c, 0x74, 0x65, + 0x72, 0x20, 0x69, 0x74, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x72, 0x65, 0x64, + 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x20, 0x69, 0x74, + 0x0a, 0x66, 0x72, 0x65, 0x65, 0x6c, 0x79, 0x2c, 0x20, 0x73, 0x75, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x20, 0x74, 0x6f, 0x20, 0x74, 0x68, 0x65, 0x20, + 0x66, 0x6f, 0x6c, 0x6c, 0x6f, 0x77, 0x69, 0x6e, 0x67, 0x20, 0x72, 0x65, + 0x73, 0x74, 0x72, 0x69, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x3a, 0x0a, + 0x0a, 0x31, 0x2e, 0x20, 0x54, 0x68, 0x65, 0x20, 0x6f, 0x72, 0x69, 0x67, + 0x69, 0x6e, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x69, 0x73, 0x20, 0x73, + 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, 0x20, 0x6d, 0x75, 0x73, 0x74, + 0x20, 0x6e, 0x6f, 0x74, 0x20, 0x62, 0x65, 0x20, 0x6d, 0x69, 0x73, 0x72, + 0x65, 0x70, 0x72, 0x65, 0x73, 0x65, 0x6e, 0x74, 0x65, 0x64, 0x3b, 0x20, + 0x79, 0x6f, 0x75, 0x20, 0x6d, 0x75, 0x73, 0x74, 0x20, 0x6e, 0x6f, 0x74, + 0x0a, 0x20, 0x20, 0x20, 0x63, 0x6c, 0x61, 0x69, 0x6d, 0x20, 0x74, 0x68, + 0x61, 0x74, 0x20, 0x79, 0x6f, 0x75, 0x20, 0x77, 0x72, 0x6f, 0x74, 0x65, + 0x20, 0x74, 0x68, 0x65, 0x20, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, + 0x6c, 0x20, 0x73, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, 0x2e, 0x20, + 0x49, 0x66, 0x20, 0x79, 0x6f, 0x75, 0x20, 0x75, 0x73, 0x65, 0x20, 0x74, + 0x68, 0x69, 0x73, 0x20, 0x73, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, + 0x0a, 0x20, 0x20, 0x20, 0x69, 0x6e, 0x20, 0x61, 0x20, 0x70, 0x72, 0x6f, + 0x64, 0x75, 0x63, 0x74, 0x2c, 0x20, 0x61, 0x6e, 0x20, 0x61, 0x63, 0x6b, + 0x6e, 0x6f, 0x77, 0x6c, 0x65, 0x64, 0x67, 0x6d, 0x65, 0x6e, 0x74, 0x20, + 0x69, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x70, 0x72, 0x6f, 0x64, 0x75, + 0x63, 0x74, 0x20, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x77, 0x6f, 0x75, 0x6c, 0x64, 0x0a, 0x20, + 0x20, 0x20, 0x62, 0x65, 0x20, 0x61, 0x70, 0x70, 0x72, 0x65, 0x63, 0x69, + 0x61, 0x74, 0x65, 0x64, 0x20, 0x62, 0x75, 0x74, 0x20, 0x69, 0x73, 0x20, + 0x6e, 0x6f, 0x74, 0x20, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, + 0x2e, 0x0a, 0x0a, 0x32, 0x2e, 0x20, 0x41, 0x6c, 0x74, 0x65, 0x72, 0x65, + 0x64, 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, 0x76, 0x65, 0x72, + 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x20, 0x6d, 0x75, 0x73, 0x74, 0x20, 0x62, + 0x65, 0x20, 0x70, 0x6c, 0x61, 0x69, 0x6e, 0x6c, 0x79, 0x20, 0x6d, 0x61, + 0x72, 0x6b, 0x65, 0x64, 0x20, 0x61, 0x73, 0x20, 0x73, 0x75, 0x63, 0x68, + 0x2c, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x6d, 0x75, 0x73, 0x74, 0x20, 0x6e, + 0x6f, 0x74, 0x0a, 0x20, 0x20, 0x20, 0x62, 0x65, 0x20, 0x6d, 0x69, 0x73, + 0x72, 0x65, 0x70, 0x72, 0x65, 0x73, 0x65, 0x6e, 0x74, 0x65, 0x64, 0x20, + 0x61, 0x73, 0x20, 0x62, 0x65, 0x69, 0x6e, 0x67, 0x20, 0x74, 0x68, 0x65, + 0x20, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x6c, 0x20, 0x73, 0x6f, + 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, 0x2e, 0x0a, 0x0a, 0x33, 0x2e, 0x20, + 0x54, 0x68, 0x69, 0x73, 0x20, 0x6e, 0x6f, 0x74, 0x69, 0x63, 0x65, 0x20, + 0x6d, 0x61, 0x79, 0x20, 0x6e, 0x6f, 0x74, 0x20, 0x62, 0x65, 0x20, 0x72, + 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x64, 0x20, 0x6f, 0x72, 0x20, 0x61, 0x6c, + 0x74, 0x65, 0x72, 0x65, 0x64, 0x20, 0x66, 0x72, 0x6f, 0x6d, 0x20, 0x61, + 0x6e, 0x79, 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x0a, 0x20, 0x20, + 0x20, 0x64, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x69, 0x6f, + 0x6e, 0x2e, 0x0a, 0x0a +}; +unsigned int glfw_LICENSE_len = 904; diff --git a/misc/glfw_LICENSE.md b/misc/glfw_LICENSE.md new file mode 100644 index 0000000..7494a3f --- /dev/null +++ b/misc/glfw_LICENSE.md @@ -0,0 +1,23 @@ +Copyright (c) 2002-2006 Marcus Geelnard + +Copyright (c) 2006-2019 Camilla Löwy + +This software is provided 'as-is', without any express or implied +warranty. In no event will the authors be held liable for any damages +arising from the use of this software. + +Permission is granted to anyone to use this software for any purpose, +including commercial applications, and to alter it and redistribute it +freely, subject to the following restrictions: + +1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would + be appreciated but is not required. + +2. Altered source versions must be plainly marked as such, and must not + be misrepresented as being the original software. + +3. This notice may not be removed or altered from any source + distribution. + diff --git a/src/definitions.cpp b/src/definitions.cpp index 274e009..9937ec5 100644 --- a/src/definitions.cpp +++ b/src/definitions.cpp @@ -8,6 +8,10 @@ unsigned char* _binary_LICENSE_end = _binary_LICENSE_start + LICENSE_len; unsigned char* _binary_imgui_LICENSE_start = imgui_LICENSE; unsigned char* _binary_imgui_LICENSE_end = imgui_LICENSE + imgui_LICENSE_len; +#include "../misc/generated/glfw_LICENSE.h" +unsigned char* _binary_glfw_LICENSE_start = glfw_LICENSE; +unsigned char* _binary_glfw_LICENSE_end = glfw_LICENSE + glfw_LICENSE_len; + #include "../misc/generated/imfiledialog_LICENSE.h" unsigned char* _binary_imfiledialog_LICENSE_start = imfiledialog_LICENSE; unsigned char* _binary_imfiledialog_LICENSE_end = imfiledialog_LICENSE + imfiledialog_LICENSE_len; diff --git a/src/definitions.h b/src/definitions.h index 96f51ff..d139284 100644 --- a/src/definitions.h +++ b/src/definitions.h @@ -11,6 +11,9 @@ extern unsigned char* _binary_LICENSE_end; extern unsigned char* _binary_imgui_LICENSE_start; extern unsigned char* _binary_imgui_LICENSE_end; +extern unsigned char* _binary_glfw_LICENSE_start; +extern unsigned char* _binary_glfw_LICENSE_end; + extern unsigned char* _binary_imfiledialog_LICENSE_start; extern unsigned char* _binary_imfiledialog_LICENSE_end; diff --git a/src/main.cpp b/src/main.cpp index ac515e5..55487f2 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -99,6 +99,13 @@ static void _ts_create_popups() { ImGui::TreePop(); } + if (ImGui::TreeNode("https://github.com/glfw/glfw")) { + char* license = (char*)_binary_glfw_LICENSE_start; + int64_t license_length = _binary_glfw_LICENSE_end - _binary_glfw_LICENSE_start; + ImGui::Text("%.*s", (int)license_length, license); + ImGui::TreePop(); + } + if (ImGui::TreeNode("https://github.com/nothings/stb/blob/master/stb_image.h")) { ImGui::Text("public domain"); ImGui::TreePop(); -- cgit v1.2.3-70-g09d2