/* ** SaveAsJPEG.fred.pre ** ** $VER: SaveAsJPEG.fred.pre 1.3.0 (11.1.94) ** ** If the SaveAsJPEG.fred script appears in the InvokeADPro list, ** this program will ask the user to enter the level of quality for the ** JPEG'd file. These parameters will be stuffed into REXX clips. ** ** If they fail to answer, the InvokeADPro list will be aborted. ** ** Clips Exported: ** FREDJPEGQuality - Quality level of JPEG'd files ** FREDJPEGFNameSelect - String describing how the filename ** should be modified ** FREDJPEGSeqFileSelect - Name of sequence file created ** ** ** NOTE: Clip names are case sensitive. ** ** This script requires FRED v1.4.0 (or higher) to run. Also required is ** ADPro v2.5.0 (or higher). ** ** Copyright © 1992-1994 ASDG, Incorporated ** All Rights Reserved */ ADDRESS "ADPro" OPTIONS RESULTS PARSE ARG NumberOfCells NumberOfFrames NL = '0A'X SQ = '27'X DQ = '22'X TRUE = 1 FALSE = 0 /* ** Set the quality level, and if BOOST should be used. */ CALL "FREDSCRIPTS:FREDFunctions/GetANumber" '"Quality level"' 32 1 1000 TRUE IF (RESULT = (1-1)) THEN EXIT 10 Quality = RESULT /* ** Specify whether the given filename should be reused for the ** JPEG'd filename. */ CALL "FREDSCRIPTS:FREDFunctions/ModifyFilenameSelect" '"'".jpeg"'"' 4 1 10 FNameSelect = RESULT IF (RESULT = 10) THEN EXIT RESULT CALL "FREDSCRIPTS:FREDFunctions/SeqFileSelect" SeqFileSelect = RESULT IF (RESULT = 10) THEN EXIT RESULT /* ** Update the clips. */ SETCLIP( "FREDJPEGQuality", Quality ) SETCLIP( "FREDJPEGFNameSelect", FNameSelect ) SETCLIP( "FREDJPEGSeqFileSelect", SeqFileSelect ) EXIT 0