Nebula
Loading...
Searching...
No Matches
semaphore.h
Go to the documentation of this file.
1#pragma once
2//------------------------------------------------------------------------------
11//------------------------------------------------------------------------------
12#include "ids/id.h"
13#include "barrier.h"
14
15#ifdef CreateSemaphore
16#pragma push_macro("CreateSemaphore")
17#undef CreateSemaphore
18#endif
19
20namespace CoreGraphics
21{
22
24
26{
27 Binary, // binary semaphore means it can only be signaled or unsignaled
28 Timeline // a timeline semaphore
29};
30
32{
33#if NEBULA_GRAPHICS_DEBUG
34 const char* name = nullptr;
35#endif
37};
38
42void DestroySemaphore(const SemaphoreId& semaphore);
43
45uint64 SemaphoreGetValue(const SemaphoreId& semaphore);
47void SemaphoreSignal(const SemaphoreId& semaphore);
49void SemaphoreReset(const SemaphoreId& semaphore);
50
51} // namespace CoreGraphics
52
53#pragma pop_macro("CreateSemaphore")
#define ID_24_8_TYPE(x)
Definition id.h:132
Acceleration structures are used to enable ray tracing on the GPU by dividing the scene into a BVH.
Definition accelerationstructure.h:24
void SemaphoreSignal(const SemaphoreId &semaphore)
signal semaphore
Definition vksemaphore.cc:104
uint64 SemaphoreGetValue(const SemaphoreId &semaphore)
get semaphore index
Definition vksemaphore.cc:95
void SemaphoreReset(const SemaphoreId &semaphore)
reset semaphore
Definition vksemaphore.cc:121
void DestroySemaphore(const SemaphoreId &semaphore)
destroy semaphore
Definition vksemaphore.cc:85
SemaphoreId CreateSemaphore(const SemaphoreCreateInfo &info)
create semaphore
Definition vksemaphore.cc:37
SemaphoreType
Definition semaphore.h:26
@ Binary
Definition semaphore.h:27
@ Timeline
Definition semaphore.h:28
Definition semaphore.h:32
SemaphoreType type
Definition semaphore.h:36
Definition semaphore.h:23
uint64_t uint64
Definition types.h:36