]> git.mxchange.org Git - flightgear.git/blobdiff - utils/fgcom/fgcom.cxx
Icons modifications
[flightgear.git] / utils / fgcom / fgcom.cxx
index f93b16eba74a1cc54ca8f5181e2b0ae2ff168496..7e3515da74d24e2b34cbc27a7179ff7b1ee4b40f 100644 (file)
@@ -448,8 +448,10 @@ main (int argc, char *argv[])
     callsign = DEFAULT_USER;
 
   iaxc_set_callerid ( callsign, app.c_str() );
-  iaxc_set_formats (IAXC_FORMAT_SPEEX, IAXC_FORMAT_SPEEX);
+  iaxc_set_formats (IAXC_FORMAT_SPEEX, IAXC_FORMAT_ULAW|IAXC_FORMAT_SPEEX);
   iaxc_set_speex_settings(1, 5, 0, 1, 0, 3);
+  iaxc_set_filters(IAXC_FILTER_AGC | IAXC_FILTER_DENOISE);
+  iaxc_set_silence_threshold(-20.0);
   iaxc_set_event_callback (iaxc_callback);
 
   iaxc_start_processing_thread ();
@@ -772,29 +774,15 @@ ptt (int mode)
     {
       /* mic is muted so unmute and mute speaker */
       iaxc_input_level_set (level_in);
-      /*if (!check_special_frq (selected_frequency))
-       {*/
-         iaxc_output_level_set (0.0);
-          SG_LOG( SG_GENERAL, SG_ALERT, "[SPEAK] unmute mic, mute speaker" );
-       /*}
-      else
-       {
-          SG_LOG( SG_GENERAL, SG_ALERT, "[SPEAK] unmute mic" );
-       }*/
+      iaxc_output_level_set (0.0);
+      SG_LOG( SG_GENERAL, SG_ALERT, "[SPEAK] unmute mic, mute speaker" );
     }
   else
     {
       /* mic is unmuted so mute and unmute speaker */
       iaxc_input_level_set (0.0);
-      /*if (!check_special_frq (selected_frequency))
-       {*/
-         iaxc_output_level_set (level_out);
-          SG_LOG( SG_GENERAL, SG_ALERT, "[LISTEN] mute mic, unmute speaker" );
-       /*}
-      else
-       {
-          SG_LOG( SG_GENERAL, SG_ALERT, "[LISTEN] mute mic" );
-       }*/
+      iaxc_output_level_set (level_out);
+      SG_LOG( SG_GENERAL, SG_ALERT, "[LISTEN] mute mic, unmute speaker" );
     }
 }