mirror of
https://github.com/RGBCube/serenity
synced 2025-05-22 14:25:07 +00:00

I used this utility to check if the possible TGA images' cases for different origins (explictly the Y origin) are generating the same bitmap, as I felt that my eyes are not a good-enough measurement tool for this kind of task. This might be useful in the future for testing other implementations so I rather have this nice utility in our codebase.
23 lines
455 B
Markdown
23 lines
455 B
Markdown
## Name
|
|
|
|
image2bin - convert an image to a binary bitmap
|
|
|
|
## Synopsis
|
|
|
|
```**sh
|
|
$ image2bin <path-to-image>
|
|
```
|
|
|
|
## Description
|
|
|
|
`image2bin` uses LibGfx to decode a specified image to a raw bitmap, so it could be stored
|
|
in a raw binary format for further examination.
|
|
|
|
## Examples
|
|
|
|
```sh
|
|
# Convert a PNG image to raw bitmap
|
|
$ image2bin example.png > example.bin
|
|
# Convert a JPG image to raw bitmap
|
|
$ image2bin another_example.jpg > another_example.bin
|
|
```
|