home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / softsys / khoros / 2944 < prev    next >
Encoding:
Internet Message Format  |  1992-11-21  |  2.9 KB

  1. Path: sparky!uunet!ogicse!mimbres.cs.unm.edu!pprg.unm.edu!daemon
  2. From: young@chama.eece.unm.edu (Mark Young)
  3. Newsgroups: comp.soft-sys.khoros
  4. Subject: Re: pbm2viff question
  5. Message-ID: <41775@pprg.eece.unm.edu.pprg.unm.edu>
  6. Date: 21 Nov 92 14:29:56 GMT
  7. Article-I.D.: pprg.41775
  8. Sender: daemon@pprg.unm.edu
  9. Lines: 82
  10.  
  11. Hi,
  12.  
  13.    I responded to Suran yesterday, but thought that others may want
  14. the fix as well.
  15.  
  16. On Nov 20, 11:08am, Suran de SILVA wrote:
  17. } Subject: pbm2viff question
  18. } From suran@nff.ncl.omron.co.jp  Thu Nov 19 19:09:02 1992
  19. } Hi,
  20. }     Has anybody been using the Khoros file-format conversion program,
  21. } pbm2viff?  I tried using it on an image I scanned in using an EPSON GT-4000
  22. } in pbm format.  I got the following error message from pbm2viff:
  23. }     read_pbm:  Error!  Invalid width.
  24. }     Unable to read width of the pbm image.
  25. }     pbm2viff: Could not read input image.    
  26.  
  27. Hi Suran,
  28.  
  29.    I looked into the problem you were having with pbm2viff and have a fix
  30. for you.  It was my fault (usually is).  When writing the format i thought
  31. the spec said that the pbm identifier ie P1, P2, P3, P4, etc must come on
  32. line by itself.  That the format must look something like:
  33.  
  34. P4
  35. 200 197
  36.  
  37. not:
  38.  
  39. P4 200 197
  40.  
  41. If you are interested in fixing the problem here is a fix that i have
  42. done a fairly healthy, but not extensive, testing on the omron and sun
  43. with your test file and a few of our own.  So i don't expect any problems,
  44. but as always please let me know if you find any.  To fix the problem
  45. you'll need to change the file $KHOROS_HOME/src/file_formats/Lib/pbm.c
  46. at line 112 from:
  47.  
  48.         if (!fgets(line, LENGTH, file))
  49.         {
  50.            (void) fprintf(stderr,"read_pbm:  Error!  Unexpected end of \n\
  51.  
  52. to:
  53.         if (fscanf(file," %2c", line) <= 0)
  54.         {
  55.            (void) fprintf(stderr,"read_pbm:  Error!  Unexpected end of \n\
  56.  
  57.  
  58. Then re-install the file formats library ($KHOROS_HOME/src/file_formats/Lib)
  59. and also the pbm2viff program itself which is located in:
  60.  
  61.     $KHOROS_HOME/src/file_formats/standards/pbm2viff
  62.  
  63. } Thanks in advance.
  64. } rgds,
  65. } Suran.
  66. } suran@nff.ncl.omron.co.jp
  67. }-- End of excerpt from Suran de SILVA
  68.  
  69. Anyway i apologize for any problems this may have caused and thanks
  70. again for bring this bug to our attention.
  71.  
  72.                         thanks,
  73.                              Mark
  74.  
  75. ps.  i'll cc: this to khoros-bugs so that it gets logged.  Also i'll respond
  76.      with this fix to the khoros mailing list later today since other people
  77.      will probably get hit by this.
  78.      
  79.  
  80. -----------------------------------------------------------------------------
  81. Mark Young                         young@chama.eece.unm.edu
  82.  
  83. Khoros Group                       (505) 277-6563  (work)
  84. University of New Mexico           Albuquerque,    NM 87131
  85. -----------------------------------------------------------------------------
  86. Humor is something that is plentyful if you are willing to laugh at yourself.
  87.