src/core1: various video/screen/framebuffer related documentations
neue Datei: include/core1/vimgr.h
umbenannt: src/core1/code_E360.c -> src/core1/vimgr.c
This commit is contained in:
@@ -86,8 +86,8 @@ void fxairscore_draw(enum item_e item_id, struct8s *arg1, Gfx **gfx, Mtx **mtx,
|
||||
gDPSetPrimColor((*gfx)++, 0, 0, 0x00, 0x00, 0x00, 0x78);
|
||||
}
|
||||
x = func_802FB0E4(arg1);
|
||||
x = ((-40 + x) + D_80381F68[var_s6]) - ((f32) framebuffer_width / 2);
|
||||
y = ((78 + (i_part * 15.5)) - ((f32) framebuffer_height / 2));
|
||||
x = ((-40 + x) + D_80381F68[var_s6]) - ((f32) gFramebufferWidth / 2);
|
||||
y = ((78 + (i_part * 15.5)) - ((f32) gFramebufferHeight / 2));
|
||||
|
||||
//stagger x position
|
||||
x = (i_part & 1) ? x + 5.0f : x - 5.0f;
|
||||
|
||||
@@ -8,9 +8,6 @@ f32 time_getDelta(void);
|
||||
f32 func_802FB0DC(struct8s *);
|
||||
f32 func_802FB0E4(struct8s *);
|
||||
|
||||
extern s32 framebuffer_width; //framebuffer_w
|
||||
extern s32 framebuffer_height; //framebuffer_h
|
||||
|
||||
|
||||
Gfx D_80369920[] = {
|
||||
gsDPPipeSync(),
|
||||
@@ -154,8 +151,8 @@ void func_802FD360(struct8s *arg0, Gfx **gfx, Mtx **mtx, Vtx **vtx){
|
||||
tmp_f26 = (arg0->unk20 == ITEM_0_HOURGLASS_TIMER && texture_width == 0x10) ? 1.0f : 0.0f;
|
||||
for(tmp_s4 = 0; tmp_s4 < 2; tmp_s4++){//L802FD528
|
||||
for(tmp_s2 = 0; tmp_s2 < 2; tmp_s2++){//
|
||||
(*vtx)->v.ob[0] = ((func_802FB0DC(arg0) + (((texture_width*arg0->unk40*tmp_s2 - texture_width*arg0->unk40/2) - (f32)framebuffer_width/2) + arg0->unk38)) + tmp_f26) * 4.0f;
|
||||
(*vtx)->v.ob[1] = ((((texture_height*arg0->unk40/2 - texture_height*arg0->unk40*tmp_s4) + (f32)framebuffer_height/2) - arg0->unk3C) - func_802FB0E4(arg0)*arg0->unk4C)*4.0f;
|
||||
(*vtx)->v.ob[0] = ((func_802FB0DC(arg0) + (((texture_width*arg0->unk40*tmp_s2 - texture_width*arg0->unk40/2) - (f32)gFramebufferWidth/2) + arg0->unk38)) + tmp_f26) * 4.0f;
|
||||
(*vtx)->v.ob[1] = ((((texture_height*arg0->unk40/2 - texture_height*arg0->unk40*tmp_s4) + (f32)gFramebufferHeight/2) - arg0->unk3C) - func_802FB0E4(arg0)*arg0->unk4C)*4.0f;
|
||||
(*vtx)->v.ob[2] = -0x14;
|
||||
(*vtx)->v.tc[0] = ((texture_width -1) * tmp_s2) << 6;
|
||||
(*vtx)->v.tc[1] = ((texture_height -1) * tmp_s4) << 6;
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
extern f32 vtxList_getGlobalNorm(BKVertexList *);
|
||||
extern void func_80253208(Gfx **gdl, s32 x, s32 y, s32 w, s32 h, void *color_buffer);
|
||||
|
||||
extern s16 D_803A5D00[2][0xF660];
|
||||
extern f32 func_802FB0E4(struct8s*);
|
||||
|
||||
typedef struct {
|
||||
@@ -210,7 +209,7 @@ void fxcommon3score_draw(enum item_e item_id, void *arg1, Gfx **gfx, Mtx **mtx,
|
||||
if(a1->unk6C == 0.0f){
|
||||
a1->unk6C = 1.1*(vtxList_getGlobalNorm(model_getVtxList(a1->model)) * a1->unk3C);
|
||||
}
|
||||
func_80253208(gfx, a1->unk30 - a1->unk6C, sp40 - a1->unk6C, 2*a1->unk6C, 2*a1->unk6C, D_803A5D00[getActiveFramebuffer()]);
|
||||
func_80253208(gfx, a1->unk30 - a1->unk6C, sp40 - a1->unk6C, 2*a1->unk6C, 2*a1->unk6C, gFramebuffers[getActiveFramebuffer()]);
|
||||
if(a1->anim_ctrl != NULL){
|
||||
animctrl_drawSetup(a1->anim_ctrl, sp5C, 1);
|
||||
}
|
||||
|
||||
@@ -6,9 +6,6 @@
|
||||
|
||||
extern f32 func_802FB0E4(struct8s*);
|
||||
|
||||
extern s32 framebuffer_width;
|
||||
extern s32 framebuffer_height;
|
||||
|
||||
/* .data */
|
||||
BKSprite * gSpriteHealth = NULL;
|
||||
BKSprite * gSpriteRedHealth = NULL;
|
||||
@@ -112,8 +109,8 @@ void fxhealthscore_draw(enum item_e item_id, struct8s *arg1, Gfx **gfx, Mtx **mt
|
||||
gDPSetPrimColor((*gfx)++, 0, 0, 0xFF, 0xFF, 0xFF, 0x78);
|
||||
}
|
||||
|
||||
f20 = 96.0f - (f32) framebuffer_width / 2 + (i * 13);
|
||||
f14 = (f32) framebuffer_height / 2 - func_802FB0E4(arg1) - D_80381F08[s6] - -48.0f;
|
||||
f20 = 96.0f - (f32) gFramebufferWidth / 2 + (i * 13);
|
||||
f14 = (f32) gFramebufferHeight / 2 - func_802FB0E4(arg1) - D_80381F08[s6] - -48.0f;
|
||||
f14 = (i & 1) ? f14 + 5.75 : f14 - 5.75;
|
||||
|
||||
gSPVertex((*gfx)++, *vtx, 4, 0);
|
||||
|
||||
@@ -141,8 +141,8 @@ void fxhoneycarrierscore_draw(s32 arg0, struct8s *arg1, Gfx **arg2, Mtx **arg3,
|
||||
}
|
||||
}
|
||||
}
|
||||
sp128 = (244.0f - ((f32) framebuffer_width / 2));
|
||||
sp124 = func_802FB0E4(arg1) + ((f32) framebuffer_height / 2) - 246.0f;
|
||||
sp128 = (244.0f - ((f32) gFramebufferWidth / 2));
|
||||
sp124 = func_802FB0E4(arg1) + ((f32) gFramebufferHeight / 2) - 246.0f;
|
||||
guTranslate(*arg3, sp128 * 4.0f, sp124 * 4.0f, 0.0f);
|
||||
gSPMatrix((*arg2)++, OS_K0_TO_PHYSICAL((*arg3)++), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
guRotate(*arg3, func_802FDE60(D_803815D8 + D_803815DC), 0.0f, 0.0f, 1.0f);
|
||||
|
||||
@@ -176,8 +176,8 @@ void fxjinjoscore_draw(s32 arg0, struct8s *arg1, Gfx **gfx, Mtx **mtx, Vtx **vtx
|
||||
// If the jinjo is collected then it's drawn fully opaque, otherwise it's drawn with partial alpha
|
||||
gDPSetPrimColor((*gfx)++, 0, 0, 0x00, 0x00, 0x00, jinjo_collected ? 0xFF : 0x6E);
|
||||
}
|
||||
center_x = pos_x - (f32) framebuffer_width / 2 + x_offset;
|
||||
center_y = (f32) framebuffer_height / 2 + func_802FB0E4(arg1) - 266.0f + 40.0f + y_offset - D_80381E78[jinjo_id];
|
||||
center_x = pos_x - (f32) gFramebufferWidth / 2 + x_offset;
|
||||
center_y = (f32) gFramebufferHeight / 2 + func_802FB0E4(arg1) - 266.0f + 40.0f + y_offset - D_80381E78[jinjo_id];
|
||||
gSPVertex((*gfx)++, *vtx, 4, 0);
|
||||
// Set up the positions of the four vertices
|
||||
for(i = 0; i < 2; i++){
|
||||
|
||||
@@ -102,8 +102,8 @@ void fxlifescore_draw(enum item_e item_id, struct8s *arg1, Gfx **gfx, Mtx **mtx,
|
||||
sp104 = sp104 + 4;
|
||||
}
|
||||
|
||||
var_s5 = (40.0f - ((f32) framebuffer_width / 2)) + spE0;
|
||||
var_s4 = (((((f32) framebuffer_height / 2) - func_802FB0E4(arg1)) - -16.0f) - spDC);
|
||||
var_s5 = (40.0f - ((f32) gFramebufferWidth / 2)) + spE0;
|
||||
var_s4 = (((((f32) gFramebufferHeight / 2) - func_802FB0E4(arg1)) - -16.0f) - spDC);
|
||||
for(var_v1 = 0; var_v1 < 2; var_v1++){
|
||||
for(var_v0 = 0; var_v0 < 2; var_v0++){
|
||||
(*vtx)->v.ob[0] = (s16) (s32) (((((f32) spF0 * D_80381EB8 * (f32) var_v0) - (((f32) spE8 * D_80381EB8) / 2)) + var_s5) * 4.0f);
|
||||
|
||||
Reference in New Issue
Block a user