public static HResult TimeSeek(this IMFByteStreamTimeSeek timeSeek, TimeSpan timePosition)
        {
            if (timeSeek == null)
            {
                throw new ArgumentNullException("timeSeek");
            }

            return(timeSeek.TimeSeek(timePosition.Ticks));
        }
        public static HResult GetTimeSeekResult(this IMFByteStreamTimeSeek timeSeek, out TimeSpan startTime, out TimeSpan stopTime, out TimeSpan duration)
        {
            if (timeSeek == null)
            {
                throw new ArgumentNullException("timeSeek");
            }

            long start, stop, dur;

            HResult hr = timeSeek.GetTimeSeekResult(out start, out stop, out dur);

            startTime = TimeSpan.FromTicks(start);
            stopTime  = TimeSpan.FromTicks(stop);
            duration  = TimeSpan.FromTicks(dur);

            return(hr);
        }