(D3D9) Remove d3d9_clear

This commit is contained in:
twinaphex 2022-04-19 14:03:29 +02:00
parent 7c37f9c053
commit 4114545564
4 changed files with 8 additions and 14 deletions

View File

@ -251,16 +251,6 @@ static INLINE void d3d9_draw_primitive(
d3d9_end_scene(dev);
}
static INLINE void d3d9_clear(
LPDIRECT3DDEVICE9 dev,
unsigned count, const D3DRECT *rects, unsigned flags,
INT32 color, float z, unsigned stencil)
{
if (dev)
IDirect3DDevice9_Clear(dev, count, rects, flags,
color, z, stencil);
}
static INLINE bool d3d9_lock_rectangle(
LPDIRECT3DTEXTURE9 tex,
unsigned level,

View File

@ -725,7 +725,8 @@ static bool d3d9_frame(void *data, const void *frame,
screen_vp.Width = width;
screen_vp.Height = height;
d3d9_set_viewports(d3d->dev, &screen_vp);
d3d9_clear(d3d->dev, 0, 0, D3DCLEAR_TARGET, 0, 1, 0);
IDirect3DDevice9_Clear(d3d->dev, 0, 0, D3DCLEAR_TARGET,
0, 1, 0);
d3d9_set_vertex_shader_constantf(d3d->dev, 0, (const float*)&d3d->mvp_transposed, 4);
if (!d3d->renderchain_driver->render(
@ -750,7 +751,8 @@ static bool d3d9_frame(void *data, const void *frame,
#endif
if (!ret || d3d->needs_restore)
return true;
d3d9_clear(d3d->dev, 0, 0, D3DCLEAR_TARGET, 0, 1, 0);
IDirect3DDevice9_Clear(d3d->dev, 0, 0, D3DCLEAR_TARGET,
0, 1, 0);
}
}

View File

@ -1017,7 +1017,8 @@ static bool d3d9_cg_renderchain_render(
viewport.MaxZ = 1.0f;
d3d9_set_viewports(chain->dev, &viewport);
d3d9_clear(chain->dev, 0, 0, D3DCLEAR_TARGET, 0, 1, 0);
IDirect3DDevice9_Clear(chain->dev, 0, 0, D3DCLEAR_TARGET,
0, 1, 0);
viewport.Width = out_width;
viewport.Height = out_height;

View File

@ -609,7 +609,8 @@ static bool hlsl_d3d9_renderchain_render(
viewport.MaxZ = 1.0f;
d3d9_set_viewports(chain->chain.dev, &viewport);
d3d9_clear(chain->chain.dev, 0, 0, D3DCLEAR_TARGET, 0, 1, 0);
IDirect3DDevice9_Clear(chain->chain.dev, 0, 0, D3DCLEAR_TARGET,
0, 1, 0);
viewport.Width = out_width;
viewport.Height = out_height;