[Freeswitch-branches] [commit] r5592 - freeswitch/branches/greenlizard/src/mod/asr_tts/mod_openmrcp

Freeswitch SVN greenlizard at freeswitch.org
Mon Aug 13 14:14:49 EDT 2007


Author: greenlizard
Date: Mon Aug 13 14:14:48 2007
New Revision: 5592

Modified:
   freeswitch/branches/greenlizard/src/mod/asr_tts/mod_openmrcp/mod_openmrcp.c

Log:
remove warnings coming from module before merge to trunk

Modified: freeswitch/branches/greenlizard/src/mod/asr_tts/mod_openmrcp/mod_openmrcp.c
==============================================================================
--- freeswitch/branches/greenlizard/src/mod/asr_tts/mod_openmrcp/mod_openmrcp.c	(original)
+++ freeswitch/branches/greenlizard/src/mod/asr_tts/mod_openmrcp/mod_openmrcp.c	Mon Aug 13 14:14:48 2007
@@ -53,6 +53,9 @@
  * - fix audio problem with TTS, convert from using queue to using a switch_buffer
  * (in progress)
  *
+ * - use a regex for extracting xml from raw result received from mrcp recognition
+ * server
+ *
  */
 
 #ifdef __ICC
@@ -582,28 +585,25 @@
  * Called back by openmrcp client thread every time it receives audio 
  * from the TTS server we are connected to.  Puts audio in a queueu
  * and it will be pulled out from read_tts
- */
+
 static apr_status_t openmrcp_tts_write_frame_NEW(audio_sink_t *sink, media_frame_t *frame)
 {
 	tts_session_t *tts_session = sink->object;	
 	media_frame_t *media_frame;
 	switch_byte_t *buffer;
 	size_t len;
-	apr_status_t status = 
 
 	len = frame->codec_frame.size;
 
-	/* create new media frame */
+	// create new media frame 
 	media_frame = (media_frame_t *) switch_core_alloc(tts_session->pool, sizeof(media_frame_t));
 	if (!media_frame) {
 		switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "media_frame creation failed\n");
 		return SWITCH_STATUS_MEMERR;
 	}
 	
-	/**
-	 * since *frame might get freed by caller (true or false?), allocate a
-	 * new buffer and copy *data into it.
-	 **/
+	// since *frame might get freed by caller (true or false?), allocate a
+	// new buffer and copy *data into it.
 	buffer = (switch_byte_t *) switch_core_alloc(tts_session->pool, sizeof(switch_byte_t)*len);
 	if (!buffer) {
 		switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Could not allocate buffer\n");
@@ -615,7 +615,7 @@
 	media_frame->type = MEDIA_FRAME_TYPE_AUDIO;
 
 
-	/* add audio to buffer */
+	// add audio to buffer 
 	switch_mutex_lock(tts_session->audio_lock);
 	if (switch_buffer_write(tts_session->audio_buffer, buffer, len) == 0) {
 		switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING, "Could not write to buffer\n");
@@ -632,6 +632,7 @@
 	return MRCP_STATUS_SUCCESS;
 
 }
+*/
 
 
 /** 
@@ -1190,8 +1191,6 @@
 {
 	media_frame_t *queue_frame = NULL;
 	tts_session_t *tts_session = (tts_session_t *) sh->private_info;
-	size_t requested_len = *datalen;
-	size_t return_len = 0;
 
 	if (switch_queue_trypop(tts_session->audio_queue, (void *) &queue_frame)) {
 		switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING, "could not pop from queue\n");



More information about the Freeswitch-branches mailing list