private static MediaCodecBufferFlags GetSyncsampleflags(MediaExtractorSampleFlags mxflag) { switch (mxflag) { case MediaExtractorSampleFlags.None: return(MediaCodecBufferFlags.None); case MediaExtractorSampleFlags.Encrypted: return(MediaCodecBufferFlags.None); case MediaExtractorSampleFlags.Sync: return(MediaCodecBufferFlags.SyncFrame); default: return(MediaCodecBufferFlags.None); } }
private MediaCodecBufferFlags MFlags2MCodecBuff(MediaExtractorSampleFlags mfg) { switch (mfg) { case MediaExtractorSampleFlags.None: return(MediaCodecBufferFlags.None); case MediaExtractorSampleFlags.Encrypted: return(MediaCodecBufferFlags.KeyFrame); case MediaExtractorSampleFlags.Sync: return(MediaCodecBufferFlags.SyncFrame); default: throw new NotImplementedException("ConvertMediaExtractorSampleFlagsToMediaCodecBufferFlags"); } }