home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The CDPD Public Domain Collection for CDTV 4
/
CDPD_IV.bin
/
networking
/
worldwideweb
/
mosaic_1.2_dnet
/
rexx
/
soxaudio.rexx
< prev
Wrap
OS/2 REXX Batch file
|
1994-07-04
|
1KB
|
42 lines
/* SOXAudio.rexx */
/* Plays sun audio files, used to be more versatile, but */
/* For mosaic 2.0 and above, file extensions can't be relied on */
/* we would have used oplay, but it sounds awful on some of the files on the
net ! */
options RESULTS
ARG filename screen
/* TRACE ai
PARSE UPPER VAR filename filehead'.'fileext */
if ~show(l, "rexxsupport.library") then
if ~addlib("rexxsupport.library", 0, -30) then
EXIT
IF SHOW('P',"INFOWIN.1") THEN DO
ADDRESS INFOWIN.1
'MESSAGE FROM soxaudio.rexx MESSAGE '|| 'rename '||filename||' '||filename||'.au'
'MESSAGE FROM soxaudio.rexx MESSAGE '|| 'sox -t ul -r 8000 '||filename||'.au -v 10 -t 8svx '||filename||'.8svx'
'MESSAGE FROM soxaudio.rexx MESSAGE '|| 'sound '||filename||'.8svx'
'MESSAGE FROM soxaudio.rexx MESSAGE '|| 'multiview '||filename||'.8svx '||TRIM(screen)
'MESSAGE FROM soxaudio.rexx MESSAGE '|| ' Delay(30)'
END
ADDRESS COMMAND
'rename '||filename||' '||filename||'.au'
'sox -t ul -r 8000 '||filename||'.au -v 10 -t 8svx '||filename||'.8svx'
/* If you have UPD installed, USE THIS */
IF SHOW('P',"PLAY") THEN DO
ADDRESS PLAY 'file '||filename||'.8svx'
END
ELSE DO
/* Otherwise use sound, if it is there */
'sound '||filename||'.8svx'
/* Or multiview */
/* 'multiview '||filename||'.8svx '||screen */
END
ADDRESS COMMAND
Delay(30)
'DELETE >nil: <nil: '||filename
'DELETE >nil: <nil: '||filename||'.iff'
exit