Fixed OSX initial window size.
This commit is contained in:
parent
0faf6f53c1
commit
e5801a9d8c
@ -64,13 +64,13 @@ class Occlusion : public entry::AppI
|
||||
{
|
||||
Args args(_argc, _argv);
|
||||
|
||||
m_state.m_width = 1280;
|
||||
m_state.m_height = 720;
|
||||
uint32_t width = 1280;
|
||||
uint32_t height = 720;
|
||||
m_debug = BGFX_DEBUG_TEXT;
|
||||
m_reset = BGFX_RESET_VSYNC;
|
||||
|
||||
bgfx::init(args.m_type, args.m_pciId);
|
||||
bgfx::reset(m_state.m_width, m_state.m_height, m_reset);
|
||||
bgfx::reset(width, height, m_reset);
|
||||
|
||||
// Enable debug text.
|
||||
bgfx::setDebug(m_debug);
|
||||
|
@ -250,7 +250,9 @@ namespace entry
|
||||
struct WindowState
|
||||
{
|
||||
WindowState()
|
||||
: m_nwh(NULL)
|
||||
: m_width(0)
|
||||
, m_height(0)
|
||||
, m_nwh(NULL)
|
||||
{
|
||||
m_handle.idx = UINT16_MAX;
|
||||
}
|
||||
|
@ -469,6 +469,9 @@ namespace entry
|
||||
bx::Thread thread;
|
||||
thread.init(mte.threadFunc, &mte);
|
||||
|
||||
WindowHandle handle = { 0 };
|
||||
m_eventQueue.postSizeEvent(handle, ENTRY_DEFAULT_WIDTH, ENTRY_DEFAULT_HEIGHT);
|
||||
|
||||
while (!(m_exit = [dg applicationHasTerminated]) )
|
||||
{
|
||||
if (bgfx::RenderFrame::Exiting == bgfx::renderFrame() )
|
||||
|
Loading…
Reference in New Issue
Block a user