Sebastian Dröge
408f0870a6
decklinkaudio{src,sink}: Only start streams / scheduled playback if there is a videosrc at this point
2015-02-09 17:15:21 +01:00
Sebastian Dröge
349113d15a
decklinkaudiosrc: Don't provide a clock
...
The audio source only works together with the video source, and the video
source is already providing a clock.
2015-02-09 17:04:27 +01:00
Sebastian Dröge
4de7fdfa3a
decklinkaudiosink: Throttle reading from the ringbuffer
...
The driver has an internal buffer of unspecified and unconfigurable size, and
it will pull data from our ring buffer as fast as it can until that is full.
Unfortunately that means that we pull silence from the ringbuffer unless its
size is by conincidence larger than the driver's internal ringbuffer.
The good news is that it's not required to completely fill the buffer for
proper playback. So we now throttle reading from the ringbuffer whenever
the driver has buffered more than half of our ringbuffer size by waiting
on the clock for the amount of time until it has buffered less than that
again.
2015-02-09 16:22:39 +01:00
Sebastian Dröge
a6bcd09b6c
decklinkaudiosink: Start scheduled playback when going to PLAYING
...
The ringbuffer's acquire() is too early, and ringbuffer's start() will only be
called after the clock has advanced a bit... which it won't unless we start
scheduled playback.
2015-02-09 16:22:39 +01:00
Sebastian Dröge
22b0a4dad5
decklink{audio,video}src: Take the capture times from the pipeline clock
...
Not from the decklink clock. Both will return exactly the same time once the
decklink clock got slaved to the pipeline clock and received the first
observation, but until then it will return bogus values. But as both return
exactly the same values, we can as well use the pipeline clock directly.
2015-02-08 21:56:04 +01:00
Sebastian Dröge
e9b49018ed
decklinkvideosink: Always lock the mutex before starting the streams
2015-01-28 17:02:59 +01:00
Sebastian Dröge
837eee7085
decklinkvideosink: Fix deadlock
2015-01-28 16:59:30 +01:00
Sebastian Dröge
4eb5cd9156
decklink{audio,video}sink: Only start scheduled playback once both sources are ready and we are in PLAYING
...
Otherwise we might start the scheduled playback before the audio or video streams are
actually enabled, and then error out later because they are enabled to late.
We enable the streams when getting the caps, which might be *after* we were
set to PLAYING state.
2015-01-28 16:13:16 +01:00
Sebastian Dröge
e2ff5587fe
decklink{audio,video}src: Only start the streams once both sources are ready and we are in PLAYING
...
Otherwise we might start the streams before the audio or video streams are
actually enabled, and then error out later because they are enabled to late.
We enable the streams when getting the caps, which might be *after* we were
set to PLAYING state.
2015-01-28 16:13:16 +01:00
Sebastian Dröge
00176a1ddf
decklink: Make sure our clock never returns NONE, always advances and does not jump when going from PAUSED to PLAYING
...
It basically behaves the same as the audio clocks.
2015-01-28 16:13:16 +01:00
Sebastian Dröge
b3a4772834
decklinkvideosink: Handle the clock returning GST_CLOCK_TIME_NONE properly
2015-01-28 16:13:16 +01:00
Sebastian Dröge
8a5d2c561c
decklinkvideo{sink,src}: Make elements more similar to the audio elements by enabling the video input/output only when getting the actual caps
...
This will also make it easier later to support caps changes and support
selecting the mode based on the caps if that should ever be implemented.
2015-01-28 16:13:16 +01:00
Sebastian Dröge
f3ae93e504
decklinkvideosrc: Properly report caps if mode!=auto and handle caps changes properly for mode=auto
2015-01-28 16:13:16 +01:00
Sebastian Dröge
7fb57938c1
decklinkaudiosrc: Don't release input device twice on errors in set_caps()
2015-01-28 16:13:16 +01:00
Sebastian Dröge
c6d5c4c2e1
decklinkaudiosrc: Release the audio input on errors, not the video input
2015-01-26 15:33:45 +01:00
Sebastian Dröge
e734c3cf13
decklinkvideosink: Also consider max-lateness property value before dropping late frames
2015-01-15 12:49:46 +01:00
Sebastian Dröge
5a12b2670e
decklinkvideosink: Stop scheduled playback shortly in PAUSED->PLAYING if it was running already
...
This fixes handling of flushing seeks, where we will get a PAUSED->PLAYING
state transition after the previous one without actually going to PAUSED
first.
2015-01-14 16:33:53 +01:00
Sebastian Dröge
92fa187d11
decklinkvideosink: Don't schedule too late frames in prepare()
...
Otherwise we will overflow the internal buffer of the hardware
with useless frames and run into an error. This is necessary until
this bug in basesink is fixed:
https://bugzilla.gnome.org/show_bug.cgi?id=742916
2015-01-14 16:02:57 +01:00
Sebastian Dröge
7b979703f8
decklinkvideosink: Keep track of the time when we went to PLAYING for the external clock too
...
Otherwise we're adding an offset of the time the pipeline was in PLAYING
already to the running time when converting it to our internal clock.
2015-01-14 16:00:54 +01:00
Sebastian Dröge
aed66838f3
decklinkvideosink: Enable QoS and set max-lateness to 20ms
2015-01-14 13:33:15 +01:00
Sebastian Dröge
ab9ee34aba
decklink: Use BT2020 colorspace for UltraHD resolutions
2015-01-13 19:56:45 +01:00
Sebastian Dröge
65119ae8b4
decklink: Fix indention once again
2015-01-13 19:56:45 +01:00
Sebastian Dröge
d2e309d341
decklinkvideosink: Get our own "start time" instead of the one of the pipeline
...
decklinkvideosink might be added later to the pipeline, or its state might
be handled separately from the pipeline. In which case the running time when
we (last) went into PLAYING state will be different from the pipeline's.
However we need our own start time to tell the Decklink API, which running
time should be displayed at the moment we go to PLAYING and start scheduled
rendering.
2015-01-13 17:44:17 +01:00
Sebastian Dröge
b79ece392c
decklink: Initialize refcount of our C++ classes in the constructor
...
CID 1262288
CID 1262287
CID 1262289
2015-01-12 15:58:38 +01:00
Sebastian Dröge
4531a341a8
decklinkvideosrc: Post LATENCY message when the mode changes
...
Different modes have different framerates, and thus different latencies. We
might need to reconfigure the latency of the pipeline.
2015-01-08 18:16:12 +01:00
Sebastian Dröge
beede3f27d
decklinkvideosrc: Fix compiler warning
2015-01-08 18:16:12 +01:00
Florian Langlois
9480d91ad4
decklinkvideosrc: Add automatic mode detection
...
https://bugzilla.gnome.org/show_bug.cgi?id=739284
2015-01-08 18:16:12 +01:00
Sebastian Dröge
7e7cabb422
decklink: Add a dummy value to the video connection mapping table for auto
2015-01-08 12:55:51 +01:00
Sebastian Dröge
ed0d4cc653
decklinkaudiosrc: Add property to select the audio input connection
2015-01-08 12:48:22 +01:00
Sebastian Dröge
34de6ad73b
decklink: Add XLR and RCA audio connection enums
2015-01-08 12:23:53 +01:00
Sebastian Dröge
a35d5ae9b9
decklinkvideosrc: Add auto value for the connection property
...
This will use the default/auto connection for video capturing, and can
be set via the Decklink configuration tools.
2015-01-08 12:23:09 +01:00
Sebastian Dröge
478deb4805
decklink: Fix indention once again
2015-01-08 12:13:03 +01:00
Florian Langlois
81c1ef190d
decklink: Add property for configuring the input connection of the video sources
2015-01-08 12:12:50 +01:00
Florian Langlois
e7c6eb6326
decklink: Fix latency values for sources
2015-01-07 16:42:57 +01:00
Sebastian Dröge
196d9c4829
decklink: Add support for 4K / UHD modes
2014-12-29 17:58:37 +01:00
Sebastian Dröge
0122a9d1b6
decklink: Fix indention
2014-12-29 17:58:37 +01:00
Sebastian Dröge
d632a48d6c
decklink: Fix various compiler warnings with gcc
2014-12-19 15:05:58 +01:00
Sebastian Dröge
5e7782ca39
decklink: Re-add the COM initialization code for Windows
...
Untested, and we will never deinitialize COM again.
2014-12-19 14:50:25 +01:00
Sebastian Dröge
f9d16c5913
decklink: Remove in-same-pipeline detection code for audio/video elements of the same device
...
This causes deadlocks sometimes for some reason.
2014-12-19 14:40:40 +01:00
Sebastian Dröge
9c2e09cf39
decklinkvideosink: Implement clock slaving
2014-12-19 14:40:40 +01:00
Sebastian Dröge
b9e17c5605
decklinkvideosink: Add some more debug output for when frames are scheduled
2014-12-19 14:40:40 +01:00
Sebastian Dröge
ec90bbb6f3
decklink: Add property for configuring the buffer size of the sources
2014-12-19 14:40:40 +01:00
Sebastian Dröge
112fdd266a
decklinkaudiosrc: Implement timestamp jitter and discont handling
2014-12-19 14:40:40 +01:00
Sebastian Dröge
7c0fb92f1b
decklink: Our capture time is the end timestamp of the buffer, subtract the duration
2014-12-19 14:40:40 +01:00
Sebastian Dröge
4ef676f109
decklink: Allow for a maximum of 5 packets to be queued up
...
In case downstream is a bit slow with consuming packets at times.
2014-12-19 14:40:40 +01:00
Sebastian Dröge
aac0027ed2
decklink: Implement latency query in sources and remember selected mode
2014-12-19 14:40:40 +01:00
Sebastian Dröge
23d6eaaa10
decklink: Remove obsolete files
2014-12-19 14:40:39 +01:00
Sebastian Dröge
6d931a0c0e
decklink: Add initial version of audio and video sources
2014-12-19 14:40:39 +01:00
Sebastian Dröge
57d46fe9e1
decklink: Initial version of the audio/video sink rewrite
2014-12-19 14:40:39 +01:00
Sebastian Dröge
2d25f2e0b8
decklink: Fix make distcheck
...
And properly dist all headers and source files.
2014-12-04 15:43:20 +01:00