libtcspc.Broadcast

final class libtcspc.Broadcast(*event_types, outputs)[source]

Bases: Node

Broadcasts every event to several downstream processors.

Each event received is forwarded to every connected downstream. Likewise, end-of-input is propagated to every downstream.

Parameters:
  • *event_types (EventType) – The event types to broadcast. Every output must be connected to a downstream that handles all of these types.

  • outputs (int or Sequence[str]) – The output ports. An integer N creates N ports named "output-0" through "output-(N-1)". A sequence of names creates ports with those exact names. Must specify at least one output.

Notes

Events handled:

  • Events matching one of event_types: broadcast to every downstream.

  • Events not in event_types: rejected at graph build time.

  • End of input: broadcast to every downstream.

See also

tcspc::broadcast()

The underlying C++ factory function.