Skip to content

Commit

Permalink
Refresh 12
Browse files Browse the repository at this point in the history
  • Loading branch information
n64 committed Sep 20, 2020
1 parent 9214ddd commit 8b872a7
Show file tree
Hide file tree
Showing 137 changed files with 2,106 additions and 1,586 deletions.
20 changes: 19 additions & 1 deletion CHANGES
Original file line number Diff line number Diff line change
@@ -1,5 +1,23 @@
Refresh 12

1.) Debug box improvements (#1066)
2.) Improve 'geo_render_mirror_mario' (#1064)
3.) Cleanup and small labeling (#1063)
4.) Anim renames and other related renames (#1062)
5.) remove do while 0 and make one line comments consistent (#1061)
6.) fixed typo in segments.h (#1060)
7.) Name unknown fields (from public repo) (#1058)
8.) Change 'void *' to 'struct MainPoolState *' (#1057)
9.) Fix type of freeList (#1056)
10.) Newer version of diff script (#1055)
11.) Add stubbed_printfs based on unused audio strings (#1054)
12.) Fix comment in paintings.c (#1053)
13.) Add defines for hardcoded cell/floor height values (#1051)
14.) Update README.md: Remove GitHub specific Markdown syntax (#1052)
15.) Properly label interation status that handle's Bowser's shockwave attack (#1050)

Refresh 11
1.) (HEAD -> master, origin/master, origin/HEAD) Make geo_process_level_of_detail endian-independent (#1049)
1.) Make geo_process_level_of_detail endian-independent (#1049)
2.) Label oMoveFlags and slight cleanup. (#1046)
3.) Avoid UB in synthesis_resample_and_mix_reverb (#1048)
4.) Change some void * to correct type (#1047)
Expand Down
17 changes: 11 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -528,8 +528,6 @@ $(BUILD_DIR)/actors/%.o: OPT_FLAGS := -g
$(BUILD_DIR)/bin/%.o: OPT_FLAGS := -g
$(BUILD_DIR)/src/goddard/%.o: OPT_FLAGS := -g
$(BUILD_DIR)/src/goddard/%.o: MIPSISET := -mips1
$(BUILD_DIR)/src/audio/%.o: OPT_FLAGS := -O2 -Wo,-loopunroll,0
$(BUILD_DIR)/src/audio/load.o: OPT_FLAGS := -O2 -framepointer -Wo,-loopunroll,0
$(BUILD_DIR)/lib/src/%.o: OPT_FLAGS :=
$(BUILD_DIR)/lib/src/math/ll%.o: MIPSISET := -mips3 -32
$(BUILD_DIR)/lib/src/math/%.o: OPT_FLAGS := -O2
Expand All @@ -545,15 +543,22 @@ $(BUILD_DIR)/lib/src/_Ldtob.o: OPT_FLAGS := -O3
$(BUILD_DIR)/lib/src/_Printf.o: OPT_FLAGS := -O3
$(BUILD_DIR)/lib/src/sprintf.o: OPT_FLAGS := -O3

# enable loop unrolling except for external.c (external.c might also have used
# unrolling, but it makes one loop harder to match)
$(BUILD_DIR)/src/audio/%.o: OPT_FLAGS := -O2
$(BUILD_DIR)/src/audio/load.o: OPT_FLAGS := -O2
# Enable loop unrolling except for external.c (external.c might also have used
# unrolling, but it makes one loop harder to match).
# For all audio files other than external.c and port_eu.c, put string literals
# in .data. (In Shindou, the port_eu.c string literals also moved to .data.)
$(BUILD_DIR)/src/audio/%.o: OPT_FLAGS := -O2 -use_readwrite_const
$(BUILD_DIR)/src/audio/port_eu.o: OPT_FLAGS := -O2
$(BUILD_DIR)/src/audio/external.o: OPT_FLAGS := -O2 -Wo,-loopunroll,0
else

$(BUILD_DIR)/src/audio/%.o: OPT_FLAGS := -O2 -Wo,-loopunroll,0
$(BUILD_DIR)/src/audio/load.o: OPT_FLAGS := -O2 -framepointer -Wo,-loopunroll,0

# The source-to-source optimizer copt is enabled for audio. This makes it use
# acpp, which needs -Wp,-+ to handle C++-style comments.
# All other files than external.c should really use copt, but only a few have
# been matched so far.
$(BUILD_DIR)/src/audio/effects.o: OPT_FLAGS := -O2 -Wo,-loopunroll,0 -sopt,-inline=sequence_channel_process_sound,-scalaroptimize=1 -Wp,-+
$(BUILD_DIR)/src/audio/synthesis.o: OPT_FLAGS := -O2 -sopt,-scalaroptimize=1 -Wp,-+
#$(BUILD_DIR)/src/audio/seqplayer.o: OPT_FLAGS := -O2 -sopt,-inline_manual,-scalaroptimize=1 -Wp,-+ #-Wo,-v,-bb,-l,seqplayer_list.txt
Expand Down
60 changes: 29 additions & 31 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -138,36 +138,34 @@ docker run --rm --mount type=bind,source="$(pwd)",destination=/sm64 --user $UID:
Resulting artifacts can be found in the `build` directory.

## Project Structure

```
sm64
├── actors: object behaviors, geo layout, and display lists
├── asm: handwritten assembly code, rom header
│ └── non_matchings: asm for non-matching sections
├── assets: animation and demo data
│ ├── anims: animation data
│ └── demos: demo data
├── bin: C files for ordering display lists and textures
├── build: output directory
├── data: behavior scripts, misc. data
├── doxygen: documentation infrastructure
├── enhancements: example source modifications
├── include: header files
├── levels: level scripts, geo layout, and display lists
├── lib: SDK library code
├── rsp: audio and Fast3D RSP assembly code
├── sound: sequences, sound samples, and sound banks
├── src: C source code for game
│ ├── audio: audio code
│ ├── buffers: stacks, heaps, and task buffers
│ ├── engine: script processing engines and utils
│ ├── game: behaviors and rest of game source
│ ├── goddard: Mario intro screen
│ └── menu: title screen and file, act, and debug level selection menus
├── text: dialog, level names, act names
├── textures: skybox and generic texture data
└── tools: build tools
```

sm64
├── actors: object behaviors, geo layout, and display lists
├── asm: handwritten assembly code, rom header
│ └── non_matchings: asm for non-matching sections
├── assets: animation and demo data
│ ├── anims: animation data
│ └── demos: demo data
├── bin: C files for ordering display lists and textures
├── build: output directory
├── data: behavior scripts, misc. data
├── doxygen: documentation infrastructure
├── enhancements: example source modifications
├── include: header files
├── levels: level scripts, geo layout, and display lists
├── lib: SDK library code
├── rsp: audio and Fast3D RSP assembly code
├── sound: sequences, sound samples, and sound banks
├── src: C source code for game
│ ├── audio: audio code
│ ├── buffers: stacks, heaps, and task buffers
│ ├── engine: script processing engines and utils
│ ├── game: behaviors and rest of game source
│ ├── goddard: Mario intro screen
│ └── menu: title screen and file, act, and debug level selection menus
├── text: dialog, level names, act names
├── textures: skybox and generic texture data
└── tools: build tools

## Contributing

Expand All @@ -176,4 +174,4 @@ discuss what you would like to change.

Run `clang-format` on your code to ensure it meets the project's coding standards.

Official Discord: https://discord.gg/DuYH3Fh
Official Discord: [discord.gg/DuYH3Fh](https://discord.gg/DuYH3Fh)
14 changes: 14 additions & 0 deletions asm/non_matchings/eu/audio/sequence_channel_process_script.s
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
.data
.asciiz "Audio:Track :Call Macro Level Over Error!\n"
.balign 4
.asciiz "Audio:Track :Loops Macro Level Over Error!\n"
.balign 4
.asciiz "SUB:ERR:BANK %d NOT CACHED.\n"
.balign 4
.asciiz "SUB:ERR:BANK %d NOT CACHED.\n"
.balign 4
.asciiz "Audio:Track: CTBLCALL Macro Level Over Error!\n"
.balign 4
.asciiz "Err :Sub %x ,address %x:Undefined SubTrack Function %x"
.balign 4

.late_rodata
.late_rodata_alignment 4
glabel jtbl_EU_80306714
Expand Down
5 changes: 2 additions & 3 deletions asm/rom_header.s
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

.byte 0x80, 0x37, 0x12, 0x40 /* PI BSD Domain 1 register */
.word 0x0000000F /* Clockrate setting*/
.word entry_point /* Entrypoint */
.word entry_point /* Entrypoint */

/* Revision */
.if VERSION_SH == 1
Expand Down Expand Up @@ -39,8 +39,7 @@
.endif

.if VERSION_SH == 1
.byte 0x03 /* Version (Shindou) */
.byte 0x03 /* Version (Shindou) */
.else
.byte 0x00 /* Version */
.endif

Loading

0 comments on commit 8b872a7

Please sign in to comment.