private static VBRData findVBR(BufferedBinaryReader source, long position) { VBRData result; byte[] data = new byte[4]; // Check for VBR header at given position source.Seek(position, SeekOrigin.Begin); source.Read(data, 0, 4); string vbrId = Utils.Latin1Encoding.GetString(data); if (VBR_ID_XING.Equals(vbrId)) { result = getXingInfo(source); } else if (VBR_ID_FHG.Equals(vbrId)) { result = getFhGInfo(source); } else { result = new VBRData(); result.Reset(); } return(result); }
// ---------- CONSTRUCTORS & INITIALIZERS protected void resetData() { vbrData.Reset(); HeaderFrame.Reset(); }