mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-12-03 01:13:22 +00:00
- fix nullptr crash in player.camera reference when player.camera is nullptr
This commit is contained in:
parent
f954df7a00
commit
7c9d8a0b99
2 changed files with 4 additions and 2 deletions
|
@ -256,6 +256,7 @@ sector_t *FGLRenderer::RenderView(player_t* player)
|
|||
NoInterpolateView = false;
|
||||
|
||||
// Shader start time does not need to be handled per level. Just use the one from the camera to render from.
|
||||
if (player->camera)
|
||||
gl_RenderState.CheckTimer(player->camera->Level->ShaderStartTime);
|
||||
// prepare all camera textures that have been used in the last frame.
|
||||
// This must be done for all levels, not just the primary one!
|
||||
|
|
|
@ -404,6 +404,7 @@ sector_t *VulkanFrameBuffer::RenderView(player_t *player)
|
|||
NoInterpolateView = false;
|
||||
|
||||
// Shader start time does not need to be handled per level. Just use the one from the camera to render from.
|
||||
if (player->camera)
|
||||
GetRenderState()->CheckTimer(player->camera->Level->ShaderStartTime);
|
||||
// prepare all camera textures that have been used in the last frame.
|
||||
// This must be done for all levels, not just the primary one!
|
||||
|
|
Loading…
Reference in a new issue