Skip to content

Commit 684625d

Browse files
committed
change ratio to 1..2 from 1..4
Signed-off-by: Liang <[email protected]>
1 parent 80634df commit 684625d

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ ffmpeg -init_hw_device vaapi=va -init_hw_device opencl=ocl@va -hwaccel vaapi -hw
6868
`./ffmpeg -h filter=raisr`
6969

7070
raisr AVOptions:
71-
ratio <float> ..FV....... ratio of the upscaling, between 1 and 4 (from 1 to 4) (default 2)
71+
ratio <float> ..FV....... ratio of the upscaling, between 1 and 2 (default 2)
7272
bits <int> ..FV....... bit depth (from 8 to 10) (default 8)
7373
range <string> ..FV....... color range of the input. If you are working with images, you may want to set range to full (video/full) (default video)
7474
threadcount <int> ..FV....... thread count (from 1 to 120) (default 20)

ffmpeg/vf_raisr.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
#include <unistd.h>
3939

4040
#define MIN_RATIO 1
41-
#define MAX_RATIO 4
41+
#define MAX_RATIO 2
4242
#define DEFAULT_RATIO 2
4343

4444
#define MIN_THREADCOUNT 1
@@ -78,7 +78,7 @@ typedef struct RaisrContext
7878
#define OFFSET(x) offsetof(RaisrContext, x)
7979
#define FLAGS AV_OPT_FLAG_FILTERING_PARAM | AV_OPT_FLAG_VIDEO_PARAM
8080
static const AVOption raisr_options[] = {
81-
{"ratio", "ratio of the upscaling, between 1 and 4", OFFSET(ratio), AV_OPT_TYPE_FLOAT, {.dbl = DEFAULT_RATIO}, MIN_RATIO, MAX_RATIO, FLAGS},
81+
{"ratio", "ratio of the upscaling, between 1 and 2", OFFSET(ratio), AV_OPT_TYPE_FLOAT, {.dbl = DEFAULT_RATIO}, MIN_RATIO, MAX_RATIO, FLAGS},
8282
{"bits", "bit depth", OFFSET(bits), AV_OPT_TYPE_INT, {.i64 = 8}, 8, 10, FLAGS},
8383
{"range", "input color range", OFFSET(range), AV_OPT_TYPE_STRING, {.str = "video"}, 0, 0, FLAGS},
8484
{"threadcount", "thread count", OFFSET(threadcount), AV_OPT_TYPE_INT, {.i64 = DEFAULT_THREADCOUNT}, MIN_THREADCOUNT, MAX_THREADCOUNT, FLAGS},

ffmpeg/vf_raisr_opencl.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
#include "libavutil/pixdesc.h"
2828

2929
#define MIN_RATIO 1
30-
#define MAX_RATIO 4
30+
#define MAX_RATIO 2
3131
#define DEFAULT_RATIO 2
3232

3333
typedef struct RaisrOpenCLContext {
@@ -212,7 +212,7 @@ static av_cold void raisr_opencl_uninit(AVFilterContext *avctx)
212212
#define OFFSET(x) offsetof(RaisrOpenCLContext, x)
213213
#define FLAGS (AV_OPT_FLAG_FILTERING_PARAM | AV_OPT_FLAG_VIDEO_PARAM)
214214
static const AVOption raisr_opencl_options[] = {
215-
{"ratio", "ratio (currently only ratio of 2 is supported)", OFFSET(ratio),
215+
{"ratio", "ratio of the upscaling, between 1 and 2", OFFSET(ratio),
216216
AV_OPT_TYPE_FLOAT, {.dbl = DEFAULT_RATIO}, MIN_RATIO, MAX_RATIO, FLAGS},
217217
{"bits", "bit depth", OFFSET(bits), AV_OPT_TYPE_INT, {.i64 = 8}, 8, 10, FLAGS},
218218
{"range", "input color range", OFFSET(range), AV_OPT_TYPE_INT, {.i64 = VideoRange}, VideoRange, FullRange, FLAGS, "range"},

0 commit comments

Comments
 (0)