mirror of
https://github.com/libretro/RetroArch.git
synced 2025-02-15 23:19:24 +00:00
Merge pull request #26 from freakdave/master
(Xbox 1) Debug output bugfixes
This commit is contained in:
commit
14a998e3d1
@ -19,18 +19,18 @@
|
||||
CharacterSet="2">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
Optimization="3"
|
||||
OptimizeForProcessor="2"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)\msvc-stdint";"$(SolutionDir)\msvc-71""
|
||||
PreprocessorDefinitions="_DEBUG;_XBOX;_XBOX1;RARCH_CONSOLE;HAVE_XINPUT_XBOX1;PACKAGE_VERSION=\"0.9.6\";__STDC_CONSTANT_MACROS;HAVE_ZLIB;HAVE_GRIFFIN;HAVE_RARCH_MAIN_WRAP;HAVE_LIBRETRO_MANAGEMENT;HAVE_RARCH_EXEC;HAVE_DEFAULT_RETROPAD_INPUT;HAVE_CONFIGFILE;HAVE_VID_CONTEXT;HAVE_DSOUND;HAVE_D3D8"
|
||||
MinimalRebuild="TRUE"
|
||||
BasicRuntimeChecks="3"
|
||||
BasicRuntimeChecks="0"
|
||||
RuntimeLibrary="1"
|
||||
EnableEnhancedInstructionSet="1"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="FALSE"
|
||||
DebugInformationFormat="4"/>
|
||||
DebugInformationFormat="3"/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
|
@ -32,6 +32,7 @@
|
||||
#endif
|
||||
|
||||
wchar_t strw_buffer[128];
|
||||
unsigned font_x, font_y;
|
||||
|
||||
static void check_window(xdk_d3d_video_t *d3d)
|
||||
{
|
||||
@ -131,6 +132,9 @@ static void xdk_d3d_set_viewport(bool force_full)
|
||||
vp.MaxZ = m_zFar;
|
||||
d3d->d3d_render_device->SetViewport(&vp);
|
||||
|
||||
font_x = vp.X;
|
||||
font_y = vp.Y;
|
||||
|
||||
//if(gl->overscan_enable && !force_full)
|
||||
//{
|
||||
// m_left = -gl->overscan_amount/2;
|
||||
@ -346,6 +350,9 @@ static void *xdk_d3d_init(const video_info_t *video, const input_driver_t **inpu
|
||||
d3d->debug_font->SetBkColor(D3DCOLOR_ARGB(100,0,0,0));
|
||||
d3d->debug_font->SetTextHeight(14);
|
||||
d3d->debug_font->SetTextAntialiasLevel(d3d->debug_font->GetTextAntialiasLevel());
|
||||
|
||||
font_x = 0;
|
||||
font_y = 0;
|
||||
#endif
|
||||
|
||||
return d3d;
|
||||
@ -448,10 +455,10 @@ static bool xdk_d3d_frame(void *data, const void *frame,
|
||||
bool ret = false;
|
||||
sprintf(buf, "%.2f MB free / %.2f MB total", stat.dwAvailPhys/(1024.0f*1024.0f), stat.dwTotalPhys/(1024.0f*1024.0f));
|
||||
rarch_convert_char_to_wchar(strw_buffer, buf, sizeof(strw_buffer));
|
||||
d3d->debug_font->TextOut(d3d->pFrontBuffer, strw_buffer, (unsigned)-1, 30, 50 );
|
||||
d3d->debug_font->TextOut(d3d->pBackBuffer, strw_buffer, (unsigned)-1, 30, 50 );
|
||||
d3d->debug_font->TextOut(d3d->pFrontBuffer, strw_buffer, (unsigned)-1, font_x + 30, font_y + 50 );
|
||||
d3d->debug_font->TextOut(d3d->pBackBuffer, strw_buffer, (unsigned)-1, font_x + 30, font_y + 50 );
|
||||
|
||||
if(ret = gfx_window_title(buf2, sizeof(buf2)) || buf_fps_last)
|
||||
if(ret = gfx_window_title(buf2, sizeof(buf2)) || sizeof(buf_fps_last))
|
||||
{
|
||||
if(ret)
|
||||
{
|
||||
@ -459,10 +466,12 @@ static bool xdk_d3d_frame(void *data, const void *frame,
|
||||
rarch_convert_char_to_wchar(strw_buffer, buf2, sizeof(strw_buffer));
|
||||
}
|
||||
else if(buf_fps_last)
|
||||
{
|
||||
rarch_convert_char_to_wchar(strw_buffer, buf_fps_last, sizeof(strw_buffer));
|
||||
}
|
||||
|
||||
d3d->debug_font->TextOut(d3d->pFrontBuffer, strw_buffer, (unsigned)-1, 30, 70 );
|
||||
d3d->debug_font->TextOut(d3d->pBackBuffer, strw_buffer, (unsigned)-1, 30, 70 );
|
||||
d3d->debug_font->TextOut(d3d->pFrontBuffer, strw_buffer, (unsigned)-1, font_x + 30, font_y + 70 );
|
||||
d3d->debug_font->TextOut(d3d->pBackBuffer, strw_buffer, (unsigned)-1, font_x + 30, font_y + 70 );
|
||||
d3d->pFrontBuffer->Release();
|
||||
d3d->pBackBuffer->Release();
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user