Revert "(D3D) Cleanups"

This reverts commit f93ca7b7e6.
This commit is contained in:
twinaphex 2015-04-06 01:34:31 +02:00
parent f93ca7b7e6
commit 8bdfc3d8cb

View File

@ -108,10 +108,11 @@ static bool d3d_init_shader(void *data)
static void d3d_deinit_chain(d3d_video_t *d3d)
{
renderchain_deinit(d3d->chain);
d3d->chain = NULL;
#ifdef _XBOX
renderchain_free(d3d);
#else
renderchain_deinit(d3d->chain);
d3d->chain = NULL;
#endif
}
@ -893,23 +894,26 @@ static bool d3d_init_chain(d3d_video_t *d3d, const video_info_t *video_info)
video_info->input_scale * RARCH_SCALE_BASE;
#endif
d3d->chain = renderchain_new();
if (!d3d->chain)
return false;
#ifdef _XBOX
if (!renderchain_init(d3d, video_info,
NULL, NULL, NULL,
video_info->rgb32 ?
RETRO_PIXEL_FORMAT_XRGB8888 : RETRO_PIXEL_FORMAT_RGB565))
{
RARCH_ERR("[D3D]: Failed to init render chain.\n");
return false;
}
#else
d3d->chain = renderchain_new();
if (!d3d->chain)
return false;
if (!renderchain_init(d3d->chain, &d3d->video_info, d3dr,
&d3d->final_viewport, &link_info,
d3d->video_info.rgb32 ? RETRO_PIXEL_FORMAT_XRGB8888 : RETRO_PIXEL_FORMAT_RGB565))
#endif
{
RARCH_ERR("[D3D]: Failed to init render chain.\n");
RARCH_ERR("[D3D9]: Failed to init render chain.\n");
return false;
}