# Disc-mapped structs checked by cos_layout_check (docs/NATIVE_PORT_PHASE4_6.md, step 4.0c).
#
# A struct belongs here when the game reads it straight out of a file loaded from the disc (or a
# file it writes, like the save): its host layout must equal the GameCube layout, which the
# decomp records as /* 0xNN */ comments before each field and `// Size: 0xNN` after the brace.
# native/tools/layout_check.py turns those into static_asserts; the checks that fail until their
# format step lands are listed in layout_xfail.txt. A struct changed to BE(T)/OFFSET_PTR by a
# phase 4 step goes (or stays) here.
#
# Format: a header path relative to game/include at the start of a line, then its structs
# indented, one per line, by qualified name. A struct line may add `size=0xNN` and
# `<field>=0xNN` for what the decomp does not comment (they must agree with any comment there).
# Each group names the step that owns it.

# 4.3, 4.5: block headers shared by the J3D, J2D, JMessage and font files; textures and fonts
JSystem/JUtility/JUTDataHeader.h
    JUTDataBlockHeader      size=0x8
    JUTDataFileHeader
JSystem/JUtility/JUTTexture.h
    ResTIMG
JSystem/JUtility/JUTPalette.h
    ResTLUT                 size=0x4 format=0x0 transparency=0x1 numColors=0x2
JSystem/JUtility/JUTNameTab.h
    ResNTAB                 size=0x8 mEntryNum=0x0 mPad0=0x2 mEntries=0x4
    ResNTAB::Entry          size=0x4 mKeyCode=0x0 mOffs=0x2
JSystem/JUtility/JUTFont.h
    ResFONT                 size=0x20
    ResFONT::INF1           size=0x14
    ResFONT::WID1           size=0x10
    ResFONT::MAP1           size=0x14
    ResFONT::GLY1           size=0x20

# 4.4: RARC archives
JSystem/JKernel/JKRArchive.h
    SArcHeader              size=0x20
    SArcDataInfo            size=0x20
    JKRArchive::SDIDirEntry size=0x10 type=0x0 name_offset=0x4 field_0x8=0x8 num_entries=0xA first_file_index=0xC
    JKRArchive::SDIFileEntry size=0x14 file_id=0x0 name_hash=0x2 type_flags_and_name_offset=0x4 data_offset=0x8 data_size=0xC
JSystem/JKernel/JKRDvdRipper.h
    SYaz0Header             size=0x8 signature=0x0 length=0x4

# 4.6: BMG messages
JSystem/JMessage/data.h
    JMessage::data::JUTMesgInfo
    JMessage::data::JUTMesgIDData
f_op/f_op_msg_mng.h
    JMSMesgEntry_c          size=0x18

# 4.7: JParticle (JPAC1-00)
JSystem/JParticle/JPABaseShape.h
    JPABaseShapeData
    JPAColorRegAnmKey
JSystem/JParticle/JPAExtraShape.h
    JPAExtraShapeData
JSystem/JParticle/JPASweepShape.h
    JPASweepShapeData
JSystem/JParticle/JPAExTexShape.h
    JPAExTexShapeData
JSystem/JParticle/JPADynamicsBlock.h
    JPADynamicsBlockData
JSystem/JParticle/JPAFieldBlock.h
    JPAFieldBlockData
JSystem/JParticle/JPAKeyBlock.h
    JPAKeyBlockData
JSystem/JParticle/JPATexture.h
    JPATextureData

# 4.8: logo-scene resources (item_table.bin)
d/d_com_inf_game.h
    ItemTableList           size=0x1F0 mMagic=0x0 mEntryCount=0xA mPadding=0xC mItemTables=0x10

# 4.9a-d: stage and room chunks (dzs/dzr); the {num, pointer} pairs overlay a chunk's
# {m_entryNum, m_offset} once relocated in place
d/d_stage.h
    dStage_nodeHeader       size=0xC
    dStage_fileHeader
    stage_vrbox_info_class
    stage_tresure_data_class
    stage_tresure_class     size=0x8
    stage_stag_info_class
    stage_scls_info_class
    stage_scls_info_dummy_class size=0x8
    stage_lightvec_info_class
    stage_pselect_info_class
    stage_plight_info_class
    stage_palet_info_class
    stage_map_info_class
    stage_map_info_dummy_class size=0x8
    stage_envr_info_class
    stage_camera2_data_class
    stage_camera_class      size=0x8
    stage_arrow_data_class
    stage_arrow_class       size=0x8
    stage_actor_data_class
    stage_actor_class       size=0x8
    stage_tgsc_data_class
    stage_tgsc_class        size=0x8
    roomRead_data_class
    roomRead_class          size=0x8
    dStage_MemoryMap_c      size=0x8
    dStage_MemoryConfig_data
    dStage_MemoryConfig_c   size=0x8
    dStage_dPath_c          size=0x8
    dStage_dPnt_c
    dStage_Mult_info
    dStage_Multi_c          size=0x8
    stage_sound_data
    dStage_SoundInfo_c      size=0x8
    dStage_FileList_dt_c
    dStage_FloorInfo_dt_c
    dStage_FloorInfo_c      size=0x8
    dStage_Lbnk_c           size=0x8
    dStage_DMap_dt_c
    dStage_DMap_c           size=0x8
    dStage_Event_dt_c
    dStage_EventInfo_c
    dStage_Ship_dt_c
    dStage_Ship_c           size=0x8
