public void read(EndianBinaryReader r) { Count = r.ReadInt32(); BPMs = new Bpm[Count]; for (int i = 0; i < Count; i++) { var obj = new Bpm(); obj.read(r); BPMs[i] = obj; } }
public void read(BinaryReader r) { this.Count = r.ReadInt32(); this.BPMs = new Bpm[this.Count]; for (int i = 0; i < this.Count; i++) { Bpm obj = new Bpm(); obj.read(r); this.BPMs[i] = obj; } }
public void read(EndianBinaryReader r) { try { Count = r.ReadInt32(); BPMs = new Bpm[Count]; for (int i = 0; i < Count; i++) { var obj = new Bpm(); obj.read(r); BPMs[i] = obj; } } catch (Exception ex) { // incomplete song information may cause exceptions during conversion // such as, "End of Stream reached with 4 bytes left to read" throw new Exception("Corrupt CDLC ... Regenerating or Converting the original with Creator GUI may fix it." + Environment.NewLine + "Make sure the song information is complete and correct, including Song Year and Avg Tempo information. (HINT)" + Environment.NewLine + ex.Message + Environment.NewLine + Environment.NewLine); } }
public void read(EndianBinaryReader r) { //if (r.BaseStream.Length >0) //{ Count = r.ReadInt32(); BPMs = new Bpm[Count]; for (int i = 0; i < Count; i++) { var obj = new Bpm(); obj.read(r); BPMs[i] = obj; } //} }
public void read(EndianBinaryReader r) { try { Count = r.ReadInt32(); BPMs = new Bpm[Count]; for (int i = 0; i < Count; i++) { var obj = new Bpm(); obj.read(r); BPMs[i] = obj; } } catch (Exception ex) { // incomplete song information causes exceptions during conversion // such as, "End of Stream reached with 4 bytes left to read" throw new Exception("Corrupt CDLC ... Regenerating with Creator GUI may fix it." + Environment.NewLine + "Make sure the song information is complete and correct, including Song Year and Avg Tempo information. (HINT)" + Environment.NewLine + ex.Message + Environment.NewLine + Environment.NewLine); } }
public void read(BinaryReader r) { this.Count = r.ReadInt32(); this.BPMs = new Bpm[this.Count]; for (int i=0; i<this.Count; i++) { Bpm obj = new Bpm(); obj.read(r); this.BPMs[i] = obj; } }