Allow users to disable Point Filtering.

This commit is contained in:
Mateus Lacerda 2025-02-11 21:51:31 -03:00 committed by Alejandro Asenjo Nitti
parent 24d3a97b2d
commit b7740b11a0
18 changed files with 144 additions and 115 deletions

View File

@ -7,6 +7,7 @@
#include "assets/ast_sector_z.h"
#include "port/interpolation/FrameInterpolation.h"
#include "port/hooks/list/EngineEvent.h"
#include "port/mods/PortEnhancements.h"
// f32 path1 = 0.0f;
// f32 path2 = 0.0f;
@ -144,7 +145,7 @@ void Display_DrawHelpAlert(void) {
switch (centered) {
case false:
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0x00, 0x00, 255, 255, 0, 255);
if (sp78 < 0.0f) {
Graphics_DisplaySmallText(OTRGetRectDimensionFromLeftEdgeOverride(38.0f), 106, 1.0f, 1.0f, "HELP!!");
@ -154,7 +155,7 @@ void Display_DrawHelpAlert(void) {
break;
case true:
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0x00, 0x00, 255, 255, 0, 255);
Graphics_DisplaySmallText(OTRGetRectDimensionFromLeftEdgeOverride(38.0f), 106, 1.0f, 1.0f, "HELP!!");
Graphics_DisplaySmallText(OTRGetRectDimensionFromRightEdgeOverride(248), 106, 1.0f, 1.0f, "HELP!!");
@ -779,7 +780,7 @@ void Display_Reticle(Player* player) {
Matrix_Push(&gGfxMatrix);
Matrix_Translate(gGfxMatrix, translate->x, translate->y, translate->z, MTXF_APPLY);
if (gChargeTimers[player->num] >= 20) {
RCP_SetupDL(&gMasterDisp, SETUPDL_63_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_63_OPTIONAL);
if (i == 1) {
gDPSetPrimColor(gMasterDisp++, 0x00, 0x00, 255, 0, 0, 255);
gDPSetEnvColor(gMasterDisp++, 255, 0, 0, 255);
@ -789,7 +790,7 @@ void Display_Reticle(Player* player) {
gDPSetEnvColor(gMasterDisp++, 255, 255, 0, 255);
}
} else {
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_36_POINT]);
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_36_OPTIONAL]);
}
if (i == 1) {
@ -1685,7 +1686,7 @@ void Display_LockOnIndicator(void) {
Matrix_Scale(gGfxMatrix, var_fs0 * 1.5f, var_fs0 * 1.5f, 1.0f, MTXF_APPLY);
Matrix_RotateZ(gGfxMatrix, D_display_801615A8[i] * M_DTOR, MTXF_APPLY);
Matrix_SetGfxMtx(&gMasterDisp);
RCP_SetupDL(&gMasterDisp, SETUPDL_67_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_67_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0x00, 0x00, 255, 0, 0, 255);
gDPSetEnvColor(gMasterDisp++, 255, 0, 0, 255);
gSPDisplayList(gMasterDisp++, D_1024F60);

View File

@ -23,6 +23,7 @@
#include "assets/ast_enmy_planet.h"
#include "assets/ast_zoness.h"
#include "port/interpolation/FrameInterpolation.h"
#include "port/mods/PortEnhancements.h"
// rodata
const char D_800D7230[] = "Enm->wrk3=<%d>\n";
@ -140,7 +141,7 @@ void BonusText_DrawAll(void) {
BonusText* bonus;
s32 i;
RCP_SetupDL(&gMasterDisp, SETUPDL_62_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_62_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
for (i = 0, bonus = gBonusText; i < ARRAY_COUNT(gBonusText); i++, bonus++) {

View File

@ -5,6 +5,7 @@
#include "mods.h"
#include "port/interpolation/FrameInterpolation.h"
#include "port/hooks/list/EngineEvent.h"
#include "port/mods/PortEnhancements.h"
f32 gNextVsViewScale;
f32 gVsViewScale;
@ -381,7 +382,7 @@ void Game_Update(void) {
break;
case GSTATE_SHOW_LOGO:
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0x00, 0x00, 255, 255, 255, 255);
Lib_TextureRect_IA8(&gMasterDisp, gNintendoLogo, 128, 74, 100.0f, 86.0f, 1.0f, 1.0f);
gGameState++;
@ -401,7 +402,7 @@ void Game_Update(void) {
Timer_CreateTask(MSEC_TO_CYCLES(1000), Timer_Increment, (s32*) &gGameState, 1);
/* fallthrough */
case GSTATE_LOGO_WAIT:
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0x00, 0x00, 255, 255, 255, 255);
Lib_TextureRect_IA8(&gMasterDisp, gNintendoLogo, 128, 74, 100.0f, 86.0f, 1.0f, 1.0f);
break;

View File

@ -3,6 +3,7 @@
#include "prevent_bss_reordering.h"
#include "port/interpolation/FrameInterpolation.h"
#include "port/hooks/Events.h"
#include "port/mods/PortEnhancements.h"
Vec3f D_801616A0;
Vec3f D_801616B0;
@ -132,7 +133,7 @@ void HUD_LivesCount1_Draw(f32 xPos, f32 yPos, s32 lifeCount) {
s32 maxLives;
s32 digits;
RCP_SetupDL(&gMasterDisp, SETUPDL_78_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
player = &gPlayer[0];
@ -160,7 +161,7 @@ void HUD_LivesCount1_Draw(f32 xPos, f32 yPos, s32 lifeCount) {
xPos += 11.0f;
yPos -= 1.0f;
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
if (lifeCount < 0) {
@ -498,7 +499,7 @@ void HUD_TeamShields_Draw(f32 xPos, f32 yPos, s32 arg2) {
if ((arg2 <= 0) && (arg2 != -2) &&
((gPlayState == PLAY_PAUSE) || (gShowLevelClearStatusScreen == 1) || (gLevelStartStatusScreenTimer != 0))) {
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
if ((arg2 == 0) && (gPlayer[0].state == PLAYERSTATE_LEVEL_COMPLETE)) {
Graphics_DisplaySmallText(xPos + (8.0f * xScale) + 4.0f, yPos + 2.0f, 1.0f, 1.0f, " OK ");
@ -613,7 +614,7 @@ void HUD_VenomTitleCard_Draw(void) {
}
if (i != 9) {
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_IA8(&gMasterDisp, sVenomTitleCardDLs[i], sVenomTitleCardWidths[i], 19, sVenomTitleCardWidths[i],
@ -682,7 +683,7 @@ void HUD_TitleCard_Draw(f32 x, f32 y) {
break;
}
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
if ((levelIdx != 14) && (levelIdx != 15)) { // LEVEL_KATINA || LEVEL_FORTUNA
@ -739,7 +740,7 @@ void HUD_Number_Draw(f32 xPos, f32 yPos, s32 k, f32 scale, bool skipLeadingZeroe
}
void HUD_MsgWindowBg_Draw2(f32 xPos, f32 yPos, f32 xScale, f32 yScale) {
RCP_SetupDL(&gMasterDisp, SETUPDL_78_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 60, 60, 128, 96);
gDPSetAlphaDither(gMasterDisp++, G_AD_DISABLE);
Lib_TextureRect_CI8(&gMasterDisp, aMsgWindowBgTex, aMsgWindowBgTLUT, 24, 17, xPos, yPos, xScale, yScale);
@ -880,7 +881,7 @@ void HUD_DrawLevelClearScreen(void) {
levelIdx = HUD_GetLevelIndex();
if (levelClearState != LEVEL_CLEAR_STATE_0) {
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
x = 98.0f;
y = 64.0f;
@ -933,7 +934,7 @@ void HUD_LivesCount2_Draw(f32 x, f32 y, s32 number) {
s32 i;
s32 form;
RCP_SetupDL(&gMasterDisp, SETUPDL_78_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
form = FORM_ARWING;
@ -1022,11 +1023,11 @@ void HUD_TeammateStatus_Draw(void) {
for (j = 0; j < 3; j++) {
HUD_MsgWindowBg_Draw2(x[j][0] - 6.0f, y[j][1] - 1.0f, 2.4f, 0.7f);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_IA8(&gMasterDisp, sText[j], sTextWidth[j], sTextHeght[j], x[j][1], y[j][1], 1.0f, 1.0f);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
shield = gTeamShields[3 - j];
if (shield <= 0) {
@ -1233,7 +1234,7 @@ void HUD_LevelClearStatusScreen_Draw(void) {
}
x4 += (4 - i) * 8;
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 90, 160, 200, 255);
HUD_Number_Draw(OTRGetRectDimensionFromLeftEdgeOverride(24.0f), 30.0f + 3.0f, D_801617C0[5], 1.0f, false, 999);
@ -1251,7 +1252,7 @@ void HUD_LevelClearStatusScreen_Draw(void) {
HUD_LivesCount2_Draw(232.0f, 90.0f, D_801617C0[3]);
}
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_IA8(&gMasterDisp, aTextStatusOfTeam, 120, 12, x6 - 8.0f, y6 + 10.0f, 1.0f, 1.0f);
@ -1662,7 +1663,7 @@ void HUD_PauseScreen_Update(void) {
break;
}
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_IA8(&gMasterDisp, sLevelTitleCard[j].titleCardTex, sLevelTitleCard[j].titleCardWidth,
@ -1670,7 +1671,7 @@ void HUD_PauseScreen_Update(void) {
HUD_MsgWindowBg_Draw2(x1 - 10.0f, y0 - 4.0f, 4.7f, 2.8f);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
if (sPauseScreenIwork[1] == 0) {
temp = (sPauseScreenTimer[0] % 20);
@ -2251,7 +2252,7 @@ s32 ActorMissileSeek_ModeCheck(ActorMissileSeekMode mode) {
void HUD_RadioCharacterName_Draw(void) {
if (gGameState == GSTATE_PLAY) {
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
f32 xPos = OTRGetRectDimensionFromLeftEdgeOverride(73.0f);
@ -2344,7 +2345,7 @@ void HUD_IncomingMsg_Draw(void) {
f32 xPos = 142.0f;
f32 yPos = 18.0f;
RCP_SetupDL(&gMasterDisp, SETUPDL_78_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
switch (D_80161790 / 2) {
@ -2940,7 +2941,7 @@ void HUD_KillCountStars_Update(void) {
j = gVsKills[gPlayerNum][i];
RCP_SetupDL(&gMasterDisp, SETUPDL_77_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_77_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
gDPSetEnvColor(gMasterDisp++, r[j], g[j], b[j], 0);
@ -2970,7 +2971,7 @@ void HUD_VsModePortrait_Draw(void) {
f32 faceXpos[] = { 113.0f, 273.0f, 113.0f, 273.0f };
f32 faceYpos[] = { 79.0f, 79.0f, 199.0f, 199.0f };
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
HUD_VsModePortraitTex_Draw(faceXpos[gPlayerNum], faceYpos[gPlayerNum], 0.54f, gPlayerNum);
}
@ -2980,12 +2981,12 @@ void HUD_VS_ShieldGauge_Draw(void) {
f32 D_800D20F8[] = { 78.0f, 78.0f, 198.0f, 198.0f };
Math_SmoothStepToF(&D_800D19E0[gPlayerNum], gPlayer[gPlayerNum].shields * (1.0f / 255.0f), 0.3f, 10.0f, 0.01f);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
HUD_VS_ShieldGaugeTex_Draw(D_800D20E8[gPlayerNum] + 3.0f, D_800D20F8[gPlayerNum] + 18.0f, 1.0f, 1.0f,
D_800D19E0[gPlayerNum]);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
@ -3050,7 +3051,7 @@ void HUD_BoostGauge_Draw(f32 xPos, f32 yPos) {
temp_t9 = D_800D19AC[playerNum];
RCP_SetupDL(&gMasterDisp, SETUPDL_78_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, temp_t9, temp_t9, temp_t9, 255);
@ -3062,7 +3063,7 @@ void HUD_BoostGauge_Draw(f32 xPos, f32 yPos) {
HUD_BoostGaugeOverheat_Draw(boostGaugeXpos[playerNum] + temp + 1.0f, boostGaugeYpos[playerNum] + sp60, temp_fs0,
1.0f);
}
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
HUD_BoostGaugeFrame_Draw(boostGaugeXpos[playerNum], boostGaugeYpos[playerNum], 1.0f, 1.0f);
}
@ -3074,7 +3075,7 @@ void HUD_VS_PlayerNumber_Draw(void) {
s32 playerNumberG[] = { 242, 30, 179, 30 };
s32 playerNumberB[] = { 12, 0, 67, 255 };
RCP_SetupDL(&gMasterDisp, SETUPDL_78_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, playerNumberR[gPlayerNum], playerNumberG[gPlayerNum],
playerNumberB[gPlayerNum], 255);
Graphics_DisplayHUDNumber(playerNumberXpos[gPlayerNum], playerNumberYpos[gPlayerNum], gPlayerNum + 1);
@ -3104,7 +3105,7 @@ void HUD_VS_BombCount_Draw(void) {
if (((sVsBombCountFlashTimer[gPlayerNum] & 2) != 0) ||
((sVsBombCountFlashTimer[gPlayerNum] == 0) && (gBombCount[gPlayerNum] != 0))) {
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_78_POINT]);
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_78_OPTIONAL]);
if (gBombCount[gPlayerNum] >= 2) {
if (Math_SmoothStepToF(&D_800D21A4, D_800D21A0, 0.4f, 100.0f, 0.1f) == 0.0f) {
if (D_800D21A0 == 255.0f) {
@ -3136,13 +3137,13 @@ void HUD_VS_DrawHUD(void) {
}
void HUD_VS_X_Draw(f32 xPos, f32 yPos, s32 r, s32 g, s32 b) {
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_78_POINT]);
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_78_OPTIONAL]);
gDPSetPrimColor(gMasterDisp++, 0, 0, r, g, b, D_hud_80161708);
Lib_TextureRect_CI4(&gMasterDisp, aXTex, aXTLUT, 16, 7, xPos, yPos, 1.0f, 1.0f);
}
void HUD_VS_LivesCount_Draw(f32 xPos, f32 yPos, s32 number, s32 r, s32 g, s32 b) {
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_78_POINT]);
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_78_OPTIONAL]);
gDPSetPrimColor(gMasterDisp++, 0, 0, r, g, b, D_hud_80161708);
if (number >= 10) {
@ -3181,12 +3182,12 @@ void HUD_DrawBossHealth(void) {
temp2 = OTRGetRectDimensionFromLeftEdgeOverride(temp2);
temp4 = OTRGetRectDimensionFromLeftEdgeOverride(temp4);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_CI4(&gMasterDisp, D_1011A40, D_1011AB0, 32, 7, temp2, temp3, 1.0f, 1.0f);
f32 border = sp3C;
border = OTRGetRectDimensionFromLeftEdgeOverride(border);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
Lib_TextureRect_IA8(&gMasterDisp, D_1002040, 40, 12, border, temp1, 1.0f, 1.0f);
if (sp3C >= 25.0f) {
@ -3194,12 +3195,12 @@ void HUD_DrawBossHealth(void) {
}
if ((D_801616C4 >= 0.1f) && (sp3C >= 25.0f)) {
RCP_SetupDL(&gMasterDisp, SETUPDL_78_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_CI8(&gMasterDisp, D_10129C0, D_1013090, 16, 109, temp4, temp5, 1.0f, D_801616C4);
}
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 0, 0, 0, 255);
if (D_801616BC > 0.0f) {
@ -3250,12 +3251,12 @@ void HUD_DisplayCountdown(f32 xPos, f32 yPos, s32* countdown, f32 scale) {
}
if ((i % 2) != 0) {
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_78_POINT]);
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_78_OPTIONAL]);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_CI4(&gMasterDisp, D_1011E80, D_1011EC0, 16, 8, (var_fs0 * scale) + xPos, yPos, scale,
scale);
} else {
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_76_POINT]);
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_76_OPTIONAL]);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
HUD_DisplaySmallNumber((var_fs0 * scale) + xPos, yPos, scale, var_s2);
var_fs0 += 9.0f;
@ -3396,7 +3397,7 @@ void HUD_Score_Update(f32 xPos, f32 yPos) {
g = 160;
b = 200;
}
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, r, g, b, 255);
HUD_Score_Draw(xPos, yPos);
}
@ -3534,7 +3535,7 @@ void HUD_BombCounter_Draw(f32 x, f32 y) {
D_80161784 = 0.0f;
}
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_78_POINT]);
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_78_OPTIONAL]);
gDPSetPrimColor(gMasterDisp++, 0, 0, (s32) D_80161770, (s32) D_80161774, (s32) D_80161778, D_hud_80161708);
if (gCurrentLevel == LEVEL_AQUAS) {
@ -3604,7 +3605,7 @@ void HUD_BombCounter_Draw(f32 x, f32 y) {
break;
case 6:
RCP_SetupDL(&gMasterDisp, SETUPDL_78_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_CI4(&gMasterDisp, D_blue_marine_3000090, D_blue_marine_3000120, 32, 9, x + 1.0f, y, 1.0f,
1.0f);

View File

@ -19,6 +19,7 @@
#include "assets/ast_title.h"
#include "assets/ast_zoness.h"
#include "port/hooks/Events.h"
#include "port/mods/PortEnhancements.h"
u16** gRadioMsgList;
s32 gRadioMsgListIndex;
@ -435,7 +436,7 @@ void func_radio_800BAAE8(void) {
D_800D4A74 = -1.0f;
}
sp38 = gRadioPortraitScaleY * 20.0f * D_800D4A74;
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_76_POINT]);
gSPDisplayList(gMasterDisp++, gRcpSetupDLs[SETUPDL_76_OPTIONAL]);
gDPSetPrimColor(gMasterDisp++, 0x00, 0x00, 255, 255, 255, 255);
if (mirror) {
@ -470,7 +471,7 @@ void func_radio_800BB388(void) {
sp30 = temp_fa0 * D_800D4A78;
RCP_SetupDL(&gMasterDisp, SETUPDL_85);
RCP_SetupDL(&gMasterDisp, SETUPDL_85_OPTIONAL);
switch (gGameState) {
case GSTATE_TITLE:
@ -496,7 +497,7 @@ void func_radio_800BB388(void) {
}
if (gRadioTextBoxScaleY == 1.3f) {
RCP_SetupDL(&gMasterDisp, SETUPDL_85);
RCP_SetupDL(&gMasterDisp, SETUPDL_85_OPTIONAL);
gMsgCharIsPrinting =
Message_DisplayText(&gMasterDisp, gRadioMsg, gRadioPrintPosX, gRadioPrintPosY, gRadioMsgCharIndex);
}
@ -715,7 +716,7 @@ void Radio_Draw(void) {
if ((gTeamShields[idx] <= 0) && (gGameFrameCount & 4) && (gTeamShields[idx] != -2) &&
(gCurrentRadioPortrait != RCID_STATIC) && (gCurrentRadioPortrait != RCID_STATIC + 1) &&
(gCurrentRadioPortrait != RCID_1000)) {
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0x00, 0x00, 255, 255, 0, 255);
Graphics_DisplaySmallText(OTRGetRectDimensionFromLeftEdgeOverride(31.0f), 167, 1.0f, 1.0f, "DOWN");
HUD_TeamDownWrench_Draw(1);
@ -764,7 +765,7 @@ void Radio_Draw(void) {
if ((gActors[idx].obj.status != OBJ_ACTIVE) && (gGameFrameCount & 4) &&
(gPlayer[0].state == PLAYERSTATE_ACTIVE) && (gCurrentRadioPortrait != RCID_STATIC) &&
(gCurrentRadioPortrait != RCID_STATIC + 1) && (gCurrentRadioPortrait != RCID_1000)) {
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0x00, 0x00, 255, 255, 0, 255);
Graphics_DisplaySmallText(OTRGetRectDimensionFromLeftEdgeOverride(31.0f), 167, 1.0f, 1.0f, "DOWN");
}

View File

@ -1229,7 +1229,7 @@ Gfx gRcpSetupDLs[][9] = {
gsSPSetGeometryMode(0),
gsSPSetOtherMode(G_SETOTHERMODE_L, G_MDSFT_ALPHACOMPARE, 3, G_AC_NONE | G_ZS_PIXEL),
gsDPSetRenderMode(G_RM_XLU_SURF, G_RM_XLU_SURF2),
gsSPSetOtherModeHi(G_AD_PATTERN | G_CD_MAGICSQ | G_CK_NONE | G_TC_FILT | G_TF_POINT | G_TT_RGBA16 | G_TL_TILE |
gsSPSetOtherModeHi(G_AD_PATTERN | G_CD_MAGICSQ | G_CK_NONE | G_TC_FILT | G_TF_BILERP | G_TT_RGBA16 | G_TL_TILE |
G_TD_CLAMP | G_TP_NONE | G_CYC_1CYCLE | G_PM_NPRIMITIVE),
gsSPEndDisplayList(),
},

View File

@ -85,7 +85,7 @@ void Map_LevelSelect(void) {
/* Draw */
if ((sCurrentPlanetId >= 0) && (sCurrentPlanetId < PLANET_MAX)) {
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
Graphics_DisplaySmallText(20, y, 1.0f, 1.0f, "PLANET:");

View File

@ -197,7 +197,7 @@ void Jukebox_Update(void) {
/* Draw */
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
Graphics_Printf("SFX ID: %08X", sfx);

View File

@ -397,7 +397,7 @@ void Spawner(void) {
gPlayer[0].baseSpeed = gArwingSpeed;
}
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
/* Spawners */

View File

@ -6,6 +6,7 @@
#include "assets/ast_great_fox.h"
#include "assets/ast_ending.h"
#include "prevent_bss_reordering.h"
#include "port/mods/PortEnhancements.h"
void Ending_8018CE20(s32);
void Ending_801926D4(void);
@ -420,7 +421,7 @@ void Ending_801886F4(void) {
return;
}
RCP_SetupDL(&gMasterDisp, SETUPDL_78_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0x00, 0x00, 255, 255, 255, 255);
switch ((D_ending_80196F90 % 8) / 2) {

View File

@ -2,6 +2,7 @@
#include "assets/ast_arwing.h"
#include "assets/ast_ending_expert.h"
#include "assets/ast_allies.h"
#include "port/mods/PortEnhancements.h"
ArwingInfo D_ending_80198590;
Vec3f D_ending_801985D0;
@ -50,7 +51,7 @@ void Ending_8018CE20(u32 arg0) {
1.0f);
} else {
xPos = (320 - Graphics_GetSmallTextWidth(D_ending_80192E74[i].unk_00)) / 2;
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetTextureFilter(gMasterDisp++, G_TF_POINT);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 155, 155, alpha);
Graphics_DisplaySmallText(xPos, D_ending_80192E74[i].unk_0E, 1.0f, 1.0f,
@ -169,7 +170,7 @@ void Ending_8018D814(u32 arg0, AssetInfo* asset) {
alpha = (asset->unk_0C + asset->unk_10 - arg0) * 255 / asset->fogFar;
}
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, asset->prim.r, asset->prim.g, asset->prim.b, alpha);
@ -189,7 +190,7 @@ void Ending_8018DA0C(u32 arg0, AssetInfo* asset) {
alpha = (arg0 - asset->unk_0C) * 255 / asset->fogNear;
}
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, asset->prim.r, asset->prim.g, asset->prim.b, alpha);
Graphics_DisplaySmallText((s16) asset->unk_18.x, (s16) asset->unk_18.y, asset->unk_30.x, asset->unk_30.y,

View File

@ -6,10 +6,11 @@
#include "global.h"
#include "assets/ast_training.h"
#include "port/mods/PortEnhancements.h"
void Training_RingPassCount_Draw(void) {
if (gRingPassCount != 0) {
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
HUD_Number_Draw(OTRGetDimensionFromRightEdgeOverride(250.0f), 50.0f, gRingPassCount, 1.0f, 0, 999);
}

View File

@ -16,6 +16,7 @@
#include "assets/ast_text.h"
#include "assets/ast_font_3d.h"
#include "port/interpolation/FrameInterpolation.h"
#include "port/mods/PortEnhancements.h"
extern bool gBackToMap;
@ -2181,14 +2182,14 @@ void Map_Prologue_Draw(void) {
Map_PrologueArwing_Draw();
RCP_SetupDL(&gMasterDisp, SETUPDL_81_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_81_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 180, 180, 180, 255);
// Prologue text
Message_DisplayScrollingText(&gMasterDisp, gMsg_ID_1, sPrologueTextXpos, sPrologueTextYpos, 218, 70,
Message_GetCharCount(gMsg_ID_1));
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
// Vertical Fade Margins for prologue text
@ -2200,7 +2201,7 @@ void Map_Prologue_Draw(void) {
Background_DrawPartialStarfield(71, 118);
Background_DrawPartialStarfield(205, 239);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, sPrologueCurrentTexAlpha);
Lib_TextureRect_RGBA16(&gMasterDisp, sPrologueTextures[sPrologueTexIdx], 96, 52, 109.0f, 24.0f, 1.0f, 1.0f);
@ -2385,7 +2386,7 @@ void Map_LylatCard_Update(void) {
void Map_LylatCard_Draw(void) {
s32 i;
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, (s32) D_menu_801CEA9C);
@ -3844,7 +3845,7 @@ void Map_PathChange_DrawOptions(void) {
}
if (gGameFrameCount & mask) { // can't be != 0?
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, r[colorIndex], g[colorIndex], b[colorIndex], 255);
Lib_TextureRect_IA8(&gMasterDisp, aMapProceedNextCourseTex, 96, 22, x + 11.0f, y + 3.0f, 1.0f, 1.0f);
}
@ -5419,7 +5420,7 @@ void Map_TitleCards_Draw(void) {
s32 i;
s32 planetCardIdx = sMapCurPlanetCards[sCurrentPlanetId];
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, (s32) sMapPlanetCardAlpha);
@ -5511,7 +5512,7 @@ void Map_801A9A8C(void) {
break;
}
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
if (CVarGetInteger("gLevelSelector", 0) && gMissionNumber == 6) {
@ -5556,7 +5557,7 @@ void Map_801A9DE8(void) {
}
void Map_TotalHits_Draw(void) {
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
@ -5622,7 +5623,7 @@ void Map_PathLineBox_Draw(s32 curMission) {
PlanetId* ptr = &gMissionPlanet[0];
for (x = 0.0f, i = 0; i < 7; i++, x += 24.0f + x2, ptr++) {
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
if (i < 6) {
r = g = b = 255;
@ -5669,7 +5670,7 @@ void Map_PathInfo_Draw(s32 missionIdx, f32 x, f32 y, s32 idx) {
static s32 D_menu_801B6AE8[] = { 30, 179, 30 };
static s32 D_menu_801B6AF4[] = { 0, 67, 255 };
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
Graphics_DisplaySmallText(x + 12.0f - Graphics_GetSmallTextWidth(sPlanetNames[idx]) * 0.5f, y - 8.0f, 1.0f, 1.0f,
@ -5691,7 +5692,7 @@ void Map_PathInfo_Draw(s32 missionIdx, f32 x, f32 y, s32 idx) {
x2 = 0.0f;
for (i = 0; i < 3; i++, x2 += 9.0f) {
if ((gMissionTeamStatus[missionIdx] & mask) != 0) {
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, D_menu_801B6ADC[i], D_menu_801B6AE8[i], D_menu_801B6AF4[i], 255);
Graphics_DisplaySmallText((s32) x + x2 - 1.0f, (s32) y + 24.0f + 8.0f + 2.0f, 1.0f, 1.0f,
D_menu_801B6AD0[i]);
@ -6117,7 +6118,7 @@ void Map_BriefingRadio_Draw(s32 arg0) {
case 20:
case 21:
if (sTeamStatusAlpha != 0) {
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, sTeamStatusAlpha);
xPos = 205.0f;
yPos = 77.0f;
@ -6140,7 +6141,7 @@ void Map_BriefingRadio_Draw(s32 arg0) {
break;
case 0:
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
if ((gGameFrameCount & 0x10) != 0) {
Graphics_DisplaySmallText(sTeamStatusPos[i], 131 + 28, 1.0f, 1.0f, "OK !");
@ -6153,7 +6154,7 @@ void Map_BriefingRadio_Draw(s32 arg0) {
break;
}
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, alpha[i]);
Lib_TextureRect_RGBA16(&gMasterDisp, sRadioCharacterFaces[i], 28, 28, sTeamStatusPos[i], 131.0f,
1.0f, 1.0f);
@ -6892,7 +6893,7 @@ void Map_SetCamRot(f32 camAtX, f32 camAtY, f32 camAtZ, f32* camEyeX, f32* camEye
}
void Map_RemainingLives_Draw(s32 xPos, s32 yPos, s32 number) {
RCP_SetupDL(&gMasterDisp, SETUPDL_85_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_85_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_CI4(&gMasterDisp, aMapArwingIconTex, aMapArwingIconTLUT, 16, 16, xPos, yPos, 1.0f, 1.0f);
@ -6900,7 +6901,7 @@ void Map_RemainingLives_Draw(s32 xPos, s32 yPos, s32 number) {
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
Lib_TextureRect_CI4(&gMasterDisp, aMapXTex, aMapXTLUT, 16, 7, xPos + 18.0f, yPos + 9.0f, 1.0f, 1.0f);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
if (number >= 10) {

View File

@ -14,6 +14,7 @@
#include "assets/ast_vs_menu.h"
#include "assets/ast_map.h"
#include "port/interpolation/FrameInterpolation.h"
#include "port/mods/PortEnhancements.h"
extern s32 gRankingTeamAlive[][3];
extern Gfx gMapVenomCloudDL[];
@ -1472,12 +1473,12 @@ void Option_Sound_Draw(void) {
Option_Sound_Speaker_Draw();
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_RGBA16(&gMasterDisp, aMapWhiteSquareTex, 8, 8, D_menu_801AEFA8[0], D_menu_801AEFD4[0],
D_menu_801AF000, 0.2f);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_IA8(&gMasterDisp, D_OPT_8005CD0, 112, 13, D_menu_801AEFA8[1], D_menu_801AEFD4[1], 1.0f, 1.0f);
@ -1741,7 +1742,7 @@ void Option_ExpertSound_Draw(void) {
if (!showJukebox) {
#endif
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
@ -1969,7 +1970,7 @@ void Option_Data_Draw(void) {
Option_DrawMenuLabel();
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
@ -2159,7 +2160,7 @@ void Option_RankingMenu_Draw(void) {
Option_RankingMenu2_Draw();
} else {
Title_RankingData_Draw();
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
Option_Color_FlashRed(&D_menu_801B93F0);
colorGB = D_menu_801B93F0;
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, colorGB, colorGB, 255);
@ -2167,7 +2168,7 @@ void Option_RankingMenu_Draw(void) {
Lib_TextureRect_IA8(&gMasterDisp, D_VS_MENU_7004010, 8, 8, 70.0f, (D_menu_801B93E4 * 17.0f) + 55.0f, 1.0f,
1.0f);
}
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
Graphics_DisplaySmallText(242, 215, 1.0f, 1.0f, "PUSH A");
}
@ -2263,7 +2264,7 @@ void Option_80197914(void) {
}
void Option_OrdinalNumbers_Draw(s32 ordinalType, s32 xPos, s32 yPos) {
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
if (ordinalType != 9) {
@ -2273,7 +2274,7 @@ void Option_OrdinalNumbers_Draw(s32 ordinalType, s32 xPos, s32 yPos) {
Lib_TextureRect_IA8(&gMasterDisp, aLargeText_0, 16, 15, xPos, yPos - 25.0f, 1.0f, 1.0f);
}
RCP_SetupDL(&gMasterDisp, SETUPDL_85_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_85_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
switch (ordinalType) {
@ -2298,7 +2299,7 @@ void Option_OrdinalNumbers_Draw(s32 ordinalType, s32 xPos, s32 yPos) {
void Option_RankingName_Draw(s32 rankIdx, s32 xPos, s32 yPos) {
char rankName[4];
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
rankName[0] = gSaveFile.save.data.rankNameEntry[rankIdx][0] & 0xFF;
@ -2310,7 +2311,7 @@ void Option_RankingName_Draw(s32 rankIdx, s32 xPos, s32 yPos) {
}
void Option_RankingTotalHits_Draw(s32 rankIdx, s32 xPos, s32 yPos) {
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 60, 60, 255, 170);
Lib_TextureRect_IA8(&gMasterDisp, aMapOptionBgTex, 24, 17, xPos, yPos, 3.17f, 1.05f);
@ -2327,7 +2328,7 @@ void Option_RankingTeamAlive_Draw(s32 rankIdx, s32 xPos, s32 yPos) {
f32 xOffset;
s32 i;
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
for (xOffset = 0.0f, i = 0; i < ARRAY_COUNT(sTeamAlivePrimR); i++, xOffset += 12.0f) {
gDPSetPrimColor(gMasterDisp++, 0, 0, sTeamAlivePrimR[i], sTeamAlivePrimG[i], sTeamAlivePrimB[i], 255);
@ -2368,7 +2369,7 @@ void Option_RankingRouteFrame_Draw(s32 rankIdx, s32 routeIdx, f32 xPos, f32 yPos
PlanetId end;
if ((yPos > 30.0f) && (yPos < 200.0f)) {
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
if (routeIdx < 6) {
r = g = b = 255;
@ -2426,7 +2427,7 @@ void Option_RankingTeamPresence_Draw(s32 rankIdx, s32 routeIdx, f32 xPos, f32 yP
s32 i;
if ((yPos > 12.0f) && (yPos < 154.0f)) {
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
teamAlive[0] = gSaveFile.save.data.stats[rankIdx][routeIdx].peppyAlive & 1;
teamAlive[1] = gSaveFile.save.data.stats[rankIdx][routeIdx].slippyAlive & 1;
@ -2451,7 +2452,7 @@ void Option_RankingPlanetName_Draw(s32 rankIdx, s32 routeIdx, f32 xPos, f32 yPos
planetIdx = gSaveFile.save.data.stats[rankIdx][routeIdx].planetId & 0xF;
planetName = D_menu_801AEEAC[planetIdx];
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
textWidth = Graphics_GetSmallTextWidth(planetName) / 2.0f;
Graphics_DisplaySmallText(xPos + 12.0f - textWidth, yPos - 8.0f, 1.0f, 1.0f, planetName);
@ -2813,7 +2814,7 @@ void Option_VS_HandicapSet_Draw(s32 PlayerIdx) {
static s32 sCharNameG[4] = { 242, 30, 255, 30 };
static s32 sCharNameB[4] = { 12, 0, 67, 255 };
RCP_SetupDL(&gMasterDisp, SETUPDL_85);
RCP_SetupDL(&gMasterDisp, SETUPDL_85_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
@ -3361,7 +3362,7 @@ void Option_VsTimeTrialStageSelect_Draw(void) {
alpha[i] = 32;
}
RCP_SetupDL(&gMasterDisp, SETUPDL_85);
RCP_SetupDL(&gMasterDisp, SETUPDL_85_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, alpha[i]);
@ -3407,7 +3408,7 @@ void Option_VsStageSelect2_Draw(void) {
alpha[i] = 32;
}
RCP_SetupDL(&gMasterDisp, SETUPDL_85);
RCP_SetupDL(&gMasterDisp, SETUPDL_85_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, alpha[i]);
@ -3456,7 +3457,7 @@ void Option_VsSelectionArrows_Draw(f32 xPos, f32 yPos, f32 offset, s32 r, s32 g,
}
void Option_AcceptCancel_Draw(void) {
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_IA8(&gMasterDisp, aAtoConfirmTex, 96, 10, 62.0f, 213.0f, 1.0f, 1.0f);
Lib_TextureRect_IA8(&gMasterDisp, aBtoCancelTex, 96, 10, 166.0f, 213.0f, 1.0f, 1.0f);
@ -3638,28 +3639,28 @@ void Option_DrawCardLabel(OptionCardTexture tex) {
if (!(tex.xScale <= 0.0f) && !(tex.yScale <= 0.0f)) {
switch (tex.type) {
case 1:
RCP_SetupDL(&gMasterDisp, SETUPDL_78_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, tex.red, tex.green, tex.blue, tex.alpha);
Lib_TextureRect_CI4(&gMasterDisp, tex.texture, tex.palette, tex.width, tex.height, tex.xPos, tex.yPos,
tex.xScale, tex.yScale);
break;
case 2:
RCP_SetupDL(&gMasterDisp, SETUPDL_78_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, tex.red, tex.green, tex.blue, tex.alpha);
Lib_TextureRect_CI8(&gMasterDisp, tex.texture, tex.palette, tex.width, tex.height, tex.xPos, tex.yPos,
tex.xScale, tex.yScale);
break;
case 0:
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, tex.red, tex.green, tex.blue, tex.alpha);
Lib_TextureRect_IA8(&gMasterDisp, tex.texture, tex.width, tex.height, tex.xPos, tex.yPos, tex.xScale,
tex.yScale);
break;
case 3:
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, tex.red, tex.green, tex.blue, tex.alpha);
Lib_TextureRect_RGBA16(&gMasterDisp, tex.texture, tex.width, tex.height, tex.xPos, tex.yPos, tex.xScale,
tex.yScale);
@ -4211,7 +4212,7 @@ void Option_NameEntry_Draw(void) {
static f32 D_menu_801AF30C[6] = { 51.0f, 138.0f, 118.0f, 166.0f, 138.0f, 267.0f };
static f32 D_menu_801AF324[6] = { 29.0f, 49.0f, 145.0f, 155.0f, 87.0f, 127.0f };
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
if (gLastGameState == GSTATE_ENDING) {
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
@ -4579,7 +4580,7 @@ void Option_InvoiceDraw(void) {
Graphics_FillRectangle(&gMasterDisp, 25, 18, SCREEN_WIDTH - 25, SCREEN_HEIGHT - 18, 255, 255, 255, 255);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_78_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_CI4(&gMasterDisp, D_OPT_8000000, D_OPT_8000680, 128, 26, D_menu_801AF3D0[0], D_menu_801AF3F0[0],
@ -4591,7 +4592,7 @@ void Option_InvoiceDraw(void) {
Lib_TextureRect_CI4(&gMasterDisp, D_OPT_80017C0, D_OPT_80038C0, 256, 66, D_menu_801AF3D0[2], D_menu_801AF3F0[2],
1.0f, 1.0f);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_RGBA16(&gMasterDisp, D_OPT_800E170, 188, 60, D_menu_801AF3D0[3], D_menu_801AF3F0[3], 1.0f, 1.0f);

View File

@ -11,6 +11,7 @@
#include "assets/ast_title.h"
#include "assets/ast_text.h"
#include "port/interpolation/FrameInterpolation.h"
#include "port/mods/PortEnhancements.h"
f32 D_menu_801B7BB0;
f32 D_menu_801B7BB4;
@ -419,7 +420,7 @@ void Title_Ranking_Draw(void) {
u8* aTextKanjiCOMPLETE_Data = LOAD_ASSET_RAW(aTextKanjiCOMPLETE);
// Ranking header
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
Graphics_DisplaySmallText(xPos, yPos, 1.0f, 1.0f, sSTARFOX_RANKING);
@ -435,7 +436,7 @@ void Title_Ranking_Draw(void) {
// This Kanji texture was used to draw a white line.
Lib_TextureRect_IA8(&gMasterDisp, &aTextKanjiCOMPLETE_Data[288], 16, 2, 36, 32, 15.2f, 1.0f);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
Title_RankingData_Draw();
}
@ -444,7 +445,7 @@ void Title_RankingData_Draw(void) {
s32 yPos;
s32 i;
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 0, 255);
@ -2905,7 +2906,7 @@ void Title_Passage_Draw(void) {
}
void Title_StarfoxLogo_Draw(void) {
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
// LTodo: Validate this
@ -2925,7 +2926,7 @@ void Title_64Logo_Draw(void) {
}
void Title_CopyrightSymbol_Draw(void) {
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_IA8(&gMasterDisp, aTitleCopyrightTex, 16, 16, 234.0f, 20.0f, 1.0f, 1.0f);
}
@ -2953,21 +2954,21 @@ void Title_PressStart_Draw(void) {
if (gMainController < 0) {
// No Controller background
RCP_SetupDL(&gMasterDisp, SETUPDL_85_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_85_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 60, 60, 255, 200);
Lib_TextureRect_CI8(&gMasterDisp, aNoControllerBgTex, aNoControllerBgTLUT, 32, 32, sNoControllerBgXpos,
sNoControllerBgYpos, sNoControllerBgXscale, sNoControllerBgYscale);
// No Controller
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, (s32) sTitleTextPrimCol, (s32) sTitleTextPrimCol, 255);
Lib_TextureRect_IA8(&gMasterDisp, aTitleNoControllerTex, 176, 24, D_menu_801AE474, D_menu_801AE478, 1.0f,
1.0f);
} else {
// Press Start
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, (s32) sTitleTextPrimCol, (s32) sTitleTextPrimCol, 255);
Lib_TextureRect_IA8(&gMasterDisp, aTitlePressStartTex, 120, 13, 101.0f, yPos, 1.0f, 1.0f);
@ -2978,7 +2979,7 @@ void Title_PressStart_Draw(void) {
void Title_Copyright_Draw(void) {
s32 i;
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_IA8(&gMasterDisp, a1997NintendoTex, 120, 12, 102.0f, 209.0f, 1.0f, 1.0f);
@ -2996,7 +2997,7 @@ void Title_TeamName_Draw(void) {
temp_fs2 = D_menu_801AE47C[D_menu_801B8340];
temp = 210.0f;
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
@ -3050,7 +3051,7 @@ void Title_SunGlare_Draw(void) {
D_menu_801B7BD0 -= 2;
}
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetAlphaDither(gMasterDisp++, G_AD_NOISE);
gDPSetColorDither(gMasterDisp++, G_CD_NOISE);
@ -3171,7 +3172,7 @@ void Title_Logos_Draw(void) {
switch (sTitleLogoState) {
case TITLE_LOGO_STARFOX_IN:
RCP_SetupDL(&gMasterDisp, SETUPDL_85_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_85_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, (s32) sStarfoxLogoAlpha);
Lib_TextureRect_CI4(&gMasterDisp, aIntroStarfoxLogoTex, aIntroStarfoxLogoTLUT, 256, 13, 90.0f, 110.0f, 1.0f,
1.0f);
@ -3180,7 +3181,7 @@ void Title_Logos_Draw(void) {
break;
case TITLE_LOGO_NINTENDO_64:
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, (s32) sStarfoxLogoAlpha);
Lib_TextureRect_RGBA16(&gMasterDisp, aTitleN64LogoTex, 128, 88, D_menu_801B9070, D_menu_801B9074,
D_menu_801B9078, D_menu_801B907C);
@ -3315,14 +3316,14 @@ void Title_TitleCard_Draw(void) {
break;
case TITLE_CARD_GREAT_FOX:
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_IA8(&gMasterDisp, aTitleGreatFoxCardTex, 144, 28, aTitleGreatFoxCardXpos,
aTitleGreatFoxCardYpos, 1.0f, 1.0f);
break;
case TITLE_CARD_ARWING:
RCP_SetupDL(&gMasterDisp, SETUPDL_83_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_83_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_IA8(&gMasterDisp, aTitleArwingCardTex, 112, 26, sTitleArwingCardXpos, sTitleArwingCardYpos,

View File

@ -224,7 +224,7 @@ void OnItemGoldRingDraw(ObjectDrawPostSetupEvent* event) {
}
event->event.cancelled = true;
RCP_SetupDL(&gMasterDisp, SETUPDL_29_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_29_OPTIONAL);
Graphics_SetScaleMtx(item->width * 2.0f);
gSPDisplayList(gMasterDisp++, D_101D870);
}
@ -297,7 +297,7 @@ void OnBoostGaugeDraw(IEvent* event){
f32 x = 70;
f32 y = 30;
RCP_SetupDL(&gMasterDisp, SETUPDL_76_POINT);
RCP_SetupDL(&gMasterDisp, SETUPDL_76_OPTIONAL);
gDPSetPrimColor(gMasterDisp++, 0, 0, 255, 255, 255, 255);
Lib_TextureRect_CI8(&gMasterDisp, D_1012290, D_10126B0, 48, 22, OTRGetRectDimensionFromRightEdgeOverride(SCREEN_WIDTH - x), y, 1.0f, 1.0f);
Lib_TextureRect_CI8(&gMasterDisp, D_10126F0, D_1012750, 24, 4, OTRGetRectDimensionFromRightEdgeOverride(SCREEN_WIDTH - (x - 9)), y + 3, 1.0f, 1.0f);

View File

@ -7,6 +7,21 @@ extern "C" {
void PortEnhancements_Register();
void PortEnhancements_Init();
void PortEnhancements_Exit();
#define SETUPDL_OPTIONAL(digits) \
(CVarGetInteger("gHUDPointFiltering", 1) == 1 ? SETUPDL_##digits##_POINT : SETUPDL_##digits)
#define SETUPDL_29_OPTIONAL SETUPDL_OPTIONAL(29)
#define SETUPDL_36_OPTIONAL SETUPDL_OPTIONAL(36)
#define SETUPDL_62_OPTIONAL SETUPDL_OPTIONAL(62)
#define SETUPDL_63_OPTIONAL SETUPDL_OPTIONAL(63)
#define SETUPDL_67_OPTIONAL SETUPDL_OPTIONAL(67)
#define SETUPDL_75_OPTIONAL SETUPDL_OPTIONAL(75)
#define SETUPDL_76_OPTIONAL SETUPDL_OPTIONAL(76)
#define SETUPDL_77_OPTIONAL SETUPDL_OPTIONAL(77)
#define SETUPDL_78_OPTIONAL SETUPDL_OPTIONAL(78)
#define SETUPDL_81_OPTIONAL SETUPDL_OPTIONAL(81)
#define SETUPDL_83_OPTIONAL SETUPDL_OPTIONAL(83)
#define SETUPDL_85_OPTIONAL SETUPDL_OPTIONAL(85)
#ifdef __cplusplus
};

View File

@ -399,6 +399,9 @@ void DrawSettingsMenu(){
ImGui::Text("Texture Filter (Needs reload)");
UIWidgets::EnhancementCombobox("gTextureFilter", filters, 0);
if (Ship::Context::GetInstance()->GetConfig()->GetString("Window.Backend.Name") != windowBackendNames[Ship::WindowBackend::FAST3D_SDL_OPENGL]) {
UIWidgets::PaddedEnhancementCheckbox("Apply Point Filtering to UI Elements", "gHUDPointFiltering", true, false, false, "", UIWidgets::CheckboxGraphics::Cross, true);
}
UIWidgets::Spacer(0);
Ship::Context::GetInstance()->GetWindow()->GetGui()->GetGameOverlay()->DrawSettings();