public static Codec getDecoderById ( CodecID codecId ) throws JavaAVException { if ( codecId == null ) throw new NullPointerException ( "CodecID is null." ) ; AVCodec avCodec = avcodec_find_decoder ( codecId . value ( ) ) ; if ( avCodec == null || avCodec . isNull ( ) ) throw new JavaAVException ( "Decoder not found: " + codecId . toString ( ) ) ; Codec codec = new Codec ( ) ; codec . avCodec = avCodec ; return codec ; }
Create a new decoder with specified codec id .