tx32767.wad is a Doom texture wad that shows that a texture can contain up to 32,767 patches, even though some tools like DeuTex and Wintex enforce lower, arbitrary, limits. -- AYM 2004-01-03 This is how it was generated: # # Makefile to generate a Doom texture wad that redefines STARTAN3 # to use 32767 patches. You need DeuTex version 4.5 or later (not # released as of this writing), as version 4.4 limits the number # of patches per texture to 256. # AYM 2004-01-03 # # This file is copyright 2004 André Majorel, and distributed # under the terms of version 2 of the GNU General Public License. all: tx32767p.wad clean: rm -rf patches textures/texture1.txt wadinfo.txt tx32767p.wad tx32767p.wad: patches textures/texture1.txt /no/such/file printf '%s\n' '[patches]' 'black' 'white' >wadinfo.txt printf '%s\n' '[texture1]' 'texture1' >>wadinfo.txt [ ! -e $@ ] || mv $@ $@~ deutex -doom /usr/share/games/doom -build $@ patches: mkdir -p patches ppmmake rgb:0/0/0 1 1 >patches/black.ppm ppmmake rgb:f/f/f 1 1 >patches/white.ppm # 32767 = 256*128 - 1. A two-pixel patch is needed pnmcat -tb patches/white.ppm patches/black.ppm >patches/double.ppm textures/texture1.txt: mkdir -p textures awk ' \ BEGIN { \ width = 256; \ height = 128; \ printf("%-10s %3d %3d\n", "startan3", width, height); \ for (x = 0; x < width; x++) { \ for (y = 0; y < height; y++) { \ if (x == 255 && y == 127) \ continue; \ else if (x == 255 && y == 126) \ colour = "double"; \ else { \ if ((x % 2) == (y % 2)) \ colour = "black"; \ else \ colour = "white"; \ } \ printf("* %-8s %3d %3d\n", colour, x, y); \ } \ } \ }' $@ || rm -f $@ /no/such/file: