1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-08-24 16:01:26 +00:00
oot/tools/assets/n64.py
Dragorn421 8411c34b38
wip: New assets system tm
Builds gc-eu-mq-dbg OK from clean after
1) make setup
2) python3 -m tools.assets.extract -j
3) replace 0x80A8E610 with sShadowTex in extracted/gc-eu-mq-dbg/assets/overlays/ovl_En_Jsjutan/sShadowMaterialDL.inc.c
4) make various symbols in extracted data like sTex static
2025-02-05 16:31:29 +01:00

50 lines
780 B
Python

import enum
class G_IM_FMT(enum.Enum):
RGBA = 0
YUV = 1
CI = 2
IA = 3
I = 4
def __init__(self, i: int):
self.i = i
by_i: dict[int, "G_IM_FMT"]
G_IM_FMT.by_i = {fmt.i: fmt for fmt in G_IM_FMT}
class G_IM_SIZ(enum.Enum):
_4b = (0, 4)
_8b = (1, 8)
_16b = (2, 16)
_32b = (3, 32)
def __init__(self, i: int, bpp: int):
self.i = i
self.bpp = bpp
by_i: dict[int, "G_IM_SIZ"]
G_IM_SIZ.by_i = {siz.i: siz for siz in G_IM_SIZ}
G_MDSFT_TEXTLUT = 14
class G_TT(enum.Enum):
NONE = 0b00 << G_MDSFT_TEXTLUT
RGBA16 = 0b10 << G_MDSFT_TEXTLUT
IA16 = 0b11 << G_MDSFT_TEXTLUT
def __init__(self, i: int):
self.i = i
by_i: dict[int, "G_TT"]
G_TT.by_i = {tt.i: tt for tt in G_TT}