public int SetCurrentTimeEx(double seekTime, MF_MEDIA_ENGINE_SEEK_MODE seekMode) { return(((delegate * unmanaged <IMFMediaEngineEx *, double, MF_MEDIA_ENGINE_SEEK_MODE, int>)(lpVtbl[80]))((IMFMediaEngineEx *)Unsafe.AsPointer(ref this), seekTime, seekMode)); }
/// <summary> /// Seeks to a new playback position using the specified <see cref="MF_MEDIA_ENGINE_SEEK_MODE"/>. /// </summary> /// <param name="mediaEngine">A valid IMFMediaBufferEx instance.</param> /// <param name="seekTime">The new playback position.</param> /// <param name="seekMode">Specifies if the seek is a normal seek or an approximate seek.</param> /// <returns>If this function succeeds, it returns the S_OK member. Otherwise, it returns another HResult's member that describe the error.</returns> public static HResult SetCurrentTimeEx(this IMFMediaEngineEx mediaEngine, TimeSpan seekTime, MF_MEDIA_ENGINE_SEEK_MODE seekMode) { if (mediaEngine == null) { throw new ArgumentNullException("mediaEngine"); } return(mediaEngine.SetCurrentTimeEx(seekTime.TotalSeconds, seekMode)); }