From aebb9e582b3e8bb5e6a5cc59ded9f8c1bb66bbbb Mon Sep 17 00:00:00 2001 From: SuperDude88 <82904174+SuperDude88@users.noreply.github.com> Date: Wed, 23 Sep 2026 21:47:53 -0400 Subject: [PATCH] Redundant Struct Declarations --- include/JSystem/J3DGraphAnimator/J3DModelData.h | 1 - include/JSystem/J3DGraphBase/J3DVertex.h | 1 - include/JSystem/JFramework/JFWDisplay.h | 2 -- include/JSystem/JStudio/JStudio/jstudio-object.h | 2 -- include/JSystem/JUtility/JUTException.h | 2 -- include/JSystem/JUtility/JUTXfb.h | 1 - include/SSystem/SComponent/c_cc_d.h | 1 - include/d/d_bg_s.h | 2 +- include/d/d_bg_w.h | 2 +- include/m_Do/m_Do_ext.h | 8 ++++---- src/d/actor/d_a_obj_mkie.cpp | 2 +- 11 files changed, 7 insertions(+), 17 deletions(-) diff --git a/include/JSystem/J3DGraphAnimator/J3DModelData.h b/include/JSystem/J3DGraphAnimator/J3DModelData.h index 39d8efdce..e4e34726b 100644 --- a/include/JSystem/J3DGraphAnimator/J3DModelData.h +++ b/include/JSystem/J3DGraphAnimator/J3DModelData.h @@ -8,7 +8,6 @@ #include "JSystem/J3DGraphBase/J3DVertex.h" #include "JSystem/J3DGraphBase/J3DMaterial.h" -typedef struct _GXColor GXColor; class JUTNameTab; enum J3DMaterialCopyFlag { diff --git a/include/JSystem/J3DGraphBase/J3DVertex.h b/include/JSystem/J3DGraphBase/J3DVertex.h index b3184eb30..7a5a15b14 100644 --- a/include/JSystem/J3DGraphBase/J3DVertex.h +++ b/include/JSystem/J3DGraphBase/J3DVertex.h @@ -5,7 +5,6 @@ #include "dolphin/mtx/vec.h" #include "dolphin/types.h" -typedef struct _GXColor GXColor; class J3DModel; class J3DAnmVtxColor; class J3DVertexBuffer; diff --git a/include/JSystem/JFramework/JFWDisplay.h b/include/JSystem/JFramework/JFWDisplay.h index 4d06b074d..8a23f94c3 100644 --- a/include/JSystem/JFramework/JFWDisplay.h +++ b/include/JSystem/JFramework/JFWDisplay.h @@ -8,8 +8,6 @@ #include "dolphin/os/OSAlarm.h" #include "dolphin/types.h" -typedef struct _GXColor GXColor; -typedef struct _GXRenderModeObj GXRenderModeObj; class JKRHeap; typedef void (*JFWDisplayUnkFunc)(void); diff --git a/include/JSystem/JStudio/JStudio/jstudio-object.h b/include/JSystem/JStudio/JStudio/jstudio-object.h index 2c0617e9d..bf874dbfc 100644 --- a/include/JSystem/JStudio/JStudio/jstudio-object.h +++ b/include/JSystem/JStudio/JStudio/jstudio-object.h @@ -4,8 +4,6 @@ #include "JSystem/JStudio/JStudio/jstudio-control.h" #include "limits.h" -typedef struct _GXColor GXColor; - namespace JStudio { namespace data { enum TEOperationData { diff --git a/include/JSystem/JUtility/JUTException.h b/include/JSystem/JUtility/JUTException.h index 33cdfd02a..aa3ad31a7 100644 --- a/include/JSystem/JUtility/JUTException.h +++ b/include/JSystem/JUtility/JUTException.h @@ -8,8 +8,6 @@ #include "dolphin/os/OSError.h" #include "global.h" -typedef struct _GXRenderModeObj GXRenderModeObj; -typedef struct OSContext OSContext; class JUTDirectPrint; class JUTExternalFB { diff --git a/include/JSystem/JUtility/JUTXfb.h b/include/JSystem/JUtility/JUTXfb.h index 054a4ca3b..36d05cf39 100644 --- a/include/JSystem/JUtility/JUTXfb.h +++ b/include/JSystem/JUtility/JUTXfb.h @@ -3,7 +3,6 @@ #include "JSystem/JUtility/JUTVideo.h" -typedef struct _GXRenderModeObj GXRenderModeObj; class JKRHeap; class JUTXfb { diff --git a/include/SSystem/SComponent/c_cc_d.h b/include/SSystem/SComponent/c_cc_d.h index 486702d7a..e17196c33 100644 --- a/include/SSystem/SComponent/c_cc_d.h +++ b/include/SSystem/SComponent/c_cc_d.h @@ -15,7 +15,6 @@ class cCcD_TriAttr; class cCcD_AabAttr; class cCcD_CylAttr; class cCcD_SphAttr; -typedef struct _GXColor GXColor; enum cCcD_AtSPrm_e { /* 0x01 */ cCcD_AtSPrm_Set_e = 0x01, diff --git a/include/d/d_bg_s.h b/include/d/d_bg_s.h index 2ff487dc4..f9763cc58 100644 --- a/include/d/d_bg_s.h +++ b/include/d/d_bg_s.h @@ -74,7 +74,7 @@ public: // void ChkDeleteActorRegist(fopAc_ac_c*) {} // void DebugDrawPoly(dBgW&) {} // void Draw() {} - // void DrawPoly(cBgS_PolyInfo&, _GXColor&) {} + // void DrawPoly(cBgS_PolyInfo&, GXColor&) {} dBgW* GetBgWPointer(cBgS_PolyInfo& i_poly) { return (dBgW*)cBgS::GetBgWPointer(i_poly); } // void GetPolyCamId(cBgS_PolyInfo&) {} // void GroundCross(cBgS_GndChk*) {} diff --git a/include/d/d_bg_w.h b/include/d/d_bg_w.h index ec3797c21..6e9660d49 100644 --- a/include/d/d_bg_w.h +++ b/include/d/d_bg_w.h @@ -3,6 +3,7 @@ #include "SSystem/SComponent/c_bg_w.h" #include "SSystem/SComponent/c_sxyz.h" +#include "dolphin/gx/GXStruct.h" class dBgS_Acch; class cM3dGPla; @@ -14,7 +15,6 @@ class dBgS_CrrPos; class cBgS_PolyInfo; class fopAc_ac_c; class dBgS_CaptPoly; -typedef struct _GXColor GXColor; class dBgW : public cBgW { public: diff --git a/include/m_Do/m_Do_ext.h b/include/m_Do/m_Do_ext.h index 168db7fde..7e93d689c 100644 --- a/include/m_Do/m_Do_ext.h +++ b/include/m_Do/m_Do_ext.h @@ -596,11 +596,11 @@ public: // some calls to these functions define i_color inline which is illegal in C++ for a non-const // reference parameter - we add these overloads to enable standard compiler compatibility #if !__MWERKS__ - void update(u16 i_segs, f32 i_size, const _GXColor& i_color, u16 i_space, dKy_tevstr_c* i_tevStr) { - update(i_segs, i_size, const_cast<_GXColor&>(i_color), i_space, i_tevStr); + void update(u16 i_segs, f32 i_size, const GXColor& i_color, u16 i_space, dKy_tevstr_c* i_tevStr) { + update(i_segs, i_size, const_cast(i_color), i_space, i_tevStr); } - void update(u16 i_segs, const _GXColor& i_color, dKy_tevstr_c* i_tevStr) { - update(i_segs, const_cast<_GXColor&>(i_color), i_tevStr); + void update(u16 i_segs, const GXColor& i_color, dKy_tevstr_c* i_tevStr) { + update(i_segs, const_cast(i_color), i_tevStr); } #endif diff --git a/src/d/actor/d_a_obj_mkie.cpp b/src/d/actor/d_a_obj_mkie.cpp index 0e389ce12..6909699fb 100644 --- a/src/d/actor/d_a_obj_mkie.cpp +++ b/src/d/actor/d_a_obj_mkie.cpp @@ -267,7 +267,7 @@ BOOL daObjMkie::Act_c::chk_light() { /* 00000DF4-00000E84 .text eff_break__Q29daObjMkie5Act_cFv */ void daObjMkie::Act_c::eff_break() { - _GXColor envColor; + GXColor envColor; envColor.r = (u8)tevStr.mColorC0.r; envColor.g = (u8)tevStr.mColorC0.g; envColor.b = (u8)tevStr.mColorC0.b;