[Subject Prev][Subject Next][Thread Prev][Thread Next][Subject Index][Thread Index]
How to print to file in svgalib?
Hi,
I've been struggling to get an output of my screen graphics for
the last 2 months. I just need a picture in jpg/png ( a screenshot). How
do I do this?
I am running at 1024x768 at 256 colors (mode 12)
I can dump a 1024x768 byte memory to file which I fill with
gl_getbox(0,0,1024,768,memory_dump_pointer)
I can also get a color table of 768 bytes with
gl_getpalette(color_table_pointer)
I save these dumps to file and use netpbm's
raw2gif -s 1024 768 -p color_table_file memory_dump_file > out.gif
This gives just a bluish-green 1024x768 box (every time). The
svgalib maintainer had suggested something like the above and also said
that one has to define color tables properly.
Can someone help? TIA,
Indraneel
--
/************************************************************************.
# Indraneel Majumdar ¡ E-mail: indraneel@xxxxxxxxxxxx #
# Bioinformatics Unit (EMBNET node), ¡ URL: http://scorpius.iwarp.com #
# Centre for DNA Fingerprinting and Diagnostics, #
# Hyderabad, India - 500076 #
`************************************************************************/