summaryrefslogtreecommitdiff
path: root/src/code/code_800AD920.c
diff options
context:
space:
mode:
authorTharo <17233964+Thar0@users.noreply.github.com>2023-09-16 22:16:58 +0100
committerGitHub <noreply@github.com>2023-09-16 17:16:58 -0400
commit9b207c356a66aec59815cbbd557f40d48d7cccdd (patch)
treec21d897790081774101831ac610682317ef5a149 /src/code/code_800AD920.c
parent239a172114b891fffe7af21777dc5313f0de9441 (diff)
Document Framebuffer Filters, VisCvg and VisZbuf (#1534)
* Document z_viscvg and z_viszbuf Co-authored-by: Tharo <17233964+Thar0@users.noreply.github.com> Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> * Few more notes * Some more notes Co-authored-by: Tharo <17233964+Thar0@users.noreply.github.com> * Review * Americanisation, FB RGB * Oops * Review * Minor documentation modifications * Header, base struct and enums Co-authored-by: Tharo <17233964+Thar0@users.noreply.github.com> * functions.h fix * Suggested changes, further adjustments to file doc comments * Further suggested changes, standardize capitalization of gfxP * g --------- Co-authored-by: Elliptic Ellipsis <elliptic.ellipsis@gmail.com> Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
Diffstat (limited to 'src/code/code_800AD920.c')
-rw-r--r--src/code/code_800AD920.c60
1 files changed, 0 insertions, 60 deletions
diff --git a/src/code/code_800AD920.c b/src/code/code_800AD920.c
deleted file mode 100644
index 94479e164..000000000
--- a/src/code/code_800AD920.c
+++ /dev/null
@@ -1,60 +0,0 @@
-#include "global.h"
-
-// Note : This file is related to z_vismono, the original name was probably z_vis<something after "mono" alphabetically>
-
-// z-buffer
-extern u16 D_0E000000[];
-
-// Init
-void func_800AD920(struct_80166500* this) {
- this->useRgba = false;
- this->setScissor = false;
- this->primColor.r = 255;
- this->primColor.g = 255;
- this->primColor.b = 255;
- this->primColor.a = 255;
- this->envColor.a = 255;
- this->envColor.r = 0;
- this->envColor.g = 0;
- this->envColor.b = 0;
-}
-
-// Destroy
-void func_800AD950(struct_80166500* this) {
-}
-
-// Draw
-void func_800AD958(struct_80166500* this, Gfx** gfxp) {
- Gfx* gfx = *gfxp;
- u16* tex = D_0E000000;
- s32 fmt = !this->useRgba ? G_IM_FMT_IA : G_IM_FMT_RGBA;
- s32 y;
- s32 height = 6;
-
- gDPPipeSync(gfx++);
- if (this->setScissor == true) {
- gDPSetScissor(gfx++, G_SC_NON_INTERLACE, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT);
- }
-
- gDPSetOtherMode(gfx++,
- G_AD_DISABLE | G_CD_MAGICSQ | G_CK_NONE | G_TC_FILT | G_TF_POINT | G_TT_NONE | G_TL_TILE |
- G_TD_CLAMP | G_TP_NONE | G_CYC_1CYCLE | G_PM_NPRIMITIVE,
- G_AC_NONE | G_ZS_PRIM | G_RM_OPA_SURF | G_RM_OPA_SURF2);
- gDPSetCombineLERP(gfx++, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT,
- PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT);
-
- gDPSetColor(gfx++, G_SETPRIMCOLOR, this->primColor.rgba);
- gDPSetColor(gfx++, G_SETENVCOLOR, this->envColor.rgba);
-
- for (y = 0; y <= SCREEN_HEIGHT - height; y += height) {
- gDPLoadTextureBlock(gfx++, tex, fmt, G_IM_SIZ_16b, SCREEN_WIDTH, height, 0, G_TX_NOMIRROR | G_TX_CLAMP,
- G_TX_NOMIRROR | G_TX_CLAMP, G_TX_NOMASK, G_TX_NOMASK, G_TX_NOLOD, G_TX_NOLOD);
-
- gSPTextureRectangle(gfx++, 0, y << 2, SCREEN_WIDTH << 2, (y + height) << 2, G_TX_RENDERTILE, 0, 0, 1 << 10,
- 1 << 10);
- tex += SCREEN_WIDTH * height;
- }
-
- gDPPipeSync(gfx++);
- *gfxp = gfx;
-}