<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    From 1.2rc1 source code:<br>
    <meta http-equiv="content-type" content="text/html;
      charset=ISO-8859-1">
    <span class="Apple-style-span" style="color: rgb(136, 0, 0);
      font-family: monospace; font-style: normal; font-variant: normal;
      font-weight: normal; letter-spacing: normal; line-height: 16px;
      orphans: 2; text-align: -webkit-auto; text-indent: 0px;
      text-transform: none; white-space: pre; widows: 2; word-spacing:
      0px; -webkit-text-decorations-in-effect: none;
      -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;
      background-color: rgb(255, 255, 255); font-size: medium; "><br>
      <big><font color="#000000">preprocess.c:<br>
          <br>
          /* FIXME: This VAD is a kludge */<br>
          st-&gt;speech_prob = Pframe;<br>
          if (st-&gt;vad_enabled)<br>
          {<br>
          if (st-&gt;speech_prob &gt; st-&gt;speech_prob_start ||
          (st-&gt;was_speech &amp;&amp; st-&gt;speech_prob &gt;
          st-&gt;speech_prob_continue))<br>
          {<br>
          st-&gt;was_speech=1;<br>
          return 1;<br>
          } else<br>
          {<br>
          st-&gt;was_speech=0;<br>
          return 0;<br>
          }<br>
          } else {<br>
          return 1;<br>
          }<br>
          <br>
          AND<br>
          <br>
          case SPEEX_PREPROCESS_SET_VAD:<br>
          speex_warning("The VAD has been replaced by a hack pending a
          complete rewrite");<br>
          st-&gt;vad_enabled = (*(spx_int32_t*)ptr);<br>
          break;<br>
          <br>
          <br>
          As you can see, it is a hack, not supposed to be very good.
          Still, weird that you get<br>
          this result. If you want a sample to test it, check speexenc.c
          file in speex source code package.<br>
          I usually implement this kind of feature outside of speex
          becauses I want a better control<br>
          on how it happens and when to do something about it :)<br>
          <br>
          Yanick Bourbeau<br>
        </font></big><br>
      <br>
      <br>
      <br>
      <br>
    </span>On 11-08-29 04:16 PM, Clifton Craig wrote:
    <blockquote
      cite="mid:76E42D8B-E78E-41DF-9883-79904ACAFB2A@gmail.com"
      type="cite"><base href="x-msg://6/">+1 on this question as I
      wanted to start playing with it as well.
      <div><br>
        <div>
          <div>On Aug 29, 2011, at 9:41 AM, Shridhar, Vasant wrote:</div>
          <br class="Apple-interchange-newline">
          <blockquote type="cite"><span class="Apple-style-span"
              style="border-collapse: separate; font-family: Helvetica;
              font-style: normal; font-variant: normal; font-weight:
              normal; letter-spacing: normal; line-height: normal;
              orphans: 2; text-indent: 0px; text-transform: none;
              white-space: normal; widows: 2; word-spacing: 0px;
              -webkit-border-horizontal-spacing: 0px;
              -webkit-border-vertical-spacing: 0px;
              -webkit-text-decorations-in-effect: none;
              -webkit-text-size-adjust: auto; -webkit-text-stroke-width:
              0px; font-size: medium; ">
              <div link="blue" vlink="purple" lang="EN-US">
                <div class="WordSection1" style="page: WordSection1; ">
                  <div style="margin-top: 0in; margin-right: 0in;
                    margin-bottom: 0.0001pt; margin-left: 0in;
                    font-size: 11pt; font-family: Calibri, sans-serif; ">I
                    have been trying to understand how to get the VAD
                    algorithm working.&nbsp; I sent an input stream of all
                    zeros into the preprocessor but still got a return
                    value of 1 indicating that speech was detected.&nbsp; Is
                    this feature not available with the latest release?&nbsp;
                    I thought at the very least it would detect this as
                    silence and return 0 but that does not seem to be
                    the case.<o:p></o:p></div>
                  <div style="margin-top: 0in; margin-right: 0in;
                    margin-bottom: 0.0001pt; margin-left: 0in;
                    font-size: 11pt; font-family: Calibri, sans-serif; "><o:p>&nbsp;</o:p></div>
                  <div style="margin-top: 0in; margin-right: 0in;
                    margin-bottom: 0.0001pt; margin-left: 0in;
                    font-size: 11pt; font-family: Calibri, sans-serif; ">Does
                    anyone have any information on how to use this or
                    some example code to set this up I might try.<o:p></o:p></div>
                  <div style="margin-top: 0in; margin-right: 0in;
                    margin-bottom: 0.0001pt; margin-left: 0in;
                    font-size: 11pt; font-family: Calibri, sans-serif; "><o:p>&nbsp;</o:p></div>
                  <div style="margin-top: 0in; margin-right: 0in;
                    margin-bottom: 0.0001pt; margin-left: 0in;
                    font-size: 11pt; font-family: Calibri, sans-serif; ">Thanks,<o:p></o:p></div>
                  <div style="margin-top: 0in; margin-right: 0in;
                    margin-bottom: 0.0001pt; margin-left: 0in;
                    font-size: 11pt; font-family: Calibri, sans-serif; "><o:p>&nbsp;</o:p></div>
                  <div style="margin-top: 0in; margin-right: 0in;
                    margin-bottom: 0.0001pt; margin-left: 0in;
                    font-size: 11pt; font-family: Calibri, sans-serif; ">Vas<o:p></o:p></div>
                </div>
                _______________________________________________<br>
                Speex-dev mailing list<br>
                <a moz-do-not-send="true"
                  href="mailto:Speex-dev@xiph.org" style="color: blue;
                  text-decoration: underline; ">Speex-dev@xiph.org</a><br>
                <a moz-do-not-send="true"
                  href="http://lists.xiph.org/mailman/listinfo/speex-dev"
                  style="color: blue; text-decoration: underline; ">http://lists.xiph.org/mailman/listinfo/speex-dev</a><br>
              </div>
            </span></blockquote>
        </div>
        <br>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
Speex-dev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Speex-dev@xiph.org">Speex-dev@xiph.org</a>
<a class="moz-txt-link-freetext" href="http://lists.xiph.org/mailman/listinfo/speex-dev">http://lists.xiph.org/mailman/listinfo/speex-dev</a>
</pre>
    </blockquote>
    <br>
  </body>
</html>