Vuo
2.4.4
Loading...
Searching...
No Matches
runtime
VuoRuntimeContext.hh
Go to the documentation of this file.
1
10
#pragma once
11
12
extern
"C"
13
{
14
18
typedef
enum
{
19
PortContext_EventBlocking_None
,
20
PortContext_EventBlocking_Door
,
21
PortContext_EventBlocking_Wall
,
22
PortContext_EventBlocking_NotApplicable
23
}
PortContext_EventBlocking
;
24
28
struct
PortContext
29
{
30
bool
event
;
31
void
*
data
;
32
bool
dataRetained
;
33
dispatch_queue_t
triggerQueue
;
34
dispatch_semaphore_t
triggerSemaphore
;
35
void
*
triggerFunction
;
36
PortContext_EventBlocking
eventBlocking
;
37
};
38
42
struct
NodeContext
43
{
44
struct
PortContext
**
portContexts
;
45
unsigned
long
portContextCount
;
46
void
*
instanceData
;
47
void
*
nodeMutex
;
48
void
*
nodeConditionVariable
;
49
unsigned
long
claimingEventId
;
50
dispatch_group_t
executingGroup
;
51
void
*
executingEventIds
;
52
bool
*
outputEvents
;
53
54
void
*
executingEventIdsSync
;
55
};
56
57
struct
PortContext
*
vuoCreatePortContext
(
void
*
data
,
bool
isTrigger,
const
char
*triggerQueueName);
58
struct
NodeContext
*
vuoCreateNodeContext
(
bool
hasInstanceData,
bool
isComposition,
size_t
outputEventCount);
59
void
vuoFreePortContext
(
struct
PortContext
*portContext);
60
void
vuoFreeNodeContext
(
struct
NodeContext
*nodeContext);
61
void
vuoSetPortContextEvent
(
struct
PortContext
*portContext,
bool
event);
62
void
vuoSetPortContextData
(
struct
PortContext
*portContext,
void
*data);
63
void
vuoSetPortContextTriggerFunction
(
struct
PortContext
*portContext,
void
*triggerFunction);
64
bool
vuoGetPortContextEvent
(
struct
PortContext
*portContext);
65
void
*
vuoGetPortContextData
(
struct
PortContext
*portContext);
66
dispatch_queue_t
vuoGetPortContextTriggerQueue
(
struct
PortContext
*portContext);
67
dispatch_semaphore_t
vuoGetPortContextTriggerSemaphore
(
struct
PortContext
*portContext);
68
void
*
vuoGetPortContextTriggerFunction
(
struct
PortContext
*portContext);
69
void
vuoSetPortContextEventBlocking
(
struct
PortContext
*portContext,
PortContext_EventBlocking
eventBlocking);
70
void
vuoRetainPortContextData
(
struct
PortContext
*portContext);
71
72
void
vuoSetNodeContextPortContexts
(
struct
NodeContext
*nodeContext,
struct
PortContext
**
portContexts
,
unsigned
long
portContextCount
);
73
void
vuoSetNodeContextInstanceData
(
struct
NodeContext
*nodeContext,
void
*
instanceData
);
74
void
vuoSetNodeContextClaimingEventId
(
struct
NodeContext
*nodeContext,
unsigned
long
claimingEventId
);
75
void
vuoSetNodeContextOutputEvent
(
struct
NodeContext
*nodeContext,
size_t
index,
bool
event);
76
struct
PortContext
*
vuoGetNodeContextPortContext
(
struct
NodeContext
*nodeContext,
size_t
index);
77
void
*
vuoGetNodeContextInstanceData
(
struct
NodeContext
*nodeContext);
78
unsigned
long
vuoGetNodeContextClaimingEventId
(
struct
NodeContext
*nodeContext);
79
dispatch_group_t
vuoGetNodeContextExecutingGroup
(
struct
NodeContext
*nodeContext);
80
bool
vuoGetNodeContextOutputEvent
(
struct
NodeContext
*nodeContext,
size_t
index);
81
82
bool
vuoEventHitAnyInputPort
(
NodeContext
*nodeContext);
83
bool
vuoEventHitInputPort
(
NodeContext
*nodeContext,
PortContext_EventBlocking
eligibleEventBlocking);
84
void
vuoSetOutputEventsAfterNodeExecution
(
NodeContext
*nodeContext);
85
void
vuoResetNodeContextEvents
(
struct
NodeContext
*nodeContext);
86
87
void
vuoStartedExecutingEvent
(
struct
NodeContext
*nodeContext,
unsigned
long
eventId);
88
void
vuoSpunOffExecutingEvent
(
struct
NodeContext
*nodeContext,
unsigned
long
eventId);
89
bool
vuoFinishedExecutingEvent
(
struct
NodeContext
*nodeContext,
unsigned
long
eventId);
90
unsigned
long
vuoGetOneExecutingEvent
(
struct
NodeContext
*nodeContext);
91
92
}
Generated on Thu Nov 9 2023 16:59:30 for Vuo by
1.9.8