mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-12-14 19:10:09 +01:00
fftools/ffmpeg: support applying container level cropping
Signed-off-by: James Almer <jamrial@gmail.com>
This commit is contained in:
@@ -155,6 +155,7 @@ typedef struct OptionsContext {
|
||||
SpecifierOptList hwaccel_devices;
|
||||
SpecifierOptList hwaccel_output_formats;
|
||||
SpecifierOptList autorotate;
|
||||
SpecifierOptList apply_cropping;
|
||||
|
||||
/* output options */
|
||||
StreamMap *stream_maps;
|
||||
@@ -239,6 +240,7 @@ enum IFilterFlags {
|
||||
IFILTER_FLAG_AUTOROTATE = (1 << 0),
|
||||
IFILTER_FLAG_REINIT = (1 << 1),
|
||||
IFILTER_FLAG_CFR = (1 << 2),
|
||||
IFILTER_FLAG_CROP = (1 << 3),
|
||||
};
|
||||
|
||||
typedef struct InputFilterOptions {
|
||||
@@ -254,6 +256,11 @@ typedef struct InputFilterOptions {
|
||||
* accurate */
|
||||
AVRational framerate;
|
||||
|
||||
unsigned crop_top;
|
||||
unsigned crop_bottom;
|
||||
unsigned crop_left;
|
||||
unsigned crop_right;
|
||||
|
||||
int sub2video_width;
|
||||
int sub2video_height;
|
||||
|
||||
@@ -539,6 +546,13 @@ typedef struct KeyframeForceCtx {
|
||||
|
||||
typedef struct Encoder Encoder;
|
||||
|
||||
enum CroppingType {
|
||||
CROP_DISABLED = 0,
|
||||
CROP_ALL,
|
||||
CROP_CODEC,
|
||||
CROP_CONTAINER,
|
||||
};
|
||||
|
||||
typedef struct OutputStream {
|
||||
const AVClass *class;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user