HP SVA V2.0 Parallel Compositing Reference Guide

pcContextSync(3)
NAME
pcContextSync -- Synchronizes context changes for all hosts.
Synopsis
PCerr pcContextSync(
PCcontext ctx
);
Parameters
ctx
The context whose properties are to be synchronized.
Returns
This function returns PC_NO_ERROR on successful completion.
Description
The Library supports any of the hosts making changes to the values of Context Properties. Since
each of the hosts can run on a separate machine, a mechanism is needed to coordinate any changes
across all the hosts that are members of the context. This is the purpose of pcContextSync.
Hosts make changes to the context by calling pcContextSetInteger or pcContextSetString.
Typically, one host changes global properties, such as PC_FRAME_HEIGHT and PC_FRAME_WIDTH.
This host may also set the host-specific PC_OUTPUT… properties for each host. Following these
changes, the host calls pcContextSync. The remaining hosts that want to receive these changed
properties call pcContextSync, followed by a series of calls to pcContextGetInteger or
pcContextGetString.
pcContextSync effectively acts as synchronization barrier to coordinate these calls. If
pcContextSync is called by one host, it must be called by all hosts. At the point the host setting
the properties calls pcContextSync, the changes made by this host are flushed to all of the
hosts. The hosts reading the context properties do not progress beyond the pcContextSync
until the changed parameters have been received.
Note the following:
Hosts do not block on the pcContextSync call. Instead, they block (if necessary) on any
attempt to use a context property until after the context has been updated on that host.
There is an implicit pcContextSync executed immediately following a pcFrameBegin
call, so there is no need to sync before starting a frame.
If more than one host sets a specific context property, the results are undefined.
The HP implementation returns an error when more than one host sets the same property.
A host may not call pcContextSync between pcFrameBegin and pcFrameEnd.
55