Examples: Refactored directx11_example to be easier to copy & paste into user application.

This commit is contained in:
ocornut
2015-03-09 13:45:23 +00:00
parent 567184dc9f
commit b4165c43ff
7 changed files with 512 additions and 459 deletions

View File

@@ -90,7 +90,6 @@ static void ImGui_ImplDX9_RenderDrawLists(ImDrawList** const cmd_lists, int cmd_
int vtx_offset = 0;
for (int n = 0; n < cmd_lists_count; n++)
{
// Render command list
const ImDrawList* cmd_list = cmd_lists[n];
for (size_t cmd_i = 0; cmd_i < cmd_list->commands.size(); cmd_i++)
{
@@ -184,7 +183,7 @@ bool ImGui_ImplDX9_Init(void* hwnd, IDirect3DDevice9* device)
if (!QueryPerformanceCounter((LARGE_INTEGER *)&g_Time))
return false;
// FIXME
// FIXME: resizing
RECT rect;
GetClientRect((HWND)hwnd, &rect);
int display_w = (int)(rect.right - rect.left);