Exemple #1
0
 VocFormat(VocFormat cloneFrom)
 {
     SampleRate   = cloneFrom.SampleRate;
     stream       = SegmentStream.CreateWithoutOwningStream(cloneFrom.stream, 0, (int)cloneFrom.stream.Length);
     blocks       = cloneFrom.blocks;
     totalSamples = cloneFrom.totalSamples;
     Rewind();
 }
Exemple #2
0
        bool ISoundLoader.TryParseSound(Stream stream, out ISoundFormat sound)
        {
            try
            {
                sound = new VocFormat(stream);
                return(true);
            }
            catch
            {
                // Not a (supported) VOC
            }

            sound = null;
            return(false);
        }
Exemple #3
0
 public VocStream(VocFormat format)
 {
     this.format = format;
 }