-
Notifications
You must be signed in to change notification settings - Fork 0
/
Cargo.toml
81 lines (70 loc) · 2.3 KB
/
Cargo.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
[package]
name = "julia-set"
version = "0.1.0"
edition = "2021"
rust-version = "1.70.0"
authors = ["Alex Ostrovski <[email protected]>"]
readme = "README.md"
license = "MIT OR Apache-2.0"
keywords = ["julia", "fractal", "graphics", "opencl", "vulkan"]
categories = ["mathematics", "multimedia::images", "rendering"]
description = "Julia set computation and rendering"
repository = "https://github.com/slowli/julia-set-rs"
[badges]
maintenance = { status = "experimental" }
[package.metadata.docs.rs]
all-features = true
# Set `docsrs` to enable unstable `doc(cfg(...))` attributes.
rustdoc-args = ["--cfg", "docsrs"]
[dependencies]
anyhow = "1.0.86"
image = { version = "0.25.2", default-features = false, features = ["png", "jpeg"] }
num-complex = "0.4.6"
thiserror = "1.0.63"
# OpenCL backend
ocl = { version = "0.19.7", optional = true }
lazy_static = { version = "1.5.0", optional = true }
# Vulkan backend
shaderc = { version = "0.8.3", optional = true }
vulkano = { version = "0.34.1", optional = true }
# CPU backend
rayon = { version = "1.10.0", optional = true }
[dependencies.arithmetic-parser]
version = "0.3.0"
git = "https://github.com/slowli/arithmetic-parser.git"
rev = "b03e8cf6945f2ad2cc2d95a2f0fbf1651ef8e53b"
features = ["num-complex"]
optional = true
[dev-dependencies]
clap = { version = "4.5.13", features = ["derive"] }
criterion = "0.5.0"
doc-comment = "0.3.3"
version-sync = "0.9.1"
[features]
default = []
# Enables the Vulkan backend (GPU-based).
vulkan_backend = ["arithmetic-parser", "shaderc", "vulkano"]
# Enables the OpenCL backend (GPU-based).
opencl_backend = ["arithmetic-parser", "ocl", "lazy_static"]
# Enables the CPU backend with native functions.
cpu_backend = ["rayon"]
# Enables the CPU backend with support of dynamically defined functions.
dyn_cpu_backend = ["cpu_backend", "arithmetic-parser"]
[[test]]
name = "references"
path = "tests/references.rs"
required-features = ["cpu_backend"]
[[example]]
name = "cli"
path = "examples/cli.rs"
required-features = ["dyn_cpu_backend"]
# TODO: strictly speaking, we need any of 3 "dynamic" backends, but the manifest
# seemingly doesn't allow to express this.
[[bench]]
name = "basics"
harness = false
required-features = ["dyn_cpu_backend"]
path = "benches/basics.rs"
# Speed up snapshot testing.
[profile.dev.package.julia-set]
opt-level = 2