Use appropriate print format
Change-Id: I6fca4ca7346ee9de3b5ce8a9618bde327e0ed979
(cherry picked from commit bf7039a39f)
(cherry picked from commit 77782d6ae0)
having injected events on the recv list can cause out of order TS
values which results in is_in_dtmf incorrectly returning NULL and
letting the transcoded PCM frames through.
It also doesn't make sense to add DTMF to the send list unless they're
actually being sent, so injected delayed or unblocked
Change-Id: I07e2a35e27142715a5257f199326b7a3d133e2a8
now that the returned last_event_ts is always that of the previous
DTMF, we can ensure that the next one isn't transmitted until that
time plus the required pause.
Like the num_samples calculation, the actual time needs to be
increased by 1 packets worth of samples so tha pause lasts the
full duration required
Change-Id: I6da1dd7cbcf49f7f0431a5123df2cdc382fe3dba
the num_samples was added to the start_pts, which is the first event
packet timestamp, which has already increased its ts by its event
duration. so, the total duration of events ends up being one packet
more than intended.
Change-Id: I423bb222a81c5bd78e570ff2026c72dd4dd1b100
in some scenarios the start event ts can be before the *pts value, which
will result in a shortened DTMF event being transmitted than expected during
injection as the end event ts is calculated based on that initial dtmf start
value.
This change updates the end event ts by the amount the start ts was
behind, so that the resulting event has the right duration
Change-Id: Ia637d1e1c5d92de8b35317ec552c22eae23c0645
In the file implementations follow the rules:
1. Firstly goes the correlated header file, then one empty row.
2. Secondly go system headers, so in angle-brackets, then one empty row.
3. Thirdly, go custom header files, so in double quotes,
then one empty row.
4. If there is "xt_RTPENGINE.h", it's mentioned next, but separately,
then one empty row.
5. If there are pre-processor definitions, they are added.
6. And eventually at least one empty row before the code.
In some situations it's allowed to step aside from the rules,
when inclusions are dependent on each other, so on the sequence,
and also possibly on some inline objects definitions, but if possible
to follow the rules, it's being done.
Change-Id: Ie512a970e230fe202398656d1942e8874bb14cd9
previously, dtmf_inject wouldn't add the events as the dtmf_payload_type
was set to -1 as part of the delay buffer handling. However, as we
know we want this DTMF, this change updates the function to check for
and use the real_dtmf_payload_type value
Then, in codec_add_dtmf_event, we can check the injected bool and
if set, use the real_dtmf_payload_type again to decide whether to
push the event onto the queue
closes#1722
Change-Id: I34e35f92e014f4aed9e045737df7400155b86602
DTMF injection must use the codec handler of the primary payload (audio
stream), not the handler of the DTMF PT itself.
Change-Id: Ied2d1f969bfc76ef7af0ada063b90a47c4633557
Support using the SSRC TS derived from received RTP packets as "encoder"
TS (the "next" expected TS) for passthrough RTP in addition to the FIFO
TS of an actual encoder.
Change-Id: I7c49c27651eb89c5349bbf290b1c0ad160f77e3b
The "duration" is not valid for events which are not end events as
there's no previous event to derive a duration from.
Change-Id: I3f9dad536b168cce24d1a58c5bcf25e5cacfe7a8
In order to support a per-call toggle for DTMF logging without having
the global config option set, we always open the socket just in case.
Change-Id: Ibb62672afa21e41623e74603214b4d9d8b94443c
Support multiple tone frequencies for DTMF-security=tone to enable
audibly distinguishing multiple consecutive DTMF events from one
another.
Change-Id: I6fa33a5768aae198220d0b0cc4c53308c5661a52
The `dtmf_send` event might not have a matching entry while handling a
received DTMF event. Move bookkeeping of the random output event into
`dtmf_recv`.
Change-Id: I5507b0b7f5eca6e29cbcaccc905ab25249b22aa3
Create a dedicated struct to hold certain attributes shared by both sink
handlers and media subscriptions, as a preparation to simplify handling
these attributs.
Change-Id: I866159c33ed6d6a2873d2cf68c4906ea705d253e
Complete overhaul of the codec handling code:
*) obsolete flags `asymmetric codecs`, `symmetric codecs`, `reorder
codecs`
*) support proper codec offer/answer
*) split codec manipulation (strip/offer/accept/etc) into separate
functions for clarity and better code maintenance
*) fully update codec handlers in both directions after an answer
*) explicit allocation and handling of codecs and payload types in a
codec_store object
*) improve codec matchup logic during answer
*) more explicit handling of supplemental codecs (CN/DTMF)
*) remove now obsolete hacks for handling certain use cases
Change-Id: I996705ba8fe339524c2f70e6bb0fd854f9a1f4fb