8000 GitHub - silkeh/png2c: A simple tool for converting PNG images to a C definition.
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
/ png2c Public

A simple tool for converting PNG images to a C definition.

License

Notifications You must be signed in to change notification settings

silkeh/png2c

8000

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

png2c

A simple tool for converting PNG images to a C definition.

Usage

Download and install the library and tools using:

go get github.com/silkeh/png2c

To convert an image, use it as follows:

png2c -file pixel.png -var pixel -mode 565 -brief Pixel

Which will result in something like:

/**
 * @brief   Pixel (1x1)
 */
const uint16_t pixel[1][1] = {
    { 0xe005 }
};

Note that no compensation for the alpha channel is done when the alpha channel is not represented in the output format.

About

A simple tool for converting PNG images to a C definition.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

0