private MediaProgram(AVProgram *ptr) { if (ptr == null) { throw new ArgumentNullException(nameof(ptr)); } _ptr = ptr; }
public static extern AVProgram *av_find_program_from_stream(AVFormatContext *ic, AVProgram *last, int s);
internal static MediaProgram?FromNativeOrNull(AVProgram *ptr) => ptr != null ? new MediaProgram?(new MediaProgram(ptr)) : null;
public static MediaProgram FromNative(AVProgram *ptr) => new MediaProgram(ptr);