AudioEngine/WaveFile.cs
(开头部分) 6KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.IO;
namespace AudioEngine
{
public class WaveFile
{
String _path;
int _nChannels = 0;
int _sampleRate = 0;
int _bps = 0;
UInt32 _nSamples = 0;
float _duration = 0;
int _ChanBlock = 0;
BinaryReader bI;
float[][] _data;
UInt32 _startMarker;
UInt32 _endMarker;
public readonly decimal T;
public float MaxAllowableValue
{
get { return Int16.MaxValue; }
}
public float[][] GetData()
{
float[][] outArr = new float[_nChannels][];
for (int c = 0; c < _nChannels; c++) {
outArr[c] = new float[NSamples];
for (UInt32 pos = _startMarker; pos < _endMarker; pos++)
outArr[c][pos - _startMarker] = _data[c][pos];
}
return outArr;
}
public float Duration
{
get { return _duration; }
}
public int NChannels
{
get { return _nChannels; }
}
public int SampleRate
{
get { return _sampleRate; }
}
public int BPS
{
get { return _bps; }
}
后面还有 157 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。