diff options
author | 2023-01-05 05:12:10 +0100 | |
---|---|---|
committer | 2023-01-04 23:12:10 -0500 | |
commit | 5581eaa50a42256242f32569f59ce10d70ddd8c2 (patch) | |
tree | 0d79e41b381ebf6d50ab5b7e20c0993b7328b5b6 /3rdparty/bgfx/examples/common/entry/entry_android.cpp | |
parent | 34c37d4f5415f886ec3ae462b008cebbf5fa22f9 (diff) |
Update BGFX, BX and BIMG (#10750)
* Update to bgfx a93a714632b79b5ddbf5c86ac323fa9b76ed3433
Co-authored-by: Бранимир Караџић <branimirkaradzic@gmail.com>
Diffstat (limited to '3rdparty/bgfx/examples/common/entry/entry_android.cpp')
-rw-r--r-- | 3rdparty/bgfx/examples/common/entry/entry_android.cpp | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/3rdparty/bgfx/examples/common/entry/entry_android.cpp b/3rdparty/bgfx/examples/common/entry/entry_android.cpp index cd2baf9044f..3a6ac8561d3 100644 --- a/3rdparty/bgfx/examples/common/entry/entry_android.cpp +++ b/3rdparty/bgfx/examples/common/entry/entry_android.cpp @@ -1,14 +1,12 @@ /* - * Copyright 2011-2021 Branimir Karadzic. All rights reserved. - * License: https://github.com/bkaradzic/bgfx#license-bsd-2-clause + * Copyright 2011-2022 Branimir Karadzic. All rights reserved. + * License: https://github.com/bkaradzic/bgfx/blob/master/LICENSE */ #include "entry_p.h" #if ENTRY_CONFIG_USE_NATIVE && BX_PLATFORM_ANDROID -#include <bgfx/platform.h> - #include <bx/thread.h> #include <bx/file.h> @@ -29,18 +27,6 @@ extern "C" namespace entry { - /// - inline void androidSetWindow(::ANativeWindow* _window) - { - bgfx::PlatformData pd; - pd.ndt = NULL; - pd.nwh = _window; - pd.context = NULL; - pd.backBuffer = NULL; - pd.backBufferDS = NULL; - bgfx::setPlatformData(pd); - } - struct GamepadRemap { uint16_t m_keyCode; @@ -233,7 +219,6 @@ namespace entry if (m_window != m_app->window) { m_window = m_app->window; - androidSetWindow(m_window); int32_t width = ANativeWindow_getWidth(m_window); int32_t height = ANativeWindow_getHeight(m_window); @@ -550,6 +535,21 @@ namespace entry BX_UNUSED(_handle, _lock); } + void* getNativeWindowHandle(WindowHandle _handle) + { + if (kDefaultWindowHandle.idx == _handle.idx) + { + return s_ctx.m_window; + } + + return NULL; + } + + void* getNativeDisplayHandle() + { + return NULL; + } + int32_t MainThreadEntry::threadFunc(bx::Thread* _thread, void* _userData) { BX_UNUSED(_thread); |