diff --git a/Cargo.lock b/Cargo.lock index 40e8bdc..fd59f3d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2,12 +2,6 @@ # It is not intended for manual editing. version = 3 -[[package]] -name = "ab_glyph_rasterizer" -version = "0.1.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c71b1793ee61086797f5c80b6efa2b8ffa6d5dd703f118545808a7f2e27f7046" - [[package]] name = "abi_stable" version = "0.10.5" @@ -19,7 +13,7 @@ dependencies = [ "core_extensions", "crossbeam-channel", "generational-arena", - "libloading 0.7.4", + "libloading", "lock_api", "once_cell", "parking_lot", @@ -56,21 +50,6 @@ dependencies = [ "core_extensions", ] -[[package]] -name = "addr2line" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a76fd60b23679b7d19bd066031410fb7e458ccc5e958eb5c325888ce4baedc97" -dependencies = [ - "gimli", -] - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - [[package]] name = "ahash" version = "0.8.0" @@ -82,25 +61,6 @@ dependencies = [ "version_check", ] -[[package]] -name = "andrew" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c4afb09dd642feec8408e33f92f3ffc4052946f6b20f32fb99c1f58cd4fa7cf" -dependencies = [ - "bitflags", - "rusttype", - "walkdir", - "xdg", - "xml-rs", -] - -[[package]] -name = "android_glue" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "000444226fcff248f2bc4c7625be32c63caccfecc2723a2b9f78a7487a49c407" - [[package]] name = "as_derive_utils" version = "0.10.3" @@ -119,21 +79,6 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" -[[package]] -name = "backtrace" -version = "0.3.67" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "233d376d6d185f2a3093e58f283f60f880315b6c60075b01f36b3b85154564ca" -dependencies = [ - "addr2line", - "cc", - "cfg-if 1.0.0", - "libc", - "miniz_oxide", - "object", - "rustc-demangle", -] - [[package]] name = "bit_field" version = "0.10.2" @@ -146,34 +91,12 @@ version = "1.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" -[[package]] -name = "block" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d8c1fef690941d3e7788d328517591fecc684c084084702d6ff1641e993699a" - [[package]] name = "bumpalo" version = "3.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0d261e256854913907f67ed06efbc3338dfe6179796deefc1ff763fc1aee5535" -[[package]] -name = "calloop" -version = "0.6.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b036167e76041694579972c28cf4877b4f92da222560ddb49008937b6a6727c" -dependencies = [ - "log", - "nix 0.18.0", -] - -[[package]] -name = "cc" -version = "1.0.79" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50d30906286121d95be3d479533b458f87493b30a4b5f79a607db8f5d11aa91f" - [[package]] name = "cfg-if" version = "0.1.10" @@ -186,15 +109,6 @@ version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" -[[package]] -name = "cgl" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ced0551234e87afee12411d535648dd89d2e7f34c78b753395567aff3d447ff" -dependencies = [ - "libc", -] - [[package]] name = "cglue" version = "0.2.12" @@ -216,7 +130,7 @@ checksum = "f713559a7e76bef29ef6eafb64d05fca776a177bb369be02bbea342dc42ffce8" dependencies = [ "itertools", "lazy_static", - "proc-macro-crate 1.1.3", + "proc-macro-crate", "proc-macro2", "quote", "syn 1.0.109", @@ -234,12 +148,6 @@ dependencies = [ "syn 1.0.109", ] -[[package]] -name = "chlorine" -version = "1.0.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75476fe966a8af7c0ceae2a3e514afa87d4451741fcdfab8bfaa07ad301842ec" - [[package]] name = "coarsetime" version = "0.1.23" @@ -252,135 +160,6 @@ dependencies = [ "wasm-bindgen", ] -[[package]] -name = "cocoa" -version = "0.23.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c54201c07dcf3a5ca33fececb8042aed767ee4bfd5a0235a8ceabcda956044b2" -dependencies = [ - "bitflags", - "block", - "cocoa-foundation", - "core-foundation 0.9.3", - "core-graphics 0.22.3", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "cocoa" -version = "0.24.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f425db7937052c684daec3bd6375c8abe2d146dca4b8b143d6db777c39138f3a" -dependencies = [ - "bitflags", - "block", - "cocoa-foundation", - "core-foundation 0.9.3", - "core-graphics 0.22.3", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "cocoa-foundation" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "931d3837c286f56e3c58423ce4eba12d08db2374461a785c86f672b08b5650d6" -dependencies = [ - "bitflags", - "block", - "core-foundation 0.9.3", - "core-graphics-types", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "core-foundation" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57d24c7a13c43e870e37c1556b74555437870a04514f7685f5b354e090567171" -dependencies = [ - "core-foundation-sys 0.7.0", - "libc", -] - -[[package]] -name = "core-foundation" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "194a7a9e6de53fa55116934067c844d9d749312f75c6f6d0980e8c252f8c2146" -dependencies = [ - "core-foundation-sys 0.8.3", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3a71ab494c0b5b860bdc8407ae08978052417070c2ced38573a9157ad75b8ac" - -[[package]] -name = "core-foundation-sys" -version = "0.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5827cebf4670468b8772dd191856768aedcb1b0278a04f989f7766351917b9dc" - -[[package]] -name = "core-graphics" -version = "0.19.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3889374e6ea6ab25dba90bb5d96202f61108058361f6dc72e8b03e6f8bbe923" -dependencies = [ - "bitflags", - "core-foundation 0.7.0", - "foreign-types", - "libc", -] - -[[package]] -name = "core-graphics" -version = "0.22.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2581bbab3b8ffc6fcbd550bf46c355135d16e9ff2a6ea032ad6b9bf1d7efe4fb" -dependencies = [ - "bitflags", - "core-foundation 0.9.3", - "core-graphics-types", - "foreign-types", - "libc", -] - -[[package]] -name = "core-graphics-types" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a68b68b3446082644c91ac778bf50cd4104bfb002b5a6a7c44cca5a2c70788b" -dependencies = [ - "bitflags", - "core-foundation 0.9.3", - "foreign-types", - "libc", -] - -[[package]] -name = "core-video-sys" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34ecad23610ad9757664d644e369246edde1803fcb43ed72876565098a5d3828" -dependencies = [ - "cfg-if 0.1.10", - "core-foundation-sys 0.7.0", - "core-graphics 0.19.2", - "libc", - "objc", -] - [[package]] name = "core_extensions" version = "1.5.3" @@ -415,44 +194,14 @@ dependencies = [ "cfg-if 1.0.0", ] -[[package]] -name = "cty" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b365fabc795046672053e29c954733ec3b05e4be654ab130fe8f1f94d7051f35" - -[[package]] -name = "darling" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d706e75d87e35569db781a9b5e2416cff1236a47ed380831f959382ccd5f858" -dependencies = [ - "darling_core 0.10.2", - "darling_macro 0.10.2", -] - [[package]] name = "darling" version = "0.13.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c" dependencies = [ - "darling_core 0.13.4", - "darling_macro 0.13.4", -] - -[[package]] -name = "darling_core" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0c960ae2da4de88a91b2d920c2a7233b400bc33cb28453a2987822d8392519b" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim 0.9.3", - "syn 1.0.109", + "darling_core", + "darling_macro", ] [[package]] @@ -465,18 +214,7 @@ dependencies = [ "ident_case", "proc-macro2", "quote", - "strsim 0.10.0", - "syn 1.0.109", -] - -[[package]] -name = "darling_macro" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9b5a2f4ac4969822c62224815d069952656cadc7084fdca9751e6d959189b72" -dependencies = [ - "darling_core 0.10.2", - "quote", + "strsim", "syn 1.0.109", ] @@ -486,7 +224,7 @@ version = "0.13.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" dependencies = [ - "darling_core 0.13.4", + "darling_core", "quote", "syn 1.0.109", ] @@ -503,17 +241,6 @@ version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "50eb3a329e19d78c3a3dfa4ec5a51ecb84fa3a20c06edad04be25356018218f9" -[[package]] -name = "derivative" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - [[package]] name = "dirs" version = "4.0.0" @@ -531,39 +258,9 @@ checksum = "1b1d1d91c932ef41c0f2663aa8b0ca0342d444d842c06914aa0a7e352d0bada6" dependencies = [ "libc", "redox_users", - "winapi 0.3.9", + "winapi", ] -[[package]] -name = "dispatch" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd0c93bb4b0c6d9b77f4435b0ae98c24d17f1c45b2ff844c6151a07256ca923b" - -[[package]] -name = "dlib" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b11f15d1e3268f140f68d390637d5e76d849782d971ae7063e0da69fe9709a76" -dependencies = [ - "libloading 0.6.7", -] - -[[package]] -name = "dlib" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac1b7517328c04c2aa68422fc60a41b92208182142ed04a25879c26c8f878794" -dependencies = [ - "libloading 0.7.4", -] - -[[package]] -name = "downcast-rs" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ea835d29036a4087793836fa931b08837ad5e957da9e23886b29586fb9b6650" - [[package]] name = "either" version = "1.8.1" @@ -582,37 +279,6 @@ version = "1.0.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "fuchsia-zircon" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e9763c69ebaae630ba35f74888db465e49e259ba1bc0eda7d06f4a067615d82" -dependencies = [ - "bitflags", - "fuchsia-zircon-sys", -] - -[[package]] -name = "fuchsia-zircon-sys" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dcaa9ae7725d12cdb85b3ad99a434db70b468c09ded17e012d86b5c1010f7a7" - [[package]] name = "generational-arena" version = "0.2.8" @@ -633,111 +299,6 @@ dependencies = [ "wasi", ] -[[package]] -name = "gimli" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad0a93d233ebf96623465aad4046a8d3aa4da22d4f4beba5388838c8a434bbb4" - -[[package]] -name = "gl_generator" -version = "0.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a95dfc23a2b4a9a2f5ab41d194f8bfda3cabec42af4e39f08c339eb2a0c124d" -dependencies = [ - "khronos_api", - "log", - "xml-rs", -] - -[[package]] -name = "glium" -version = "0.29.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0a58e115545ab8ce2238630c06a60f30a835271e3aff861db08d81561643d7a9" -dependencies = [ - "backtrace", - "fnv", - "gl_generator", - "glutin", - "lazy_static", - "memoffset", - "smallvec", - "takeable-option", -] - -[[package]] -name = "glutin" -version = "0.26.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ae1cbb9176b9151c4ce03f012e3cd1c6c18c4be79edeaeb3d99f5d8085c5fa3" -dependencies = [ - "android_glue", - "cgl", - "cocoa 0.23.0", - "core-foundation 0.9.3", - "glutin_egl_sys", - "glutin_emscripten_sys", - "glutin_gles2_sys", - "glutin_glx_sys", - "glutin_wgl_sys", - "lazy_static", - "libloading 0.6.7", - "log", - "objc", - "osmesa-sys", - "parking_lot", - "wayland-client", - "wayland-egl", - "winapi 0.3.9", - "winit", -] - -[[package]] -name = "glutin_egl_sys" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68900f84b471f31ea1d1355567eb865a2cf446294f06cef8d653ed7bcf5f013d" -dependencies = [ - "gl_generator", - "winapi 0.3.9", -] - -[[package]] -name = "glutin_emscripten_sys" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80de4146df76e8a6c32b03007bc764ff3249dcaeb4f675d68a06caf1bac363f1" - -[[package]] -name = "glutin_gles2_sys" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8094e708b730a7c8a1954f4f8a31880af00eb8a1c5b5bf85d28a0a3c6d69103" -dependencies = [ - "gl_generator", - "objc", -] - -[[package]] -name = "glutin_glx_sys" -version = "0.1.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d93d0575865098580c5b3a423188cd959419912ea60b1e48e8b3b526f6d02468" -dependencies = [ - "gl_generator", - "x11-dl", -] - -[[package]] -name = "glutin_wgl_sys" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3da5951a1569dbab865c6f2a863efafff193a93caf05538d193e9e3816d21696" -dependencies = [ - "gl_generator", -] - [[package]] name = "goblin" version = "0.5.4" @@ -770,47 +331,6 @@ version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" -[[package]] -name = "imgui" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24cfcf6e3326886321c5d637caf1ce217006651059015fae372b1c49c0e722b2" -dependencies = [ - "bitflags", - "imgui-sys", - "parking_lot", -] - -[[package]] -name = "imgui-glium-renderer" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c295c510c0d7209cf2304741808425bcd8e421142679d2448a38d4aa51762f3" -dependencies = [ - "glium", - "imgui", -] - -[[package]] -name = "imgui-sys" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85ca00be6b78bf02b57e91468cf19d08dfcc11d0fb3c2f3dc491c29404d8d330" -dependencies = [ - "cc", - "chlorine", -] - -[[package]] -name = "imgui-winit-support" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22ae881a42852470216c77fba5835b9701815adac24dfaa8d4ebf3a368376756" -dependencies = [ - "imgui", - "winit", -] - [[package]] name = "indexmap" version = "1.9.3" @@ -830,15 +350,6 @@ dependencies = [ "cfg-if 1.0.0", ] -[[package]] -name = "iovec" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2b3ea6ff95e175473f8ffe6a7eb7c00d054240321b84c57051175fe3c1e075e" -dependencies = [ - "libc", -] - [[package]] name = "itertools" version = "0.10.5" @@ -854,56 +365,18 @@ version = "1.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "453ad9f582a441959e5f0d088b02ce04cfe8d51a8eaf077f12ac6d3e94164ca6" -[[package]] -name = "jni-sys" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaf4bc02d17cbdd7ff4c7438cafcdf7fb9a4613313ad11b4f8fefe7d3fa0130" - -[[package]] -name = "kernel32-sys" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7507624b29483431c0ba2d82aece8ca6cdba9382bff4ddd0f7490560c056098d" -dependencies = [ - "winapi 0.2.8", - "winapi-build", -] - -[[package]] -name = "khronos_api" -version = "3.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2db585e1d738fc771bf08a151420d3ed193d9d895a36df7f6f8a9456b911ddc" - [[package]] name = "lazy_static" version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" -[[package]] -name = "lazycell" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55" - [[package]] name = "libc" version = "0.2.140" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "99227334921fae1a979cf0bfdfcc6b3e5ce376ef57e16fb6fb3ea2ed6095f80c" -[[package]] -name = "libloading" -version = "0.6.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "351a32417a12d5f7e82c368a66781e307834dae04c6ce0cd4456d52989229883" -dependencies = [ - "cfg-if 1.0.0", - "winapi 0.3.9", -] - [[package]] name = "libloading" version = "0.7.4" @@ -911,7 +384,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b67380fd3b2fbe7527a606e18729d21c6f3951633d0500574c4dc22d2d638b9f" dependencies = [ "cfg-if 1.0.0", - "winapi 0.3.9", + "winapi", ] [[package]] @@ -919,340 +392,103 @@ name = "lock_api" version = "0.4.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "435011366fe56583b16cf956f9df0095b405b82d76425bc8981c0e22e60ec4df" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "log" -version = "0.4.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" -dependencies = [ - "cfg-if 1.0.0", -] - -[[package]] -name = "malloc_buf" -version = "0.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62bb907fe88d54d8d9ce32a3cceab4218ed2f6b7d35617cafe9adf84e43919cb" -dependencies = [ - "libc", -] - -[[package]] -name = "memchr" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" - -[[package]] -name = "memflow" -version = "0.2.0-beta10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7f18ed9240420aadc21d8ba082e4a27c526fd3155a829b4de94013eb7855766" -dependencies = [ - "abi_stable", - "bitflags", - "bumpalo", - "cglue", - "coarsetime", - "dataview 1.0.1", - "dirs", - "fixed-slice-vec", - "goblin", - "hashbrown 0.13.2", - "itertools", - "libloading 0.7.4", - "log", - "memflow-derive", - "memmap", - "no-std-compat", - "once_cell", - "pelite", - "rangemap", - "serde", - "smallvec", - "toml 0.7.3", - "x86_64", -] - -[[package]] -name = "memflow-derive" -version = "0.2.0-beta3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee50e66f855a8a9c93b7c107fab899b25952ba8c7f0e97602a662a99c84fbef7" -dependencies = [ - "darling 0.13.4", - "proc-macro-crate 1.1.3", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "memflow-reclass-plugin" -version = "0.2.0-beta10" -dependencies = [ - "glium", - "imgui", - "imgui-glium-renderer", - "imgui-winit-support", - "log", - "memflow", - "serde", - "simple-logging", - "toml 0.7.3", - "winres", -] - -[[package]] -name = "memmap" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6585fd95e7bb50d6cc31e20d4cf9afb4e2ba16c5846fc76793f11218da9c475b" -dependencies = [ - "libc", - "winapi 0.3.9", -] - -[[package]] -name = "memmap2" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9b70ca2a6103ac8b665dc150b142ef0e4e89df640c9e6cf295d189c3caebe5a" -dependencies = [ - "libc", -] - -[[package]] -name = "memoffset" -version = "0.6.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5aa361d4faea93603064a027415f07bd8e1d5c88c9fbf68bf56a285428fd79ce" -dependencies = [ - "autocfg", -] - -[[package]] -name = "minimal-lexical" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" - -[[package]] -name = "miniz_oxide" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b275950c28b37e794e8c55d88aeb5e139d0ce23fdbbeda68f8d7174abdf9e8fa" -dependencies = [ - "adler", -] - -[[package]] -name = "mio" -version = "0.6.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4afd66f5b91bf2a3bc13fad0e21caedac168ca4c707504e75585648ae80e4cc4" -dependencies = [ - "cfg-if 0.1.10", - "fuchsia-zircon", - "fuchsia-zircon-sys", - "iovec", - "kernel32-sys", - "libc", - "log", - "miow", - "net2", - "slab", - "winapi 0.2.8", -] - -[[package]] -name = "mio-extras" -version = "2.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52403fe290012ce777c4626790c8951324a2b9e3316b3143779c72b029742f19" -dependencies = [ - "lazycell", - "log", - "mio", - "slab", -] - -[[package]] -name = "miow" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ebd808424166322d4a38da87083bfddd3ac4c131334ed55856112eb06d46944d" -dependencies = [ - "kernel32-sys", - "net2", - "winapi 0.2.8", - "ws2_32-sys", -] - -[[package]] -name = "ndk" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5eb167c1febed0a496639034d0c76b3b74263636045db5489eee52143c246e73" -dependencies = [ - "jni-sys", - "ndk-sys", - "num_enum", - "thiserror", -] - -[[package]] -name = "ndk-glue" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bdf399b8b7a39c6fb153c4ec32c72fd5fe789df24a647f229c239aa7adb15241" -dependencies = [ - "lazy_static", - "libc", - "log", - "ndk", - "ndk-macro", - "ndk-sys", -] - -[[package]] -name = "ndk-macro" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05d1c6307dc424d0f65b9b06e94f88248e6305726b14729fd67a5e47b2dc481d" -dependencies = [ - "darling 0.10.2", - "proc-macro-crate 0.1.5", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "ndk-sys" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1bcdd74c20ad5d95aacd60ef9ba40fdf77f767051040541df557b7a9b2a2121" - -[[package]] -name = "net2" -version = "0.2.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74d0df99cfcd2530b2e694f6e17e7f37b8e26bb23983ac530c0c97408837c631" -dependencies = [ - "cfg-if 0.1.10", - "libc", - "winapi 0.3.9", -] - -[[package]] -name = "nix" -version = "0.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83450fe6a6142ddd95fb064b746083fc4ef1705fe81f64a64e1d4b39f54a1055" -dependencies = [ - "bitflags", - "cc", - "cfg-if 0.1.10", - "libc", +dependencies = [ + "autocfg", + "scopeguard", ] [[package]] -name = "nix" -version = "0.20.0" +name = "log" +version = "0.4.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa9b4819da1bc61c0ea48b63b7bc8604064dd43013e7cc325df098d49cd7c18a" +checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" dependencies = [ - "bitflags", - "cc", "cfg-if 1.0.0", - "libc", ] [[package]] -name = "no-std-compat" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b93853da6d84c2e3c7d730d6473e8817692dd89be387eb01b94d7f108ecb5b8c" - -[[package]] -name = "nom" -version = "7.1.3" +name = "memchr" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d273983c5a657a70a3e8f2a01329822f3b8c8172b73826411a55751e404a0a4a" -dependencies = [ - "memchr", - "minimal-lexical", -] +checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" [[package]] -name = "num_enum" -version = "0.4.3" +name = "memflow" +version = "0.2.0-beta10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca565a7df06f3d4b485494f25ba05da1435950f4dc263440eda7a6fa9b8e36e4" +checksum = "a7f18ed9240420aadc21d8ba082e4a27c526fd3155a829b4de94013eb7855766" dependencies = [ - "derivative", - "num_enum_derive", + "abi_stable", + "bitflags", + "bumpalo", + "cglue", + "coarsetime", + "dataview 1.0.1", + "dirs", + "fixed-slice-vec", + "goblin", + "hashbrown 0.13.2", + "itertools", + "libloading", + "log", + "memflow-derive", + "memmap", + "no-std-compat", + "once_cell", + "pelite", + "rangemap", + "serde", + "smallvec", + "toml 0.7.3", + "x86_64", ] [[package]] -name = "num_enum_derive" -version = "0.4.3" +name = "memflow-derive" +version = "0.2.0-beta3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffa5a33ddddfee04c0283a7653987d634e880347e96b5b2ed64de07efb59db9d" +checksum = "ee50e66f855a8a9c93b7c107fab899b25952ba8c7f0e97602a662a99c84fbef7" dependencies = [ - "proc-macro-crate 0.1.5", + "darling", + "proc-macro-crate", "proc-macro2", "quote", "syn 1.0.109", ] [[package]] -name = "objc" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "915b1b472bc21c53464d6c8461c9d3af805ba1ef837e1cac254428f4a77177b1" +name = "memflow-reclass-plugin" +version = "0.2.0-beta10" dependencies = [ - "malloc_buf", + "log", + "memflow", + "serde", + "simple-logging", + "toml 0.7.3", + "winres", ] [[package]] -name = "object" -version = "0.30.3" +name = "memmap" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea86265d3d3dcb6a27fc51bd29a4bf387fae9d2986b823079d4986af253eb439" +checksum = "6585fd95e7bb50d6cc31e20d4cf9afb4e2ba16c5846fc76793f11218da9c475b" dependencies = [ - "memchr", + "libc", + "winapi", ] [[package]] -name = "once_cell" -version = "1.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da32515d9f6e6e489d7bc9d84c71b060db7247dc035bbe44eac88cf87486d8d5" - -[[package]] -name = "osmesa-sys" -version = "0.1.2" +name = "no-std-compat" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88cfece6e95d2e717e0872a7f53a8684712ad13822a7979bc760b9c77ec0013b" -dependencies = [ - "shared_library", -] +checksum = "b93853da6d84c2e3c7d730d6473e8817692dd89be387eb01b94d7f108ecb5b8c" [[package]] -name = "owned_ttf_parser" -version = "0.15.2" +name = "once_cell" +version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05e6affeb1632d6ff6a23d2cd40ffed138e82f1532571a26f527c8a284bb2fbb" -dependencies = [ - "ttf-parser", -] +checksum = "da32515d9f6e6e489d7bc9d84c71b060db7247dc035bbe44eac88cf87486d8d5" [[package]] name = "parking_lot" @@ -1276,7 +512,7 @@ dependencies = [ "libc", "redox_syscall 0.2.16", "smallvec", - "winapi 0.3.9", + "winapi", ] [[package]] @@ -1302,33 +538,12 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7a7cf3f8ecebb0f4895f4892a8be0a0dc81b498f9d56735cb769dc31bf00815b" -[[package]] -name = "percent-encoding" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e" - -[[package]] -name = "pkg-config" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ac9a59f73473f1b8d852421e59e64809f025994837ef743615c6d0c5b305160" - [[package]] name = "plain" version = "0.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b4596b6d070b27117e987119b4dac604f3c58cfb0b191112e24771b2faeac1a6" -[[package]] -name = "proc-macro-crate" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d6ea3c4595b96363c13943497db34af4460fb474a95c43f4446ad341b8c9785" -dependencies = [ - "toml 0.5.11", -] - [[package]] name = "proc-macro-crate" version = "1.1.3" @@ -1363,25 +578,6 @@ version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8b9283c6b06096b47afc7109834fdedab891175bb5241ee5d4f7d2546549f263" -[[package]] -name = "raw-window-handle" -version = "0.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e28f55143d0548dad60bb4fbdc835a3d7ac6acc3324506450c5fdd6e42903a76" -dependencies = [ - "libc", - "raw-window-handle 0.4.3", -] - -[[package]] -name = "raw-window-handle" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b800beb9b6e7d2df1fe337c9e3d04e3af22a124460fb4c30fcc22c9117cefb41" -dependencies = [ - "cty", -] - [[package]] name = "redox_syscall" version = "0.1.57" @@ -1417,12 +613,6 @@ dependencies = [ "tstr", ] -[[package]] -name = "rustc-demangle" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4a36c42d1873f9a77c53bde094f9664d9891bc604a45b4798fd2c389ed12e5b" - [[package]] name = "rustc_version" version = "0.2.3" @@ -1441,16 +631,6 @@ dependencies = [ "semver 1.0.17", ] -[[package]] -name = "rusttype" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ff8374aa04134254b7995b63ad3dc41c7f7236f69528b28553da7d72efaa967" -dependencies = [ - "ab_glyph_rasterizer", - "owned_ttf_parser", -] - [[package]] name = "rustversion" version = "1.0.12" @@ -1463,21 +643,6 @@ version = "1.0.13" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f91339c0467de62360649f8d3e185ca8de4224ff281f66000de5eb2a77a79041" -[[package]] -name = "same-file" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" -dependencies = [ - "winapi-util", -] - -[[package]] -name = "scoped-tls" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1cf6437eb19a8f4a6cc0f7dca544973b0b78843adbfeb3683d1a94a0024a294" - [[package]] name = "scopeguard" version = "1.1.0" @@ -1565,16 +730,6 @@ dependencies = [ "serde", ] -[[package]] -name = "shared_library" -version = "0.1.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a9e7e0f2bfae24d8a5b5a66c5b257a83c7412304311512a0c054cd5e619da11" -dependencies = [ - "lazy_static", - "libc", -] - [[package]] name = "simple-logging" version = "2.0.2" @@ -1586,46 +741,12 @@ dependencies = [ "thread-id", ] -[[package]] -name = "slab" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6528351c9bc8ab22353f9d776db39a20288e8d6c37ef8cfe3317cf875eecfc2d" -dependencies = [ - "autocfg", -] - [[package]] name = "smallvec" version = "1.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a507befe795404456341dfab10cef66ead4c041f62b8b11bbb92bffe5d0953e0" -[[package]] -name = "smithay-client-toolkit" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4750c76fd5d3ac95fa3ed80fe667d6a3d8590a960e5b575b98eea93339a80b80" -dependencies = [ - "andrew", - "bitflags", - "calloop", - "dlib 0.4.2", - "lazy_static", - "log", - "memmap2", - "nix 0.18.0", - "wayland-client", - "wayland-cursor", - "wayland-protocols", -] - -[[package]] -name = "strsim" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6446ced80d6c486436db5c078dde11a9f73d42b57fb273121e160b84f63d894c" - [[package]] name = "strsim" version = "0.10.0" @@ -1654,12 +775,6 @@ dependencies = [ "unicode-ident", ] -[[package]] -name = "takeable-option" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "36ae8932fcfea38b7d3883ae2ab357b0d57a02caaa18ebb4f5ece08beaec4aa0" - [[package]] name = "thiserror" version = "1.0.40" @@ -1688,7 +803,7 @@ checksum = "c7fbf4c9d56b320106cd64fd024dadfa0be7cb4706725fc44a7d7ce952d820c1" dependencies = [ "libc", "redox_syscall 0.1.57", - "winapi 0.3.9", + "winapi", ] [[package]] @@ -1749,12 +864,6 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e78122066b0cb818b8afd08f7ed22f7fdbc3e90815035726f0840d0d26c0747a" -[[package]] -name = "ttf-parser" -version = "0.15.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b3e06c9b9d80ed6b745c7159c40b311ad2916abb34a49e9be2653b90db0d8dd" - [[package]] name = "typed-arena" version = "2.0.2" @@ -1779,16 +888,6 @@ version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "442887c63f2c839b346c192d047a7c87e73d0689c9157b00b53dcc27dd5ea793" -[[package]] -name = "walkdir" -version = "2.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "36df944cda56c7d8d8b7496af378e6b16de9284591917d307c9b4d313c44e698" -dependencies = [ - "same-file", - "winapi-util", -] - [[package]] name = "wasi" version = "0.11.0+wasi-snapshot-preview1" @@ -1849,95 +948,6 @@ version = "0.2.81" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6a89911bd99e5f3659ec4acf9c4d93b0a90fe4a2a11f15328472058edc5261be" -[[package]] -name = "wayland-client" -version = "0.28.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3ab332350e502f159382201394a78e3cc12d0f04db863429260164ea40e0355" -dependencies = [ - "bitflags", - "downcast-rs", - "libc", - "nix 0.20.0", - "scoped-tls", - "wayland-commons", - "wayland-scanner", - "wayland-sys", -] - -[[package]] -name = "wayland-commons" -version = "0.28.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a21817947c7011bbd0a27e11b17b337bfd022e8544b071a2641232047966fbda" -dependencies = [ - "nix 0.20.0", - "once_cell", - "smallvec", - "wayland-sys", -] - -[[package]] -name = "wayland-cursor" -version = "0.28.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be610084edd1586d45e7bdd275fe345c7c1873598caa464c4fb835dee70fa65a" -dependencies = [ - "nix 0.20.0", - "wayland-client", - "xcursor", -] - -[[package]] -name = "wayland-egl" -version = "0.28.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99ba1ab1e18756b23982d36f08856d521d7df45015f404a2d7c4f0b2d2f66956" -dependencies = [ - "wayland-client", - "wayland-sys", -] - -[[package]] -name = "wayland-protocols" -version = "0.28.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "286620ea4d803bacf61fa087a4242ee316693099ee5a140796aaba02b29f861f" -dependencies = [ - "bitflags", - "wayland-client", - "wayland-commons", - "wayland-scanner", -] - -[[package]] -name = "wayland-scanner" -version = "0.28.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce923eb2deb61de332d1f356ec7b6bf37094dc5573952e1c8936db03b54c03f1" -dependencies = [ - "proc-macro2", - "quote", - "xml-rs", -] - -[[package]] -name = "wayland-sys" -version = "0.28.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d841fca9aed7febf9bed2e9796c49bf58d4152ceda8ac949ebe00868d8f0feb8" -dependencies = [ - "dlib 0.5.0", - "lazy_static", - "pkg-config", -] - -[[package]] -name = "winapi" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "167dc9d6949a9b857f3451275e911c3f44255842c1f7a76f33c55103a909087a" - [[package]] name = "winapi" version = "0.3.9" @@ -1948,64 +958,18 @@ dependencies = [ "winapi-x86_64-pc-windows-gnu", ] -[[package]] -name = "winapi-build" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d315eee3b34aca4797b2da6b13ed88266e6d612562a0c46390af8299fc699bc" - [[package]] name = "winapi-i686-pc-windows-gnu" version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" -[[package]] -name = "winapi-util" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70ec6ce85bb158151cae5e5c87f95a8e97d2c0c4b001223f33a334e3ce5de178" -dependencies = [ - "winapi 0.3.9", -] - [[package]] name = "winapi-x86_64-pc-windows-gnu" version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" -[[package]] -name = "winit" -version = "0.24.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da4eda6fce0eb84bd0a33e3c8794eb902e1033d0a1d5a31bc4f19b1b4bbff597" -dependencies = [ - "bitflags", - "cocoa 0.24.1", - "core-foundation 0.9.3", - "core-graphics 0.22.3", - "core-video-sys", - "dispatch", - "instant", - "lazy_static", - "libc", - "log", - "mio", - "mio-extras", - "ndk", - "ndk-glue", - "ndk-sys", - "objc", - "parking_lot", - "percent-encoding", - "raw-window-handle 0.3.4", - "smithay-client-toolkit", - "wayland-client", - "winapi 0.3.9", - "x11-dl", -] - [[package]] name = "winnow" version = "0.4.1" @@ -2024,27 +988,6 @@ dependencies = [ "toml 0.5.11", ] -[[package]] -name = "ws2_32-sys" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d59cefebd0c892fa2dd6de581e937301d8552cb44489cdff035c6187cb63fa5e" -dependencies = [ - "winapi 0.2.8", - "winapi-build", -] - -[[package]] -name = "x11-dl" -version = "2.20.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1536d6965a5d4e573c7ef73a2c15ebcd0b2de3347bdf526c34c297c00ac40f0" -dependencies = [ - "lazy_static", - "libc", - "pkg-config", -] - [[package]] name = "x86_64" version = "0.14.10" @@ -2056,27 +999,3 @@ dependencies = [ "rustversion", "volatile", ] - -[[package]] -name = "xcursor" -version = "0.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "463705a63313cd4301184381c5e8042f0a7e9b4bb63653f216311d4ae74690b7" -dependencies = [ - "nom", -] - -[[package]] -name = "xdg" -version = "2.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c4583db5cbd4c4c0303df2d15af80f0539db703fa1c68802d4cbbd2dd0f88f6" -dependencies = [ - "dirs", -] - -[[package]] -name = "xml-rs" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2d7d3948613f75c98fd9328cfdcc45acc4d360655289d0a7d4ec931392200a3" diff --git a/Cargo.toml b/Cargo.toml index 9681cb0..5abf929 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -33,11 +33,5 @@ memflow = { version = "=0.2.0-beta10", features = ["plugins"] } serde = { version = "1.0", features = ["derive"] } toml = "0.7" -# gui -glium = "0.29.0" -imgui = "0.7.0" -imgui-glium-renderer = "0.7.0" -imgui-winit-support = "0.7.0" - [target.'cfg(windows)'.build-dependencies] winres = "0.1" diff --git a/src/config/mod.rs b/src/config/mod.rs new file mode 100644 index 0000000..6e98cef --- /dev/null +++ b/src/config/mod.rs @@ -0,0 +1 @@ +pub mod settings; diff --git a/src/config/settings.rs b/src/config/settings.rs new file mode 100644 index 0000000..8656bbf --- /dev/null +++ b/src/config/settings.rs @@ -0,0 +1,78 @@ +use memflow::prelude::v1::*; +use serde::{Deserialize, Serialize}; + +// see https://github.com/serde-rs/serde/issues/368 +fn default_string_info() -> String { + "info".to_string() +} +fn default_bool_true() -> bool { + true +} + +#[derive(Debug, Clone, Serialize, Deserialize)] +pub struct Config { + pub connector: String, + #[serde(default)] + pub args: String, + + #[serde(default = "default_string_info")] + pub log_level: String, + + // TODO: expose caching options (lifetimes, etc) + #[serde(default = "default_bool_true")] + pub parse_sections: bool, +} + +impl Default for Config { + fn default() -> Config { + Config { + connector: String::new(), + args: String::new(), + + log_level: "info".to_string(), + + parse_sections: false, + } + } +} + +pub struct Settings { + config: Config, +} + +impl Settings { + /// Loads the current config from the {PWD}/Plugins/memflow.toml file. + pub fn new() -> Self { + // load config file + let pwd = std::env::current_dir().expect("unable to get pwd"); + let config = if let Ok(configstr) = + std::fs::read_to_string(pwd.join("Plugins").join("memflow.toml")) + { + toml::from_str::(&configstr).unwrap_or_default() + } else { + Config::default() + }; + + Self { config } + } + + /// Saves the current configuration to the {PWD}/Plugins/memflow.toml file. + pub fn persist(&self) -> Result<()> { + let pwd = std::env::current_dir().map_err(|_| { + Error(ErrorOrigin::Other, ErrorKind::Unknown).log_error("unable to get pwd") + })?; + let configstr = toml::to_string_pretty(&self.config).map_err(|_| { + Error(ErrorOrigin::Other, ErrorKind::Configuration) + .log_error("unable to serialize config") + })?; + std::fs::write(pwd.join("Plugins").join("memflow.toml"), configstr).map_err(|_| { + Error(ErrorOrigin::Other, ErrorKind::NotFound).log_error("unable to write config file") + })?; + Ok(()) + } + + /// Retrieves the current config + pub fn config(&self) -> Config { + self.config.clone() + } +} diff --git a/src/gui/alert.rs b/src/gui/alert.rs deleted file mode 100644 index b4ae310..0000000 --- a/src/gui/alert.rs +++ /dev/null @@ -1,38 +0,0 @@ -use super::support; - -use imgui::*; -use memflow::prelude::v1::Error; - -pub fn show_error(title: &str, text: &str, error: Error) { - show_alert(title, &format!("{}:\n{}", text, error.as_str())) -} - -pub fn show_alert(title: &str, text: &str) { - support::show_window(title, 400.0, 160.0, |run, ui| { - Window::new(im_str!("Warning")) - .position([10.0, 10.0], Condition::Always) - .size([375.0, 1000.0], Condition::Always) - .title_bar(false) - .resizable(false) - .movable(false) - .scroll_bar(false) - .save_settings(false) - .focus_on_appearing(false) - .movable(false) - .build(ui, || { - ui.text(title); - ui.separator(); - - ui.dummy([0.0, 16.0]); - - ui.text(text); - - ui.dummy([0.0, 16.0]); - - if ui.button(im_str!("Ok"), [64.0, 26.0]) { - // close window - *run = false; - } - }); - }) -} diff --git a/src/gui/mod.rs b/src/gui/mod.rs deleted file mode 100644 index 2fc7fc2..0000000 --- a/src/gui/mod.rs +++ /dev/null @@ -1,6 +0,0 @@ -mod support; - -pub mod settings; -pub use settings::{Config, Settings}; - -pub mod alert; diff --git a/src/gui/settings.rs b/src/gui/settings.rs deleted file mode 100644 index 7edf558..0000000 --- a/src/gui/settings.rs +++ /dev/null @@ -1,194 +0,0 @@ -use super::support; - -use imgui::*; -use memflow::prelude::v1::*; -use serde::{Deserialize, Serialize}; - -// see https://github.com/serde-rs/serde/issues/368 -fn default_string_info() -> String { - "info".to_string() -} -fn default_bool_true() -> bool { - true -} - -#[derive(Debug, Clone, Serialize, Deserialize)] -pub struct Config { - pub connector: String, - #[serde(default)] - pub args: String, - - #[serde(default = "default_string_info")] - pub log_level: String, - - // TODO: expose caching options (lifetimes, etc) - #[serde(default = "default_bool_true")] - pub parse_sections: bool, -} - -impl Default for Config { - fn default() -> Config { - Config { - connector: String::new(), - args: String::new(), - - log_level: "info".to_string(), - - parse_sections: false, - } - } -} - -pub struct Settings { - config: Config, -} - -impl Settings { - /// Loads the current config from the {PWD}/Plugins/memflow.toml file. - pub fn new() -> Self { - // load config file - let pwd = std::env::current_dir().expect("unable to get pwd"); - let config = if let Ok(configstr) = - std::fs::read_to_string(pwd.join("Plugins").join("memflow.toml")) - { - toml::from_str::(&configstr).unwrap_or_default() - } else { - Config::default() - }; - - Self { config } - } - - /// Saves the current configuration to the {PWD}/Plugins/memflow.toml file. - pub fn persist(&self) -> Result<()> { - let pwd = std::env::current_dir().map_err(|_| { - Error(ErrorOrigin::Other, ErrorKind::Unknown).log_error("unable to get pwd") - })?; - let configstr = toml::to_string_pretty(&self.config).map_err(|_| { - Error(ErrorOrigin::Other, ErrorKind::Configuration) - .log_error("unable to serialize config") - })?; - std::fs::write(pwd.join("Plugins").join("memflow.toml"), configstr).map_err(|_| { - Error(ErrorOrigin::Other, ErrorKind::NotFound).log_error("unable to write config file") - })?; - Ok(()) - } - - /// Retrieves the current config - pub fn config(&self) -> Config { - self.config.clone() - } - - /// Displays the configuration UI to the user and updates the config - /// This function blocks until the user clicks the "Ok" button. - pub fn configure(&mut self) { - let inventory = Inventory::scan(); - let connectors: Vec = inventory - .available_connectors() - .iter() - .map(|c| ImString::from(c.to_owned())) - .collect::>(); - - let mut connector_idx = connectors - .iter() - .enumerate() - .find(|(_, c)| c.to_str() == self.config.connector) - .map(|(i, _)| i as i32) - .unwrap_or_default(); - let mut connector_args = ImString::from(self.config.args.clone()); - let mut log_level_idx = match self.config.log_level.to_lowercase().as_ref() { - "off" => 0, - "error" => 1, - "warn" => 2, - "info" => 3, - "debug" => 4, - "trace" => 5, - _ => 0, - }; - let mut parse_sections = self.config.parse_sections; - - { - support::show_window("memflow", 400.0, 290.0, |run, ui| { - let connectors_ref: Vec<&ImStr> = - connectors.iter().map(|c| c.as_ref()).collect::>(); - - Window::new(im_str!("memflow")) - .position([10.0, 10.0], Condition::Always) - .size([375.0, 1000.0], Condition::Always) - .title_bar(false) - .resizable(false) - .movable(false) - .scroll_bar(false) - .save_settings(false) - .focus_on_appearing(false) - .movable(false) - .build(ui, || { - ui.text(im_str!("Inventory")); - ui.separator(); - - ui.list_box( - im_str!("Connector"), - &mut connector_idx, - &connectors_ref[..], - 4, - ); - - ui.input_text(im_str!("Args"), &mut connector_args).build(); - - ui.dummy([0.0, 16.0]); - - ui.text(im_str!("Options")); - ui.separator(); - - ComboBox::new(im_str!("Log Level")).build_simple_string( - ui, - &mut log_level_idx, - &[ - im_str!("Off"), - im_str!("Error"), - im_str!("Warn"), - im_str!("Info"), - im_str!("Debug"), - im_str!("Trace"), - ], - ); - - ui.checkbox(im_str!("Parse Sections"), &mut parse_sections); - - // TODO: configure caching - - ui.dummy([0.0, 16.0]); - - if ui.button(im_str!("Load"), [64.0, 26.0]) { - // update config - self.config.connector = connectors - .get(connector_idx as usize) - .map(|c| c.to_string()) - .unwrap_or_default(); - self.config.args = connector_args.to_str().to_owned(); - self.config.log_level = match log_level_idx { - 0 => "off", - 1 => "error", - 2 => "warn", - 3 => "info", - 4 => "debug", - 5 => "trace", - _ => "off", - } - .to_string(); - self.config.parse_sections = parse_sections; - - // close window - *run = false; - } - - ui.same_line(64.0 + 16.0); - - if ui.button(im_str!("Cancel"), [64.0, 26.0]) { - *run = false; - } - }); - }); - } - } -} diff --git a/src/gui/support.rs b/src/gui/support.rs deleted file mode 100644 index 9d7887e..0000000 --- a/src/gui/support.rs +++ /dev/null @@ -1,175 +0,0 @@ -use glium::glutin; -use glium::glutin::event::{Event, WindowEvent}; -use glium::glutin::event_loop::{ControlFlow, EventLoop}; -use glium::glutin::platform::run_return::EventLoopExtRunReturn; -use glium::glutin::window::WindowBuilder; -use glium::{Display, Surface}; -use imgui::{Context, FontConfig, FontGlyphRanges, FontSource, Ui}; -use imgui_glium_renderer::Renderer; -use imgui_winit_support::{HiDpiMode, WinitPlatform}; -use std::time::Instant; - -const CLEAR_COLOR: [f32; 4] = [0.25, 0.25, 0.25, 1.0]; - -pub fn show_window( - title: &str, - width: f32, - height: f32, - mut run_ui: F, -) { - let title = match title.rfind('/') { - Some(idx) => title.split_at(idx + 1).1, - None => title, - }; - let mut event_loop = EventLoop::new(); - let context = glutin::ContextBuilder::new().with_vsync(true); - let builder = WindowBuilder::new() - .with_title(title.to_owned()) - .with_inner_size(glutin::dpi::LogicalSize::new(width as f64, height as f64)) - .with_visible(true) - .with_always_on_top(true) - .with_resizable(false); - let display = - Display::new(builder, context, &event_loop).expect("Failed to initialize display"); - - let mut imgui = Context::create(); - imgui.set_ini_filename(None); - - // styling - { - let style = imgui.style_mut(); - style.window_border_size = 0f32; - - style.colors[imgui::StyleColor::Text as usize] = [1.00, 1.00, 1.00, 1.00]; - style.colors[imgui::StyleColor::TextDisabled as usize] = [0.40, 0.40, 0.40, 1.00]; - style.colors[imgui::StyleColor::ChildBg as usize] = [0.25, 0.25, 0.25, 1.00]; - style.colors[imgui::StyleColor::WindowBg as usize] = CLEAR_COLOR; - style.colors[imgui::StyleColor::PopupBg as usize] = [0.25, 0.25, 0.25, 1.00]; - style.colors[imgui::StyleColor::Border as usize] = [0.12, 0.12, 0.12, 0.71]; - style.colors[imgui::StyleColor::BorderShadow as usize] = [1.00, 1.00, 1.00, 0.06]; - style.colors[imgui::StyleColor::FrameBg as usize] = [0.42, 0.42, 0.42, 0.54]; - style.colors[imgui::StyleColor::FrameBgHovered as usize] = [0.42, 0.42, 0.42, 0.40]; - style.colors[imgui::StyleColor::FrameBgActive as usize] = [0.56, 0.56, 0.56, 0.67]; - style.colors[imgui::StyleColor::TitleBg as usize] = [0.19, 0.19, 0.19, 1.00]; - style.colors[imgui::StyleColor::TitleBgActive as usize] = [0.22, 0.22, 0.22, 1.00]; - style.colors[imgui::StyleColor::TitleBgCollapsed as usize] = [0.17, 0.17, 0.17, 0.90]; - style.colors[imgui::StyleColor::MenuBarBg as usize] = [0.335, 0.335, 0.335, 1.000]; - style.colors[imgui::StyleColor::ScrollbarBg as usize] = [0.24, 0.24, 0.24, 0.53]; - style.colors[imgui::StyleColor::ScrollbarGrab as usize] = [0.41, 0.41, 0.41, 1.00]; - style.colors[imgui::StyleColor::ScrollbarGrabHovered as usize] = [0.52, 0.52, 0.52, 1.00]; - style.colors[imgui::StyleColor::ScrollbarGrabActive as usize] = [0.76, 0.76, 0.76, 1.00]; - style.colors[imgui::StyleColor::CheckMark as usize] = [0.65, 0.65, 0.65, 1.00]; - style.colors[imgui::StyleColor::SliderGrab as usize] = [0.52, 0.52, 0.52, 1.00]; - style.colors[imgui::StyleColor::SliderGrabActive as usize] = [0.64, 0.64, 0.64, 1.00]; - style.colors[imgui::StyleColor::Button as usize] = [0.54, 0.54, 0.54, 0.35]; - style.colors[imgui::StyleColor::ButtonHovered as usize] = [0.52, 0.52, 0.52, 0.59]; - style.colors[imgui::StyleColor::ButtonActive as usize] = [0.76, 0.76, 0.76, 1.00]; - style.colors[imgui::StyleColor::Header as usize] = [0.38, 0.38, 0.38, 1.00]; - style.colors[imgui::StyleColor::HeaderHovered as usize] = [0.47, 0.47, 0.47, 1.00]; - style.colors[imgui::StyleColor::HeaderActive as usize] = [0.76, 0.76, 0.76, 0.77]; - style.colors[imgui::StyleColor::Separator as usize] = [0.000, 0.000, 0.000, 0.137]; - style.colors[imgui::StyleColor::SeparatorHovered as usize] = [0.700, 0.671, 0.600, 0.290]; - style.colors[imgui::StyleColor::SeparatorActive as usize] = [0.702, 0.671, 0.600, 0.674]; - style.colors[imgui::StyleColor::ResizeGrip as usize] = [0.26, 0.59, 0.98, 0.25]; - style.colors[imgui::StyleColor::ResizeGripHovered as usize] = [0.26, 0.59, 0.98, 0.67]; - style.colors[imgui::StyleColor::ResizeGripActive as usize] = [0.26, 0.59, 0.98, 0.95]; - style.colors[imgui::StyleColor::PlotLines as usize] = [0.61, 0.61, 0.61, 1.00]; - style.colors[imgui::StyleColor::PlotLinesHovered as usize] = [1.00, 0.43, 0.35, 1.00]; - style.colors[imgui::StyleColor::PlotHistogram as usize] = [0.90, 0.70, 0.00, 1.00]; - style.colors[imgui::StyleColor::PlotHistogramHovered as usize] = [1.00, 0.60, 0.00, 1.00]; - style.colors[imgui::StyleColor::TextSelectedBg as usize] = [0.73, 0.73, 0.73, 0.35]; - style.colors[imgui::StyleColor::ModalWindowDimBg as usize] = [0.80, 0.80, 0.80, 0.35]; - style.colors[imgui::StyleColor::DragDropTarget as usize] = [1.00, 1.00, 0.00, 0.90]; - style.colors[imgui::StyleColor::NavHighlight as usize] = [0.26, 0.59, 0.98, 1.00]; - style.colors[imgui::StyleColor::NavWindowingHighlight as usize] = [1.00, 1.00, 1.00, 0.70]; - style.colors[imgui::StyleColor::NavWindowingDimBg as usize] = [0.80, 0.80, 0.80, 0.20]; - } - - let mut platform = WinitPlatform::init(&mut imgui); - { - let gl_window = display.gl_window(); - let window = gl_window.window(); - platform.attach_window(imgui.io_mut(), window, HiDpiMode::Rounded); - } - - let hidpi_factor = platform.hidpi_factor(); - let font_size = (13.0 * hidpi_factor) as f32; - imgui.fonts().add_font(&[ - FontSource::DefaultFontData { - config: Some(FontConfig { - size_pixels: font_size, - ..FontConfig::default() - }), - }, - FontSource::TtfData { - data: include_bytes!("../../resources/mplus-1p-regular.ttf"), - size_pixels: font_size, - config: Some(FontConfig { - rasterizer_multiply: 1.75, - glyph_ranges: FontGlyphRanges::japanese(), - ..FontConfig::default() - }), - }, - ]); - - imgui.io_mut().font_global_scale = (1.0 / hidpi_factor) as f32; - - let mut renderer = Renderer::init(&mut imgui, &display).expect("Failed to initialize renderer"); - - let mut last_frame = Instant::now(); - - event_loop.run_return(|event, _, control_flow| match event { - Event::NewEvents(_) => { - let now = Instant::now(); - imgui.io_mut().update_delta_time(now - last_frame); - last_frame = now; - } - Event::MainEventsCleared => { - let gl_window = display.gl_window(); - platform - .prepare_frame(imgui.io_mut(), gl_window.window()) - .expect("Failed to prepare frame"); - gl_window.window().request_redraw(); - } - Event::RedrawRequested(_) => { - let mut ui = imgui.frame(); - - let mut run = true; - run_ui(&mut run, &mut ui); - if !run { - let gl_window = display.gl_window(); - let window = gl_window.window(); - window.set_visible(false); - *control_flow = ControlFlow::Exit; - } - - let gl_window = display.gl_window(); - let mut target = display.draw(); - target.clear_color_srgb( - CLEAR_COLOR[0], - CLEAR_COLOR[1], - CLEAR_COLOR[2], - CLEAR_COLOR[3], - ); - platform.prepare_render(&ui, gl_window.window()); - let draw_data = ui.render(); - renderer - .render(&mut target, draw_data) - .expect("Rendering failed"); - target.finish().expect("Failed to swap buffers"); - } - Event::WindowEvent { - event: WindowEvent::CloseRequested, - .. - } => { - let gl_window = display.gl_window(); - let window = gl_window.window(); - window.set_visible(false); - *control_flow = ControlFlow::Exit; - } - event => { - let gl_window = display.gl_window(); - platform.handle_event(imgui.io_mut(), gl_window.window(), &event); - } - }); -} diff --git a/src/lib.rs b/src/lib.rs index f8c6995..f3d3331 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -4,7 +4,7 @@ use reclass::*; mod memflow_wrapper; use memflow_wrapper::*; -mod gui; +mod config; use std::ffi::c_void; use std::ptr; diff --git a/src/memflow_wrapper.rs b/src/memflow_wrapper.rs index 7663470..654820e 100644 --- a/src/memflow_wrapper.rs +++ b/src/memflow_wrapper.rs @@ -1,7 +1,4 @@ -use crate::gui::{ - alert, - settings::{Config, Settings}, -}; +use crate::config::settings::{Config, Settings}; use std::collections::HashMap; use std::sync::{Arc, Mutex, MutexGuard}; @@ -18,11 +15,6 @@ pub unsafe fn lock_memflow<'a>() -> Result> { MEMFLOW_INSTANCE = Some(Arc::new(Mutex::new(memflow))); } Err(err) => { - alert::show_error( - "Unable to load memflow", - "Memflow failed to initialize some of its components", - err, - ); return Err(err.log_error("unable to initialize memflow")); } }; @@ -55,18 +47,9 @@ impl Memflow { simple_logging::log_to_file("memflow_reclass.log", LevelFilter::Info).ok(); // load config file and set initial logging level - let mut settings = Settings::new(); + let settings = Settings::new(); log_level_from_str(settings.config().log_level.as_ref()); - // show configuration dialog - settings.configure(); - if let Err(err) = settings.persist() { - alert::show_error( - "Unable to save settings", - "The configuration file could not be written", - err, - ); - } let config = settings.config(); // update logging level after showing the configuration dialog