1234567891011121314151617181920212223242526272829303132333435 |
- #ifndef API_VIDEO_CODECS_VIDEO_DECODER_H_
- #define API_VIDEO_CODECS_VIDEO_DECODER_H_
- #include "../videoutil.h"
- #include "video_encoder_defines.h"
- typedef struct _DecoderConfig{
- int width;
- int height;
- int color_space; //VIDEO_FORMAT_I420 or VIDEO_FORMAT_RGB24
- int decode_id; //ffmpeg decoder enum
- }DecoderConfig;
- typedef struct _DecoderedFrame{
- video_frame *frame;
- int key_frame;
- }DecoderedFrame;
- typedef struct _VideoDecoder VideoDecoder;
- VideoDecoder *video_decoder_open(const DecoderConfig *config, VideoCodingLogCallBack *log_func);
- video_frame *video_decoder_process(VideoDecoder *obj, unsigned char *input_packet,
- int length, int *remain_length, int *key_frame);
- void video_decoder_close(VideoDecoder *obj);
- #endif // API_VIDEO_CODECS_VIDEO_ENCODER_H_
|