https://github.com/coloz/image-to-bitmap-array
convert image to C bitmap array | 一个Angular编写的纯前端的图片取模程序
https://github.com/coloz/image-to-bitmap-array
angular arduino bitmap-array image-convert u8g2
Last synced: 15 days ago
JSON representation
convert image to C bitmap array | 一个Angular编写的纯前端的图片取模程序
- Host: GitHub
- URL: https://github.com/coloz/image-to-bitmap-array
- Owner: coloz
- Created: 2018-01-16T16:15:50.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2023-05-24T00:47:21.000Z (about 3 years ago)
- Last Synced: 2024-04-15T05:54:51.898Z (about 2 years ago)
- Topics: angular, arduino, bitmap-array, image-convert, u8g2
- Language: TypeScript
- Homepage: https://arduino.me/a/image-to-bitmap-array
- Size: 4.11 MB
- Stars: 223
- Watchers: 7
- Forks: 50
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# convert image to C bitmap array
一个纯前端的图片取模程序,可将图片转换为C语言数组形式,用于单片机/arduino显示图片。
## 演示地址
[1602/2004 LCD 在线字符编辑器](https://arduino.me/a/1602-character-editor)
[OLED/LCD/12864 在线图片取模工具](https://arduino.me/a/image-to-bitmap-array)
## 设备端使用
推荐使用 [u8g2](https://github.com/olikraus/u8g2) 配合本软件进行图片显示
[基于Arduino的演示](https://www.arduino.cn/thread-42174-1-1.html)
## 抖动取模
利用 [Floyd-Steinberg-Dither](https://en.wikipedia.org/wiki/Floyd–Steinberg_dithering) 进行取模,可以将灰度转换成点密度。
| 原图 | 阀值取模 | 抖动取模 |
| ----------------------- | ----------------------- | ----------------------- |
|  |  |  |
|  |  |  |
|  |  |  |
|  |  |  |
抖动取模代码来自项目[canvas-floyd-steinberg-dither](https://github.com/tgiachett/canvas-floyd-steinberg-dither)
## 更新
2017.2.8 取模软件好多,选择困难症又犯了,为了自救,所以自己做了个
2020.4.28 这个小软件意外受欢迎,那我再更新下吧
2020.5.1 新增抖动取模功能
## 编译
```
npm i
ng build --prod
```
## 在线乞讨
觉得不错,就请star一下