[Video] Rename grBufferClear to gfxBufferClear
This commit is contained in:
parent
33d8caba16
commit
6a0d221302
|
@ -241,7 +241,7 @@ void guLoadTextures()
|
|||
tbuf_size = grTexCalcMemRequired(GFX_LOD_LOG2_1024, GFX_LOD_LOG2_1024,
|
||||
GR_ASPECT_LOG2_1x1, GFX_TEXFMT_RGB_565);
|
||||
gfxRenderBuffer(GR_BUFFER_TEXTUREBUFFER_EXT);
|
||||
grBufferClear(0, 0, 0xFFFF);
|
||||
gfxBufferClear(0, 0, 0xFFFF);
|
||||
gfxRenderBuffer(GR_BUFFER_BACKBUFFER);
|
||||
}
|
||||
else
|
||||
|
@ -251,7 +251,7 @@ void guLoadTextures()
|
|||
tbuf_size = grTexCalcMemRequired(GFX_LOD_LOG2_2048, GFX_LOD_LOG2_2048,
|
||||
GR_ASPECT_LOG2_1x1, GFX_TEXFMT_RGB_565);
|
||||
gfxRenderBuffer(GR_BUFFER_TEXTUREBUFFER_EXT);
|
||||
grBufferClear(0, 0, 0xFFFF);
|
||||
gfxBufferClear(0, 0, 0xFFFF);
|
||||
gfxRenderBuffer(GR_BUFFER_BACKBUFFER);
|
||||
}
|
||||
|
||||
|
@ -364,7 +364,7 @@ void DisplayLoadProgress(const wchar_t *format, ...)
|
|||
output(x, 360, 1, buf);
|
||||
grBufferSwap(0);
|
||||
gfxColorMask(FXTRUE, FXTRUE);
|
||||
grBufferClear(0, 0, 0xFFFF);
|
||||
gfxBufferClear(0, 0, 0xFFFF);
|
||||
}
|
||||
|
||||
#ifdef _WIN32
|
||||
|
@ -552,9 +552,9 @@ int InitGfx()
|
|||
gfxRenderBuffer(GR_BUFFER_BACKBUFFER);
|
||||
gfxColorMask(FXTRUE, FXTRUE);
|
||||
gfxDepthMask(FXTRUE);
|
||||
grBufferClear(0, 0, 0xFFFF);
|
||||
gfxBufferClear(0, 0, 0xFFFF);
|
||||
grBufferSwap(0);
|
||||
grBufferClear(0, 0, 0xFFFF);
|
||||
gfxBufferClear(0, 0, 0xFFFF);
|
||||
gfxDepthMask(FXFALSE);
|
||||
grTexFilterMode(0, GR_TEXTUREFILTER_BILINEAR, GR_TEXTUREFILTER_BILINEAR);
|
||||
grTexFilterMode(1, GR_TEXTUREFILTER_BILINEAR, GR_TEXTUREFILTER_BILINEAR);
|
||||
|
@ -1118,7 +1118,7 @@ static void DrawFrameBuffer()
|
|||
|
||||
gfxDepthMask(FXTRUE);
|
||||
gfxColorMask(FXTRUE, FXTRUE);
|
||||
grBufferClear(0, 0, 0xFFFF);
|
||||
gfxBufferClear(0, 0, 0xFFFF);
|
||||
drawViRegBG();
|
||||
}
|
||||
|
||||
|
@ -1435,7 +1435,7 @@ void newSwapBuffers()
|
|||
if (g_settings->wireframe() || g_settings->buff_clear() || (g_settings->hacks(CSettings::hack_PPL) && g_settings->ucode() == CSettings::ucode_S2DEX))
|
||||
{
|
||||
gfxDepthMask((g_settings->hacks(CSettings::hack_RE2) && g_settings->fb_depth_render_enabled()) ? FXFALSE : FXTRUE);
|
||||
grBufferClear(0, 0, 0xFFFF);
|
||||
gfxBufferClear(0, 0, 0xFFFF);
|
||||
}
|
||||
|
||||
if (g_settings->fb_read_back_to_screen2_enabled())
|
||||
|
|
|
@ -1325,8 +1325,7 @@ void gfxAuxBufferExt(GrBuffer_t buffer)
|
|||
}
|
||||
}
|
||||
|
||||
FX_ENTRY void FX_CALL
|
||||
grBufferClear(GrColor_t color, gfxAlpha_t alpha, FxU32 depth)
|
||||
void gfxBufferClear(GrColor_t color, gfxAlpha_t alpha, FxU32 depth)
|
||||
{
|
||||
WriteTrace(TraceGlitch, TraceDebug, "color: %d alpha: %d depth: %d", color, alpha, depth);
|
||||
vbo_draw();
|
||||
|
@ -1345,7 +1344,7 @@ grBufferClear(GrColor_t color, gfxAlpha_t alpha, FxU32 depth)
|
|||
alpha / 255.0f);
|
||||
break;
|
||||
default:
|
||||
WriteTrace(TraceGlitch, TraceWarning, "grBufferClear: unknown color format : %x", lfb_color_fmt);
|
||||
WriteTrace(TraceGlitch, TraceWarning, "gfxBufferClear: unknown color format : %x", lfb_color_fmt);
|
||||
}
|
||||
|
||||
glClear(GL_COLOR_BUFFER_BIT);
|
||||
|
|
|
@ -1598,8 +1598,7 @@ void gfxAuxBufferExt(GrBuffer_t buffer)
|
|||
grDisplayGLError("gfxAuxBufferExt");
|
||||
}
|
||||
|
||||
FX_ENTRY void FX_CALL
|
||||
grBufferClear(GrColor_t color, gfxAlpha_t alpha, FxU32 depth)
|
||||
void gfxBufferClear(GrColor_t color, gfxAlpha_t alpha, FxU32 depth)
|
||||
{
|
||||
WriteTrace(TraceGlitch, TraceDebug, "color: %X alpha: %X depth: %X", color, alpha, depth);
|
||||
switch (lfb_color_fmt)
|
||||
|
@ -1617,7 +1616,7 @@ grBufferClear(GrColor_t color, gfxAlpha_t alpha, FxU32 depth)
|
|||
alpha / 255.0f);
|
||||
break;
|
||||
default:
|
||||
WriteTrace(TraceGlitch, TraceWarning, "grBufferClear: unknown color format : %x", lfb_color_fmt);
|
||||
WriteTrace(TraceGlitch, TraceWarning, "gfxBufferClear: unknown color format : %x", lfb_color_fmt);
|
||||
}
|
||||
|
||||
if (w_buffer_mode)
|
||||
|
@ -1629,7 +1628,7 @@ grBufferClear(GrColor_t color, gfxAlpha_t alpha, FxU32 depth)
|
|||
// ZIGGY TODO check that color mask is on
|
||||
buffer_cleared = 1;
|
||||
|
||||
grDisplayGLError("grBufferClear");
|
||||
grDisplayGLError("gfxBufferClear");
|
||||
}
|
||||
|
||||
// #include <unistd.h>
|
||||
|
|
|
@ -57,6 +57,7 @@ void gfxAuxBufferExt(GrBuffer_t buffer);
|
|||
FxU32 gfxGet(FxU32 pname, FxU32 plength, FxI32 *params);
|
||||
void gfxFramebufferCopyExt(int x, int y, int w, int h, int from, int to, int mode);
|
||||
void gfxRenderBuffer(GrBuffer_t buffer);
|
||||
void gfxBufferClear(GrColor_t color, gfxAlpha_t alpha, FxU32 depth);
|
||||
|
||||
extern uint32_t nbTextureUnits;
|
||||
extern uint32_t g_scr_res_x, g_scr_res_y, g_res_x, g_res_y;
|
||||
|
|
|
@ -259,7 +259,7 @@ int OpenTextureBuffer(COLOR_IMAGE & cimage)
|
|||
gfxTextureBufferExt(texbuf->tmu, texbuf->tex_addr, texbuf->info.smallLodLog2, texbuf->info.largeLodLog2,
|
||||
texbuf->info.aspectRatioLog2, texbuf->info.format, GR_MIPMAPLEVELMASK_BOTH);
|
||||
gfxDepthMask(FXFALSE);
|
||||
grBufferClear(0, 0, 0xFFFF);
|
||||
gfxBufferClear(0, 0, 0xFFFF);
|
||||
gfxDepthMask(FXTRUE);
|
||||
gfxRenderBuffer(GR_BUFFER_BACKBUFFER);
|
||||
rdp.texbufs[i].count--;
|
||||
|
@ -301,7 +301,7 @@ int OpenTextureBuffer(COLOR_IMAGE & cimage)
|
|||
{
|
||||
rdp.cur_image->clear = FALSE;
|
||||
gfxDepthMask(FXFALSE);
|
||||
grBufferClear(0, 0, 0xFFFF);
|
||||
gfxBufferClear(0, 0, 0xFFFF);
|
||||
gfxDepthMask(FXTRUE);
|
||||
}
|
||||
//*/
|
||||
|
|
|
@ -2397,7 +2397,7 @@ void rdp_fillrect()
|
|||
update_scissor();
|
||||
gfxDepthMask(FXTRUE);
|
||||
gfxColorMask(FXFALSE, FXFALSE);
|
||||
grBufferClear(0, 0, rdp.fill_color ? rdp.fill_color & 0xFFFF : 0xFFFF);
|
||||
gfxBufferClear(0, 0, rdp.fill_color ? rdp.fill_color & 0xFFFF : 0xFFFF);
|
||||
gfxColorMask(FXTRUE, FXTRUE);
|
||||
rdp.update |= UPDATE_ZBUF_ENABLED;
|
||||
}
|
||||
|
@ -2438,7 +2438,7 @@ void rdp_fillrect()
|
|||
((uint32_t)((float)((color & 0x003E) >> 1) / 31.0f * 255.0f) << 8);
|
||||
}
|
||||
gfxDepthMask(FXFALSE);
|
||||
grBufferClear(color, 0, 0xFFFF);
|
||||
gfxBufferClear(color, 0, 0xFFFF);
|
||||
gfxDepthMask(FXTRUE);
|
||||
rdp.update |= UPDATE_ZBUF_ENABLED;
|
||||
WriteTrace(TraceRDP, TraceDebug, "Fillrect - cleared the texture buffer");
|
||||
|
@ -2722,7 +2722,7 @@ static void RestoreScale()
|
|||
rdp.update |= UPDATE_VIEWPORT | UPDATE_SCISSOR;
|
||||
//*
|
||||
gfxDepthMask(FXFALSE);
|
||||
grBufferClear(0, 0, 0xFFFF);
|
||||
gfxBufferClear(0, 0, 0xFFFF);
|
||||
gfxDepthMask(FXTRUE);
|
||||
//*/
|
||||
}
|
||||
|
@ -2985,7 +2985,7 @@ void rdp_setcolorimage()
|
|||
else //just clear buffer
|
||||
{
|
||||
gfxColorMask(FXTRUE, FXTRUE);
|
||||
grBufferClear (0, 0, 0xFFFF);
|
||||
gfxBufferClear (0, 0, 0xFFFF);
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
|
|
@ -197,7 +197,7 @@ void DrawHiresDepthImage(const DRAWIMAGE & d)
|
|||
GR_ASPECT_LOG2_1x1, GFX_TEXFMT_RGB_565, GR_MIPMAPLEVELMASK_BOTH);
|
||||
gfxRenderBuffer(GR_BUFFER_TEXTUREBUFFER_EXT);
|
||||
gfxAuxBufferExt(GR_BUFFER_AUXBUFFER);
|
||||
grBufferClear(0, 0, 0xFFFF);
|
||||
gfxBufferClear(0, 0, 0xFFFF);
|
||||
gfxDrawTriangle(&v[0], &v[2], &v[1]);
|
||||
gfxDrawTriangle(&v[2], &v[3], &v[1]);
|
||||
gfxRenderBuffer(GR_BUFFER_BACKBUFFER);
|
||||
|
|
Loading…
Reference in New Issue