using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using skyscraper5.Mpeg2;
using skyscraper5.Skyscraper.IO;
using skyscraper5.Skyscraper.Plugins;

namespace skyscraper5.Dvb.DataBroadcasting.DataCarouselDescriptors
{
	[SkyscraperPlugin]
	[TsDescriptor(0x09,"DataCarousel")]
    class CompressedModuleDescriptor : TsDescriptor
    {
        public CompressedModuleDescriptor(byte[] buffer)
        {
            MemoryStream ms = new MemoryStream(buffer, false);
            CompressionMethod = ms.ReadUInt8();
            OriginalSize = ms.ReadUInt32BE();
        }

        public uint OriginalSize { get; private set; }

        public byte CompressionMethod { get; private set; }
    }
}
