publishing commit

This commit is contained in:
Tove 2026-02-09 18:25:15 +01:00
parent dc9c37908d
commit 209968af33
5 changed files with 26 additions and 3 deletions

1
.gitignore vendored
View file

@ -1,3 +1,4 @@
/target
/.direnv
*.png
perf.*

2
Cargo.lock generated
View file

@ -50,7 +50,7 @@ dependencies = [
[[package]]
name = "imgsyn"
version = "0.1.0"
version = "1.0.0"
dependencies = [
"png",
]

View file

@ -1,7 +1,14 @@
[package]
name = "imgsyn"
version = "0.1.0"
description = "Image synthesizer"
license = "MIT"
repository = "https://git.tudbut.de/tudbut/imgsyn"
version = "1.0.0"
edition = "2024"
[dependencies]
png = "0.18.0"
png = { version = "0.18.0", optional = true }
[features]
default = ["png"]
png = ["dep:png"]

14
README.md Normal file
View file

@ -0,0 +1,14 @@
# ImgSyn Image Synthesizer
ImgSyn is an image synthesizer written in rust, capable
of applying layered effects and transformations to a canvas
to produce an image. The image can then be given out as a PNG,
or accessed from rust directly.
Notably, ImgSyn uses the same model as rust iterators, just for
images.
![A graph created in ImgSyn](./graph.png)
See the tests in lib.rs for some examples.

View file

@ -80,6 +80,7 @@ pub trait ImgSyn: Clone {
let painted = self.paint(meta);
PaintedCanvas::rgba255(&painted)
}
#[cfg(feature = "png")]
fn png(self, meta: Canvas) -> Vec<u8> {
let painted = self.paint(meta);
let mut data = Vec::new();