2024-11-08 00:00:00 +00:00
|
|
|
#ifndef AVUTILS_H
|
|
|
|
#define AVUTILS_H
|
|
|
|
|
|
|
|
extern "C" {
|
|
|
|
#include <libavformat/avformat.h>
|
|
|
|
}
|
|
|
|
|
2024-11-10 00:00:00 +00:00
|
|
|
#define CALC_FFMPEG_VERSION(a, b, c) (a << 16 | b << 8 | c)
|
|
|
|
|
2024-12-01 09:55:56 +00:00
|
|
|
AVRational get_video_frame_rate(AVFormatContext *ifmt_ctx, int in_vstream_idx);
|
|
|
|
|
2024-11-08 00:00:00 +00:00
|
|
|
int64_t get_video_frame_count(AVFormatContext *ifmt_ctx, int in_vstream_idx);
|
|
|
|
|
2024-11-10 00:00:00 +00:00
|
|
|
enum AVPixelFormat
|
|
|
|
get_encoder_default_pix_fmt(const AVCodec *encoder, AVPixelFormat target_pix_fmt);
|
|
|
|
|
2024-12-01 09:55:56 +00:00
|
|
|
float get_frame_diff(AVFrame *frame1, AVFrame *frame2);
|
|
|
|
|
2024-11-08 00:00:00 +00:00
|
|
|
#endif // AVUTILS_H
|