mirror of
https://github.com/libretro/RetroArch
synced 2025-04-16 17:43:02 +00:00
Some small opts to two conditionals
This commit is contained in:
parent
724acc4eb9
commit
5d4c6a9564
@ -193,8 +193,8 @@ static void vulkan_emulated_mailbox_loop(void *userdata)
|
|||||||
for (;;)
|
for (;;)
|
||||||
{
|
{
|
||||||
slock_lock(mailbox->lock);
|
slock_lock(mailbox->lock);
|
||||||
while ( !(mailbox->flags & VK_MAILBOX_FLAG_DEAD)
|
while ( !(mailbox->flags & VK_MAILBOX_FLAG_DEAD)
|
||||||
&& !(mailbox->flags & VK_MAILBOX_FLAG_REQUEST_ACQUIRE))
|
&& !(mailbox->flags & VK_MAILBOX_FLAG_REQUEST_ACQUIRE))
|
||||||
scond_wait(mailbox->cond, mailbox->lock);
|
scond_wait(mailbox->cond, mailbox->lock);
|
||||||
|
|
||||||
if (mailbox->flags & VK_MAILBOX_FLAG_DEAD)
|
if (mailbox->flags & VK_MAILBOX_FLAG_DEAD)
|
||||||
@ -2905,7 +2905,7 @@ bool vulkan_create_swapchain(gfx_ctx_vulkan_data_t *vk,
|
|||||||
vulkan_create_wait_fences(vk);
|
vulkan_create_wait_fences(vk);
|
||||||
|
|
||||||
if ( (vk->flags & VK_DATA_FLAG_EMULATING_MAILBOX)
|
if ( (vk->flags & VK_DATA_FLAG_EMULATING_MAILBOX)
|
||||||
&& vk->mailbox.swapchain == VK_NULL_HANDLE)
|
&& (vk->mailbox.swapchain == VK_NULL_HANDLE))
|
||||||
{
|
{
|
||||||
vulkan_emulated_mailbox_init(
|
vulkan_emulated_mailbox_init(
|
||||||
&vk->mailbox, vk->context.device, vk->swapchain);
|
&vk->mailbox, vk->context.device, vk->swapchain);
|
||||||
@ -2920,7 +2920,7 @@ bool vulkan_create_swapchain(gfx_ctx_vulkan_data_t *vk,
|
|||||||
/* We are tearing down, and entering a state
|
/* We are tearing down, and entering a state
|
||||||
* where we are supposed to have
|
* where we are supposed to have
|
||||||
* acquired an image, so block until we have acquired. */
|
* acquired an image, so block until we have acquired. */
|
||||||
if (!(vk->context.flags & VK_CTX_FLAG_HAS_ACQUIRED_SWAPCHAIN))
|
if (! (vk->context.flags & VK_CTX_FLAG_HAS_ACQUIRED_SWAPCHAIN))
|
||||||
if (vk->mailbox.swapchain != VK_NULL_HANDLE)
|
if (vk->mailbox.swapchain != VK_NULL_HANDLE)
|
||||||
res = vulkan_emulated_mailbox_acquire_next_image_blocking(
|
res = vulkan_emulated_mailbox_acquire_next_image_blocking(
|
||||||
&vk->mailbox,
|
&vk->mailbox,
|
||||||
|
@ -3690,7 +3690,7 @@ static void netplay_sync_post_frame(netplay_t *netplay, bool stalled)
|
|||||||
if (netplay->catch_up)
|
if (netplay->catch_up)
|
||||||
{
|
{
|
||||||
netplay->catch_up = false;
|
netplay->catch_up = false;
|
||||||
input_state_get_ptr()->flags &= ~INP_FLAG_NONBLOCKING;
|
input_state_get_ptr()->flags &= ~INP_FLAG_NONBLOCKING;
|
||||||
driver_set_nonblock_state();
|
driver_set_nonblock_state();
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
@ -4008,8 +4008,7 @@ static void remote_unpaused(netplay_t *netplay,
|
|||||||
for (i = 0; i < netplay->connections_size; i++)
|
for (i = 0; i < netplay->connections_size; i++)
|
||||||
{
|
{
|
||||||
struct netplay_connection *sc = &netplay->connections[i];
|
struct netplay_connection *sc = &netplay->connections[i];
|
||||||
if ( (sc->flags & NETPLAY_CONN_FLAG_ACTIVE)
|
if (sc->flags & (NETPLAY_CONN_FLAG_ACTIVE | NETPLAY_CONN_FLAG_PAUSED))
|
||||||
&& (sc->flags & NETPLAY_CONN_FLAG_PAUSED))
|
|
||||||
{
|
{
|
||||||
netplay->remote_paused = true;
|
netplay->remote_paused = true;
|
||||||
break;
|
break;
|
||||||
@ -7134,8 +7133,8 @@ static void netplay_frontend_paused(netplay_t *netplay, bool paused)
|
|||||||
for (i = 0; i < netplay->connections_size; i++)
|
for (i = 0; i < netplay->connections_size; i++)
|
||||||
{
|
{
|
||||||
struct netplay_connection *connection = &netplay->connections[i];
|
struct netplay_connection *connection = &netplay->connections[i];
|
||||||
if ( (connection->flags & NETPLAY_CONN_FLAG_ACTIVE)
|
if (connection->flags &
|
||||||
&& (connection->flags & NETPLAY_CONN_FLAG_PAUSED))
|
(NETPLAY_CONN_FLAG_ACTIVE | NETPLAY_CONN_FLAG_PAUSED))
|
||||||
paused_ct++;
|
paused_ct++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user