| 248 | } |
| 249 | |
| 250 | void ShutdownInstance() { |
| 251 | app.FreeResources(); |
| 252 | |
| 253 | #ifdef CREATE_SUB_WINDOW |
| 254 | if (subContext) { |
| 255 | BE1::rhi.DestroyRenderTarget(subRenderTarget); |
| 256 | |
| 257 | HWND hwnd = (HWND)BE1::rhi.GetWindowHandleFromContext(subContext); |
| 258 | BE1::rhi.DestroyContext(subContext); |
| 259 | |
| 260 | ::DestroyWindow(hwnd); |
| 261 | } |
| 262 | #endif |
| 263 | |
| 264 | if (mainContext) { |
| 265 | BE1::rhi.DestroyRenderTarget(mainRenderTarget); |
| 266 | |
| 267 | HWND hwnd = (HWND)BE1::rhi.GetWindowHandleFromContext(mainContext); |
| 268 | BE1::rhi.DestroyContext(mainContext); |
| 269 | |
| 270 | ::DestroyWindow(hwnd); |
| 271 | } |
| 272 | |
| 273 | app.Shutdown(); |
| 274 | |
| 275 | BE1::Engine::ShutdownBase(); |
| 276 | } |
| 277 | |
| 278 | int APIENTRY _tWinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPTSTR lpCmdLine, int nCmdShow) { |
| 279 | UNREFERENCED_PARAMETER(hPrevInstance); |
no test coverage detected