1 | [package] |
2 | name = "femtovg" |
3 | description = "Antialiased 2D vector drawing library" |
4 | version = "0.12.0" |
5 | license = "MIT OR Apache-2.0" |
6 | readme = "README.md" |
7 | authors = [ |
8 | "Peter Todorov <ptodorov@cytec.bg>" , |
9 | "Adam Nemecek <adamnemecek@gmail.com>" , |
10 | ] |
11 | keywords = ["graphics" , "canvas" , "vector" , "drawing" , "gpu" ] |
12 | categories = ["graphics" ] |
13 | repository = "https://github.com/femtovg/femtovg" |
14 | edition = "2021" |
15 | exclude = ["assets" , "examples" ] |
16 | |
17 | [profile.release] |
18 | debug = true |
19 | |
20 | [dependencies] |
21 | fnv = "1.0.7" |
22 | rgb = "0.8.50" |
23 | bytemuck = { version = "1.16" , features = ["derive" ] } |
24 | imgref = "1.11.0" |
25 | bitflags = "2.6.0" |
26 | rustybuzz = "0.20.0" |
27 | unicode-bidi = "0.3.17" |
28 | unicode-segmentation = "1.12.0" |
29 | slotmap = "1.0.7" |
30 | lru = { version = "0.12.5" , default-features = false } |
31 | image = { version = "0.25.0" , optional = true, default-features = false } |
32 | serde = { version = "1.0" , optional = true, features = ["derive" , "rc" ] } |
33 | glow = { version = "0.16.0" , default-features = false } |
34 | log = "0.4" |
35 | wgpu = { version = "23" , optional = true, default-features = false, features = ["wgsl" ] } |
36 | |
37 | [target.'cfg(not(target_arch = "wasm32"))'.dependencies] |
38 | glutin = { version = "0.31" , optional = true, default-features = false } |
39 | |
40 | [target.'cfg(target_arch = "wasm32")'.dependencies] |
41 | web_sys = { version = "0.3" , package = "web-sys" , features = [ |
42 | "WebGlContextAttributes" , |
43 | "HtmlImageElement" , |
44 | "WebGl2RenderingContext" , |
45 | ] } |
46 | wasm-bindgen = "0.2" |
47 | |
48 | [features] |
49 | default = ["image-loading" ] |
50 | image-loading = ["image" ] |
51 | debug_inspector = [] |
52 | wgpu = ["dep:wgpu" ] |
53 | |
54 | [dev-dependencies] |
55 | winit = { version = "0.29.1" } |
56 | euclid = "0.22.3" |
57 | rand = "0.8" |
58 | svg = "0.14.0" |
59 | usvg = { version = "0.33.0" } |
60 | instant = { version = "0.1" , features = ["now" ] } |
61 | resource = "0.5.0" |
62 | image = { version = "0.25.0" , default-features = false, features = [ |
63 | "jpeg" , |
64 | "png" , |
65 | ] } |
66 | cosmic-text = "0.12.1" |
67 | swash = "=0.1.17" # keep this in sync with cosmic-text |
68 | lazy_static = "1.4.0" |
69 | spin_on = "0.1" |
70 | wgpu = { version = "23" } |
71 | |
72 | [target.'cfg(not(target_arch = "wasm32"))'.dev-dependencies] |
73 | glutin = "0.31.0" |
74 | glutin-winit = "0.4.0" |
75 | raw-window-handle = "0.5.0" |
76 | |
77 | [target.'cfg(target_arch = "wasm32")'.dev-dependencies] |
78 | web_sys = { version = "0.3" , package = "web-sys" , features = [ |
79 | "console" , |
80 | "WebGlContextAttributes" , |
81 | ] } |
82 | console_error_panic_hook = "0.1.5" |
83 | instant = { version = "0.1" , features = ["wasm-bindgen" , "now" ] } |
84 | resource = { version = "0.5.0" , features = ["force-static" ] } |
85 | getrandom = { version = "0.2.2" , features = ["js" ] } |
86 | wgpu = { version = "23" , features = ["webgl" ] } |
87 | wasm-bindgen-futures = { version = "0.4.45" } |
88 | |
89 | [[example]] |
90 | name = "book_example_1_1" |
91 | path = "book/src/1_getting_started/1_setting_up.rs" |
92 | |
93 | [[example]] |
94 | name = "book_example_1_2" |
95 | path = "book/src/1_getting_started/2_rendering.rs" |
96 | |
97 | [[example]] |
98 | name = "book_example_1_3" |
99 | path = "book/src/1_getting_started/3_event_loop.rs" |
100 | |
101 | [package.metadata.docs.rs] |
102 | features = ["glutin/egl" ] |
103 | all-features = true |
104 | rustdoc-args = ["--cfg" , "docsrs" ] |
105 | |