home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD1.iso / GFX / Converter / BB_IENG3.LZX / ImageEngineerV3.0 / ARexx / Antique.rexx < prev    next >
Encoding:
OS/2 REXX Batch file  |  1996-04-18  |  1.2 KB  |  53 lines

  1. /* Image Engineer ARexx macro script */
  2. /* by Simon Edwards                  */
  3. /* 11/7/95                           */
  4.  
  5. Options results
  6. signal on error            /* Setup a place for errors to go */
  7.  
  8. if arg()==0 then exit
  9.  
  10. 'PROJECT_INFO' arg(1) 'TYPE'
  11. if RESULT~='COLOUR' then do
  12.     'CONVERT_TO_COLOUR' arg(1)
  13.     greycolour=RESULT
  14.     'CONTRAST' greycolour '-11 GREEN'
  15.         Project1=RESULT
  16.     CLOSE greycolour
  17. end
  18. else do
  19.     'CONTRAST' arg(1) '-11 GREEN'
  20.     Project1=RESULT
  21. end
  22.  
  23.  
  24. 'BRIGHTNESS' Project1 '-21 GREEN'
  25. Project2=RESULT
  26. CLOSE Project1
  27.  
  28. 'CONTRAST' Project2 '-24 BLUE'
  29. Project1=RESULT
  30. CLOSE Project2
  31. 'BRIGHTNESS' Project1 '-41 BLUE'
  32. CLOSE Project1
  33.  
  34. exit
  35.  
  36. /*******************************************************************/
  37. /* This is where control goes when an error code is returned by IE */
  38. /* It puts up a message saying what happened and on which line     */
  39. /*******************************************************************/
  40. error:
  41. if RC=5 then do            /* Did the user just cancel us? */
  42.     IE_TO_FRONT
  43.     LAST_ERROR
  44.     'REQUEST "'||RESULT||'"'
  45.     exit
  46. end
  47. else do
  48.     IE_TO_FRONT
  49.     LAST_ERROR
  50.     'REQUEST "Error detected!!!'||D2C(10)||'Image Engineer error message is as follows'||D2C(10)||result||D2C(10)||'Script failed on line '||SIGL||'"' 'Doh!'
  51.     exit
  52. end
  53.