diff options
author | ericu@google.com <ericu@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-22 20:49:41 +0000 |
---|---|---|
committer | ericu@google.com <ericu@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-22 20:49:41 +0000 |
commit | 0ee2861b2b02700e8df8b4c6bcc956223bf0f22a (patch) | |
tree | d4a62b7ff9cfeef99b18676ca03c70a28a6eb3a0 /o3d | |
parent | ce2644e0189ee4b8c03f1bc75d6dfff319eaade3 (diff) | |
download | chromium_src-0ee2861b2b02700e8df8b4c6bcc956223bf0f22a.zip chromium_src-0ee2861b2b02700e8df8b4c6bcc956223bf0f22a.tar.gz chromium_src-0ee2861b2b02700e8df8b4c6bcc956223bf0f22a.tar.bz2 |
Review URL: http://codereview.chromium.org/140024
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18953 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'o3d')
-rw-r--r-- | o3d/core/win/d3d9/renderer_d3d9.cc | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/o3d/core/win/d3d9/renderer_d3d9.cc b/o3d/core/win/d3d9/renderer_d3d9.cc index 8001043..ec2c0d3 100644 --- a/o3d/core/win/d3d9/renderer_d3d9.cc +++ b/o3d/core/win/d3d9/renderer_d3d9.cc @@ -986,8 +986,8 @@ Renderer::InitStatus RendererD3D9::InitPlatformSpecific( 1 /* MIP levels */, FALSE, DEFAULT_CHARSET, - OUT_DEFAULT_PRECIS, - DEFAULT_QUALITY, + OUT_TT_PRECIS, + PROOF_QUALITY, DEFAULT_PITCH | FF_DONTCARE /* pitch and font family */, L"Arial", &fullscreen_message_font_)) { @@ -1427,10 +1427,7 @@ void RendererD3D9::ShowFullscreenMessage() { const float midline_width = width() / 2.0f; const D3DXCOLOR background_color(0.0f, 0.0f, 0.0f, 0.5f); SetRect(&rect, 0, 0, width(), height()); - // Drawing the message before the background puts it on top. - HR(fullscreen_message_font_->DrawText(NULL, - L"Press ESC to exit full screen mode.", -1, &rect, - DT_CENTER | DT_VCENTER, D3DXCOLOR(1.0f, 1.0f, 1.0f, 1.0f))); + D3DXVECTOR2 line_vertices[2]; HR(fullscreen_message_line_->SetWidth(line_base_height)); line_vertices[0].x = midline_width - 400.0f - curve_radius; @@ -1453,6 +1450,16 @@ void RendererD3D9::ShowFullscreenMessage() { HR(fullscreen_message_line_->Draw(line_vertices, 2, background_color)); } HR(fullscreen_message_line_->End()); + + DWORD z_enable; // Back up this setting and restore it afterward. + d3d_device_->GetRenderState(D3DRS_ZENABLE, &z_enable); + d3d_device_->SetRenderState(D3DRS_ZENABLE, FALSE); + + HR(fullscreen_message_font_->DrawText(NULL, + L"Press ESC to exit full screen mode.", -1, &rect, + DT_CENTER | DT_VCENTER, D3DXCOLOR(1.0f, 1.0f, 1.0f, 1.0f))); + + d3d_device_->SetRenderState(D3DRS_ZENABLE, z_enable); } // Notifies DX9 that rendering of the frame is complete and swaps the buffers. |