Files
pureref-tauri/src-tauri/Cargo.toml
小煜 5416a2df36 feat(compression): add zlib compression for scene files and image optimization
- Add flate2 dependency for zlib compression support in Rust backend
- Implement compressed scene file format with magic number (PURGIFZ1) for format detection
- Add backward compatibility for loading uncompressed legacy scene files
- Convert scene JSON to compact format (no indentation) to reduce file size
- Add image compression utilities with configurable quality and dimensions
- Implement image size detection and compression necessity checking
- Add helper functions for base64 image size calculation and MIME type detection
- Disable global Tauri object in web context for security
- Reduce memory footprint for large scene files and high-resolution images through compression
2025-12-22 12:16:22 +08:00

43 lines
1.2 KiB
TOML

[package]
name = "refvroid"
version = "0.1.1"
description = "RefVroid - Animation Reference Desktop App"
authors = ["you"]
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[lib]
# The `_lib` suffix may seem redundant but it is necessary
# to make the lib name unique and wouldn't conflict with the bin name.
# This seems to be only an issue on Windows, see https://github.com/rust-lang/cargo/issues/8519
name = "refvroid_lib"
crate-type = ["staticlib", "cdylib", "rlib"]
[build-dependencies]
tauri-build = { version = "2", features = [] }
[dependencies]
tauri = { version = "2", features = ["tray-icon"] }
tauri-plugin-opener = "2"
tauri-plugin-dialog = "2"
tauri-plugin-clipboard-manager = "2"
tauri-plugin-fs = "2"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
base64 = "0.22"
image = "0.25"
arboard = "3"
flate2 = "1.0" # zlib 压缩
[target.'cfg(windows)'.dependencies]
windows = { version = "0.58", features = [
"Win32_UI_WindowsAndMessaging",
"Win32_Foundation",
"Win32_System_DataExchange",
"Win32_System_Ole",
"Win32_UI_Shell",
"Win32_System_Memory"
] }