cyndilib.finder
#
Source#
- class cyndilib.finder.Source#
Bases:
object
Represents an NDI® source
- set_preview_tally(self, bool value)#
Set the source’s preview tally to the given state
Note
This is only valid for sources attached to an active
receiver.Receiver
- set_program_tally(self, bool value)#
Set the source’s program tally to the given state
Note
This is only valid for sources attached to an active
receiver.Receiver
Finder#
- class cyndilib.finder.Finder#
Bases:
object
Discovers NDI® sources available on the network
- change_callback#
A callback to be used when sources are added or removed
- finder_thread#
The thread used to make blocking calls to update sources
- close(self)#
Closes the
finder_thread
- get_source_names(self)#
Get the discovered sources as a
list[str]
- open(self)#
Starts the
finder_thread
and begins searching for sources
- set_change_callback(self, cb)#
Set the
change_callback
- update_sources(self)#
Manually update the current sources tracked by the NDI® library
Warning
This method should typically not be called directly and especially not if the
finder_thread
is in use.
- wait(self, timeout=None)#
Wait for a source to be added or removed
- wait_for_sources(self, float timeout)#
Wait for the NDI® library to report a change in its source list
If a change was detected a call to
update_sources()
should follow.- Parameters:
timeout (float) – Time (in seconds) to block before a change is detected
- Returns:
Flag indicating if a change was detected before the timout was reached
- Return type:
Warning
This method should typically not be called directly and especially not if the
finder_thread
is in use.