rahman
rahman

Reputation: 4948

convert and display image in C

I'm going to put a background on my embedded console application. The question is simple: I just don't know how to do that :) suppose I have a picture of any format and want to convert it to character array to print it. As i told you I'm clueless on this one, so if this is a bad approach, please let me know. If any better solution, please suggest it. thank you all!

Upvotes: 2

Views: 1273

Answers (1)

Prof. Falken
Prof. Falken

Reputation: 24937

You need to decide if you want an actual image as is, or if you want an image converted to text: enter image description here

If an image converted to text is what you want, have a look at AAlib as @IlmariKaronen suggested, or maybe jp2a.

If you do want a "real" image, then you need to use a terminal emulator which supports changing background image via a proprietary escape sequence, and I think for instance eterm supports this. Then the background could look something like this: enter image description here

If you are using the Linux console without X11, there are other options related to FBDEV and bootsplash, but I don't know those as well.

Upvotes: 1

Related Questions