mirror of
https://github.com/RGBCube/serenity
synced 2025-05-20 17:55:08 +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.
455 B
455 B
Name
image2bin - convert an image to a binary bitmap
Synopsis
$ 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
# 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