예제 #1
0
파일: MP3Class.cs 프로젝트: uwx/Open-GHTCP
 public Mp3Class(Stream stream1, int int5, Enum4 enum40, int int6)
 {
     _class810 = new ZzSoundClass81[int5];
     for (var i = 0; i < _class810.Length; i++)
     {
         _class810[i] = new ZzSoundClass81(new Class104(enum40));
     }
     FileStream = stream1;
     _class820  = new Class82(FileStream, int6);
     _int2      = _class820.method_2();
     _long0     = -1L;
     _class1070 = null;
     if (!method_0())
     {
         throw new Mp3Exception("Mp3 Decoder: Cannot read header.");
     }
     _short0 = 0;
     for (var j = 0; j < _class810.Length; j++)
     {
         _short0 += (short)_class810[j].method_2();
     }
     _int4       = _class810[0].method_1();
     WaveFormat0 = new WaveFormat(_int4, _short0);
     _double0    = WaveFormat0.int_0 * (WaveFormat0.short_1 / _class810.Length) / (_int3 / 8.0);
     _long1      = 0L;
     if (_class1070 != null && _class1070.method_10())
     {
         _long0 = Convert.ToInt64(_class1070.method_18((int)(FileStream.Length - _int2) / _class810.Length) *
                                  (WaveFormat0.int_0 * (WaveFormat0.short_1 / 1000.0)));
     }
     if (_long0 <= 0L)
     {
         _long0 = (long)((FileStream.Length - _int2) * _double0);
     }
 }
예제 #2
0
파일: MP3Stream.cs 프로젝트: uwx/Open-GHTCP
 public Mp3Stream(Stream stream1, Enum4 enum40, int int5)
 {
     _class810  = new ZzSoundClass81(new Class104(enum40));
     FileStream = stream1;
     _class820  = new Class82(FileStream, int5);
     _int2      = _class820.method_2();
     _long0     = -1L;
     _class1070 = null;
     if (!method_0())
     {
         throw new Mp3Exception("Mp3 Decoder: Cannot read header.");
     }
     _short0     = (short)_class810.method_2();
     _int4       = _class810.method_1();
     WaveFormat0 = new WaveFormat(_int4, _short0);
     _double0    = WaveFormat0.int_0 * WaveFormat0.short_1 / (_int3 / 8.0);
     _long1      = 0L;
     if (_class1070 != null && _class1070.method_10())
     {
         _long0 = Convert.ToInt64(_class1070.method_18((int)(FileStream.Length - _int2)) *
                                  (WaveFormat0.int_0 * (WaveFormat0.short_1 / 1000.0)));
         _class830 = _class1070.method_11();
         if (_class830 != null && _class830.Int2 == -1)
         {
             _class830.Int2 = (int)(FileStream.Length - _int2);
         }
     }
     if (_long0 <= 0L)
     {
         _long0 = (long)((FileStream.Length - _int2) * _double0);
     }
 }