COMMON: Resize QMB particle texture, remove uwater, new 256x256 scope texture

This commit is contained in:
Steam Deck User 2023-03-16 22:20:27 -04:00
parent 27a8810d2a
commit fa9920406b
38 changed files with 0 additions and 196 deletions

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

View file

@ -1,89 +0,0 @@
import os
import struct
def findall():
filelist = os.listdir()
#print(filelist)
try:
os.mkdir('out')
print("Starting conversion, created 'out' directory...")
except:
print("Starting conversion, 'out' directory exists...")
for filename in filelist:
splits = filename.split('.')
suffix = splits[-1]
cancel = False
if suffix is 'h':
print("- Processing " + filename + "...")
h = open(filename, 'r')
width = -1
height = -1
for line in h:
if line[0] is not '#':
continue
words = line.split()
if words[1][-13:] == 'TEXTURE_WIDTH':
width = int(words[2])
elif words[1][-14:] == 'TEXTURE_HEIGHT':
height = int(words[2])
elif words[1][-14:] == 'TEXTURE_FORMAT':
if words[2] != '4':
print("-- Texture format not supported, only accepting GU_PSM_T4 !")
cancel = True
elif words[1][-15:] == 'TEXTURE_SWIZZLE':
if words[2] != '1':
print("-- Non-swizzled textures not recommended!")
#cancel = True
elif words[1][-14:] == 'PALETTE_FORMAT':
if words[2] != '3':
print("-- Palette format not supported, only accepting GU_PSM_8888 !")
cancel = True
if width == -1 or height == -1:
print("Missing either width or height in header !")
cancel = True
newfile = open(filename[:-2] + '.r4w', 'wb')
newfile.write(bytes("c4fe", 'utf-8'))
newfile.write(struct.pack('i', width))
newfile.write(struct.pack('i', height))
newfile.write(bytes("xxxx", 'utf-8'))
# the raw file
try:
raw = open(filename[:-2] + '.raw', 'rb')
# (width * height / 2) bytes for 4bpp
newfile.write(raw.read(int((width * height) / 2)))
raw.close()
except Exception as e:
print('-- Couldn\'t read ' + filename[:-2] + '.raw')
print("--- Exception: %s" % e)
cancel = True
# the rawpal file
try:
rawpal = open(filename[:-2] + '.rawpal', 'rb')
# 4 bytes per color, 16 colors
newfile.write(rawpal.read(4 * 16))
rawpal.close()
except Exception as e:
print('-- Couldn\'t read ' + filename[:-2] + '.rawpal')
print("--- Exception: %s" % e)
cancel = True
newfile.close()
if cancel:
os.remove(filename[:-2] + '.r4w')
print('-- ' + filename[:-2] + '.r4w was NOT generated.')
else:
try:
os.rename(filename[:-2] + '.r4w', 'out/' + filename[:-2] + '.r4w')
except:
os.remove('out/' + filename[:-2] + '.r4w')
os.rename(filename[:-2] + '.r4w', 'out/' + filename[:-2] + '.r4w')
print('-- Created ./out/' + filename[:-2] + '.r4w')
findall()

View file

@ -1,15 +0,0 @@
/* File produced with RAWTEX Gimp plugin v1.06
Written by Franck Charlet. */
#define DOORWAY_MET_TEXTURE_WIDTH 32
#define DOORWAY_MET_TEXTURE_REAL_WIDTH 32
#define DOORWAY_MET_TEXTURE_HEIGHT 64
#define DOORWAY_MET_TEXTURE_REAL_HEIGHT 64
#define DOORWAY_MET_TEXTURE_FORMAT 4
#define DOORWAY_MET_TEXTURE_MIPMAPS 0
#define DOORWAY_MET_TEXTURE_SWIZZLE 1
#define DOORWAY_MET_PALETTE_FORMAT 3
#define DOORWAY_MET_PALETTE_COLORS (16 / 8)
#define DOORWAY_MET_PALETTE_MASK 0xf
#define DOORWAY_MET_MIPMAPS_OFFSET0 0

Binary file not shown.

View file

