home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD1.iso / GFX / ADPro251-3.DMS / ADPro251-3.adf / FREDScripts.lha / FREDSavers / SaveAsJPEG.fred.pre < prev    next >
Encoding:
Text File  |  1994-01-31  |  1.6 KB  |  76 lines

  1. /*
  2. ** SaveAsJPEG.fred.pre
  3. **
  4. ** $VER: SaveAsJPEG.fred.pre 1.3.0 (11.1.94)
  5. **
  6. ** If the SaveAsJPEG.fred script appears in the InvokeADPro list,
  7. ** this program will ask the user to enter the level of quality for the
  8. ** JPEG'd file.  These parameters will be stuffed into REXX clips.
  9. **
  10. ** If they fail to answer, the InvokeADPro list will be aborted.
  11. **
  12. ** Clips Exported:
  13. **    FREDJPEGQuality        -    Quality level of JPEG'd files
  14. **    FREDJPEGFNameSelect    -    String describing how the filename
  15. **                    should be modified
  16. **    FREDJPEGSeqFileSelect    -    Name of sequence file created
  17. **
  18. **
  19. ** NOTE: Clip names are case sensitive.
  20. **
  21. ** This script requires FRED v1.4.0 (or higher) to run.  Also required is
  22. ** ADPro v2.5.0 (or higher).
  23. **
  24. ** Copyright © 1992-1994 ASDG, Incorporated
  25. ** All Rights Reserved
  26. */
  27.  
  28.  
  29. ADDRESS "ADPro"
  30. OPTIONS RESULTS
  31.  
  32. PARSE ARG NumberOfCells NumberOfFrames
  33.  
  34. NL = '0A'X
  35. SQ = '27'X
  36. DQ = '22'X
  37. TRUE  = 1
  38. FALSE = 0
  39.  
  40.  
  41. /*
  42. ** Set the quality level, and if BOOST should be used.
  43. */
  44.  
  45. CALL "FREDSCRIPTS:FREDFunctions/GetANumber" '"Quality level"' 32 1 1000 TRUE
  46. IF (RESULT = (1-1)) THEN
  47.     EXIT 10
  48. Quality = RESULT
  49.  
  50.  
  51. /*
  52. ** Specify whether the given filename should be reused for the
  53. ** JPEG'd filename.
  54. */
  55.  
  56. CALL "FREDSCRIPTS:FREDFunctions/ModifyFilenameSelect" '"'".jpeg"'"' 4 1 10
  57. FNameSelect = RESULT
  58. IF (RESULT = 10) THEN
  59.     EXIT RESULT
  60.  
  61. CALL "FREDSCRIPTS:FREDFunctions/SeqFileSelect"
  62. SeqFileSelect = RESULT
  63. IF (RESULT = 10) THEN
  64.     EXIT RESULT
  65.  
  66.  
  67. /*
  68. ** Update the clips.
  69. */
  70.  
  71. SETCLIP( "FREDJPEGQuality", Quality )
  72. SETCLIP( "FREDJPEGFNameSelect", FNameSelect )
  73. SETCLIP( "FREDJPEGSeqFileSelect", SeqFileSelect )
  74.  
  75. EXIT 0
  76.