FFmpeg
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
vc2enc_dwt.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2016 Open Broadcast Systems Ltd.
3  * Author 2016 Rostislav Pehlivanov <atomnuker@gmail.com>
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 AVCODEC_VC2ENC_DWT_H
23 #define AVCODEC_VC2ENC_DWT_H
24 
25 #include <stddef.h>
26 #include <stdint.h>
27 
28 typedef int16_t dwtcoef;
29 typedef int32_t qcoef; /* Quantization needs more precision */
30 
31 /* Only Deslauriers-Dubuc (9,7) and LeGall (5,3) supported! */
32 
34  VC2_TRANSFORM_9_7 = 0, /* Deslauriers-Dubuc (9,7) */
35  VC2_TRANSFORM_5_3 = 1, /* LeGall (5,3) */
36  VC2_TRANSFORM_13_7 = 2, /* Deslauriers-Dubuc (13,7) */
37  VC2_TRANSFORM_HAAR = 3, /* Haar without shift */
38  VC2_TRANSFORM_HAAR_S = 4, /* Haar with 1 shift/lvl */
39  VC2_TRANSFORM_FIDEL = 5, /* Fidelity filter */
40  VC2_TRANSFORM_9_7_I = 6, /* Daubechies (9,7) */
41 
43 };
44 
45 typedef struct VC2TransformContext {
48  dwtcoef *data, ptrdiff_t stride,
49  int width, int height);
51 
52 int ff_vc2enc_init_transforms(VC2TransformContext *t, int p_width, int p_height);
54 
55 #endif /* AVCODEC_VC2ENC_DWT_H */
ptrdiff_t const GLvoid * data
Definition: opengl_enc.c:101
int ff_vc2enc_init_transforms(VC2TransformContext *t, int p_width, int p_height)
Definition: vc2enc_dwt.c:214
int16_t dwtcoef
Definition: vc2enc_dwt.h:28
typedef void(APIENTRY *FF_PFNGLACTIVETEXTUREPROC)(GLenum texture)
int32_t
void ff_vc2enc_free_transforms(VC2TransformContext *t)
Definition: vc2enc_dwt.c:226
BYTE int const BYTE int int int height
Definition: avisynth_c.h:676
void(* vc2_subband_dwt[VC2_TRANSFORMS_NB])(struct VC2TransformContext *t, dwtcoef *data, ptrdiff_t stride, int width, int height)
Definition: vc2enc_dwt.h:47
dwtcoef * buffer
Definition: vc2enc_dwt.h:46
VC2TransformType
Definition: vc2enc_dwt.h:33
#define stride
int32_t qcoef
Definition: vc2enc_dwt.h:29
static int width