@ -1 +0,0 @@
˙˙*+)˙.-&˙32+˙131˙66/˙786˙:<9˙AB@˙IJH˙RSQ˙XZW˙ab`˙kmj˙uwt˙

Binary file not shown.

Binary file not shown.

View file

@ -1,15 +0,0 @@
/* File produced with RAWTEX Gimp plugin v1.06
Written by Franck Charlet. */
#define _BARBED_WIRE_V_TEXTURE_WIDTH 64
#define _BARBED_WIRE_V_TEXTURE_REAL_WIDTH 64
#define _BARBED_WIRE_V_TEXTURE_HEIGHT 64
#define _BARBED_WIRE_V_TEXTURE_REAL_HEIGHT 64
#define _BARBED_WIRE_V_TEXTURE_FORMAT 4
#define _BARBED_WIRE_V_TEXTURE_MIPMAPS 0
#define _BARBED_WIRE_V_TEXTURE_SWIZZLE 1
#define _BARBED_WIRE_V_PALETTE_FORMAT 3
#define _BARBED_WIRE_V_PALETTE_COLORS (7 / 8)
#define _BARBED_WIRE_V_PALETTE_MASK 0xf
#define _BARBED_WIRE_V_MIPMAPS_OFFSET0 0

View file

@ -1,15 +0,0 @@
/* File produced with RAWTEX Gimp plugin v1.06
Written by Franck Charlet. */
#define _BOARD_FE_TEXTURE_WIDTH 64
#define _BOARD_FE_TEXTURE_REAL_WIDTH 64
#define _BOARD_FE_TEXTURE_HEIGHT 64
#define _BOARD_FE_TEXTURE_REAL_HEIGHT 64
#define _BOARD_FE_TEXTURE_FORMAT 4
#define _BOARD_FE_TEXTURE_MIPMAPS 0
#define _BOARD_FE_TEXTURE_SWIZZLE 1
#define _BOARD_FE_PALETTE_FORMAT 3
#define _BOARD_FE_PALETTE_COLORS (16 / 8)
#define _BOARD_FE_PALETTE_MASK 0xf
#define _BOARD_FE_MIPMAPS_OFFSET0 0

Binary file not shown.

Binary file not shown.

View file

@ -1,15 +0,0 @@
/* File produced with RAWTEX Gimp plugin v1.06
Written by Franck Charlet. */
#define _CAMO_2_TEXTURE_WIDTH 32
#define _CAMO_2_TEXTURE_REAL_WIDTH 32
#define _CAMO_2_TEXTURE_HEIGHT 32
#define _CAMO_2_TEXTURE_REAL_HEIGHT 32
#define _CAMO_2_TEXTURE_FORMAT 4
#define _CAMO_2_TEXTURE_MIPMAPS 0
#define _CAMO_2_TEXTURE_SWIZZLE 1
#define _CAMO_2_PALETTE_FORMAT 3
#define _CAMO_2_PALETTE_COLORS (10 / 8)
#define _CAMO_2_PALETTE_MASK 0xf
#define _CAMO_2_MIPMAPS_OFFSET0 0

View file

@ -1 +0,0 @@
fffUUUUUffVUDUTefffTUTUDfFefEUeefUevUEfDefaUTEUffeVUffUUafHDefffTUaWAEfffUwEdffvuWDeffFDwgVdfffwUUff1UefvefffWeWefAUffvWffVEex㎡QUffQWefAUfaVUUUTeffaEEAufffWUUeff5UfSdfffVUEdfUUUdfQuxffwUWeUEuweffD<66>xwwWUeUU<55>afffUUwUwWWUUw<55>fffETUUuwfUUUu<55>afVTefUUfVfV<66>hVUUeVUffff<66><66>UTUaVeffff㍗fVUEUefEdfaffvwffVUUUgf6dfafVUwffFTUwgffEfUeUUUffUUUffQXUDDTfffUDffQAxUEEAdfaFU4a"QⅡUQfaWUT!"eWDfavUUffQgffffQUUeffVAUgffffAUWeffUEUUeffffQTEeffUETDEffffUDTTUffVUEDTf

Binary file not shown.

View file

@ -1,15 +0,0 @@
/* File produced with RAWTEX Gimp plugin v1.06
Written by Franck Charlet. */
#define _CLFND_TEXTURE_WIDTH 32
#define _CLFND_TEXTURE_REAL_WIDTH 32
#define _CLFND_TEXTURE_HEIGHT 32
#define _CLFND_TEXTURE_REAL_HEIGHT 32
#define _CLFND_TEXTURE_FORMAT 4
#define _CLFND_TEXTURE_MIPMAPS 0
#define _CLFND_TEXTURE_SWIZZLE 1
#define _CLFND_PALETTE_FORMAT 3
#define _CLFND_PALETTE_COLORS (7 / 8)
#define _CLFND_PALETTE_MASK 0xf
#define _CLFND_MIPMAPS_OFFSET0 0

Binary file not shown.

Binary file not shown.

View file

@ -1,15 +0,0 @@
/* File produced with RAWTEX Gimp plugin v1.06
Written by Franck Charlet. */
#define _METAL_RAIL7_TEXTURE_WIDTH 32
#define _METAL_RAIL7_TEXTURE_REAL_WIDTH 32
#define _METAL_RAIL7_TEXTURE_HEIGHT 16
#define _METAL_RAIL7_TEXTURE_REAL_HEIGHT 16
#define _METAL_RAIL7_TEXTURE_FORMAT 4
#define _METAL_RAIL7_TEXTURE_MIPMAPS 0
#define _METAL_RAIL7_TEXTURE_SWIZZLE 1
#define _METAL_RAIL7_PALETTE_FORMAT 3
#define _METAL_RAIL7_PALETTE_COLORS (5 / 8)
#define _METAL_RAIL7_PALETTE_MASK 0xf
#define _METAL_RAIL7_MIPMAPS_OFFSET0 0

Binary file not shown.

View file

@ -1,15 +0,0 @@
/* File produced with RAWTEX Gimp plugin v1.06
Written by Franck Charlet. */
#define _RAILLING_NDU_TEXTURE_WIDTH 64
#define _RAILLING_NDU_TEXTURE_REAL_WIDTH 64
#define _RAILLING_NDU_TEXTURE_HEIGHT 64
#define _RAILLING_NDU_TEXTURE_REAL_HEIGHT 64
#define _RAILLING_NDU_TEXTURE_FORMAT 4
#define _RAILLING_NDU_TEXTURE_MIPMAPS 0
#define _RAILLING_NDU_TEXTURE_SWIZZLE 1
#define _RAILLING_NDU_PALETTE_FORMAT 3
#define _RAILLING_NDU_PALETTE_COLORS (16 / 8)
#define _RAILLING_NDU_PALETTE_MASK 0xf
#define _RAILLING_NDU_MIPMAPS_OFFSET0 0