Close

Sync CHOPs Common

The Sync In CHOP and Sync Out CHOP are used to keep timelines in two or more TouchDesigner processes within a single frame of each other. One process will contain a Sync Out CHOP while one or more other processes contain Sync In CHOPs. The processes with Sync In CHOPs should have their Realtime flag checked off, as their frame rates will be determined by the Sync Out CHOP. Also note, all monitors (including all clients and server) should be set to the same rate. Note that unplugging or re-adding monitors may sometime change previously configured settings.

The CHOPs synchronize by pausing their own timeline until all Sync In/Out CHOPs have cooked. The Sync Out CHOP will be ahead of the Sync In CHOPs. If any CHOPs fail to communicate, the others will timeout, causing all processes to run slowly.

Client machines may come online at any point, or be switched off as desired, as the Sync Out CHOP will adjust accordingly, either timing out, temporarily or permanently banning individual clients as specified.

In addition any extra CHOP channels sent through the Sync Out CHOP is received by the Sync In CHOPs.

NOTE for Windows OS - If experiencing connection issues make sure Windows Firewall is disabled.

An Info DAT, pointing to the Sync Out CHOP, provides a detailed list of all clients:

The columns are:

  • pid: process id of the client
  • address: ip and port number
  • machine_name: client machine name
  • filename: name of the .toe file the client resides in
  • op_path: full operator path to the client
  • include: when 1, the Sync Out CHOPs waits for a reply, when 0, it is ignored.
  • timeout_total: The total number of times the Sync Out CHOP stalled waiting for this client
  • timeout_consecutive: The running number of times the Sync Out CHOP stalled waiting for this client.
  • steady_total: The total number of times the Sync Out CHOP received a reply in time.
  • steady_consecutive: The running number of times the Sync Out CHOP received a reply in time:
  • reply: The last reply from the client, all clients should have the same increasing value.


Similarly, an Info CHOP will reveal further information: Info CHOP Channels

Example Filesedit

Here are two simple example files that use Sync In and Out CHOPs. You would run the SyncServer.toe only once, and run the SyncClient.toe for every machine you want to display on. Note that you may need to adjust the Window COMP located at /perform to output to your desired monitor. Also note that Hardware Frame Lock is not enabled in these examples, so if you want to use that feature you'll need to turn that parameter on in the Window COMP for SyncClient.toe as well.

File:SyncServer.toe
File:SyncClient.toe

Intermittent Connectionsedit

Whenever a client replies, it is immediately assumed reliable, and waited upon, by the Sync Out CHOP each frame thereafter. When a client times-out a number of times in a row, however, it is continuously ignored by the Sync Out CHOP, until it replies on time again. This also applies to clients that have stopped communicating altogether. The number of consecutive timeouts is controlled by the Client Timeouts (consecutive) parameter and is reflected by the timeout_consecutive Info DAT column.

Fixing Dropped frames on Clientedit

If a particular client is dropping frames, inspect the Sync Out CHOP on the server side with an info DAT. Look at the column for timeout_consecutive. As well take note of the info chop channel for the sync in CHOP called sync_incompletes. If one or both of these attributes are increasing, try adjusting the TimeOut parameter on the sync CHOP. Increasing this value has been known to remedy this issue.

Banningedit

If a client produces unreliable communication, sometimes steady, sometimes timing out, then it can be permanently ignored by enabling Ban Clients and setting the Total Timeouts accordingly. Once a client timeouts a certain number of times, its Info DAT include column reports banned and it will always be ignored, even if it starts responding in time again.

Resettingedit

Whenever the Sync Out CHOP first starts any and all clients are accepted, and nothing is banned. Pressing Clear Stats in the Sync Out CHOP also returns to this state, clearing all banned lists, and totals, even in the remote client Info CHOPs.

See also Syncing Multiple Computers and Hardware Frame Lock.