d/d_path.h
    dPnt                    size=0x10
    dPath                   size=0xC
# 4.9a: the debug map select's /res/Menu/Menu1.dat (offsets relocated in place, as the chunks)
d/d_s_menu.h
    menu_of_scene_class::menu_inf  size=0x8 num=0x0 stage=0x4
    menu_of_scene_class::stage_inf size=0x28 name=0x0 field_0x20=0x20 roomNum=0x21 field_0x22=0x22 field_0x23=0x23 roomPtr=0x24
    menu_of_scene_class::room_inf  size=0x2C name=0x0 field_0x20=0x20 stageName=0x21 roomNo=0x29 startCode=0x2A layerNo=0x2B

# 4.10: collision (dzb)
SSystem/SComponent/c_bg_w.h
    cBgD_Blk_t              size=0x2
    cBgD_Ti_t               size=0x10
    cBgD_Tri_t              size=0xA
    cBgD_Grp_t
    cBgD_Tree_t
    cBgD_t                  size=0x34

# 4.11: J3D model data (BMD/BDL/BMT; J3DStruct.h: the infos the MAT3/MAT2 tables hold)
JSystem/J3DGraphLoader/J3DModelLoader.h
    J3DModelInfoBlock
    J3DVertexBlock
    J3DEnvelopBlock
    J3DDrawBlock
    J3DMaterialBlock
    J3DMaterialBlock_v21
    J3DMaterialDLBlock
    J3DTextureBlock
JSystem/J3DGraphLoader/J3DJointFactory.h
    J3DJointInitData
    J3DJointBlock
JSystem/J3DGraphLoader/J3DShapeFactory.h
    J3DShapeInitData
    J3DShapeMtxInitData
    J3DShapeDrawInitData
    J3DShapeBlock
JSystem/J3DGraphLoader/J3DMaterialFactory.h
    J3DMaterialInitData     size=0x14C
    J3DIndInitData          size=0x138
    J3DPatchingInfo
    J3DDisplayListInit
JSystem/J3DGraphLoader/J3DMaterialFactory_v21.h
    J3DMaterialInitData_v21 size=0x138
JSystem/J3DGraphBase/J3DStruct.h
    J3DLightInfo            size=0x34
    J3DTextureSRTInfo       size=0x14
    J3DTexMtxInfo           size=0x64
    J3DIndTexMtxInfo        size=0x1C
    J3DFogInfo              size=0x2C
    J3DNBTScaleInfo         size=0x10
    J3DIndTexOrderInfo      size=0x4
    J3DTevSwapModeInfo      size=0x4
    J3DTevSwapModeTableInfo size=0x4
    J3DTevStageInfo         size=0x14
    J3DIndTevStageInfo      size=0xC
    J3DTexCoordInfo         size=0x4
    J3DIndTexCoordScaleInfo size=0x4
    J3DBlendInfo            size=0x4
    J3DTevOrderInfo         size=0x4
    J3DColorChanInfo        size=0x8
    J3DZModeInfo            size=0x4
    J3DAlphaCompInfo        size=0x8
JSystem/J3DGraphLoader/J3DClusterLoader.h
    J3DClusterBlock
JSystem/J3DGraphAnimator/J3DJointTree.h
    J3DModelHierarchy       size=0x4

# 4.12: J3D animation data (BCK/BCA/BTK/BTP/BRK/BPK/BVA/BLA/BLK)
JSystem/J3DGraphAnimator/J3DAnimation.h
    J3DAnmKeyTableBase
    J3DAnmColorKeyTable
    J3DAnmColorFullTable
    J3DAnmVisibilityFullTable
    J3DAnmTransformKeyTable
    J3DAnmTransformFullTable
    J3DAnmTexPatternFullTable
    J3DAnmCRegKeyTable
    J3DAnmKRegKeyTable
    J3DAnmClusterKeyTable
    J3DAnmVtxColorFullData
    J3DAnmVisibilityFullData
    J3DAnmTransformFullData
    J3DAnmColorKeyData
    J3DAnmTextureSRTKeyData
    J3DAnmVtxColorKeyData
    J3DAnmTexPatternFullData
    J3DAnmTevRegKeyData
    J3DAnmColorFullData
    J3DAnmClusterFullData
    J3DAnmTransformKeyData
    J3DAnmClusterKeyData
    J3DAnmVtxColorIndexData

