MCPcopy Create free account
hub / github.com/defold/defold / VulkanSetWindowSize

Function VulkanSetWindowSize

engine/graphics/src/vulkan/graphics_native.cpp:169–188  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

167 }
168
169 void VulkanSetWindowSize(HContext _context, uint32_t width, uint32_t height)
170 {
171 VulkanContext* context = (VulkanContext*) _context;
172
173 if (dmPlatform::GetWindowStateParam(context->m_BaseContext.m_Window, WINDOW_STATE_OPENED))
174 {
175 context->m_BaseContext.m_Width = width;
176 context->m_BaseContext.m_Height = height;
177
178 dmPlatform::SetWindowSize(context->m_BaseContext.m_Window, width, height);
179
180 context->m_WindowWidth = dmPlatform::GetWindowWidth(context->m_BaseContext.m_Window);
181 context->m_WindowHeight = dmPlatform::GetWindowHeight(context->m_BaseContext.m_Window);
182
183 SwapChainChanged(context, &context->m_WindowWidth, &context->m_WindowHeight, 0, 0);
184#if ANDROID
185 SyncAndroidVulkanWindowSize(context);
186#endif
187 }
188 }
189
190 void VulkanResizeWindow(HContext _context, uint32_t width, uint32_t height)
191 {

Callers 1

VulkanResizeWindowFunction · 0.85

Calls 6

SwapChainChangedFunction · 0.85
GetWindowStateParamFunction · 0.50
SetWindowSizeFunction · 0.50
GetWindowWidthFunction · 0.50
GetWindowHeightFunction · 0.50

Tested by

no test coverage detected