1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-06-07 17:11:50 +00:00
Commit graph

386 commits

Author SHA1 Message Date
Dragorn421
c6dbebfcd2
Fix too long filenames for windows (#2591) 2025-06-05 23:02:04 -04:00
Dragorn421
b84d1afc67
Better automatic names for Limbs and JointKeys, and implement more get_as_xml (#2590) 2025-06-05 21:55:30 -04:00
fig02
28cc9d68cf
Remove "z64" prefix from all headers (#2518)
* z64 - a

* z64 - b

* z64 - c

* z64 - d

* z64 - e

* z64 - f

* z64 - g

* z64 - h

* z64 - i

* z64 - l

* z64 - m

* z64 - o

* z64 - p

* z64 - q

* z64 - r

* z64 - s

* z64 - t

* z64 - v

* restore file

* fix merge

* fix merge

---------

Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
2025-06-04 14:38:33 -04:00
Dragorn421
c903555e83
Commit some assets/overlays/ (#2582)
* Commit (inline) some assets/overlays/

* rm padding

* ovl_file_choose
2025-06-04 07:44:10 -04:00
Dragorn421
66f367e449
Commit g_pn_*.c files (#2573) 2025-06-03 20:30:44 -04:00
Dragorn421
66a7720dcd
csdis.py: write CS_CMD_ACTOR_CUE_ names in actor cue list header (#2561) 2025-06-01 09:18:13 -04:00
Dragorn421
fd5fbe138d
Commit icon_item_24_static, icon_item_{fra,ger,jpn,nes}_static, item_name_static (#2562)
* commit icon_item_24_static

* commit icon_item_LANG_static for LANG in fra,ger,jpn,nes

* commit item_name_static
2025-05-31 10:26:04 +02:00
Dragorn421
91e9553ee5
[assets system] Fix fusing resource buffer markers (#2548) 2025-05-27 17:41:51 +02:00
Dragorn421
68ea3bcc00
[assets] Better automatic names for subdata of Anim and Col data (#2543)
* better auto names for anim subdata

* better auto names for col subdata
2025-05-26 20:15:20 -04:00
Dragorn421
6b9656b42a
Commit object_link_child (#2542)
* add Vtx resources to object_link_child.xml

* object_link_child.xml limb enum and tlut blob

* cp extracted/... assets/...

* start cleanup, delete useless declarations

* inhibit object_link_child.c source gen

* move textures _WIDTH and _HEIGHT to .c, remove useless tex decls

* comments

* fixup object_link_boy comments

* remove unreferenced DLs decls

* rm 0 padding

* format the .c

* fixup

* bss
2025-05-26 16:59:33 -04:00
Tharo
faf2003d37
Force skybox split palettes to always contain 128 colors (#2535)
* Force skybox split palettes to always contain 128 colors, padding with 0 if necessary

* Review
2025-05-25 21:50:34 +02:00
Dragorn421
4201359f89
Finalize and commit object_link_boy (#2528)
* Finalize and commit object_link_boy

* bss

* format

* dont write extracted/.../object_link_boy.c

* sizes for dls and texs

* fix OK

* TEX_LEN
2025-05-25 20:21:16 +02:00
Dragorn421
eeeaa77d3f
Introduce TEX_LEN macro for texture arrays lengths (#2541) 2025-05-25 12:33:24 -04:00
Dragorn421
4eceb77128
[assets] Explicit size for textures and dlists (#2534)
* Add `conf.EXPLICIT_SIZES = True` for making some array resources declare and define with explicit length

* EXPLICIT_DL_AND_TEX_SIZES = True

* revert rm line
2025-05-23 02:58:20 -04:00
Dragorn421
f456bc6bf8
Assets system utilities (#2529) 2025-05-20 20:48:47 -04:00
Dragorn421
a6162dc8e7
Add write_source.txt: list of files to write source for during assets extraction (#2531) 2025-05-20 20:19:25 -04:00
Dragorn421
1e556e3a3d
New assets system (#2481)
* 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

* use variables from config.yml for gMtxClear and sShadowTex addresses

* Write source with static for overlays using `HACK_IS_STATIC_ON` hack

* gc-eu-mq-dbg OK from clean with `make setup && make`

* implement more skeleton-related types, cleanups, fixups

* fix extracted data to no longer produce compilation warnings

* implement more of RoomShapeImage types

* yeet XmlPath from ExternalFile usage

* Implement PlayerAnimationDataResource (link_animetion data)

* fix csdis CS_TIME extra arg

* dmadata file names no longer hardcoded for gc-eu-mq-dbg

* ntsc-1.0 OK

* xml fixes

* slightly improve standard output

* rm extract_assets.py

* generate and use Limb enums (TODO: check Skin skels and implement for Curve skels)

* handle dependencies between xmls

* introduce RawPointers xml attribute to ignore specific pointers and keep them raw

* add tools/extract_assets.sh

* fixups

* only extract if xmls changed or if -f (force) is used

* fixups, gc-eu OK

* all versions OK

* check attributes of xml resources elements

* Implement legacy skelanime resources

* fix ASSET_FILES_BIN_EXTRACTED/COMMITTED: look for .u8.bin specifically instead of just .bin

* implement JFIFResource

* fix png/jpg wildcards: look specifically for .u64.png .u32.png .u64.jpg

* Makefile: Add rules to build .png, .bin and .jpg in assets/ too

* start writing actual docs

* extract sTransCircleDL and sTransWipeDL

* misc cleanup/fixes, pygfxd 1.0.3

* refactor CDataExt.set_write callback args to use a dataclass

* Move {} to in-source

* misc

* more progress on spec

* fix missing braces in n64dd_error_textures.c

* finish xml spec doc

* assets xmls fixes

* some cleanup, use `gNameTex_WIDTH/HEIGHT` macros in dlists

* handle hackmode_syotes_room, fix compile

* C build_from_png

* rm tools/assets/bin2c

* rm ZAPD

* format

* remove rule to generate dmadata_table.py

* CC0 license (and some import cleanup)

* dont try to build zapd (rmd)

* simplify palettes with single user (ci images with a non-shared palette)

* add docs on how images are handled

* bss

* allow -j N

* fix n64texconv python bindings memory management

* move -j at the end of calling extraction script

* with -j, update last_extracts.json as each job completes rather than only if all complete

* make interrupting less jank by making child processes ignore sigint

* use enum names in `SCENE_CMD_SKYBOX_SETTINGS`

* `multiprocessing.get_context("fork")`

* import rich, except ImportError s

* fix optional rich usage

* .bss

* .bss

* .bss

* assets extraction: -j -> -j$(N_THREADS)

* .bss

* change LIMB_NONE/MAX defaults to be FILE_OFFSET instead of SKELNAME

* 0XHEX -> 0xHEX

* fix bss

* Proper includes for assets

mostly proper, some includes like dlists resources always causing a sys_matrix.h include (when not every dlist references gIdentityMtx) could be done better

* rm z64.h

* rm z64.h take two

* bss

* Make .u64 suffix for pngs optional

* fixup: rm .u64 suffix from n64dd image paths

* Remove elemtype suffixes from .bin and .jpg files

* Update images.md

* some build_from_png cleanup, more error handling, comments

* Handle skybox textures

Introduce "sub-format" suffix for pngs, with sub-formats split_lo and split_hi being used for skybox textures

* fixup for older python

* improve collision output some

* fully use SURFACETYPE[01] macros in writing extracted surface types

* use WATERBOX_PROPERTIES in extracted waterboxes

* some SceneCommandsResource cleanup

* format EnvLightSettingsList output
2025-05-18 01:29:09 +02:00
Dragorn421
39ae99c4cb
Fix fix_bss.py (#2526) 2025-05-06 16:53:24 -04:00
fig02
f7a270655b
Delete macros.h; Delete global.h (#2516) 2025-04-27 12:48:11 -04:00
fig02
2278bcb2c3
Remove Variables.h; Decouple z64.h from global.h (#2507)
* progress

* z64.h issues sorted

* remove variables.h

* format

* n64 fix

* another fix

* did the wrong fix

* fix libleo

* fix bss

* review

* remove instead of comment
2025-04-19 22:04:08 -04:00
Derek Hensley
1beeff9658
Account for z_rumble's unreferenced bss at the start in fix_bss script (#2502)
* Account for z_rumble's unreferenced bss at the start

* z_locale and black
2025-04-04 19:54:18 -04:00
Derek Hensley
1b1070d0f4
Seperate baserom segments dir from output dir (#2498) 2025-03-27 02:20:41 -04:00
Tharo
3d61fb85ef
Add n64texconv and bin2c tools to convert extracted .png and .bin to C arrays during build (#2477)
* n64texconv and bin2c

* mv tools/n64texconv tools/assets/

* fix

* more light fixes

* Silence -Wshadow for libimagequant

* Add reference counting gc for palette objects in python bindings

* Fix missing alignment in n64texconv_*_to_c functions

Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>

* Check palette size in n64texconv_image_from_png

* accept memoryview as well as bytes for binary data

* minimal doc on n64texconv_quantize_shared

* fix a buffer size passed to libimagequant

* assert pal count <= 256 on png write

* Disable palette size check for input pngs, ZAPD fails the check

* No OpenMP for clang

* When reading an indexed png into a CI format, requantize if there are too many colors for the target texel size

---------

Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
2025-02-17 17:09:42 -05:00
cadmic
a64fd8dea8
fix_bss.py: Try to handle one-past-the-end pointers (#2471)
* fix_bss.py: Try to handle one-past-the-end pointers

* Proofread
2025-02-15 16:24:25 -05:00
cadmic
be1f9e75f0
Read static symbols from .mdebug in sym_info.py (#2460)
* Patch .mdebug for data_with_rodata objects

* Read static symbols from .mdebug in sym_info.py

* Add ability to print all symbols

* Add license

* Fix bug when missing .mdebug section

* /patch_data_with_rodata_mdebug.py license + nitpicks
2025-02-09 18:16:18 -05:00
Dragorn421
36b71ca2de
Update csdis.py (#2459)
* csdis: move filemap import to main() as it is only needed there

* csdis: fix CS_TIME macro

* csdis: make `disassemble_cutscene` return cutscene size in words

* add comment on why total_entries+1
2025-02-09 16:42:39 -05:00
mzxrules
03a2612246
Rename gMtx(F)Clear to gIdentityMtx(F) (#2458) 2025-02-08 19:00:32 -05:00
cadmic
e63d2b73b7
Use CIC 6102 for iQue decompressed ROMs (#2457)
* Use CIC 6102 for iQue decompressed ROMs

* Future-proof is_ique

* Make things more readable
2025-02-06 21:10:30 +01:00
Tharo
9a3878ec7e
git subrepo clone --force git@github.com:Thar0/com-plugin.git tools/com-plugin (#2455)
subrepo:
  subdir:   "tools/com-plugin"
  merged:   "fc5aa5eda"
upstream:
  origin:   "git@github.com:Thar0/com-plugin.git"
  branch:   "main"
  commit:   "fc5aa5eda"
git-subrepo:
  version:  "0.4.6"
  origin:   "https://github.com/ingydotnet/git-subrepo"
  commit:   "110b9eb"
2025-02-05 22:53:35 -05:00
cadmic
8b82eb1ff7
Delete disassembly data for ique-cn (#2453) 2025-02-04 13:17:57 +01:00
Tharo
c028db03b4
Finish matching ique-cn (#2451)
* git subrepo clone git@github.com:Thar0/com-plugin.git tools/com-plugin

subrepo:
  subdir:   "tools/com-plugin"
  merged:   "e8543312d"
upstream:
  origin:   "git@github.com:Thar0/com-plugin.git"
  branch:   "main"
  commit:   "e8543312d"
git-subrepo:
  version:  "0.4.6"
  origin:   "https://github.com/ingydotnet/git-subrepo"
  commit:   "110b9eb"

* ique-cn OK

* Review suggestions

* Most suggestions

* git subrepo pull tools/com-plugin

subrepo:
  subdir:   "tools/com-plugin"
  merged:   "81595ed1c"
upstream:
  origin:   "git@github.com:Thar0/com-plugin.git"
  branch:   "main"
  commit:   "81595ed1c"
git-subrepo:
  version:  "0.4.6"
  origin:   "https://github.com/ingydotnet/git-subrepo"
  commit:   "110b9eb"

* Fix other versions
2025-02-04 06:55:04 -05:00
cadmic
6c06168e72
fix_bss.py: Gracefully handle EGCS-compiled files (#2452) 2025-02-03 01:42:31 -05:00
cadmic
ef53bfd693
[iQue] Match z_file_copy_erase (#2447)
* [iQue] Match z_file_copy_erase

* Reword comment
2025-01-29 14:17:13 -05:00
Sirius902
dfe232533f
Fix /bin/bash -> /usr/bin/env bash (#2448)
* Fix /bin/bash -> /usr/bin/env bash

* Add curl to docker container
2025-01-28 18:45:56 -05:00
cadmic
f8d050bf7f
git subrepo pull --force tools/ZAPD (#2441)
subrepo:
  subdir:   "tools/ZAPD"
  merged:   "35ea376da"
upstream:
  origin:   "https://github.com/zeldaret/ZAPD.git"
  branch:   "master"
  commit:   "35ea376da"
git-subrepo:
  version:  "0.4.6"
  origin:   "git@github.com:ingydotnet/git-subrepo.git"
  commit:   "110b9eb"
2025-01-24 14:02:44 -05:00
cadmic
b97a21c253
git subrepo pull tools/fado (#2437)
subrepo:
  subdir:   "tools/fado"
  merged:   "a45f99b46"
upstream:
  origin:   "git@github.com:EllipticEllipsis/fado.git"
  branch:   "master"
  commit:   "a45f99b46"
git-subrepo:
  version:  "0.4.6"
  origin:   "git@github.com:ingydotnet/git-subrepo.git"
  commit:   "110b9eb"
2025-01-22 13:42:19 -05:00
cadmic
c76d2a8a4d
[iQue] Match z_kanfont (#2428) 2025-01-19 19:41:14 -05:00
cadmic
260d92dfb6
Preserve NULL/true/false macros in permuter/decomp.me import (#2430) 2025-01-17 15:37:40 -05:00
cadmic
d066586872
[iQue] Match z_sram (#2426)
* [iQue] z_sram: Use iQue-specific read/write macros

* [iQue] z_sram: Make checksum a struct

* [iQue] z_sram: Finish matching

* Call the trigraph usage a bug

* Fix bss

* Sram_iQueReadWrite -> Sram_ReadWriteIQue

* Use SRAM_HEADER_MAGIC for loop bound

* Rename sZeldaMagic -> sSramDefaultHeader and use less char literals
2025-01-17 06:56:22 -05:00
cadmic
e2ed5568e5
[iQue] Match ovl_kaleido_scope (#2421)
* [iQue] Match ovl_kaleido_scope

* Add bug comment for OOB reads

Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>

* Preemptively fix merge conflicts

---------

Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
2025-01-14 08:32:00 -05:00
cadmic
1549f34e8e
[iQue] Update permuter/decompme import (#2415)
* [iQue] Update permuter/decompme import

* Fix GCC build
2025-01-10 18:05:10 -05:00
cadmic
e4ad4e5eee
[iQue] Match remaining src/boot files (#2417)
* [iQue] Match remaining src/boot files

* Fix debug ROM

* Use -funsigned-char

* Sort ique before gc in LNx macros
2025-01-10 18:47:55 +01:00
cadmic
26f91bd3bb
[iQue] Match gzip/zlib decompression (#2416)
* [iQue] Match gzip/zlib decompression

Co-authored-by: Anghelo Carvajal <angheloalf95@gmail.com>

* Update missed renames in disassembly

* Fix some formatting

---------

Co-authored-by: Anghelo Carvajal <angheloalf95@gmail.com>
2025-01-10 14:31:20 +01:00
Tharo
94971a61b4
[iQue] Match handwritten asm files in libultra/os, match C replacements of osGetCount and __osSetCompare (#2413)
* [iQue] Match handwritten asm files in libultra/os, match C replacements of osGetCount and __osSetCompare

* Format

* Adjust some label names in dcache functions
2025-01-10 06:16:19 -05:00
cadmic
3aafbf3971
Match remaining IDO files for iQue (#2394) 2025-01-06 01:45:12 -05:00
cadmic
9dafc2f2e4
[iQue] Build some C files with EGCS (#2396) 2025-01-02 03:35:22 -05:00
cadmic
ffc9f2d4f1
Download EGCS binutils and gcc for iQue (#2391)
* Download EGCS binutils and gcc for iQue

* Use curl -s for cleaner output
2024-12-30 09:30:37 -05:00
cadmic
a590995c1a
Add missing vimode splits in iQue disassembly (#2393) 2024-12-28 15:55:00 -05:00
cadmic
ccfb3594ac
Match iQue compression (#2389)
* Match iQue compression

* Use a dict

* Use Makefile variables for compression settings

* Put COMPRESS_ARGS last

* Pad iQue ROMs to 16 KiB

* Replace --pad-rom with --pad-to and --fill-padding-bytes

* Clarify --fill-padding-bytes
2024-12-27 10:34:45 -05:00
cadmic
aaf3183233
Download ido-recomp compiler binaries instead of committing them (#2388)
* Download ido-recomp compiler binaries instead of committing them

* Skip downloading compilers if ido_recomp/ exists

* Use make instead of bash script
2024-12-26 12:41:03 -05:00