🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: gnu.ghostscript.bug
1 messages
1 total messages Started by Timothy Gallivan Mon, 05 Oct 1992 05:34
Problems with 2 and 4 bit color.
#456
Author: Timothy Gallivan
Date: Mon, 05 Oct 1992 05:34
26 lines
1783 bytes
Hi,

I have been trying for quite some time to get Ghostscript to produce
REAL 2 and 4 bit images for a bitmapped driver I have written. No matter
what I try, Ghostscript refuses to stick 2 or 4 pixels in each byte of
the image it produces. I have been told that GS is capable of this, but
I sure can't figure out how.  Can anyone PLEASE give me a clue about
what is required to twist Ghostscript's arm in this matter.

It appears to me that calling gdev_mem_device_for_bits(4) and setting
the elements of the color_info structure to the appropriate 4-bit color
values (mainly depth=4) should be all that is necessary, but I can't get
it to work. All of this is done when the device is opened, after the
driver figures out what hardware it must write to. I have checked that
the proper routines are being called (mem_mapped4_copy_mono for
example), but I can make no sense out of the bitmap that GS produces.
For speed and memory reasons, I need to access the bitmap directly,
rather than through the higher level GS routines which return scan lines
one at a time.

By the way, the driver has it's own map_color_rgb and map_rgb_color
routines, which appear to be working correctly. Any help will be greatly
appreciated.

Tim Gallivan
timg@landau.ph.utexas.edu
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads