FFmpeg
unsharp.h
1 /*
2  * Copyright (C) 2013 Wei Gao <weigao@multicorewareinc.com>
3  * Copyright (C) 2013 Lenny Wang
4  *
5  * This file is part of FFmpeg.
6  *
7  * FFmpeg is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU Lesser General Public
9  * License as published by the Free Software Foundation; either
10  * version 2.1 of the License, or (at your option) any later version.
11  *
12  * FFmpeg is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15  * Lesser General Public License for more details.
16  *
17  * You should have received a copy of the GNU Lesser General Public
18  * License along with FFmpeg; if not, write to the Free Software
19  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20  */
21 
22 #ifndef AVFILTER_UNSHARP_H
23 #define AVFILTER_UNSHARP_H
24 
25 #include "config.h"
26 #include "avfilter.h"
27 
28 #define MIN_MATRIX_SIZE 3
29 #define MAX_MATRIX_SIZE 63
30 
31 
32 typedef struct UnsharpFilterParam {
33  int msize_x;
34  int msize_y;
35  int amount;
36  int steps_x;
37  int steps_y;
38  int scalebits;
39  int32_t halfscale;
40  uint32_t *sc[MAX_MATRIX_SIZE - 1];
42 
43 typedef struct UnsharpContext {
44  const AVClass *class;
45  int lmsize_x, lmsize_y, cmsize_x, cmsize_y;
46  float lamount, camount;
49  int hsub, vsub;
50  int opencl;
51  int (* apply_unsharp)(AVFilterContext *ctx, AVFrame *in, AVFrame *out);
53 
54 #endif /* AVFILTER_UNSHARP_H */
This structure describes decoded (raw) audio or video data.
Definition: frame.h:218
Main libavfilter public API header.
UnsharpFilterParam luma
luma parameters (width, height, amount)
Definition: unsharp.h:47
int msize_y
matrix height
Definition: unsharp.h:34
uint32_t * sc[MAX_MATRIX_SIZE - 1]
finite state machine storage
Definition: unsharp.h:40
int steps_x
horizontal step count
Definition: unsharp.h:36
Definition: unsharp.h:32
int scalebits
bits to shift pixel
Definition: unsharp.h:38
Definition: unsharp.h:43
int32_t halfscale
amount to add to pixel
Definition: unsharp.h:39
int amount
effect amount
Definition: unsharp.h:35
int steps_y
vertical step count
Definition: unsharp.h:37
int msize_x
matrix width
Definition: unsharp.h:33
Describe the class of an AVClass context structure.
Definition: log.h:67
UnsharpFilterParam chroma
chroma parameters (width, height, amount)
Definition: unsharp.h:48
An instance of a filter.
Definition: avfilter.h:338