Commit Graph

38 Commits

Author SHA1 Message Date
David Vossel
16203af95e Merged revisions 238635 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
  r238635 | dvossel | 2010-01-08 13:39:30 -0600 (Fri, 08 Jan 2010) | 22 lines
  
  fixes AUDIOHOOK_INHERIT regression
  
  During the process of removing an audiohook from one channel
  and attaching it to another the audiohook's status is updated
  to DONE and then back to whatever it was previously.  Typically
  updating the status after setting it to DONE is not a good idea
  because DONE can trigger unrecoverable audiohook destruction
  events... because of this a conditional check was added to
  audiohook_update_status to explicitly prevent the audiohook
  from ever changing after being set to DONE.  It was this check
  that prevented audiohook inherit from work properly though.
  
  Now ast_audiohook_move_by_source is treated as a special exception,
  as the audiohook must be returned to its previous status after
  attaching it to the new channel.  This is only a safe operation
  because the audiohook's lock is held the entire time, otherwise
  this could cause trouble.
  
  (closes issue #16522)
  Reported by: corruptor
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@238638 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-01-08 19:44:28 +00:00
David Vossel
0bd7425d6c Merged revisions 230583 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
  r230583 | dvossel | 2009-11-20 11:26:20 -0600 (Fri, 20 Nov 2009) | 6 lines
  
  audiohook signal trigger on every status change
  
  (issue #14618)
  
  Review: https://reviewboard.asterisk.org/r/434/
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@230586 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-11-20 17:32:16 +00:00
Tilghman Lesher
e88e6c5f6b Merged revisions 224856 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r224856 | tilghman | 2009-10-20 17:09:07 -0500 (Tue, 20 Oct 2009) | 12 lines
  
  Merged revisions 224855 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r224855 | tilghman | 2009-10-20 17:07:11 -0500 (Tue, 20 Oct 2009) | 5 lines
    
    Pay attention to the return value of the manipulate function.
    While this looks like an optimization, it prevents a crash from occurring
    when used with certain audiohook callbacks (diagnosed with SVN trunk,
    backported to 1.4 to keep the source consistent across versions).
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@224858 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-10-20 22:11:03 +00:00
Mark Michelson
92611fe933 Merged revisions 197543 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r197543 | mmichelson | 2009-05-28 09:58:06 -0500 (Thu, 28 May 2009) | 27 lines
  
  Merged revisions 197537 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r197537 | mmichelson | 2009-05-28 09:49:13 -0500 (Thu, 28 May 2009) | 21 lines
    
    Add flags to chanspy audiohook so that audio stays in sync.
    
    There are two flags being added to the chanspy audiohook here. One
    is the pre-existing AST_AUDIOHOOK_TRIGGER_SYNC flag. With this set,
    we ensure that the read and write slinfactories on the audiohook do
    not skew beyond a certain tolerance.
    
    In addition, there is a new audiohook flag added here,
    AST_AUDIOHOOK_SMALL_QUEUE. With this flag set, we do not allow for
    a slinfactory to build up a substantial amount of audio before 
    flushing it. For this particular issue, this means that the person 
    spying on the call will hear the conversations in real time with very 
    little delay in the audio.
    
    (closes issue #13745)
    Reported by: geoffs
    Patches:
          13745.patch uploaded by mmichelson (license 60)
    Tested by: snblitz
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@197545 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-05-28 15:11:15 +00:00
Tilghman Lesher
d470a900fa Merged revisions 187599 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
  r187599 | tilghman | 2009-04-09 22:55:27 -0500 (Thu, 09 Apr 2009) | 2 lines
  
  Modify headers and macros, according to Russell's suggestions on the -dev list
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@187600 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-10 03:56:37 +00:00
David Vossel
5ca0caf1cc Merged revisions 186379 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
  r186379 | dvossel | 2009-04-03 11:29:47 -0500 (Fri, 03 Apr 2009) | 4 lines
  
  audio_audiohook_write_list() did not correctly update sample size after ast_translate.
  
  audio_audiohook_write_list() did not take into account that the sample size may change after translation depending on if the original frame is is 8khz or 16khz.  the sample size is now updated after translating to reflect this possibility.  This caused the audio on the receiving end to sound terrible.  Thanks to jcolp and mmichelson for helping me work this out.

  (issue AST-197)
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@186381 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-04-03 16:38:36 +00:00
Joshua Colp
59a9992f8c Merged revisions 185197 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
  r185197 | file | 2009-03-31 11:07:36 -0300 (Tue, 31 Mar 2009) | 15 lines
  
  Merged revisions 185196 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r185196 | file | 2009-03-31 11:06:39 -0300 (Tue, 31 Mar 2009) | 8 lines
    
    Fix crash when moving audiohooks between channels.
    
    Handle the scenario where we are called to move audiohooks between channels
    and the source channel does not actually have any on it.
    
    (closes issue #14734)
    Reported by: corruptor
  ........
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@185199 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-03-31 14:10:25 +00:00
Joshua Colp
8b9b72118f Merged revisions 179291 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
  r179291 | file | 2009-03-02 10:13:45 -0400 (Mon, 02 Mar 2009) | 7 lines
  
  Fix issue where changing the volume of both directions of audio did not work.
  
  (closes issue #14574)
  Reported by: KNK
  Patches:
        audiohook_volume_fix.diff uploaded by KNK (license 545)
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@179293 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-03-02 14:14:51 +00:00
Joshua Colp
993d0af118 Merged revisions 173902 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
  r173902 | file | 2009-02-06 11:59:17 -0400 (Fri, 06 Feb 2009) | 4 lines
  
  Always detach and destroy the whisper and barge audiohooks. Additionally also allow an audiohook to be detached if it has not been attached.
  (closes issue #14414)
  Reported by: bluecrow76
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@173904 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-02-06 16:01:01 +00:00
Mark Michelson
732fd97b6b Merged revisions 166162 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
r166162 | mmichelson | 2008-12-19 17:45:00 -0600 (Fri, 19 Dec 2008) | 6 lines

Get rid of an extra space.

I don't know how this crept back in when I had already
fixed it earlier


........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@166164 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-12-19 23:45:59 +00:00
Mark Michelson
7ed70a7a3f Merged revisions 166092,166095 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
r166092 | mmichelson | 2008-12-19 16:26:16 -0600 (Fri, 19 Dec 2008) | 28 lines

Adding a new dialplan function AUDIOHOOK_INHERIT

This function is being added as a method to allow for
an audiohook to move to a new channel during a channel
masquerade. The most obvious use for such a facility is
for MixMonitor when a transfer is performed. Prior to
the addition of this functionality, if a channel 
running MixMonitor was transferred by another party, then
the recording would stop once the transfer had completed.
By using AUDIOHOOK_INHERIT, you can make MixMonitor 
continue recording the call even after the transfer
has completed.

It has also been determined that since this is seen
by most as a bug fix and is not an invasive change,
this functionality will also be backported to 1.4 and
merged into the 1.6.0 branches, even though they are
feature-frozen.

(closes issue #13538)
Reported by: mbit
Patches:
      13538.patch uploaded by putnopvut (license 60)
	  Tested by: putnopvut

Review: http://reviewboard.digium.com/r/102/


........
r166095 | mmichelson | 2008-12-19 16:40:57 -0600 (Fri, 19 Dec 2008) | 5 lines

Remove the verbatim tag from the author line

I could have sworn I already did that before, though...


........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@166098 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-12-19 23:07:33 +00:00
Mark Michelson
fdd9a6f9b6 Merged revisions 149205 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
r149205 | mmichelson | 2008-10-14 18:04:44 -0500 (Tue, 14 Oct 2008) | 20 lines

Merged revisions 149204 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r149204 | mmichelson | 2008-10-14 18:00:01 -0500 (Tue, 14 Oct 2008) | 12 lines

Add a tolerance period for sync-triggered audiohooks
so that if packetization of audio is close (but not equal)
we don't end up flushing the audiohooks over small
inconsistencies in synchronization.

Related to issue #13005, and solves the issue
for most people who were experiencing the problem.
However, a small number of people are still experiencing
the problem on long calls, so I am not closing
the issue yet


........

................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@149206 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-10-14 23:05:14 +00:00
Sean Bright
b69c8e6ab5 Another big chunk of changes from the RSW branch. Bunch of stuff from main/
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@137082 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-10 19:35:50 +00:00
Kevin P. Fleming
7df8b8b848 make datastore creation and destruction a generic API since it is not really channel related, and add the ability to add/find/remove datastores to manager sessions
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@135680 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-05 16:56:11 +00:00
Russell Bryant
c4c3e2f875 Merged revisions 130634 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r130634 | russell | 2008-07-14 05:38:14 -0500 (Mon, 14 Jul 2008) | 2 lines

Bump up the debug level for a message.

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@130635 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-14 10:39:23 +00:00
Mark Michelson
1a7806c836 Merged revisions 130236 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r130236 | mmichelson | 2008-07-11 15:03:23 -0500 (Fri, 11 Jul 2008) | 3 lines

Remove redundant logic


........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@130237 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-11 20:03:55 +00:00
Mark Michelson
48d39547ec Merged revisions 130173 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r130173 | mmichelson | 2008-07-11 14:13:29 -0500 (Fri, 11 Jul 2008) | 7 lines

Fix a typo in audiohook_read_frame_both.

While this change has not been proven to fix any
specific issue, it is incorrect and could cause
unforeseen problems.


........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@130174 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-11 19:14:15 +00:00
Michiel van Baak
f1e9371da8 - revert change to ast_queue_hangup and create ast_queue_hangup_with_cause
- make data member of the ast_frame struct a named union instead of a void

Recently the ast_queue_hangup function got a new parameter, the hangupcause
Feedback came in that this is no good and that instead a new function should be created.
This I did.

The hangupcause was stored in the seqno member of the ast_frame struct. This is not very
elegant, and since there's already a data member that one should be used.
Problem is, this member was a void *.
Now it's a named union so it can hold a pointer, an uint32 and there's a padding in case someone
wants to store another type in there in the future.

This commit is so massive, because all ast_frame.data uses have to be
altered to ast_frame.data.data

Thanks russellb and kpfleming for the feedback.

(closes issue #12674)
Reported by: mvanbaak


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@117802 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-22 16:29:54 +00:00
Brett Bryant
5634048c98 Add two new dialplan functions from libspeex for applying audio gain control
and denoising to a channel, AGC() and DENOISE(). Also included, is a change 
to the audiohook API to add a new function (ast_audiohook_remove) that can 
remove an audiohook from a channel before it is detached.

This code is based on a contribution from Switchvox.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@114926 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-01 16:57:19 +00:00
Joshua Colp
dc8fe3910d Merged revisions 113296 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r113296 | file | 2008-04-08 12:03:43 -0300 (Tue, 08 Apr 2008) | 4 lines

If audio suddenly gets fed into one side of a channel after a lapse of frames flush the other factory so that old audio does not remain in the factory causing the sync code to not execute.
(closes issue #12296)
Reported by: jvandal

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@113297 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-04-08 15:05:35 +00:00
Joshua Colp
30d85b3144 Merge over ast_audiohook_volume branch. This adds API calls for use by developers to adjust the volume on a channel.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@110542 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-03-21 17:58:59 +00:00
Joshua Colp
5fc569f5f5 Merged revisions 108083 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r108083 | file | 2008-03-12 15:26:37 -0300 (Wed, 12 Mar 2008) | 4 lines

Add a trigger mode that triggers on both read and write. The actual function that returns the combined audio frame though will wait until both sides have fed in audio, or until one side stops (such as the case when you call Wait).
(closes issue #11945)
Reported by: xheliox

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@108084 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-03-12 18:29:33 +00:00
Joshua Colp
b0be65f2ef *mumble*
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@103842 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-02-20 03:52:57 +00:00
Joshua Colp
ddf7a8a2a0 file not found.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@103840 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-02-20 03:44:40 +00:00
Joshua Colp
ef7cfaa2f8 Minor test...
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@103838 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-02-20 03:38:13 +00:00
Russell Bryant
b7425090c8 Remove a duplicate lock of the audiohook lock when destroying manipulate
audiohooks.  This causes an error when we attempt to destroy the lock later
when freeing the audiohook.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@98581 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-01-13 00:10:00 +00:00
Joshua Colp
b8efdb304b I am no longer Rockin'
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@98432 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-01-11 22:59:13 +00:00
Joshua Colp
225f268e88 Testing something...
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@98424 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-01-11 22:57:39 +00:00
Mark Michelson
6b08c442c7 Adding support for the "automixmonitor" dial and queue options.
This works in much the same way as the automonitor, except that instead of using the monitor
app, it uses the mixmonitor app. By providing an 'x' or 'X' as a dial or queue option, a DTMF
sequence may be entered (as defined in features.conf) to start the one-touch mixmonitor.

This patch also introduces some new API calls to the audiohooks code for searching for an audiohook
by type and for searching for a running audiohook by type.

Big thanks to joetester for writing the initial patch, testing it and patiently waiting for it to 
be committed.

(closes issue #10185, reported and patched by xmarksthespot)



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@90388 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-11-30 21:19:57 +00:00
Luigi Rizzo
e0ff5fef5c remove a bunch of useless #include "options.h"
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@89511 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-11-21 23:09:02 +00:00
Luigi Rizzo
9335ace850 another bunch of include removals (errno.h and asterisk/logger.h)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@89425 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-11-19 19:09:03 +00:00
Luigi Rizzo
fdb7f7ba3d Start untangling header inclusion in a way that does not affect
build times - tested, there is no measureable difference before and
after this commit.

In this change:

use asterisk/compat.h to include a small set of system headers:
inttypes.h, unistd.h, stddef.h, stddint.h, sys/types.h, stdarg.h,
stdlib.h, alloca.h, stdio.h

Where available, the inclusion is conditional on HAVE_FOO_H as determined
by autoconf.

Normally, source files should not include any of the above system headers,
and instead use either "asterisk.h" or "asterisk/compat.h" which does it
better. 

For the time being I have left alone second-level directories
(main/db1-ast, etc.).



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@89333 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-11-16 20:04:58 +00:00
Luigi Rizzo
339d27ebe9 use %d and cast to int instead of %zd for size_t object,
this helps portability.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@89109 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-11-08 09:20:05 +00:00
Kevin P. Fleming
edc78d6023 improve linked-list macros in two ways:
- the *_CURRENT macros no longer need the list head pointer argument
  - add AST_LIST_MOVE_CURRENT to encapsulate the remove/add operation when moving entries between lists


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@89106 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-11-08 05:28:47 +00:00
Joshua Colp
a565584d05 Fix memory issue that crept up with Russell's testing. It is *not* proper to free the frame we get in ast_write.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@81858 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-09-06 22:34:44 +00:00
Jason Parker
d72ea80a00 Doxygen cleanups/fixes.
Closes issue #10654, patch by snuffy


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@81560 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-09-05 16:31:39 +00:00
Joshua Colp
937d83f7e4 Minor tweak. Don't manipulate volume of the audio in the buffer if no audio is actually there.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@80157 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-21 15:51:49 +00:00
Joshua Colp
602198c402 Merge audiohooks branch into trunk. This is a new API for developers to listen and manipulate the audio going through a channel.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@78649 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2007-08-08 19:30:52 +00:00