BMD API starting with 12.0 support 64 channels so enable it when using
eligible SDK.
UG ships currently 11.6 so it won't be enabled by default but user can
ship own version.
+ replaced unneeded checks in display_decklink_reconfigure_audio
with assert (not needed, this should not happen because the format is
negotiated with `get_property(AUDIO_FORMAT)`` first)
As for now, it breaks things when using OPUS, eg on DeckLink 4K Extrme:
```
uv -t testcard:mode=Hi59 -s embedded -A OPUS -d decklink:sync -r embedded
```
Poorly synchronized input, especially when there is a timing jitter,
like sdl_mixer will stop to be played properly, but this isn't actually
purpose of this mode so it isn't perhaps a good idea to complicate the
things by adding some error-prone stuff.
Keep own copy of original and working (with wraparounds) audio TS in
order not to fight with the video over the shared variable - reconfigure
only if there is a change.
modernized video display, audio playback and vo postprocess APIs
THe APIs were already recently updated so modernize it by using bool
where the return value is semantically boolean value. Using TRUE/FALSE is
inherently ambiguous because it is not obvious from the prototype if
success is 0 or TRUE (1).
Replace [no-]low-latency option with synchronized opt - the behavior
of the no-low-latency mode has changed, anyways, so as a benefit it is
more obvious.
When the timestamp difference is too large, do not sync at all and
schedule continuously. This has been already there but the difference
wasn't allowed to be more than 2000.
In scheduled mode, we need to restart stream after configuring audio. The
previous implemenation was rather error-prone because if the audio was
configured after video, it didn't work. Now it simplifies the workflow.
This also fixes a potential crash when DisableVideoOutput in reconfigure
was called after deleting the delegate structure.
When there is a missing frame, seq is incremented but the actual time
base may have diverged.
Similarly to dropped frame - one frame is elapsed but the time base
didn't reflect that, because it was dropped.
video only, audio support will be readded later
Rewritten scheduled playback - instead of pushing the frames and guessing
the playback time as it has been before, store the frames inside and let
the completition callback pull when needed.
removed multi-device mode
This was perhaps no longer used by anyone and so it needlessly
complicated the code. Also if needed, there is an alternative in use of
aggregate (although more verbose), eg.:
```
uv -d aggregate -d decklink:device=0 -d decklink:device=1 -d \
decklink:device=2 -d decklink:device=3
```
Print overflow details (nr of samples written/dropped/buffered) only in
verbose mode. The point is that those values will differ and if there is
a moment where overflow occurs, it is better to colligate the overflow
messages into one and only to see the details in verbose mode, otherwise
the output could be flooded with the messages.
Allow passing of arbitrary option to DeckLink configuration, eg.:
uv -t decklink:cptm=pdir
via FourCC option name and value (may be also a flag or an int). The
option is passed directly to BMD API.
+ [disp] the condition `s->profile_req == bmdProfileOneSubDeviceHalfDuplex`
was probably inverted - there should perhaps be unequality, because if
not set otherwise, that option is set for quad-link by default
+ when setting the profile automatically, use detected/actual link
configuration to check quad-link, not use the value set by us (may be
set in BMD settings)
+ sort conf_name_map alphabetically
Do not link bmdDeckLinkConfigLowLatencyVideoOutput with `-d decklink:low_latency`
option because these features are not necessarily related - the BMD
feature (according to the docs) is even not honored by recent devices
and doesn't have an impact on our "low_latency" (scheduled/not
scheduled) mode of operating.
This fixes f7cc336ca - actually this change only broke the scheduled
playback, without affecting the low-latency mode (where i is always 0).
On contrary, for scheduled playback, where non-blocking is used by
default, the comparison is with 0 instead of 2 as it used to be, leading
to frequent drops.
This also reverts 00801fa3 - scheduling as currently implemented
produces last frames (actually this is not an issue - our workflow is
different than scheduled playback of steady media, that should actually
schedule next frame in completion callback).
Most importantly, deprecate the scheduled mode - not sure if used but if
someone does, we would perhaps need to know its use-case.