Пример #1
0
        /// <summary>
        /// Writing Data to specific TagStream
        /// </summary>
        /// <param name="wr">TagStream to write data</param>
        /// <param name="MinorVersion">ID3 minor version</param>
        protected override void OnWritingData(int MinorVersion)
        {
            byte[] Buf;

            TStream.FS.WriteByte((byte)_TimeStamp);

            _TempoCodes.Sort();

            foreach (TempoCode TC in _TempoCodes.ToArray())
            {
                Buf = TC.Data();
                TStream.FS.Write(Buf, 0, Buf.Length);
            }
        }
Пример #2
0
        /// <summary>
        /// Gets MemoryStream to save current frame
        /// </summary>
        /// <returns>MemoryStream contain frame information</returns>
        public override MemoryStream FrameStream(int MinorVersion)
        {
            byte[]       Buf;
            MemoryStream ms = FrameHeader(MinorVersion);

            ms.WriteByte((byte)_TimeStamp);

            _TempoCodes.Sort();

            foreach (TempoCode TC in _TempoCodes.Items)
            {
                Buf = TC.Data();
                ms.Write(Buf, 0, Buf.Length);
            }

            return(ms);
        }