Trim some of the audio off the end of the file after the recording is done.



On Fri, Mar 11, 2011 at 5:19 PM, Matt Stockton <mstockton@harqen.com> wrote:
Hi all,

I have a freeswitch lua script that is recording and I want the recording to be terminated when the user presses the '#' key. That is all working fine for me, but the recording always has the DTMF tone at the end of it. 

I am wondering, is there a way to instruct freeswitch to not record the DTMF tones? Any help is appreciated. For reference, here are some excerpts from my lua script:

function inputHook(s, type, obj) 

  freeswitch.consoleLog("INFO", "On input");

  if (inRecording and type == "dtmf" and obj['digit'] == '#') then 

      inRecording = false;

      return "break"; 

  end 

end 

.....

session:setInputCallback("inputHook", ""); 

.....

session:recordFile(recordFilePath, 202, 500, 25);


Thanks in advance


_______________________________________________
FreeSWITCH-users mailing list
FreeSWITCH-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org