This commit is contained in:
Branimir Karadžić 2017-06-29 23:19:20 -07:00
parent e9a0f266bb
commit 0fad539078
34 changed files with 66 additions and 70 deletions

View File

@ -70,7 +70,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
@ -105,7 +105,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -161,7 +161,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
@ -234,7 +234,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -557,7 +557,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
@ -768,7 +768,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -174,7 +174,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
// Set view 0 default viewport.
@ -240,7 +240,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -84,7 +84,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
@ -140,7 +140,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -141,7 +141,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
@ -243,7 +243,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -193,7 +193,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
@ -348,7 +348,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -360,7 +360,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
@ -593,7 +593,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -305,7 +305,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(
ImVec2(m_width - m_width / 5.0f - 10.0f, 10.0f)
@ -533,7 +533,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -228,7 +228,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
@ -332,7 +332,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -138,7 +138,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(
ImVec2(m_width - m_width / 5.0f - 10.0f, 10.0f)
@ -256,7 +256,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -140,7 +140,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(
ImVec2(m_width - m_width / 5.0f - 10.0f, 10.0f)
@ -284,7 +284,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -922,7 +922,7 @@ public:
, uint16_t(m_viewState.m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(
ImVec2(m_viewState.m_width - m_viewState.m_width / 5.0f - 10.0f, 10.0f)
@ -1354,7 +1354,7 @@ public:
clearViewMask(s_clearMask, BGFX_CLEAR_NONE, m_clearValues);
s_clearMask = 0;
return !restart;
return true;
}
return false;

View File

@ -2162,7 +2162,7 @@ public:
, uint16_t(m_viewState.m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(ImVec2(m_viewState.m_width - 256.0f, 10.0f) );
ImGui::Begin("Settings"
@ -2860,7 +2860,7 @@ public:
, m_clearValues.m_clearStencil
);
return !restart;
return true;
}
return false;

View File

@ -265,7 +265,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
@ -409,7 +409,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -1980,7 +1980,7 @@ public:
, m_viewState.m_height
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(
ImVec2(m_viewState.m_width - m_viewState.m_width / 5.0f - 10.0f, 10.0f)
@ -3203,7 +3203,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -218,7 +218,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(ImVec2((float)m_width - (float)m_width / 4.0f - 10.0f, 10.0f) );
ImGui::SetNextWindowSize(ImVec2((float)m_width / 4.0f, (float)m_height / 2.0f) );
@ -315,7 +315,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -588,7 +588,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(
ImVec2(m_width - m_width / 5.0f - 10.0f, 10.0f)
@ -893,7 +893,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -287,7 +287,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(
ImVec2(m_width - m_width / 5.0f - 10.0f, 10.0f)
@ -481,7 +481,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -1305,7 +1305,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
@ -1330,7 +1330,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -371,7 +371,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
int64_t now = bx::getHPCounter();
static int64_t last = now;
@ -712,7 +712,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -182,7 +182,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
@ -311,7 +311,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -102,7 +102,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
@ -192,7 +192,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -257,7 +257,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
const bgfx::Caps* caps = bgfx::getCaps();
const bool computeSupported = !!(caps->supported & BGFX_CAPS_COMPUTE);
@ -446,7 +446,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -171,7 +171,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
@ -282,7 +282,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -402,7 +402,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(
ImVec2(m_width - m_width / 5.0f - 10.0f, 10.0f)
@ -483,7 +483,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -405,7 +405,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(
ImVec2(m_width - m_width / 5.0f - 10.0f, 10.0f)
@ -522,7 +522,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -108,7 +108,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
imguiEndFrame();
@ -290,7 +290,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -365,7 +365,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(
ImVec2(m_width - m_width / 5.0f - 10.0f, 10.0f)
@ -389,7 +389,7 @@ public:
// process submitted rendering primitives.
m_currFrame = bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -589,7 +589,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(
ImVec2(m_width - m_width / 5.0f - 10.0f, 10.0f)
@ -616,7 +616,7 @@ public:
// process submitted rendering primitives.
m_currFrame = bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -365,7 +365,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(
ImVec2(m_width - m_width / 4.0f - 10.0f, 10.0f)
@ -434,7 +434,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -261,7 +261,7 @@ public:
, uint16_t(m_height)
);
bool restart = showExampleDialog(this);
showExampleDialog(this);
ImGui::SetNextWindowPos(
ImVec2(m_width - m_width / 5.0f - 10.0f, 10.0f)
@ -356,7 +356,7 @@ public:
// process submitted rendering primitives.
bgfx::frame();
return !restart;
return true;
}
return false;

View File

@ -8,10 +8,8 @@
#include "entry/cmd.h"
#include <bx/string.h>
bool showExampleDialog(entry::AppI* _app)
void showExampleDialog(entry::AppI* _app)
{
bool restart = false;
char temp[1024];
bx::snprintf(temp, BX_COUNTOF(temp), "Example: %s", _app->getName() );
@ -102,6 +100,4 @@ bool showExampleDialog(entry::AppI* _app)
);
ImGui::End();
return restart;
}

View File

@ -55,7 +55,7 @@ void imguiBeginFrame(int32_t _mx, int32_t _my, uint8_t _button, int32_t _scroll,
void imguiEndFrame();
namespace entry { class AppI; }
bool showExampleDialog(entry::AppI* _app);
void showExampleDialog(entry::AppI* _app);
namespace ImGui
{