Beispiel #1
1
 private static void EncodeFromBuffer(String output, int quality, int bandMode, byte[] buffer, int buferSize, int channels)
 {
     Speex speex = new Speex();
     bool response = speex.EncodeFromBuffer(output, quality, bandMode, channels, buffer, buferSize);
     Console.WriteLine("Encoded {0}", response ? "Success" : "Failed");
 }
Beispiel #2
0
        private static void Decode(string spxFileName, string rawFileName)
        {
            Speex speex     = new Speex();
            bool  isSuccess = speex.Decode(spxFileName, rawFileName);

            Console.WriteLine("Decoded {0}", isSuccess ? "Success" : "Failed");
        }
Beispiel #3
0
        private static void EncodeFromBuffer(String output, int quality, int bandMode, byte[] buffer, int buferSize, int channels)
        {
            Speex speex    = new Speex();
            bool  response = speex.EncodeFromBuffer(output, quality, bandMode, channels, buffer, buferSize);

            Console.WriteLine("Encoded {0}", response ? "Success" : "Failed");
        }
Beispiel #4
0
        private static void EncodeFromFile(String input, String output, int quality, int bandMode, int channels, int rate)
        {
            Speex speex    = new Speex();
            bool  response = speex.EncodeFromFile(input, output, quality, bandMode, channels, rate);

            Console.WriteLine("Encoded {0}", response ? "Success" : "Failed");
        }
Beispiel #5
0
        private static void TestEncodeFromBuffer(String input, String output, int quality, int bandMode, int channels)
        {
            byte[] tempBuffer = new byte[3];
            Speex  speex      = new Speex();
            bool   response   = speex.TestEncodeFromBuffer(input, output, quality, bandMode, channels);

            Console.WriteLine("Encoded {0}", response ? "Success" : "Failed");
        }
Beispiel #6
0
 private static void EncodeFromFile(String input, String output, int quality, int bandMode, int channels,int rate)
 {
     Speex speex = new Speex();
     bool response = speex.EncodeFromFile(input, output, quality, bandMode, channels, rate);
     Console.WriteLine("Encoded {0}", response ? "Success" : "Failed");
 }
Beispiel #7
0
 private static void TestEncodeFromBuffer(String input, String output, int quality, int bandMode, int channels)
 {
     byte[] tempBuffer = new byte[3];
     Speex speex = new Speex();
     bool response = speex.TestEncodeFromBuffer(input, output, quality, bandMode, channels);
     Console.WriteLine("Encoded {0}", response ? "Success" : "Failed");
 }
Beispiel #8
0
 private static void Decode(string spxFileName ,string rawFileName)
 {
     Speex speex = new Speex();
     bool isSuccess = speex.Decode(spxFileName, rawFileName);
     Console.WriteLine("Decoded {0}", isSuccess ? "Success" : "Failed");
 }