2024-12-04 08:06:35 +00:00
|
|
|
#pragma once
|
2024-11-08 00:00:00 +00:00
|
|
|
|
|
|
|
extern "C" {
|
|
|
|
#include <libavformat/avformat.h>
|
|
|
|
}
|
|
|
|
|
2024-12-17 16:24:51 +00:00
|
|
|
namespace video2x {
|
|
|
|
namespace avutils {
|
|
|
|
|
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-12-03 05:22:07 +00:00
|
|
|
AVPixelFormat get_encoder_default_pix_fmt(const AVCodec *encoder, AVPixelFormat target_pix_fmt);
|
2024-11-10 00:00:00 +00:00
|
|
|
|
2024-12-01 09:55:56 +00:00
|
|
|
float get_frame_diff(AVFrame *frame1, AVFrame *frame2);
|
|
|
|
|
2024-12-03 05:22:07 +00:00
|
|
|
void av_bufferref_deleter(AVBufferRef *bufferref);
|
|
|
|
|
|
|
|
void av_frame_deleter(AVFrame *frame);
|
|
|
|
|
|
|
|
void av_packet_deleter(AVPacket *packet);
|
2024-12-17 16:24:51 +00:00
|
|
|
|
|
|
|
} // namespace avutils
|
|
|
|
} // namespace video2x
|