Exemple #1
0
        public VideoReader(MkvMediaFile file, TrackEntry track, VideoParams videoParams, EncodedQueue queue) :
            base(file, track)
        {
            this.queue = queue;
#if DEBUG
            if (null == queue)
            {
                return;
            }
#endif
            // Enqueue SPS and PPS NALUs
            videoParams.enqueueParameters(queue);
        }
Exemple #2
0
        public VideoTrack(MkvMediaFile file, TrackEntry track)
        {
            this.file  = file;
            this.track = track;
            videoCodec = file.segment.videoCodec;
            switch (videoCodec)
            {
            case eVideoCodec.h264:
                videoParams = new VideoParams264(track);
                break;

            case eVideoCodec.h265:
                videoParams = new VideoParams265(track);
                break;

            default:
                throw new ApplicationException("Unexpected eVideoCodec value");
            }

            maxBytesInFrame = MaxEncodedSize.find(file, track, videoParams.decodedSize.size);
        }