diff options
| author | Aldrik Ramaekers <aldrikboy@gmail.com> | 2024-03-10 11:39:21 +0100 |
|---|---|---|
| committer | Aldrik Ramaekers <aldrikboy@gmail.com> | 2024-03-10 11:39:21 +0100 |
| commit | 31079061f125e7d8c152e3f6459fe2e3ec06a77d (patch) | |
| tree | c6e873ce1f8474cd68357c30e50c9c43d481d7ef | |
| parent | d671ea83612bcb683e675c041392922e66e57e58 (diff) | |
running on osx
| -rw-r--r-- | build_osx.sh | 19 | ||||
| -rw-r--r-- | misc/osx/LICENSE.h | 94 | ||||
| -rw-r--r-- | misc/osx/folder.h | 38 | ||||
| -rw-r--r-- | misc/osx/imfiledialog_LICENSE.h | 92 | ||||
| -rw-r--r-- | misc/osx/imgui_LICENSE.h | 94 | ||||
| -rw-r--r-- | misc/osx/logo_64.h | 102 | ||||
| -rw-r--r-- | misc/osx/search.h | 51 | ||||
| -rw-r--r-- | src/config.h | 2 | ||||
| -rw-r--r-- | src/definitions.cpp | 27 | ||||
| -rw-r--r-- | src/definitions.h | 29 | ||||
| -rw-r--r-- | src/image.h | 2 | ||||
| -rw-r--r-- | src/main.cpp | 2 | ||||
| -rw-r--r-- | src/mutex.h | 2 | ||||
| -rw-r--r-- | src/osx/main_osx.cpp | 304 | ||||
| -rw-r--r-- | src/osx/mutex.cpp | 127 |
15 files changed, 966 insertions, 19 deletions
diff --git a/build_osx.sh b/build_osx.sh new file mode 100644 index 0000000..82b41db --- /dev/null +++ b/build_osx.sh @@ -0,0 +1,19 @@ +shopt -s extglob + +OUT_DIR="bin/debug" +FLAGS="-g3 -w" + +if [[ $* == *-release* ]]; then + OUT_DIR="bin/release" + FLAGS="-O3" +fi + +mkdir -p $OUT_DIR + +# misc items are converted to header files, not embedded. (xxd -i LICENSE misc/osx/LICENSE.h) + +g++ -m64 -std=c++17 $FLAGS -DUNICODE -o $OUT_DIR/text-search imgui/imgui*.cpp imgui/backends/imgui_impl_glfw.cpp src/widgets/*.cpp src/*.cpp imfiledialog/*.cpp src/osx/*.cpp -Iimgui -Iimgui/backends -Isrc -Isrc/osx -pthread -ldl -lglfw -lGL + +if [[ $* == *-r* ]]; then + ./$OUT_DIR/text-search +fi
\ No newline at end of file diff --git a/misc/osx/LICENSE.h b/misc/osx/LICENSE.h new file mode 100644 index 0000000..350c552 --- /dev/null +++ b/misc/osx/LICENSE.h @@ -0,0 +1,94 @@ +unsigned char LICENSE[] = { + 0x54, 0x68, 0x65, 0x20, 0x4d, 0x49, 0x54, 0x20, 0x4c, 0x69, 0x63, 0x65, + 0x6e, 0x73, 0x65, 0x20, 0x28, 0x4d, 0x49, 0x54, 0x29, 0x0a, 0x0a, 0x43, + 0x6f, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, 0x28, 0x63, 0x29, + 0x20, 0x32, 0x30, 0x31, 0x39, 0x2d, 0x32, 0x30, 0x32, 0x34, 0x20, 0x41, + 0x6c, 0x64, 0x72, 0x69, 0x6b, 0x20, 0x52, 0x61, 0x6d, 0x61, 0x65, 0x6b, + 0x65, 0x72, 0x73, 0x0a, 0x0a, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, + 0x69, 0x6f, 0x6e, 0x20, 0x69, 0x73, 0x20, 0x68, 0x65, 0x72, 0x65, 0x62, + 0x79, 0x20, 0x67, 0x72, 0x61, 0x6e, 0x74, 0x65, 0x64, 0x2c, 0x20, 0x66, + 0x72, 0x65, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x63, 0x68, 0x61, 0x72, 0x67, + 0x65, 0x2c, 0x20, 0x74, 0x6f, 0x20, 0x61, 0x6e, 0x79, 0x20, 0x70, 0x65, + 0x72, 0x73, 0x6f, 0x6e, 0x20, 0x6f, 0x62, 0x74, 0x61, 0x69, 0x6e, 0x69, + 0x6e, 0x67, 0x20, 0x61, 0x20, 0x63, 0x6f, 0x70, 0x79, 0x0a, 0x6f, 0x66, + 0x20, 0x74, 0x68, 0x69, 0x73, 0x20, 0x73, 0x6f, 0x66, 0x74, 0x77, 0x61, + 0x72, 0x65, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x61, 0x73, 0x73, 0x6f, 0x63, + 0x69, 0x61, 0x74, 0x65, 0x64, 0x20, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, + 0x6e, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x66, 0x69, 0x6c, 0x65, + 0x73, 0x20, 0x28, 0x74, 0x68, 0x65, 0x20, 0x22, 0x53, 0x6f, 0x66, 0x74, + 0x77, 0x61, 0x72, 0x65, 0x22, 0x29, 0x2c, 0x20, 0x74, 0x6f, 0x20, 0x64, + 0x65, 0x61, 0x6c, 0x0a, 0x69, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x53, + 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, 0x20, 0x77, 0x69, 0x74, 0x68, + 0x6f, 0x75, 0x74, 0x20, 0x72, 0x65, 0x73, 0x74, 0x72, 0x69, 0x63, 0x74, + 0x69, 0x6f, 0x6e, 0x2c, 0x20, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x69, + 0x6e, 0x67, 0x20, 0x77, 0x69, 0x74, 0x68, 0x6f, 0x75, 0x74, 0x20, 0x6c, + 0x69, 0x6d, 0x69, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x74, 0x68, + 0x65, 0x20, 0x72, 0x69, 0x67, 0x68, 0x74, 0x73, 0x0a, 0x74, 0x6f, 0x20, + 0x75, 0x73, 0x65, 0x2c, 0x20, 0x63, 0x6f, 0x70, 0x79, 0x2c, 0x20, 0x6d, + 0x6f, 0x64, 0x69, 0x66, 0x79, 0x2c, 0x20, 0x6d, 0x65, 0x72, 0x67, 0x65, + 0x2c, 0x20, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x73, 0x68, 0x2c, 0x20, 0x64, + 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x2c, 0x20, 0x73, + 0x75, 0x62, 0x6c, 0x69, 0x63, 0x65, 0x6e, 0x73, 0x65, 0x2c, 0x20, 0x61, + 0x6e, 0x64, 0x2f, 0x6f, 0x72, 0x20, 0x73, 0x65, 0x6c, 0x6c, 0x0a, 0x63, + 0x6f, 0x70, 0x69, 0x65, 0x73, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, + 0x20, 0x53, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, 0x2c, 0x20, 0x61, + 0x6e, 0x64, 0x20, 0x74, 0x6f, 0x20, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x74, + 0x20, 0x70, 0x65, 0x72, 0x73, 0x6f, 0x6e, 0x73, 0x20, 0x74, 0x6f, 0x20, + 0x77, 0x68, 0x6f, 0x6d, 0x20, 0x74, 0x68, 0x65, 0x20, 0x53, 0x6f, 0x66, + 0x74, 0x77, 0x61, 0x72, 0x65, 0x20, 0x69, 0x73, 0x0a, 0x66, 0x75, 0x72, + 0x6e, 0x69, 0x73, 0x68, 0x65, 0x64, 0x20, 0x74, 0x6f, 0x20, 0x64, 0x6f, + 0x20, 0x73, 0x6f, 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, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, + 0x69, 0x6f, 0x6e, 0x73, 0x3a, 0x0a, 0x0a, 0x54, 0x68, 0x65, 0x20, 0x61, + 0x62, 0x6f, 0x76, 0x65, 0x20, 0x63, 0x6f, 0x70, 0x79, 0x72, 0x69, 0x67, + 0x68, 0x74, 0x20, 0x6e, 0x6f, 0x74, 0x69, 0x63, 0x65, 0x20, 0x61, 0x6e, + 0x64, 0x20, 0x74, 0x68, 0x69, 0x73, 0x20, 0x70, 0x65, 0x72, 0x6d, 0x69, + 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x20, 0x6e, 0x6f, 0x74, 0x69, 0x63, 0x65, + 0x20, 0x73, 0x68, 0x61, 0x6c, 0x6c, 0x20, 0x62, 0x65, 0x20, 0x69, 0x6e, + 0x63, 0x6c, 0x75, 0x64, 0x65, 0x64, 0x20, 0x69, 0x6e, 0x20, 0x61, 0x6c, + 0x6c, 0x0a, 0x63, 0x6f, 0x70, 0x69, 0x65, 0x73, 0x20, 0x6f, 0x72, 0x20, + 0x73, 0x75, 0x62, 0x73, 0x74, 0x61, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x20, + 0x70, 0x6f, 0x72, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x20, 0x6f, 0x66, 0x20, + 0x74, 0x68, 0x65, 0x20, 0x53, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, + 0x2e, 0x0a, 0x0a, 0x54, 0x48, 0x45, 0x20, 0x53, 0x4f, 0x46, 0x54, 0x57, + 0x41, 0x52, 0x45, 0x20, 0x49, 0x53, 0x20, 0x50, 0x52, 0x4f, 0x56, 0x49, + 0x44, 0x45, 0x44, 0x20, 0x22, 0x41, 0x53, 0x20, 0x49, 0x53, 0x22, 0x2c, + 0x20, 0x57, 0x49, 0x54, 0x48, 0x4f, 0x55, 0x54, 0x20, 0x57, 0x41, 0x52, + 0x52, 0x41, 0x4e, 0x54, 0x59, 0x20, 0x4f, 0x46, 0x20, 0x41, 0x4e, 0x59, + 0x20, 0x4b, 0x49, 0x4e, 0x44, 0x2c, 0x20, 0x45, 0x58, 0x50, 0x52, 0x45, + 0x53, 0x53, 0x20, 0x4f, 0x52, 0x0a, 0x49, 0x4d, 0x50, 0x4c, 0x49, 0x45, + 0x44, 0x2c, 0x20, 0x49, 0x4e, 0x43, 0x4c, 0x55, 0x44, 0x49, 0x4e, 0x47, + 0x20, 0x42, 0x55, 0x54, 0x20, 0x4e, 0x4f, 0x54, 0x20, 0x4c, 0x49, 0x4d, + 0x49, 0x54, 0x45, 0x44, 0x20, 0x54, 0x4f, 0x20, 0x54, 0x48, 0x45, 0x20, + 0x57, 0x41, 0x52, 0x52, 0x41, 0x4e, 0x54, 0x49, 0x45, 0x53, 0x20, 0x4f, + 0x46, 0x20, 0x4d, 0x45, 0x52, 0x43, 0x48, 0x41, 0x4e, 0x54, 0x41, 0x42, + 0x49, 0x4c, 0x49, 0x54, 0x59, 0x2c, 0x0a, 0x46, 0x49, 0x54, 0x4e, 0x45, + 0x53, 0x53, 0x20, 0x46, 0x4f, 0x52, 0x20, 0x41, 0x20, 0x50, 0x41, 0x52, + 0x54, 0x49, 0x43, 0x55, 0x4c, 0x41, 0x52, 0x20, 0x50, 0x55, 0x52, 0x50, + 0x4f, 0x53, 0x45, 0x20, 0x41, 0x4e, 0x44, 0x20, 0x4e, 0x4f, 0x4e, 0x49, + 0x4e, 0x46, 0x52, 0x49, 0x4e, 0x47, 0x45, 0x4d, 0x45, 0x4e, 0x54, 0x2e, + 0x20, 0x49, 0x4e, 0x20, 0x4e, 0x4f, 0x20, 0x45, 0x56, 0x45, 0x4e, 0x54, + 0x20, 0x53, 0x48, 0x41, 0x4c, 0x4c, 0x20, 0x54, 0x48, 0x45, 0x0a, 0x41, + 0x55, 0x54, 0x48, 0x4f, 0x52, 0x53, 0x20, 0x4f, 0x52, 0x20, 0x43, 0x4f, + 0x50, 0x59, 0x52, 0x49, 0x47, 0x48, 0x54, 0x20, 0x48, 0x4f, 0x4c, 0x44, + 0x45, 0x52, 0x53, 0x20, 0x42, 0x45, 0x20, 0x4c, 0x49, 0x41, 0x42, 0x4c, + 0x45, 0x20, 0x46, 0x4f, 0x52, 0x20, 0x41, 0x4e, 0x59, 0x20, 0x43, 0x4c, + 0x41, 0x49, 0x4d, 0x2c, 0x20, 0x44, 0x41, 0x4d, 0x41, 0x47, 0x45, 0x53, + 0x20, 0x4f, 0x52, 0x20, 0x4f, 0x54, 0x48, 0x45, 0x52, 0x0a, 0x4c, 0x49, + 0x41, 0x42, 0x49, 0x4c, 0x49, 0x54, 0x59, 0x2c, 0x20, 0x57, 0x48, 0x45, + 0x54, 0x48, 0x45, 0x52, 0x20, 0x49, 0x4e, 0x20, 0x41, 0x4e, 0x20, 0x41, + 0x43, 0x54, 0x49, 0x4f, 0x4e, 0x20, 0x4f, 0x46, 0x20, 0x43, 0x4f, 0x4e, + 0x54, 0x52, 0x41, 0x43, 0x54, 0x2c, 0x20, 0x54, 0x4f, 0x52, 0x54, 0x20, + 0x4f, 0x52, 0x20, 0x4f, 0x54, 0x48, 0x45, 0x52, 0x57, 0x49, 0x53, 0x45, + 0x2c, 0x20, 0x41, 0x52, 0x49, 0x53, 0x49, 0x4e, 0x47, 0x20, 0x46, 0x52, + 0x4f, 0x4d, 0x2c, 0x0a, 0x4f, 0x55, 0x54, 0x20, 0x4f, 0x46, 0x20, 0x4f, + 0x52, 0x20, 0x49, 0x4e, 0x20, 0x43, 0x4f, 0x4e, 0x4e, 0x45, 0x43, 0x54, + 0x49, 0x4f, 0x4e, 0x20, 0x57, 0x49, 0x54, 0x48, 0x20, 0x54, 0x48, 0x45, + 0x20, 0x53, 0x4f, 0x46, 0x54, 0x57, 0x41, 0x52, 0x45, 0x20, 0x4f, 0x52, + 0x20, 0x54, 0x48, 0x45, 0x20, 0x55, 0x53, 0x45, 0x20, 0x4f, 0x52, 0x20, + 0x4f, 0x54, 0x48, 0x45, 0x52, 0x20, 0x44, 0x45, 0x41, 0x4c, 0x49, 0x4e, + 0x47, 0x53, 0x20, 0x49, 0x4e, 0x20, 0x54, 0x48, 0x45, 0x0a, 0x53, 0x4f, + 0x46, 0x54, 0x57, 0x41, 0x52, 0x45, 0x2e +}; +unsigned int LICENSE_len = 1087; diff --git a/misc/osx/folder.h b/misc/osx/folder.h new file mode 100644 index 0000000..50c40c0 --- /dev/null +++ b/misc/osx/folder.h @@ -0,0 +1,38 @@ +unsigned char misc_folder_png[] = { + 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, 0x00, 0x00, 0x00, 0x0d, + 0x49, 0x48, 0x44, 0x52, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x18, + 0x08, 0x06, 0x00, 0x00, 0x00, 0xe0, 0x77, 0x3d, 0xf8, 0x00, 0x00, 0x00, + 0x04, 0x73, 0x42, 0x49, 0x54, 0x08, 0x08, 0x08, 0x08, 0x7c, 0x08, 0x64, + 0x88, 0x00, 0x00, 0x00, 0x09, 0x70, 0x48, 0x59, 0x73, 0x00, 0x00, 0x00, + 0x85, 0x00, 0x00, 0x00, 0x85, 0x01, 0xe2, 0xec, 0xff, 0xc1, 0x00, 0x00, + 0x00, 0x19, 0x74, 0x45, 0x58, 0x74, 0x53, 0x6f, 0x66, 0x74, 0x77, 0x61, + 0x72, 0x65, 0x00, 0x77, 0x77, 0x77, 0x2e, 0x69, 0x6e, 0x6b, 0x73, 0x63, + 0x61, 0x70, 0x65, 0x2e, 0x6f, 0x72, 0x67, 0x9b, 0xee, 0x3c, 0x1a, 0x00, + 0x00, 0x01, 0x21, 0x49, 0x44, 0x41, 0x54, 0x48, 0x89, 0xd5, 0xd6, 0xcd, + 0x2b, 0x44, 0x51, 0x18, 0x06, 0xf0, 0xdf, 0x95, 0x85, 0x92, 0x52, 0x4a, + 0xb6, 0x76, 0xa2, 0xac, 0xa4, 0x6c, 0x2c, 0x58, 0x29, 0x7f, 0x8f, 0xa5, + 0xb2, 0xb7, 0xf7, 0x07, 0xd8, 0xcb, 0x42, 0xa4, 0x24, 0xa2, 0x29, 0xb2, + 0x56, 0x4a, 0x11, 0x3b, 0xeb, 0xa1, 0xe4, 0xe3, 0xb5, 0x98, 0x7b, 0xea, + 0x36, 0x5d, 0x33, 0xe6, 0xce, 0x9d, 0x85, 0xa7, 0xde, 0xcd, 0x39, 0xa7, + 0xe7, 0x79, 0xbf, 0xce, 0x7b, 0x4e, 0x16, 0x11, 0x06, 0x89, 0xa1, 0x81, + 0xb2, 0x23, 0xcb, 0x45, 0x96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xed, 0xa3, 0x62, 0x04, 0xab, 0xca, + 0x9f, 0xcc, 0x5e, 0xd0, 0xc4, 0x59, 0x44, 0x34, 0x8b, 0x8b, 0xd9, 0xbf, + 0xff, 0x55, 0xfc, 0x00, 0xc3, 0xc3, 0xc0, 0x7f, 0x8d, 0x90, 0x01, 0xe2, + 0x00, 0x00, 0x00, 0x00, 0x49, 0x45, 0x4e, 0x44, 0xae, 0x42, 0x60, 0x82 +}; +unsigned int misc_folder_png_len = 420; diff --git a/misc/osx/imfiledialog_LICENSE.h b/misc/osx/imfiledialog_LICENSE.h new file mode 100644 index 0000000..53ce2a7 --- /dev/null +++ b/misc/osx/imfiledialog_LICENSE.h @@ -0,0 +1,92 @@ +unsigned char imfiledialog_LICENSE[] = { + 0x4d, 0x49, 0x54, 0x20, 0x4c, 0x69, 0x63, 0x65, 0x6e, 0x73, 0x65, 0x0a, + 0x0a, 0x43, 0x6f, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, 0x28, + 0x63, 0x29, 0x20, 0x32, 0x30, 0x32, 0x31, 0x20, 0x64, 0x66, 0x72, 0x61, + 0x6e, 0x78, 0x0a, 0x0a, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, + 0x6f, 0x6e, 0x20, 0x69, 0x73, 0x20, 0x68, 0x65, 0x72, 0x65, 0x62, 0x79, + 0x20, 0x67, 0x72, 0x61, 0x6e, 0x74, 0x65, 0x64, 0x2c, 0x20, 0x66, 0x72, + 0x65, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x63, 0x68, 0x61, 0x72, 0x67, 0x65, + 0x2c, 0x20, 0x74, 0x6f, 0x20, 0x61, 0x6e, 0x79, 0x20, 0x70, 0x65, 0x72, + 0x73, 0x6f, 0x6e, 0x20, 0x6f, 0x62, 0x74, 0x61, 0x69, 0x6e, 0x69, 0x6e, + 0x67, 0x20, 0x61, 0x20, 0x63, 0x6f, 0x70, 0x79, 0x0a, 0x6f, 0x66, 0x20, + 0x74, 0x68, 0x69, 0x73, 0x20, 0x73, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, + 0x65, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x61, 0x73, 0x73, 0x6f, 0x63, 0x69, + 0x61, 0x74, 0x65, 0x64, 0x20, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, + 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x66, 0x69, 0x6c, 0x65, 0x73, + 0x20, 0x28, 0x74, 0x68, 0x65, 0x20, 0x22, 0x53, 0x6f, 0x66, 0x74, 0x77, + 0x61, 0x72, 0x65, 0x22, 0x29, 0x2c, 0x20, 0x74, 0x6f, 0x20, 0x64, 0x65, + 0x61, 0x6c, 0x0a, 0x69, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x53, 0x6f, + 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, 0x20, 0x77, 0x69, 0x74, 0x68, 0x6f, + 0x75, 0x74, 0x20, 0x72, 0x65, 0x73, 0x74, 0x72, 0x69, 0x63, 0x74, 0x69, + 0x6f, 0x6e, 0x2c, 0x20, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x69, 0x6e, + 0x67, 0x20, 0x77, 0x69, 0x74, 0x68, 0x6f, 0x75, 0x74, 0x20, 0x6c, 0x69, + 0x6d, 0x69, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x74, 0x68, 0x65, + 0x20, 0x72, 0x69, 0x67, 0x68, 0x74, 0x73, 0x0a, 0x74, 0x6f, 0x20, 0x75, + 0x73, 0x65, 0x2c, 0x20, 0x63, 0x6f, 0x70, 0x79, 0x2c, 0x20, 0x6d, 0x6f, + 0x64, 0x69, 0x66, 0x79, 0x2c, 0x20, 0x6d, 0x65, 0x72, 0x67, 0x65, 0x2c, + 0x20, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x73, 0x68, 0x2c, 0x20, 0x64, 0x69, + 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x2c, 0x20, 0x73, 0x75, + 0x62, 0x6c, 0x69, 0x63, 0x65, 0x6e, 0x73, 0x65, 0x2c, 0x20, 0x61, 0x6e, + 0x64, 0x2f, 0x6f, 0x72, 0x20, 0x73, 0x65, 0x6c, 0x6c, 0x0a, 0x63, 0x6f, + 0x70, 0x69, 0x65, 0x73, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, + 0x53, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, 0x2c, 0x20, 0x61, 0x6e, + 0x64, 0x20, 0x74, 0x6f, 0x20, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x20, + 0x70, 0x65, 0x72, 0x73, 0x6f, 0x6e, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x77, + 0x68, 0x6f, 0x6d, 0x20, 0x74, 0x68, 0x65, 0x20, 0x53, 0x6f, 0x66, 0x74, + 0x77, 0x61, 0x72, 0x65, 0x20, 0x69, 0x73, 0x0a, 0x66, 0x75, 0x72, 0x6e, + 0x69, 0x73, 0x68, 0x65, 0x64, 0x20, 0x74, 0x6f, 0x20, 0x64, 0x6f, 0x20, + 0x73, 0x6f, 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, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, + 0x6f, 0x6e, 0x73, 0x3a, 0x0a, 0x0a, 0x54, 0x68, 0x65, 0x20, 0x61, 0x62, + 0x6f, 0x76, 0x65, 0x20, 0x63, 0x6f, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, + 0x74, 0x20, 0x6e, 0x6f, 0x74, 0x69, 0x63, 0x65, 0x20, 0x61, 0x6e, 0x64, + 0x20, 0x74, 0x68, 0x69, 0x73, 0x20, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, + 0x73, 0x69, 0x6f, 0x6e, 0x20, 0x6e, 0x6f, 0x74, 0x69, 0x63, 0x65, 0x20, + 0x73, 0x68, 0x61, 0x6c, 0x6c, 0x20, 0x62, 0x65, 0x20, 0x69, 0x6e, 0x63, + 0x6c, 0x75, 0x64, 0x65, 0x64, 0x20, 0x69, 0x6e, 0x20, 0x61, 0x6c, 0x6c, + 0x0a, 0x63, 0x6f, 0x70, 0x69, 0x65, 0x73, 0x20, 0x6f, 0x72, 0x20, 0x73, + 0x75, 0x62, 0x73, 0x74, 0x61, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x20, 0x70, + 0x6f, 0x72, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x20, 0x6f, 0x66, 0x20, 0x74, + 0x68, 0x65, 0x20, 0x53, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, 0x2e, + 0x0a, 0x0a, 0x54, 0x48, 0x45, 0x20, 0x53, 0x4f, 0x46, 0x54, 0x57, 0x41, + 0x52, 0x45, 0x20, 0x49, 0x53, 0x20, 0x50, 0x52, 0x4f, 0x56, 0x49, 0x44, + 0x45, 0x44, 0x20, 0x22, 0x41, 0x53, 0x20, 0x49, 0x53, 0x22, 0x2c, 0x20, + 0x57, 0x49, 0x54, 0x48, 0x4f, 0x55, 0x54, 0x20, 0x57, 0x41, 0x52, 0x52, + 0x41, 0x4e, 0x54, 0x59, 0x20, 0x4f, 0x46, 0x20, 0x41, 0x4e, 0x59, 0x20, + 0x4b, 0x49, 0x4e, 0x44, 0x2c, 0x20, 0x45, 0x58, 0x50, 0x52, 0x45, 0x53, + 0x53, 0x20, 0x4f, 0x52, 0x0a, 0x49, 0x4d, 0x50, 0x4c, 0x49, 0x45, 0x44, + 0x2c, 0x20, 0x49, 0x4e, 0x43, 0x4c, 0x55, 0x44, 0x49, 0x4e, 0x47, 0x20, + 0x42, 0x55, 0x54, 0x20, 0x4e, 0x4f, 0x54, 0x20, 0x4c, 0x49, 0x4d, 0x49, + 0x54, 0x45, 0x44, 0x20, 0x54, 0x4f, 0x20, 0x54, 0x48, 0x45, 0x20, 0x57, + 0x41, 0x52, 0x52, 0x41, 0x4e, 0x54, 0x49, 0x45, 0x53, 0x20, 0x4f, 0x46, + 0x20, 0x4d, 0x45, 0x52, 0x43, 0x48, 0x41, 0x4e, 0x54, 0x41, 0x42, 0x49, + 0x4c, 0x49, 0x54, 0x59, 0x2c, 0x0a, 0x46, 0x49, 0x54, 0x4e, 0x45, 0x53, + 0x53, 0x20, 0x46, 0x4f, 0x52, 0x20, 0x41, 0x20, 0x50, 0x41, 0x52, 0x54, + 0x49, 0x43, 0x55, 0x4c, 0x41, 0x52, 0x20, 0x50, 0x55, 0x52, 0x50, 0x4f, + 0x53, 0x45, 0x20, 0x41, 0x4e, 0x44, 0x20, 0x4e, 0x4f, 0x4e, 0x49, 0x4e, + 0x46, 0x52, 0x49, 0x4e, 0x47, 0x45, 0x4d, 0x45, 0x4e, 0x54, 0x2e, 0x20, + 0x49, 0x4e, 0x20, 0x4e, 0x4f, 0x20, 0x45, 0x56, 0x45, 0x4e, 0x54, 0x20, + 0x53, 0x48, 0x41, 0x4c, 0x4c, 0x20, 0x54, 0x48, 0x45, 0x0a, 0x41, 0x55, + 0x54, 0x48, 0x4f, 0x52, 0x53, 0x20, 0x4f, 0x52, 0x20, 0x43, 0x4f, 0x50, + 0x59, 0x52, 0x49, 0x47, 0x48, 0x54, 0x20, 0x48, 0x4f, 0x4c, 0x44, 0x45, + 0x52, 0x53, 0x20, 0x42, 0x45, 0x20, 0x4c, 0x49, 0x41, 0x42, 0x4c, 0x45, + 0x20, 0x46, 0x4f, 0x52, 0x20, 0x41, 0x4e, 0x59, 0x20, 0x43, 0x4c, 0x41, + 0x49, 0x4d, 0x2c, 0x20, 0x44, 0x41, 0x4d, 0x41, 0x47, 0x45, 0x53, 0x20, + 0x4f, 0x52, 0x20, 0x4f, 0x54, 0x48, 0x45, 0x52, 0x0a, 0x4c, 0x49, 0x41, + 0x42, 0x49, 0x4c, 0x49, 0x54, 0x59, 0x2c, 0x20, 0x57, 0x48, 0x45, 0x54, + 0x48, 0x45, 0x52, 0x20, 0x49, 0x4e, 0x20, 0x41, 0x4e, 0x20, 0x41, 0x43, + 0x54, 0x49, 0x4f, 0x4e, 0x20, 0x4f, 0x46, 0x20, 0x43, 0x4f, 0x4e, 0x54, + 0x52, 0x41, 0x43, 0x54, 0x2c, 0x20, 0x54, 0x4f, 0x52, 0x54, 0x20, 0x4f, + 0x52, 0x20, 0x4f, 0x54, 0x48, 0x45, 0x52, 0x57, 0x49, 0x53, 0x45, 0x2c, + 0x20, 0x41, 0x52, 0x49, 0x53, 0x49, 0x4e, 0x47, 0x20, 0x46, 0x52, 0x4f, + 0x4d, 0x2c, 0x0a, 0x4f, 0x55, 0x54, 0x20, 0x4f, 0x46, 0x20, 0x4f, 0x52, + 0x20, 0x49, 0x4e, 0x20, 0x43, 0x4f, 0x4e, 0x4e, 0x45, 0x43, 0x54, 0x49, + 0x4f, 0x4e, 0x20, 0x57, 0x49, 0x54, 0x48, 0x20, 0x54, 0x48, 0x45, 0x20, + 0x53, 0x4f, 0x46, 0x54, 0x57, 0x41, 0x52, 0x45, 0x20, 0x4f, 0x52, 0x20, + 0x54, 0x48, 0x45, 0x20, 0x55, 0x53, 0x45, 0x20, 0x4f, 0x52, 0x20, 0x4f, + 0x54, 0x48, 0x45, 0x52, 0x20, 0x44, 0x45, 0x41, 0x4c, 0x49, 0x4e, 0x47, + 0x53, 0x20, 0x49, 0x4e, 0x20, 0x54, 0x48, 0x45, 0x0a, 0x53, 0x4f, 0x46, + 0x54, 0x57, 0x41, 0x52, 0x45, 0x2e, 0x0a +}; +unsigned int imfiledialog_LICENSE_len = 1063; diff --git a/misc/osx/imgui_LICENSE.h b/misc/osx/imgui_LICENSE.h new file mode 100644 index 0000000..d6e4e20 --- /dev/null +++ b/misc/osx/imgui_LICENSE.h @@ -0,0 +1,94 @@ +unsigned char imgui_LICENSE[] = { + 0x54, 0x68, 0x65, 0x20, 0x4d, 0x49, 0x54, 0x20, 0x4c, 0x69, 0x63, 0x65, + 0x6e, 0x73, 0x65, 0x20, 0x28, 0x4d, 0x49, 0x54, 0x29, 0x0a, 0x0a, 0x43, + 0x6f, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, 0x28, 0x63, 0x29, + 0x20, 0x32, 0x30, 0x31, 0x34, 0x2d, 0x32, 0x30, 0x32, 0x34, 0x20, 0x4f, + 0x6d, 0x61, 0x72, 0x20, 0x43, 0x6f, 0x72, 0x6e, 0x75, 0x74, 0x0a, 0x0a, + 0x50, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x20, 0x69, + 0x73, 0x20, 0x68, 0x65, 0x72, 0x65, 0x62, 0x79, 0x20, 0x67, 0x72, 0x61, + 0x6e, 0x74, 0x65, 0x64, 0x2c, 0x20, 0x66, 0x72, 0x65, 0x65, 0x20, 0x6f, + 0x66, 0x20, 0x63, 0x68, 0x61, 0x72, 0x67, 0x65, 0x2c, 0x20, 0x74, 0x6f, + 0x20, 0x61, 0x6e, 0x79, 0x20, 0x70, 0x65, 0x72, 0x73, 0x6f, 0x6e, 0x20, + 0x6f, 0x62, 0x74, 0x61, 0x69, 0x6e, 0x69, 0x6e, 0x67, 0x20, 0x61, 0x20, + 0x63, 0x6f, 0x70, 0x79, 0x0a, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x69, 0x73, + 0x20, 0x73, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, 0x20, 0x61, 0x6e, + 0x64, 0x20, 0x61, 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x65, 0x64, + 0x20, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x20, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x20, 0x28, 0x74, 0x68, + 0x65, 0x20, 0x22, 0x53, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, 0x22, + 0x29, 0x2c, 0x20, 0x74, 0x6f, 0x20, 0x64, 0x65, 0x61, 0x6c, 0x0a, 0x69, + 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x53, 0x6f, 0x66, 0x74, 0x77, 0x61, + 0x72, 0x65, 0x20, 0x77, 0x69, 0x74, 0x68, 0x6f, 0x75, 0x74, 0x20, 0x72, + 0x65, 0x73, 0x74, 0x72, 0x69, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2c, 0x20, + 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x77, 0x69, + 0x74, 0x68, 0x6f, 0x75, 0x74, 0x20, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x72, 0x69, 0x67, + 0x68, 0x74, 0x73, 0x0a, 0x74, 0x6f, 0x20, 0x75, 0x73, 0x65, 0x2c, 0x20, + 0x63, 0x6f, 0x70, 0x79, 0x2c, 0x20, 0x6d, 0x6f, 0x64, 0x69, 0x66, 0x79, + 0x2c, 0x20, 0x6d, 0x65, 0x72, 0x67, 0x65, 0x2c, 0x20, 0x70, 0x75, 0x62, + 0x6c, 0x69, 0x73, 0x68, 0x2c, 0x20, 0x64, 0x69, 0x73, 0x74, 0x72, 0x69, + 0x62, 0x75, 0x74, 0x65, 0x2c, 0x20, 0x73, 0x75, 0x62, 0x6c, 0x69, 0x63, + 0x65, 0x6e, 0x73, 0x65, 0x2c, 0x20, 0x61, 0x6e, 0x64, 0x2f, 0x6f, 0x72, + 0x20, 0x73, 0x65, 0x6c, 0x6c, 0x0a, 0x63, 0x6f, 0x70, 0x69, 0x65, 0x73, + 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x53, 0x6f, 0x66, 0x74, + 0x77, 0x61, 0x72, 0x65, 0x2c, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x74, 0x6f, + 0x20, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x74, 0x20, 0x70, 0x65, 0x72, 0x73, + 0x6f, 0x6e, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x77, 0x68, 0x6f, 0x6d, 0x20, + 0x74, 0x68, 0x65, 0x20, 0x53, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, + 0x20, 0x69, 0x73, 0x0a, 0x66, 0x75, 0x72, 0x6e, 0x69, 0x73, 0x68, 0x65, + 0x64, 0x20, 0x74, 0x6f, 0x20, 0x64, 0x6f, 0x20, 0x73, 0x6f, 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, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x3a, + 0x0a, 0x0a, 0x54, 0x68, 0x65, 0x20, 0x61, 0x62, 0x6f, 0x76, 0x65, 0x20, + 0x63, 0x6f, 0x70, 0x79, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, 0x6e, 0x6f, + 0x74, 0x69, 0x63, 0x65, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x74, 0x68, 0x69, + 0x73, 0x20, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, + 0x20, 0x6e, 0x6f, 0x74, 0x69, 0x63, 0x65, 0x20, 0x73, 0x68, 0x61, 0x6c, + 0x6c, 0x20, 0x62, 0x65, 0x20, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x65, + 0x64, 0x20, 0x69, 0x6e, 0x20, 0x61, 0x6c, 0x6c, 0x0a, 0x63, 0x6f, 0x70, + 0x69, 0x65, 0x73, 0x20, 0x6f, 0x72, 0x20, 0x73, 0x75, 0x62, 0x73, 0x74, + 0x61, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x20, 0x70, 0x6f, 0x72, 0x74, 0x69, + 0x6f, 0x6e, 0x73, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x53, + 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, 0x2e, 0x0a, 0x0a, 0x54, 0x48, + 0x45, 0x20, 0x53, 0x4f, 0x46, 0x54, 0x57, 0x41, 0x52, 0x45, 0x20, 0x49, + 0x53, 0x20, 0x50, 0x52, 0x4f, 0x56, 0x49, 0x44, 0x45, 0x44, 0x20, 0x22, + 0x41, 0x53, 0x20, 0x49, 0x53, 0x22, 0x2c, 0x20, 0x57, 0x49, 0x54, 0x48, + 0x4f, 0x55, 0x54, 0x20, 0x57, 0x41, 0x52, 0x52, 0x41, 0x4e, 0x54, 0x59, + 0x20, 0x4f, 0x46, 0x20, 0x41, 0x4e, 0x59, 0x20, 0x4b, 0x49, 0x4e, 0x44, + 0x2c, 0x20, 0x45, 0x58, 0x50, 0x52, 0x45, 0x53, 0x53, 0x20, 0x4f, 0x52, + 0x0a, 0x49, 0x4d, 0x50, 0x4c, 0x49, 0x45, 0x44, 0x2c, 0x20, 0x49, 0x4e, + 0x43, 0x4c, 0x55, 0x44, 0x49, 0x4e, 0x47, 0x20, 0x42, 0x55, 0x54, 0x20, + 0x4e, 0x4f, 0x54, 0x20, 0x4c, 0x49, 0x4d, 0x49, 0x54, 0x45, 0x44, 0x20, + 0x54, 0x4f, 0x20, 0x54, 0x48, 0x45, 0x20, 0x57, 0x41, 0x52, 0x52, 0x41, + 0x4e, 0x54, 0x49, 0x45, 0x53, 0x20, 0x4f, 0x46, 0x20, 0x4d, 0x45, 0x52, + 0x43, 0x48, 0x41, 0x4e, 0x54, 0x41, 0x42, 0x49, 0x4c, 0x49, 0x54, 0x59, + 0x2c, 0x0a, 0x46, 0x49, 0x54, 0x4e, 0x45, 0x53, 0x53, 0x20, 0x46, 0x4f, + 0x52, 0x20, 0x41, 0x20, 0x50, 0x41, 0x52, 0x54, 0x49, 0x43, 0x55, 0x4c, + 0x41, 0x52, 0x20, 0x50, 0x55, 0x52, 0x50, 0x4f, 0x53, 0x45, 0x20, 0x41, + 0x4e, 0x44, 0x20, 0x4e, 0x4f, 0x4e, 0x49, 0x4e, 0x46, 0x52, 0x49, 0x4e, + 0x47, 0x45, 0x4d, 0x45, 0x4e, 0x54, 0x2e, 0x20, 0x49, 0x4e, 0x20, 0x4e, + 0x4f, 0x20, 0x45, 0x56, 0x45, 0x4e, 0x54, 0x20, 0x53, 0x48, 0x41, 0x4c, + 0x4c, 0x20, 0x54, 0x48, 0x45, 0x0a, 0x41, 0x55, 0x54, 0x48, 0x4f, 0x52, + 0x53, 0x20, 0x4f, 0x52, 0x20, 0x43, 0x4f, 0x50, 0x59, 0x52, 0x49, 0x47, + 0x48, 0x54, 0x20, 0x48, 0x4f, 0x4c, 0x44, 0x45, 0x52, 0x53, 0x20, 0x42, + 0x45, 0x20, 0x4c, 0x49, 0x41, 0x42, 0x4c, 0x45, 0x20, 0x46, 0x4f, 0x52, + 0x20, 0x41, 0x4e, 0x59, 0x20, 0x43, 0x4c, 0x41, 0x49, 0x4d, 0x2c, 0x20, + 0x44, 0x41, 0x4d, 0x41, 0x47, 0x45, 0x53, 0x20, 0x4f, 0x52, 0x20, 0x4f, + 0x54, 0x48, 0x45, 0x52, 0x0a, 0x4c, 0x49, 0x41, 0x42, 0x49, 0x4c, 0x49, + 0x54, 0x59, 0x2c, 0x20, 0x57, 0x48, 0x45, 0x54, 0x48, 0x45, 0x52, 0x20, + 0x49, 0x4e, 0x20, 0x41, 0x4e, 0x20, 0x41, 0x43, 0x54, 0x49, 0x4f, 0x4e, + 0x20, 0x4f, 0x46, 0x20, 0x43, 0x4f, 0x4e, 0x54, 0x52, 0x41, 0x43, 0x54, + 0x2c, 0x20, 0x54, 0x4f, 0x52, 0x54, 0x20, 0x4f, 0x52, 0x20, 0x4f, 0x54, + 0x48, 0x45, 0x52, 0x57, 0x49, 0x53, 0x45, 0x2c, 0x20, 0x41, 0x52, 0x49, + 0x53, 0x49, 0x4e, 0x47, 0x20, 0x46, 0x52, 0x4f, 0x4d, 0x2c, 0x0a, 0x4f, + 0x55, 0x54, 0x20, 0x4f, 0x46, 0x20, 0x4f, 0x52, 0x20, 0x49, 0x4e, 0x20, + 0x43, 0x4f, 0x4e, 0x4e, 0x45, 0x43, 0x54, 0x49, 0x4f, 0x4e, 0x20, 0x57, + 0x49, 0x54, 0x48, 0x20, 0x54, 0x48, 0x45, 0x20, 0x53, 0x4f, 0x46, 0x54, + 0x57, 0x41, 0x52, 0x45, 0x20, 0x4f, 0x52, 0x20, 0x54, 0x48, 0x45, 0x20, + 0x55, 0x53, 0x45, 0x20, 0x4f, 0x52, 0x20, 0x4f, 0x54, 0x48, 0x45, 0x52, + 0x20, 0x44, 0x45, 0x41, 0x4c, 0x49, 0x4e, 0x47, 0x53, 0x20, 0x49, 0x4e, + 0x20, 0x54, 0x48, 0x45, 0x0a, 0x53, 0x4f, 0x46, 0x54, 0x57, 0x41, 0x52, + 0x45, 0x2e, 0x0a +}; +unsigned int imgui_LICENSE_len = 1083; diff --git a/misc/osx/logo_64.h b/misc/osx/logo_64.h new file mode 100644 index 0000000..7f9f60e --- /dev/null +++ b/misc/osx/logo_64.h @@ -0,0 +1,102 @@ +unsigned char misc_logo_64_png[] = { + 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, 0x00, 0x00, 0x00, 0x0d, + 0x49, 0x48, 0x44, 0x52, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x40, + 0x08, 0x03, 0x00, 0x00, 0x00, 0x9d, 0xb7, 0x81, 0xec, 0x00, 0x00, 0x00, + 0x01, 0x73, 0x52, 0x47, 0x42, 0x01, 0xd9, 0xc9, 0x2c, 0x7f, 0x00, 0x00, + 0x00, 0x09, 0x70, 0x48, 0x59, 0x73, 0x00, 0x00, 0x0b, 0x13, 0x00, 0x00, + 0x0b, 0x13, 0x01, 0x00, 0x9a, 0x9c, 0x18, 0x00, 0x00, 0x01, 0x38, 0x50, + 0x4c, 0x54, 0x45, 0x00, 0x00, 0x00, 0x65, 0x83, 0xc6, 0x61, 0x80, 0xc4, + 0x62, 0x80, 0xc6, 0x6a, 0x87, 0xc9, 0x61, 0x80, 0xc5, 0x5d, 0x7e, 0xc3, + 0x6a, 0x87, 0xc8, 0x69, 0x83, 0xc4, 0x63, 0x82, 0xc5, 0x6a, 0x86, 0xc8, + 0x51, 0x74, 0xbe, 0x44, 0x69, 0xb8, 0x39, 0x60, 0xb3, 0x44, 0x6a, 0xb8, + 0x45, 0x6a, 0xb8, 0x52, 0x74, 0xbe, 0x6a, 0x86, 0xc8, 0x64, 0x83, 0xc6, + 0x68, 0x86, 0xc8, 0x3c, 0x62, 0xb4, 0x29, 0x54, 0xac, 0x3c, 0x63, 0xb4, + 0x5f, 0x7f, 0xc4, 0x31, 0x51, 0xa4, 0x48, 0x49, 0x8b, 0x9e, 0x2c, 0x31, + 0x58, 0x44, 0x7b, 0xa6, 0x29, 0x29, 0x40, 0x4c, 0x93, 0x60, 0x41, 0x72, + 0x50, 0x46, 0x83, 0x77, 0x39, 0x5a, 0x83, 0x3d, 0x52, 0x55, 0x62, 0x90, + 0xcd, 0x88, 0x44, 0xa7, 0x3e, 0x35, 0x96, 0x2e, 0x39, 0x6b, 0x69, 0x82, + 0xd8, 0x8c, 0x3d, 0x76, 0x6d, 0x7b, 0x9f, 0x3c, 0x3a, 0x80, 0x70, 0x75, + 0x9a, 0x3a, 0x3e, 0x34, 0x57, 0xa5, 0x96, 0x77, 0x67, 0xd5, 0x86, 0x3c, + 0x99, 0x34, 0x3b, 0xb7, 0x81, 0x52, 0x3b, 0x54, 0x9d, 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, 0x6a, 0x27, + 0xc8, 0xfd, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfc, 0xc4, 0xff, 0xff, + 0xff, 0xff, 0xbe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xd0, 0xcd, 0xca, 0xf4, 0xd3, + 0xc9, 0x4c, 0x2d, 0x00, 0x00, 0x02, 0x87, 0x49, 0x44, 0x41, 0x54, 0x78, + 0x9c, 0xa5, 0x97, 0x7b, 0x7b, 0xd2, 0x30, 0x14, 0x87, 0x83, 0x3b, 0xdc, + 0x54, 0x2e, 0x1b, 0x74, 0x32, 0x56, 0x45, 0x41, 0x57, 0x9c, 0xcc, 0xcb, + 0x14, 0xef, 0x02, 0x46, 0x64, 0x5e, 0x50, 0x26, 0xa2, 0x82, 0x73, 0xea, + 0xd4, 0x6d, 0xdf, 0xff, 0x1b, 0xd8, 0x4b, 0x9a, 0x26, 0x6d, 0x1a, 0x9a, + 0xec, 0xfc, 0xd5, 0xf4, 0xc9, 0xfb, 0x92, 0xcb, 0x29, 0xcf, 0xf3, 0x43, + 0xc8, 0xae, 0xd4, 0xb9, 0x15, 0x50, 0xae, 0x74, 0x26, 0x8b, 0xbc, 0xca, + 0xe5, 0xd5, 0x69, 0xaf, 0xf2, 0x39, 0x97, 0x3f, 0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xca, 0xad, + 0xe9, 0x86, 0xef, 0xe3, 0x1c, 0xc9, 0xef, 0xd9, 0x93, 0x53, 0x75, 0xfa, + 0xf4, 0x24, 0xe5, 0xb0, 0xff, 0x01, 0xcd, 0xaa, 0x92, 0x13, 0xb5, 0x92, + 0xdb, 0xbd, 0x00, 0x00, 0x00, 0x00, 0x49, 0x45, 0x4e, 0x44, 0xae, 0x42, + 0x60, 0x82 +}; +unsigned int misc_logo_64_png_len = 1178; diff --git a/misc/osx/search.h b/misc/osx/search.h new file mode 100644 index 0000000..d506746 --- /dev/null +++ b/misc/osx/search.h @@ -0,0 +1,51 @@ +unsigned char misc_search_png[] = { + 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, 0x00, 0x00, 0x00, 0x0d, + 0x49, 0x48, 0x44, 0x52, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x18, + 0x08, 0x06, 0x00, 0x00, 0x00, 0xe0, 0x77, 0x3d, 0xf8, 0x00, 0x00, 0x00, + 0x09, 0x70, 0x48, 0x59, 0x73, 0x00, 0x00, 0x06, 0x38, 0x00, 0x00, 0x06, + 0x38, 0x01, 0x72, 0x8e, 0x66, 0x17, 0x00, 0x00, 0x00, 0x19, 0x74, 0x45, + 0x58, 0x74, 0x53, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, 0x65, 0x00, 0x77, + 0x77, 0x77, 0x2e, 0x69, 0x6e, 0x6b, 0x73, 0x63, 0x61, 0x70, 0x65, 0x2e, + 0x6f, 0x72, 0x67, 0x9b, 0xee, 0x3c, 0x1a, 0x00, 0x00, 0x01, 0xc5, 0x49, + 0x44, 0x41, 0x54, 0x48, 0x89, 0xad, 0xd5, 0xcf, 0x8b, 0x8d, 0x51, 0x18, + 0x07, 0xf0, 0xcf, 0x9d, 0x31, 0x46, 0x08, 0xb3, 0x61, 0x52, 0x58, 0xa0, + 0xe4, 0x47, 0x56, 0xc3, 0x96, 0x29, 0xa5, 0x34, 0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a, 0x15, + 0x21, 0x15, 0xde, 0x4e, 0x29, 0x35, 0x07, 0xb1, 0x1b, 0xcb, 0x0a, 0x78, + 0x67, 0x83, 0xc8, 0xb4, 0xd4, 0xfe, 0x7b, 0x8e, 0x89, 0x20, 0xf2, 0x5c, + 0x41, 0xdb, 0xf8, 0x5f, 0xd4, 0x70, 0xc9, 0xbf, 0x37, 0x71, 0xa8, 0xbf, + 0xc7, 0x22, 0x37, 0xa5, 0x97, 0x6e, 0x1b, 0x56, 0x49, 0x4f, 0x6f, 0xcf, + 0xb1, 0x00, 0x57, 0xf0, 0x11, 0x7b, 0x7e, 0x03, 0x52, 0x6c, 0x8d, 0x2d, + 0x9f, 0x5c, 0xfa, 0xee, 0x00, 0x00, 0x00, 0x00, 0x49, 0x45, 0x4e, 0x44, + 0xae, 0x42, 0x60, 0x82 +}; +unsigned int misc_search_png_len = 568; diff --git a/src/config.h b/src/config.h index efc64cb..2d58c10 100644 --- a/src/config.h +++ b/src/config.h @@ -4,6 +4,8 @@ #define MAX_INPUT_LENGTH 32767 #elif defined(__linux__) #define MAX_INPUT_LENGTH 4096 +#elif defined(__APPLE__) +#define MAX_INPUT_LENGTH 1024 #endif #define MAX_ERROR_MESSAGE_LENGTH (MAX_INPUT_LENGTH) diff --git a/src/definitions.cpp b/src/definitions.cpp new file mode 100644 index 0000000..4e44572 --- /dev/null +++ b/src/definitions.cpp @@ -0,0 +1,27 @@ +#include "definitions.h" + +#ifdef __APPLE__ +#include "../misc/osx/LICENSE.h" +unsigned char* _binary_LICENSE_start = LICENSE; +unsigned char* _binary_LICENSE_end = _binary_LICENSE_start + LICENSE_len; + +#include "../misc/osx/imgui_LICENSE.h" +unsigned char* _binary_imgui_LICENSE_start = imgui_LICENSE; +unsigned char* _binary_imgui_LICENSE_end = imgui_LICENSE + imgui_LICENSE_len; + +#include "../misc/osx/imfiledialog_LICENSE.h" +unsigned char* _binary_imfiledialog_LICENSE_start = imfiledialog_LICENSE; +unsigned char* _binary_imfiledialog_LICENSE_end = imfiledialog_LICENSE + imfiledialog_LICENSE_len; + +#include "../misc/osx/logo_64.h" +unsigned char* _binary_misc_logo_64_png_start = misc_logo_64_png; +unsigned char* _binary_misc_logo_64_png_end = misc_logo_64_png + misc_logo_64_png_len; + +#include "../misc/osx/search.h" +unsigned char* _binary_misc_search_png_start = misc_search_png; +unsigned char* _binary_misc_search_png_end = misc_search_png + misc_search_png_len; + +#include "../misc/osx/folder.h" +unsigned char* _binary_misc_folder_png_start = misc_folder_png; +unsigned char* _binary_misc_folder_png_end = misc_folder_png + misc_folder_png_len; +#endif
\ No newline at end of file diff --git a/src/definitions.h b/src/definitions.h index 07b42f1..a83cbe7 100644 --- a/src/definitions.h +++ b/src/definitions.h @@ -1,28 +1,25 @@ -#ifndef INCLUDE_EMBEDDED_RESOURCES -#define INCLUDE_EMBEDDED_RESOURCES +#pragma once #define TS_VERSION "v2.1.0" // Find these with dumpbin [objfile] /SYMBOLS extern "C" { -extern unsigned char _binary_LICENSE_start[]; -extern unsigned char _binary_LICENSE_end[]; +extern unsigned char* _binary_LICENSE_start; +extern unsigned char* _binary_LICENSE_end; -extern unsigned char _binary_imgui_LICENSE_start[]; -extern unsigned char _binary_imgui_LICENSE_end[]; +extern unsigned char* _binary_imgui_LICENSE_start; +extern unsigned char* _binary_imgui_LICENSE_end; -extern unsigned char _binary_imfiledialog_LICENSE_start[]; -extern unsigned char _binary_imfiledialog_LICENSE_end[]; +extern unsigned char* _binary_imfiledialog_LICENSE_start; +extern unsigned char* _binary_imfiledialog_LICENSE_end; -extern unsigned char _binary_misc_logo_64_png_start[]; -extern unsigned char _binary_misc_logo_64_png_end[]; +extern unsigned char* _binary_misc_logo_64_png_start; +extern unsigned char* _binary_misc_logo_64_png_end; -extern unsigned char _binary_misc_search_png_start[]; -extern unsigned char _binary_misc_search_png_end[]; +extern unsigned char* _binary_misc_search_png_start; +extern unsigned char* _binary_misc_search_png_end; -extern unsigned char _binary_misc_folder_png_start[]; -extern unsigned char _binary_misc_folder_png_end[]; +extern unsigned char* _binary_misc_folder_png_start; +extern unsigned char* _binary_misc_folder_png_end; } - -#endif
\ No newline at end of file diff --git a/src/image.h b/src/image.h index 860c767..b702b57 100644 --- a/src/image.h +++ b/src/image.h @@ -14,7 +14,7 @@ typedef struct t_ts_image { int width; int height; } ts_image; -#elif defined(__linux__) +#elif defined(__linux__) || defined(__APPLE__) //#include <GL/glut.h> #include "imgui.h" diff --git a/src/main.cpp b/src/main.cpp index 32aca84..fbb0484 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -1,7 +1,7 @@ #include "../imgui/imgui.h" #include "../imgui/imgui_spectrum.h" #include "../imgui/imgui_impl_opengl3_loader.h" -#include "../imfiledialog/imFileDialog.h" +#include "../imfiledialog/ImFileDialog.h" #include "../utf8.h" #include "widgets/imgui_toggle.h" #include "definitions.h" diff --git a/src/mutex.h b/src/mutex.h index 8499bcc..790e279 100644 --- a/src/mutex.h +++ b/src/mutex.h @@ -20,7 +20,7 @@ typedef struct t_ts_thread int valid; } ts_thread; -#elif defined(__linux__) +#elif defined(__linux__) || defined(__APPLE__) #include <pthread.h> #include <unistd.h> #include <sys/types.h> diff --git a/src/osx/main_osx.cpp b/src/osx/main_osx.cpp new file mode 100644 index 0000000..a6d48d7 --- /dev/null +++ b/src/osx/main_osx.cpp @@ -0,0 +1,304 @@ +#include "imgui.h" +#include "imgui_spectrum.h" +#include "imgui_impl_glfw.h" +#include "imgui_impl_opengl3.h" +#include "../utf8.h" +#include "platform.h" +#include "mutex.h" +#include "array.h" +#include "memory_bucket.h" +#include "image.h" +#include "config.h" +#include <stdio.h> +#include <stdlib.h> +#include <errno.h> +#include <sys/types.h> +#include <sys/stat.h> +#include <dirent.h> +#define GL_SILENCE_DEPRECATION +#if defined(IMGUI_IMPL_OPENGL_ES2) +#include <GLES2/gl2.h> +#endif +#include <GLFW/glfw3.h> // Will drag system OpenGL headers + +void ts_create_gui(int window_w, int window_h); +void ts_load_images(); +void ts_init(); + +bool program_running = true; + +char config_path[MAX_INPUT_LENGTH]; +static const char* _ts_platform_get_config_file_path(char* buffer) { + char* env = getenv("HOME"); + char path_buf[MAX_INPUT_LENGTH]; + snprintf(path_buf, MAX_INPUT_LENGTH, "%s%s", env, "/text-search/"); + snprintf(buffer, MAX_INPUT_LENGTH, "%.*s%s", MAX_INPUT_LENGTH-10, path_buf, "imgui.ini"); + if (!ts_platform_dir_exists(path_buf)) { + mkdir(path_buf, S_IRWXU | S_IRWXG | S_IROTH | S_IXOTH); + } + return buffer; +} + +static void glfw_error_callback(int error, const char* description) +{ + fprintf(stderr, "GLFW Error %d: %s\n", error, description); +} + +// Main code +int main(int, char**) +{ + glfwSetErrorCallback(glfw_error_callback); + if (!glfwInit()) + return 1; + + // Decide GL+GLSL versions +#if defined(IMGUI_IMPL_OPENGL_ES2) + // GL ES 2.0 + GLSL 100 + const char* glsl_version = "#version 100"; + glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 2); + glfwWindowHint(GLFW_CONTEXT_VERSION_MINOR, 0); + glfwWindowHint(GLFW_CLIENT_API, GLFW_OPENGL_ES_API); +#elif defined(__APPLE__) + // GL 3.2 + GLSL 150 + const char* glsl_version = "#version 150"; + glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 3); + glfwWindowHint(GLFW_CONTEXT_VERSION_MINOR, 2); + glfwWindowHint(GLFW_OPENGL_PROFILE, GLFW_OPENGL_CORE_PROFILE); // 3.2+ only + glfwWindowHint(GLFW_OPENGL_FORWARD_COMPAT, GL_TRUE); // Required on Mac +#else + // GL 3.0 + GLSL 130 + const char* glsl_version = "#version 130"; + glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 3); + glfwWindowHint(GLFW_CONTEXT_VERSION_MINOR, 0); + //glfwWindowHint(GLFW_OPENGL_PROFILE, GLFW_OPENGL_CORE_PROFILE); // 3.2+ only + //glfwWindowHint(GLFW_OPENGL_FORWARD_COMPAT, GL_TRUE); // 3.0+ only +#endif + + // Create window with graphics context + GLFWwindow* window = glfwCreateWindow(1280, 720, "Text-Search", nullptr, nullptr); + if (window == nullptr) + return 1; + glfwMakeContextCurrent(window); + glfwSwapInterval(1); // Enable vsync + + IMGUI_CHECKVERSION(); + ImGui::CreateContext(); + ImGuiIO& io = ImGui::GetIO(); (void)io; + io.ConfigFlags |= ImGuiConfigFlags_NavEnableKeyboard; // Enable Keyboard Controls + io.IniFilename = _ts_platform_get_config_file_path(config_path); + + // Setup Platform/Renderer backends + ImGui_ImplGlfw_InitForOpenGL(window, true); + ImGui_ImplOpenGL3_Init(glsl_version); + + // Setup Dear ImGui style + ImGui::Spectrum::StyleColorsSpectrum(); + ImGui::Spectrum::LoadFont(18.0f); + + ts_init(); + ts_load_images(); + ts_load_config(); + + ImVec4 clear_color = ImVec4(0.45f, 0.55f, 0.60f, 1.00f); + int display_w, display_h; + while (!glfwWindowShouldClose(window)) + { + glfwPollEvents(); + + ImGui_ImplOpenGL3_NewFrame(); + ImGui_ImplGlfw_NewFrame(); + ImGui::NewFrame(); + + ts_create_gui(display_w, display_h); + + // Rendering + ImGui::Render(); + glfwGetFramebufferSize(window, &display_w, &display_h); + glViewport(0, 0, display_w, display_h); + glClearColor(clear_color.x * clear_color.w, clear_color.y * clear_color.w, clear_color.z * clear_color.w, clear_color.w); + glClear(GL_COLOR_BUFFER_BIT); + ImGui_ImplOpenGL3_RenderDrawData(ImGui::GetDrawData()); + + glfwSwapBuffers(window); + } + + // Cleanup + ImGui_ImplOpenGL3_Shutdown(); + ImGui_ImplGlfw_Shutdown(); + ImGui::DestroyContext(); + + glfwDestroyWindow(window); + glfwTerminate(); + + return 0; +} + +bool ts_platform_dir_exists(utf8_int8_t* path) { + DIR* dir = opendir(path); + if (dir) { + /* Directory exists. */ + closedir(dir); + return true; + } else if (ENOENT == errno) { + return false; // does not exist + } else { + return false; // error opening dir + } +} + +ts_file_content ts_platform_read_file(char *path, const char *mode) { + ts_file_content result; + result.content = 0; + result.content_length = 0; + result.file_error = 0; + + FILE *file = fopen(path, mode); + + if (!file) + { + if (errno == EMFILE) + result.file_error = FILE_ERROR_TOO_MANY_OPEN_FILES_PROCESS; + else if (errno == ENFILE) + result.file_error = FILE_ERROR_TOO_MANY_OPEN_FILES_SYSTEM; + else if (errno == EACCES) + result.file_error = FILE_ERROR_NO_ACCESS; + else if (errno == EPERM) + result.file_error = FILE_ERROR_NO_ACCESS; + else if (errno == ENOENT) + result.file_error = FILE_ERROR_NOT_FOUND; + else if (errno == ECONNABORTED) + result.file_error = FILE_ERROR_CONNECTION_ABORTED; + else if (errno == ECONNREFUSED) + result.file_error = FILE_ERROR_CONNECTION_REFUSED; + else if (errno == ENETDOWN) + result.file_error = FILE_ERROR_NETWORK_DOWN; + else if (errno == ESTALE) + result.file_error = FILE_ERROR_STALE; + else + { + result.file_error = FILE_ERROR_GENERIC; + } + + return result; + } + + fseek(file, 0 , SEEK_END); + int length = ftell(file); + fseek(file, 0, SEEK_SET); + + int length_to_alloc = length+1; + + result.content = malloc(length_to_alloc); + if (!result.content) { + fclose(file); + return result; + } + + memset(result.content, 0, length); + int read_result = fread(result.content, 1, length, file); + if (read_result == 0 && length != 0) + { + free(result.content); + result.content = 0; + return result; + } + + result.content_length = read_result; + + ((char*)result.content)[length] = 0; + + fclose(file); + return result; +} + +void ts_platform_list_files_block(ts_search_result* result, wchar_t* start_dir) { + + utf8_int8_t* search_dir = (utf8_int8_t*)ts_memory_bucket_reserve(&result->memory, MAX_INPUT_LENGTH); + if (start_dir == nullptr) { + strcpy(search_dir, result->directory_to_search); + } + else { + strcpy(search_dir, (char*)start_dir); + } + + // Append wildcard + utf8_int8_t* search_dir_fix = (utf8_int8_t*)ts_memory_bucket_reserve(&result->memory, MAX_INPUT_LENGTH); + strcpy(search_dir_fix, search_dir); + strcat(search_dir_fix, u8"/*"); + + DIR *d; + struct dirent *dir; + d = opendir(search_dir); + if (d) { + if (chdir(search_dir) != 0) return; + while ((dir = readdir(d)) != NULL) { + if (result->cancel_search) return; + if (chdir(search_dir) != 0) continue; + + if (dir->d_type == DT_DIR) + { + if ((strcmp(dir->d_name, ".") == 0) || (strcmp(dir->d_name, "..") == 0)) + continue; + + utf8_int8_t complete_file_path[MAX_INPUT_LENGTH]; + strcpy(complete_file_path, search_dir); + strcat(complete_file_path, "/"); + strcat(complete_file_path, dir->d_name); + + // do recursive search + ts_platform_list_files_block(result, (wchar_t*)complete_file_path); + } + // we handle DT_UNKNOWN for file systems that do not support type lookup. + else if (dir->d_type == DT_REG || dir->d_type == DT_UNKNOWN) + { + char *matched_filter = 0; + if (ts_filter_matches(&result->filters, dir->d_name, &matched_filter) == (size_t)-1) { + continue; + } + (void)matched_filter; + + + utf8_int8_t complete_file_path[MAX_INPUT_LENGTH]; + strcpy(complete_file_path, search_dir); + strcat(complete_file_path, "/"); + strcat(complete_file_path, dir->d_name); + + ts_found_file* f = (ts_found_file*)ts_memory_bucket_reserve(&result->memory, sizeof(ts_found_file)); + f->path = (utf8_int8_t*)ts_memory_bucket_reserve(&result->memory, MAX_INPUT_LENGTH); + f->match_count = 0; + f->error = 0; + f->collapsed = false; + strcpy(f->path, complete_file_path); + + ts_mutex_lock(&result->files.mutex); + ts_array_push_size(&result->files, &f, sizeof(ts_found_file*)); + ts_mutex_unlock(&result->files.mutex); + } + } + closedir(d); + } +} + +uint64_t ts_platform_get_time(uint64_t compare) { + struct timespec tms; + if (clock_gettime(CLOCK_PROCESS_CPUTIME_ID,&tms)) { + return -1; + } + uint64_t result = 0; + result = tms.tv_sec * 1000; + result += tms.tv_nsec / 1000000; + + if (compare != 0) { + return (result - compare); + } + + return result; +} + +void ts_platform_open_file_as(utf8_int8_t* str) { + // not implemented +} + +void ts_platform_open_file_in_folder(utf8_int8_t* file) { + // not implemented +}
\ No newline at end of file diff --git a/src/osx/mutex.cpp b/src/osx/mutex.cpp new file mode 100644 index 0000000..bd20f8f --- /dev/null +++ b/src/osx/mutex.cpp @@ -0,0 +1,127 @@ +#include "mutex.h" + +ts_thread ts_thread_start(void *(*start_routine) (void *), void *arg) +{ + ts_thread result; + result.valid = false; + + pthread_attr_t attr; + int attr_init_result = pthread_attr_init(&attr); + if (attr_init_result) + return result; + + int start_thread_result = pthread_create(&result.thread, &attr, start_routine, arg); + if (start_thread_result) + { + pthread_attr_destroy(&attr); + return result; + } + + result.valid = true; + pthread_attr_destroy(&attr); + + return result; +} + +void ts_thread_detach(ts_thread *ts_thread) +{ + if (ts_thread->valid) + { + pthread_detach(ts_thread->thread); + } +} + +void ts_thread_join(ts_thread *ts_thread) +{ + if (ts_thread->valid) + { + void *retval; + pthread_join(ts_thread->thread, &retval); + } +} + +bool ts_thread_tryjoin(ts_thread *ts_thread) +{ + if (ts_thread->valid) + { + void *retval; + bool thread_joined = !pthread_join(ts_thread->thread, &retval); + return thread_joined; + } + return false; +} + +void ts_thread_exit() +{ + pthread_exit(0); +} + +void ts_thread_stop(ts_thread *ts_thread) +{ + if (ts_thread->valid) + { + pthread_cancel(ts_thread->thread); + } +} + +ts_mutex ts_mutex_create() +{ + ts_mutex result; + + pthread_mutexattr_t attr; + pthread_mutexattr_init(&attr); + pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_DEFAULT); + + pthread_mutex_init(&result.mutex, &attr); + + pthread_mutexattr_destroy(&attr); + + return result; +} + +ts_mutex ts_mutex_create_recursive() +{ + ts_mutex result; + + pthread_mutexattr_t attr; + pthread_mutexattr_init(&attr); + pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE); + + pthread_mutex_init(&result.mutex, &attr); + + pthread_mutexattr_destroy(&attr); + + return result; +} + +void ts_mutex_lock(ts_mutex *ts_mutex) +{ + pthread_mutex_lock(&ts_mutex->mutex); +} + +bool ts_mutex_trylock(ts_mutex *ts_mutex) +{ + return !pthread_mutex_trylock(&ts_mutex->mutex); +} + +void ts_mutex_unlock(ts_mutex *ts_mutex) +{ + pthread_mutex_unlock(&ts_mutex->mutex); +} + +void ts_mutex_destroy(ts_mutex *ts_mutex) +{ + ts_mutex_unlock(ts_mutex); + pthread_mutex_destroy(&ts_mutex->mutex); +} + +int ts_thread_get_id() +{ + //return (int)syscall(SYS_gettid); + return -1; +} + +void ts_thread_sleep(int microseconds) +{ + usleep(microseconds); +}
\ No newline at end of file |