# 4.13: J2D screens (SCRNblo1): the pane block headers
JSystem/J2DGraph/J2DPane.h
    J2DPaneHeader                       size=0x8
    J2DPane::J2DScrnBlockHeader         size=0x8

# 4.15: save data and memory card (the save file file; memory_to_card packs the dSv_* parts of
# dSv_save_c one after the other into card_gamedata, decision H2: big-endian as on the GameCube)
d/d_save.h
    dSv_player_status_a_c
    dSv_player_status_b_c
    dSv_player_return_place_c
    dSv_player_item_c
    dSv_player_get_item_c
    dSv_player_item_record2_c
    dSv_player_item_record_c
    dSv_player_item_max2_c
    dSv_player_item_max_c
    dSv_player_bag_item_c
    dSv_player_get_bag_item_c
    dSv_player_bag_item_record_c
    dSv_player_collect_c
    dSv_player_map_c
    dSv_player_info_c
    dSv_player_config_c     size=0x5
    dSv_player_priest_c     size=0x10
    dSv_player_status_c_c
    dSv_player_c
    dSv_memBit_c
    dSv_memory_c
    dSv_ocean_c             size=0x64
    dSv_event_c
    dSv_reserve_c
    dSv_save_c
m_Do/m_Do_MemCardRWmng.h
    mDoMemCdRWm_HeaderData
    card_pictdata
    card_gamedata
    card_savedata

# 4.16: event data (event_list.dat)
d/d_event_data.h
    event_binary_data_header
    dEvDtData_c
    dEvDtCut_c
    dEvDtStaff_c
    dEvDtEvent_c

# 4.17: JStudio demos (STB, FVB)
JSystem/JStudio/JStudio/stb-data.h
    JStudio::stb::data::THeader
    JStudio::stb::data::THeader::Target
    JStudio::stb::data::TBlock
    JStudio::stb::data::TBlock_object
    JStudio::stb::data::TParagraph
JSystem/JStudio/JStudio/fvb-data.h
    JStudio::fvb::data::TBlock
    JStudio::fvb::data::THeader

# 5.1: audio data (JaiInit.aaf's sound table, banks, wave systems, stream and fx scene tables)
JSystem/JAudio/JAISoundTable.h
    SoundInfo               size=0x10
JSystem/JAudio/JASBNKParser.h
    JASystem::BNKParser::TOsc       size=0x18
    JASystem::BNKParser::TRand      size=0xC
    JASystem::BNKParser::TSense     size=0xC
    JASystem::BNKParser::TVmap      size=0x10
    JASystem::BNKParser::TKeymap    size=0xC
    JASystem::BNKParser::TInst      size=0x34
    JASystem::BNKParser::TPmap      size=0x18
    JASystem::BNKParser::TPerc      size=0x408
    JASystem::BNKParser::THeader    size=0x3E4
JSystem/JAudio/JASWSParser.h
    JASystem::WSParser::TWave       size=0x2C
    JASystem::WSParser::TWaveArchive size=0x78
    JASystem::WSParser::TWaveArchiveBank size=0xC
    JASystem::WSParser::TCtrlWave   size=0x4
    JASystem::WSParser::TCtrl       size=0xC
    JASystem::WSParser::TCtrlScene  size=0x10
    JASystem::WSParser::TCtrlGroup  size=0x10
    JASystem::WSParser::THeader     size=0x18
JSystem/JAudio/JAIStreamMgr.h
    JAInter::streamList_t   size=0x30
    JAInter::StreamLib::StreamHeader size=0x20 field_0x0=0x0 field_0x4=0x4 field_0x8=0x8 field_0xa=0xA field_0xc=0xC field_0xe=0xE field_0x10=0x10 field_0x14=0x14 field_0x18=0x18
JSystem/JAudio/JAIAnimation.h
    JAIAnimeFrameSoundData  size=0x20
    JAIAnimeSoundData       mAfsData=0x8
JSystem/JAudio/JAIFx.h
    JAInter::Fx::initOnCodeFxScene_s size=0x18 field_0x0=0x0 field_0x4=0x4 field_0x8=0x8 field_0xc=0xC field_0x10=0x10 field_0x14=0x14
JSystem/JAudio/JASDSPInterface.h
    JASystem::DSPInterface::FxlineConfig_ size=0x20
