home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 13 / AACD13.ISO / AACD / Graphics / PerfectPaint / rexx / bridge / MkAnimDCTV_Pict.rx < prev    next >
Text File  |  2000-07-06  |  1KB  |  64 lines

  1. /*     arexx Script 
  2.     Make anim with pictures
  3. */
  4.  
  5.     options results
  6.     parse ARG Port b
  7.     
  8.     ADDRESS value Port
  9.     pp_AvoidRefresh
  10.  
  11.     Preview=0
  12.     pp_DialogInit 250 60 "*Preview*Size*" 1
  13.         pp_Cycle 0 100 8 100 16 "Size" 1 "96x96|144x144|192x192" Preview
  14.     pp_Dialog
  15.     rc=result
  16.     if rc=0 then
  17.         do
  18.             EXIT
  19.         end        
  20.  
  21.     pp_GetDialog 0
  22.     Preview=result
  23.  
  24.     pp_AskMultiFile 'Load*Pictures'
  25.     count=result
  26.  
  27.     pp_AliasOn
  28.     file="Ram:MultiFile"
  29.     IF OPEN("g",file,"read") then DO
  30.         file=READLN("g")
  31.         pp_New 352 282 9
  32.         pp_MakeAnim count Preview
  33.         pp_CountFrames
  34.         count=result
  35.         Do i=1 to count-1
  36.             file=READLN("g")
  37.             pp_ProgressText 'DCTVtoILBM*#'||i
  38.             ADDRESS command;'C:ReadDCTV '||file||' ram:DCTVtemp'
  39.             ADDRESS value Port
  40.             pp_ProgressText 'Ld*Brush*#'||i
  41.             pp_Bload 'ram:DCTVtemp'
  42.             pp_GetWidthB
  43.             w=result
  44.             pp_GetHeightB
  45.             h=result
  46.             pp_ScaleBrush w/2 h
  47.             IF w=0 then DO
  48.                 EXIT
  49.             END
  50.             x=w/4
  51.             y=h/2
  52.             pp_Plot x y
  53.             pp_FastNextFrame
  54.         END
  55.         CALL close(file)        
  56.         pp_GotoFrame 1
  57.     END
  58.     pp_FreeBrush
  59.     pp_PermitRefresh
  60.     ADDRESS Command;'delete ram:DCTVtemp'
  61.     
  62.  
  63.  
  64.