home *** CD-ROM | disk | FTP | other *** search
- /*
- -----------------------------------------------------------------------------
- This AREXX-Script will save any image, the save-format must be specified
- in the argument by the user.
-
- Host address: ADPro (Art Department Professional ®ASDG)
- Written by Jan Van Overbeke, 3-DEE, ©1993.
- Read the AREXX-Scripti doc, for more info about operation and rights!
- -----------------------------------------------------------------------------
- */
-
- parse arg filename saver
- if ~ exists(filename)|filename='' then do
- say 'Unable to find the image !!'
- say 'See Ya...'
- say ''
- exit
- end
-
- address 'ADPro'
- SFORMAT saver
- if RC~=0 then do
- say 'Unable to select the saver!!!'
- say ' ->Wrong Argument?'
- say 'See Ya......'
- say ''
- exit
- end
-
- /* ---- If you use another format, adjust your prefs! ---- */
- /* ---- Or more important: add your own! ---- */
- /* ------------------------------------------------------- */
- savemode='IMAGE'
- if saver='JPEG' then savemode='RAW'
-
- say 'SaveFormat: Written by JAN VAN OVERBEKE, 3-DEE, ©1993'
- say 'Image: 'filename
- say 'Save Format: 'saver
- say ''
-
- LFORMAT "UNIVERSAL"
- if RC ~=0 then do
- say 'Unable to select the UNIVERSAL loader.'
- say 'See Ya...'
- say ''
- exit
- end
-
- say 'Loading.........'
- LOAD filename
- if RC ~=0 then do
- say 'Had some problems while loading.'
- say 'See Ya...'
- say ''
- exit
- end
-
- say 'Saving........'
- filename=filename'.new'
- SAVE filename savemode
- if RC~=0 then do
- say 'Problems while saving: NOT SAVED.'
- say 'See Ya...'
- say ''
- end
-
- SFORMAT 'IFF'
- if RC~=0 then do
- say 'Unable to switch to IFF saver.'
- say 'See Ya.....'
- end
- say ''
- exit
-