Am 31.10.2011 23:20, schrieb Florent Delannoy:
> Known issues: The .png icon is good, but its .h version is buggy — anyone 
> knows how to make a good .h from the PNG itself?


Hi Florent,

here is how I solved that problem of generating an plugin icon myself in
the past. Not sure if there is a more elegant solution (anyone?)


Run the command:

hexdump -e' 16/1 "0x%02x, " "\n"' filename

(note the strange double quoting. The -e parameter expects a complete format
string). Paste the output into the definition of a constant within the header:

      static unsigned char heroine_logo12_png[] =
         {
          0x00, 0x03, 0x5f, 0x77,
          0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a,
          ....
          ....

Note: the first four bytes seem to be some kind of internal marker required by
Cinelerra internally (maybe some internal def for Lib Guicast?)
The remainder is just the raw contents of the png file as output by hexdump.

hope that helps
Cheers,
Hermann V







_______________________________________________
Cinelerra mailing list
[email protected]
https://init.linpro.no/mailman/skolelinux.no/listinfo/cinelerra

Reply via email to