From 0be0c10aba579853acafc013c6d92c792b6e79b0 Mon Sep 17 00:00:00 2001 From: Silas Bartha Date: Sun, 18 Aug 2024 03:31:46 -0400 Subject: bevy_dither_post_process page --- content/projects/bevy_dither_post_process/index.md | 29 +++++++++++++++++++++ .../projects/bevy_dither_post_process/level_2.png | Bin 0 -> 59120 bytes .../projects/bevy_dither_post_process/level_3.png | Bin 0 -> 60434 bytes .../projects/bevy_dither_post_process/level_4.png | Bin 0 -> 59292 bytes 4 files changed, 29 insertions(+) create mode 100644 content/projects/bevy_dither_post_process/index.md create mode 100644 content/projects/bevy_dither_post_process/level_2.png create mode 100644 content/projects/bevy_dither_post_process/level_3.png create mode 100644 content/projects/bevy_dither_post_process/level_4.png (limited to 'content') diff --git a/content/projects/bevy_dither_post_process/index.md b/content/projects/bevy_dither_post_process/index.md new file mode 100644 index 0000000..fb26e48 --- /dev/null +++ b/content/projects/bevy_dither_post_process/index.md @@ -0,0 +1,29 @@ ++++ +title = "bevy_dither_post_process" +[taxonomies] +categories = ["bevy plugin"] +languages = ["rust", "wgsl"] +[extra] +github = ["exvacuum/bevy_dither_post_process"] +crates = ["bevy_dither_post_process"] ++++ + +this plugin allows you to add a "monochromatic ordered dithering" post-processing effect to cameras in your bevy engine application + +![level 3](level_3.png) + +the dithering is monochromatic (black & white) and ordered (using the bayer method) (i'm gonna write a blog post about this soon) + +it can be configured with the "level" of dithering to perform (i.e. the size of the bayer matrix to use, where level *n* results in a matrix of size *2^(n+1)*) + +![level 2](level_2.png) +![level 4](level_4.png) + +i wrote this plugin to enhance the performance of my ongoing [white (I)](@/projects/white_I/index.md) project + +originally i did all the dithering on the CPU, and while it was not a huge performance drain due to the screen size being relatively small in the terminal, i figured it would be a good idea to convert it into a shader to take advantage of the GPU and parallelism + +since i was using ordered dithering anyways it was pretty easy to port over, since that kind of dithering is super parallelizable on account of not needing to know anything about any other fragment on the screen unlike some methods that provide superior visual quality + +the reason i chose ordered dithering though was that other methods produced too much "jitter" when applied to moving objects which was pretty disorienting + diff --git a/content/projects/bevy_dither_post_process/level_2.png b/content/projects/bevy_dither_post_process/level_2.png new file mode 100644 index 0000000..a6104ff Binary files /dev/null and b/content/projects/bevy_dither_post_process/level_2.png differ diff --git a/content/projects/bevy_dither_post_process/level_3.png b/content/projects/bevy_dither_post_process/level_3.png new file mode 100644 index 0000000..28cb461 Binary files /dev/null and b/content/projects/bevy_dither_post_process/level_3.png differ diff --git a/content/projects/bevy_dither_post_process/level_4.png b/content/projects/bevy_dither_post_process/level_4.png new file mode 100644 index 0000000..acc4d2c Binary files /dev/null and b/content/projects/bevy_dither_post_process/level_4.png differ -- cgit v1.2.3