home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD2.mdf / c / library / dos / grafik / giflib11 / test-ibm.bat < prev    next >
Encoding:
DOS Batch File  |  1990-11-12  |  2.7 KB  |  83 lines

  1. @echo off
  2. rem
  3. rem Tests for the gif_lib utilities.
  4. rem Usage:
  5. rem    testgif [gif_dir] [display_prgm]
  6. rem
  7. rem   This test assumes the gif_lib utilities are available from one of the
  8. rem path directorys, and that DIR is set (directly or through command line)
  9. rem to the directory holf these gif files:
  10. rem 1. SOLID2.GIF
  11. rem 2. CHERYL.GIF
  12. rem 3. PORSCHE.GIF
  13. rem   In addition, set DISPLAY ( directly or through command line) to the
  14. rem program to display gif files in our system.
  15. rem   As this batch file intensively uses pipes which on msdos are saved as
  16. rem files on CURRENT disk, it is going to be a good idea to execute this batch
  17. rem from a ram disk.
  18.  
  19. set GIF_DIR=d:\c\gif\pic\
  20. if not x%1 == x set GIF_DIR = %1
  21.  
  22. rem
  23. rem Two display programs are available gif2herc for hercules monochrome device
  24. rem and gif2bgi for any device you have bgi driver for. See the docs for these
  25. rem programs for more.
  26. rem
  27. rem set GIF_DISPLAY=gif2herc
  28. set GIF_DISPLAY=gif2bgi -u c:\tc\bgi\ati\ati.2
  29. if not x%2 == x set GIF_DISPLAY = %2
  30.  
  31. @echo on
  32.  
  33. gifwedge | %GIF_DISPLAY%
  34.  
  35. gifbg -d tl -s 320 200 -c 255 255 255 -l 64 > bg1.gif
  36. gifcomb %GIF_DIR%porsche.gif bg1.gif | %GIF_DISPLAY%
  37.  
  38. text2gif -f 1 -s 7 -c 0 255 0 -t "Created using the IRIT solid modeler, Gershon Elber 1990" > credit.gif
  39. gifasm %GIF_DIR%solid2.gif credit.gif | %GIF_DISPLAY%
  40. del credit.gif
  41.  
  42. gifhisto -t %GIF_DIR%cheryl.gif | sort/r | more
  43. gifhisto -b -s 200 512 %GIF_DIR%cheryl.gif | gifflip -l | %GIF_DISPLAY%
  44.  
  45. gifflip -r %GIF_DIR%solid2.gif | gifrsize | %GIF_DISPLAY%
  46.  
  47. gifinter %GIF_DIR%cheryl.gif | gifflip -x | %GIF_DISPLAY%
  48.  
  49. gifbg -d "TL" -s 320 175 -c 255 255 255 -l 64 | gifpos -s 640 350 -i   0   0 > b1.gif
  50. gifbg -d "BL" -s 320 175 -c 255 255 255 -l 64 | gifpos -s 640 350 -i   0 175 > b2.gif
  51. gifbg -d "TR" -s 320 175 -c 255 255 255 -l 64 | gifpos -s 640 350 -i 320   0 > b3.gif
  52. gifbg -d "BR" -s 320 175 -c 255 255 255 -l 64 | gifpos -s 640 350 -i 320 175 > b4.gif
  53. gifasm b1.gif b2.gif b3.gif b4.gif > backgrnd.gif
  54. %GIF_DISPLAY% backgrnd.gif
  55.  
  56. copy %GIF_DIR%solid2.gif s1.gif
  57. gifrsize s1.gif > s2.gif
  58. gifrsize s2.gif > s3.gif
  59. gifrsize s3.gif > s4.gif
  60. gifpos -i 320 0 s2.gif | gifinto s2.gif
  61. gifpos -i 480 0 s3.gif | gifinto s3.gif
  62. gifpos -i 560 0 s4.gif | gifinto s4.gif
  63. gifasm s1.gif s2.gif s3.gif s4.gif > sall.gif
  64. giftext sall.gif
  65. %GIF_DISPLAY% sall.gif
  66. del s?.gif
  67.  
  68. gifpos -s 720 348 -i 400 148 %GIF_DIR%porsche.gif | %GIF_DISPLAY%
  69.  
  70. gifrsize -s 3 %GIF_DIR%solid2.gif  | gifrsize -u | %GIF_DISPLAY%
  71.  
  72. gifinter %GIF_DIR%cheryl.gif | gifrsize | %GIF_DISPLAY% -z 2
  73.  
  74. gifclip -i 1 1 492 345 %GIF_DIR%solid2.gif | gifpos -s 492 345 | %GIF_DISPLAY%
  75.  
  76. @echo off
  77.  
  78. rem Remove these variables from current shell
  79. Exit:
  80.  
  81. set GIF_DIR=
  82. set GIF_DISPLAY=
  83.