|
@@ -46,29 +46,29 @@ typedef struct { |
|
|
#define FLAGS AV_OPT_FLAG_FILTERING_PARAM|AV_OPT_FLAG_VIDEO_PARAM |
|
|
#define FLAGS AV_OPT_FLAG_FILTERING_PARAM|AV_OPT_FLAG_VIDEO_PARAM |
|
|
|
|
|
|
|
|
static const AVOption vidstabtransform_options[] = { |
|
|
static const AVOption vidstabtransform_options[] = { |
|
|
{"input", "path to the file storing the transforms (def:transforms.trf)", OFFSET(input), |
|
|
|
|
|
|
|
|
{"input", "path to the file storing the transforms", OFFSET(input), |
|
|
AV_OPT_TYPE_STRING, {.str = DEFAULT_INPUT_NAME}, .flags = FLAGS }, |
|
|
AV_OPT_TYPE_STRING, {.str = DEFAULT_INPUT_NAME}, .flags = FLAGS }, |
|
|
{"smoothing", "number of frames*2 + 1 used for lowpass filtering (def: 10)", OFFSETC(smoothing), |
|
|
|
|
|
|
|
|
{"smoothing", "number of frames*2 + 1 used for lowpass filtering", OFFSETC(smoothing), |
|
|
AV_OPT_TYPE_INT, {.i64 = 10}, 1, 1000, FLAGS}, |
|
|
AV_OPT_TYPE_INT, {.i64 = 10}, 1, 1000, FLAGS}, |
|
|
{"maxshift", "maximal number of pixels to translate image (def: -1 no limit)", OFFSETC(maxShift), |
|
|
|
|
|
|
|
|
{"maxshift", "maximal number of pixels to translate image", OFFSETC(maxShift), |
|
|
AV_OPT_TYPE_INT, {.i64 = -1}, -1, 500, FLAGS}, |
|
|
AV_OPT_TYPE_INT, {.i64 = -1}, -1, 500, FLAGS}, |
|
|
{"maxangle", "maximal angle in rad to rotate image (def: -1 no limit)", OFFSETC(maxAngle), |
|
|
|
|
|
|
|
|
{"maxangle", "maximal angle in rad to rotate image", OFFSETC(maxAngle), |
|
|
AV_OPT_TYPE_DOUBLE, {.dbl = -1.0}, -1.0, 3.14, FLAGS}, |
|
|
AV_OPT_TYPE_DOUBLE, {.dbl = -1.0}, -1.0, 3.14, FLAGS}, |
|
|
{"crop", "keep: (def), black", OFFSETC(crop), |
|
|
|
|
|
|
|
|
{"crop", "set cropping mode", OFFSETC(crop), |
|
|
AV_OPT_TYPE_INT, {.i64 = 0}, 0, 1, FLAGS, "crop"}, |
|
|
AV_OPT_TYPE_INT, {.i64 = 0}, 0, 1, FLAGS, "crop"}, |
|
|
{ "keep", "keep border", 0, |
|
|
{ "keep", "keep border", 0, |
|
|
AV_OPT_TYPE_CONST, {.i64 = VSKeepBorder }, 0, 0, FLAGS, "crop"}, |
|
|
AV_OPT_TYPE_CONST, {.i64 = VSKeepBorder }, 0, 0, FLAGS, "crop"}, |
|
|
{ "black", "black border", 0, |
|
|
{ "black", "black border", 0, |
|
|
AV_OPT_TYPE_CONST, {.i64 = VSCropBorder }, 0, 0, FLAGS, "crop"}, |
|
|
AV_OPT_TYPE_CONST, {.i64 = VSCropBorder }, 0, 0, FLAGS, "crop"}, |
|
|
{"invert", "1: invert transforms (def: 0)", OFFSETC(invert), |
|
|
|
|
|
|
|
|
{"invert", "1: invert transforms", OFFSETC(invert), |
|
|
AV_OPT_TYPE_INT, {.i64 = 0}, 0, 1, FLAGS}, |
|
|
AV_OPT_TYPE_INT, {.i64 = 0}, 0, 1, FLAGS}, |
|
|
{"relative", "consider transforms as 0: absolute, 1: relative (def)", OFFSETC(relative), |
|
|
|
|
|
|
|
|
{"relative", "consider transforms as 0: absolute, 1: relative", OFFSETC(relative), |
|
|
AV_OPT_TYPE_INT, {.i64 = 1}, 0, 1, FLAGS}, |
|
|
AV_OPT_TYPE_INT, {.i64 = 1}, 0, 1, FLAGS}, |
|
|
{"zoom", "percentage to zoom >0: zoom in, <0 zoom out (def: 0)", OFFSETC(zoom), |
|
|
|
|
|
|
|
|
{"zoom", "percentage to zoom >0: zoom in, <0 zoom out", OFFSETC(zoom), |
|
|
AV_OPT_TYPE_DOUBLE, {.dbl = 0}, 0, 100, FLAGS}, |
|
|
AV_OPT_TYPE_DOUBLE, {.dbl = 0}, 0, 100, FLAGS}, |
|
|
{"optzoom", "0: nothing, 1: determine optimal zoom (def) (added to 'zoom')", OFFSETC(optZoom), |
|
|
|
|
|
|
|
|
{"optzoom", "0: nothing, 1: determine optimal zoom (added to 'zoom')", OFFSETC(optZoom), |
|
|
AV_OPT_TYPE_INT, {.i64 = 1}, 0, 1, FLAGS}, |
|
|
AV_OPT_TYPE_INT, {.i64 = 1}, 0, 1, FLAGS}, |
|
|
{"interpol", "type of interpolation, no, linear, bilinear (def) , bicubic", OFFSETC(interpolType), |
|
|
|
|
|
|
|
|
{"interpol", "type of interpolation", OFFSETC(interpolType), |
|
|
AV_OPT_TYPE_INT, {.i64 = 2}, 0, 3, FLAGS, "interpol"}, |
|
|
AV_OPT_TYPE_INT, {.i64 = 2}, 0, 3, FLAGS, "interpol"}, |
|
|
{ "no", "no interpolation", 0, |
|
|
{ "no", "no interpolation", 0, |
|
|
AV_OPT_TYPE_CONST, {.i64 = VS_Zero }, 0, 0, FLAGS, "interpol"}, |
|
|
AV_OPT_TYPE_CONST, {.i64 = VS_Zero }, 0, 0, FLAGS, "interpol"}, |
|
|