home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / alt / graphics / pixutils / 2758 < prev    next >
Encoding:
Text File  |  1992-12-22  |  1.7 KB  |  39 lines

  1. Newsgroups: alt.graphics.pixutils
  2. Path: sparky!uunet!zaphod.mps.ohio-state.edu!uwm.edu!rpi!usenet.coe.montana.edu!osyjm
  3. From: osyjm@cs.montana.edu (Jaye Mathisen)
  4. Subject: This has got to be an easy one.  Adding a colormap?
  5. Message-ID: <1992Dec22.012855.4165@coe.montana.edu>
  6. Sender: usenet@coe.montana.edu (USENET News System)
  7. Organization: CS
  8. Date: Tue, 22 Dec 1992 01:28:55 GMT
  9. Lines: 28
  10.  
  11.  
  12. I have an image file, generated by a program that knows nothing about pbmplus.
  13. I have a colormap file, which is of the form: 'color# Redval Grnval Bluval'
  14. for 256 colors.  (Redval, Grnval and Bluval are integers between 0 and 255,
  15. but of course, it'd be easy to convert to a float if that would help).
  16.  
  17. How do I take the image file, convert it to a GIF with the colormap applied?
  18.  
  19. The grey part isn't a problem, 'rawtopgm x y file | pnmtogif > outfile', but
  20. how to get the map in there?  I don't want pbm messing with what it thinks
  21. is black or white...
  22.  
  23. pgmtoppm looks like it would almost do the trick, but specifying the 
  24. colorspec stuff doesn't look quite like it does what I want.
  25.  
  26. Alternatively, if you can tell me how to convert my above mentioned format
  27. color map files into PPM files so that I can use the -map option to pgmtoppm, 
  28. that would work as well.  At least, I think that would do what I want.
  29.  
  30. Any help much appreciated, I have a ton of these files I need to go through.
  31.  
  32. Back in the old days, the images were just loaded into the HP framebuffer, 
  33. then a separate program loaded the colormap, now I want to dig out these
  34. old images and re-display 'em.
  35. -- 
  36.  Jaye Mathisen, COE Systems Manager                (406) 994-4780
  37.  410 Roberts Hall,Dept. of Computer Science
  38.  Montana State University,Bozeman MT 59717    osyjm@cs.montana.edu
  39.