The Lurker's Guide to Babylon 5
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

69 lines
1.0 KiB

17 years ago
  1. #!/bin/csh
  2. @ x=0
  3. @ y=0
  4. @ r=0
  5. @ h=32
  6. @ pal=80
  7. @ wid=999
  8. @ maxwid=5
  9. while ($y < 272)
  10. @ x = 0
  11. convert +dither -crop ${wid}x${h}+0+${y} -colors $pal $1 r${r}.miff
  12. while ($x < ${maxwid})
  13. convert -crop 100x999+${x}00+0 r${r}.miff r${r}c${x}.gif
  14. echo $x $r
  15. @ x++
  16. end
  17. @ y += $h
  18. @ h = 24
  19. @ pal = 20
  20. @ r++
  21. if ($r == 15) then
  22. @ wid = 400
  23. @ maxwid = 4
  24. endif
  25. end
  26. #
  27. # Two-row-high set of buttons; use the same palette on both rows.
  28. #
  29. convert -colors ${pal} +dither -crop 500x48+0+${y} $1 r11-12.miff
  30. @ x = 0
  31. @ r2 = $r + 1
  32. while ($x < ${maxwid})
  33. convert -crop 100x${h}+${x}00+0 r11-12.miff r${r}c${x}.gif
  34. convert -crop 100x${h}+${x}00+${h} r11-12.miff r${r2}c${x}.gif
  35. echo $x $r - $r2
  36. @ x++
  37. end
  38. @ r += 2
  39. @ y += $h + $h
  40. while ($y < 392)
  41. @ x = 0
  42. convert +dither -crop ${wid}x${h}+0+${y} -colors $pal $1 r${r}.miff
  43. while ($x < ${maxwid})
  44. convert -crop 100x999+${x}00+0 r${r}.miff r${r}c${x}.gif
  45. echo $x $r
  46. @ x++
  47. end
  48. @ y += $h
  49. @ h = 24
  50. @ pal = 20
  51. @ r++
  52. if ($r == 15) then
  53. @ wid = 400
  54. @ maxwid = 4
  55. endif
  56. end