mirror of
https://github.com/nyanmisaka/ffmpeg-rockchip.git
synced 2025-10-05 00:43:53 +08:00
avfilter/vf_unsharp: enable slice threading
benchmarking with a simple command: ffmpeg -i 1080p.mp4 -vf unsharp=la=3:ca=3 -an -f null /dev/null with the patch, the fps increase from 50 to 120 on my local machine (i7-6770HQ). Signed-off-by: Ruiling Song <ruiling.song@intel.com>
This commit is contained in:
@@ -37,7 +37,8 @@ typedef struct UnsharpFilterParam {
|
||||
int steps_y; ///< vertical step count
|
||||
int scalebits; ///< bits to shift pixel
|
||||
int32_t halfscale; ///< amount to add to pixel
|
||||
uint32_t *sc[MAX_MATRIX_SIZE - 1]; ///< finite state machine storage
|
||||
uint32_t *sr; ///< finite state machine storage within a row
|
||||
uint32_t **sc; ///< finite state machine storage across rows
|
||||
} UnsharpFilterParam;
|
||||
|
||||
typedef struct UnsharpContext {
|
||||
@@ -47,6 +48,7 @@ typedef struct UnsharpContext {
|
||||
UnsharpFilterParam luma; ///< luma parameters (width, height, amount)
|
||||
UnsharpFilterParam chroma; ///< chroma parameters (width, height, amount)
|
||||
int hsub, vsub;
|
||||
int nb_threads;
|
||||
int opencl;
|
||||
int (* apply_unsharp)(AVFilterContext *ctx, AVFrame *in, AVFrame *out);
|
||||
} UnsharpContext;
|
||||
|
Reference in New Issue
Block a user