Color Pic in EPS-File 
Author Message
 Color Pic in EPS-File

Hi everyone,

I am using the following code to print a (greyscaled!!) pixel-picture in
an EPS-File:

/Bildbreite 128 def   % width of picture
/Bildhoehe 128 def  % height of picture
/Bits-je-Pel 24 def   % bits per pixel
/str                      % Determine string-length to read data
Bildbreite Bits-je-Pel mul
7 add 8 idiv
string
def
gsave
20 20 translate
285 285 scale
Bildbreite Bildhoehe Bits-je-Pel [Bildbreite 0 0 Bildhoehe neg 0
Bildhoehe]
{currentfile str readhexstring pop}     % Bilddaten einlesen
image
80 7D 88  (--> Image Data)

Everything works fine. But as I wanted to use more colors I tried

/Bildbreite 128 def   % width of picture
/Bildhoehe 128 def  % height of picture
/Bits-je-Pel 24 def   % bits per pixel
/str                      % Determine string-length to read data
Bildbreite Bits-je-Pel mul
7 add 8 idiv
string
def
gsave
20 20 translate
285 285 scale
Bildbreite Bildhoehe Bits-je-Pel [Bildbreite 0 0 Bildhoehe neg 0
Bildhoehe]
{currentfile str readhexstring pop}     % Bilddaten einlesen
image
000080 00007D 000088  (--> Image Data)

But I get an error ('Unrecoverable error: rangecheck in image')

[Note: If I set Bildhoehe (height of picture) to 3*128 it works (of
course the image is corrupted)]

Any Idea what's wrong??

Actually I only need red and blue as extra colors in addition to 256
shades of grey. Is it possible to reduce data size?

A lot of stupid questions ;-) Sorry!!! Hope somebody can help me!
Thank you!
Kai



Fri, 28 Sep 2001 03:00:00 GMT  
 Color Pic in EPS-File
Thank you ;-)

solved the problem on myself (using colorimage)

Bye
Kai



Sat, 29 Sep 2001 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. 4 files EPS CMYB --> 1 color EPS

2. EPS to PIC or Framemaker conversion

3. postscript to PIC or EPS

4. How to convert a composite color EPS to a tiff cmyk file with GS

5. Color Separation in eps files

6. Spot colors in EPS files

7. color in eps file

8. How to combine multiple Windows eps files into one eps file

9. HELP: including eps file into other eps file

10. Multiple inclusion of EPS file in single EPS file

11. spot-colors when converting from EPS to PDF

12. trouble with the color black in EPS

 

 
Powered by phpBB® Forum Software