FFmpeg
Loading...
Searching...
No Matches
cfhd.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2015 Kieran Kunhya
3 *
4 * This file is part of FFmpeg.
5 *
6 * FFmpeg is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
10 *
11 * FFmpeg is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
15 *
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with FFmpeg; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19 */
20
21#ifndef AVCODEC_CFHD_H
22#define AVCODEC_CFHD_H
23
24#include <stdint.h>
25
26#include "avcodec.h"
27#include "bytestream.h"
28#include "cfhddsp.h"
29
93
102
103#define VLC_BITS 9
104#define SUBBAND_COUNT 10
105#define SUBBAND_COUNT_3D 17
106
107typedef struct CFHD_RL_VLC_ELEM {
108 int16_t level;
109 int8_t len8;
110 uint16_t run;
112
113#define DWT_LEVELS 3
114#define DWT_LEVELS_3D 6
115
116typedef struct SubBand {
117 ptrdiff_t stride;
119 int width;
122 int8_t read_ok;
123} SubBand;
124
125typedef struct Plane {
126 int width;
128 ptrdiff_t stride;
129
130 int16_t *idwt_buf;
131 int16_t *idwt_tmp;
133
134 /* TODO: merge this into SubBand structure */
136 int16_t *l_h[10];
137
139} Plane;
140
141typedef struct Peak {
142 int level;
145} Peak;
146
191
193
194#endif /* AVCODEC_CFHD_H */
int32_t SampleType
Definition ac3enc.h:66
Libavcodec external API header.
#define s(width, name)
Definition cbs_vp9.c:198
CFHDSegment
Definition cfhd.h:94
@ CoefficientSegment
Definition cfhd.h:100
@ HighPassSegment
Definition cfhd.h:97
@ LowPassSegment
Definition cfhd.h:95
@ HighPassEndSegment
Definition cfhd.h:99
@ BandSegment
Definition cfhd.h:98
@ LowPassEndSegment
Definition cfhd.h:96
int ff_cfhd_init_vlcs(CFHDContext *s)
Definition cfhddata.c:181
CFHDParam
Definition cfhd.h:30
@ Quantization
Definition cfhd.h:72
@ FrameNumber
Definition cfhd.h:78
@ SampleFlags
Definition cfhd.h:77
@ BandHeight
Definition cfhd.h:69
@ NumSpatial
Definition cfhd.h:43
@ NumLevels
Definition cfhd.h:51
@ HighpassWidth
Definition cfhd.h:61
@ SampleIndexTable
Definition cfhd.h:32
@ VersionMajor
Definition cfhd.h:34
@ FirstWavelet
Definition cfhd.h:44
@ EncodedFormat
Definition cfhd.h:88
@ BandWidth
Definition cfhd.h:68
@ PeakOffsetLow
Definition cfhd.h:83
@ LowpassHeight
Definition cfhd.h:53
@ WaveletCount
Definition cfhd.h:41
@ BandSecondPass
Definition cfhd.h:86
@ LowpassPrecision
Definition cfhd.h:56
@ SubbandNumber
Definition cfhd.h:67
@ BandHeader
Definition cfhd.h:74
@ BitstreamMarker
Definition cfhd.h:33
@ LowpassScale
Definition cfhd.h:65
@ PeakLevel
Definition cfhd.h:82
@ PrescaleTable
Definition cfhd.h:87
@ HighpassHeight
Definition cfhd.h:62
@ BandTrailer
Definition cfhd.h:75
@ LowpassSubband
Definition cfhd.h:50
@ PixelOffset
Definition cfhd.h:54
@ VersionEdit
Definition cfhd.h:37
@ BandScale
Definition cfhd.h:73
@ ImageWidth
Definition cfhd.h:47
@ LowpassWidth
Definition cfhd.h:52
@ BandEncoding
Definition cfhd.h:71
@ LowpassBorder
Definition cfhd.h:63
@ DisplayHeight
Definition cfhd.h:89
@ NumFrames
Definition cfhd.h:39
@ PeakOffsetHigh
Definition cfhd.h:84
@ WaveletType
Definition cfhd.h:57
@ WaveletNumber
Definition cfhd.h:58
@ BandCodingFlags
Definition cfhd.h:81
@ HighpassBorder
Definition cfhd.h:64
@ Version
Definition cfhd.h:85
@ Precision
Definition cfhd.h:79
@ GroupTrailer
Definition cfhd.h:45
@ VersionRevision
Definition cfhd.h:36
@ ChannelCount
Definition cfhd.h:40
@ NumBands
Definition cfhd.h:60
@ LowpassDivisor
Definition cfhd.h:66
@ ChannelWidth
Definition cfhd.h:90
@ ChannelHeight
Definition cfhd.h:91
@ ImageHeight
Definition cfhd.h:48
@ SubbandBand
Definition cfhd.h:70
@ ChannelNumber
Definition cfhd.h:76
@ VersionMinor
Definition cfhd.h:35
@ SubbandCount
Definition cfhd.h:42
@ InputFormat
Definition cfhd.h:80
@ FrameIndex
Definition cfhd.h:49
@ LowpassQuantization
Definition cfhd.h:55
@ WaveletLevel
Definition cfhd.h:59
#define DWT_LEVELS_3D
Definition cfhd.h:114
#define SUBBAND_COUNT_3D
Definition cfhd.h:105
FrameType
G723.1 frame types.
Definition g723_1.h:63
AVPixelFormat
Pixel format.
Definition pixfmt.h:71
main external API structure.
Definition avcodec.h:443
uint8_t prescale_table[8]
Definition cfhd.h:185
int frame_index
Definition cfhd.h:157
enum AVPixelFormat coded_format
Definition cfhd.h:163
int cropped_height
Definition cfhd.h:162
int channel_cnt
Definition cfhd.h:172
int channel_num
Definition cfhd.h:175
int a_format
Definition cfhd.h:168
Plane plane[4]
Definition cfhd.h:186
int bpc
Definition cfhd.h:171
int coded_width
Definition cfhd.h:160
int codebook
Definition cfhd.h:179
int subband_cnt
Definition cfhd.h:173
int planes
Definition cfhd.h:155
int a_transform_type
Definition cfhd.h:169
int progressive
Definition cfhd.h:164
int transform_type
Definition cfhd.h:159
Peak peak
Definition cfhd.h:187
int frame_type
Definition cfhd.h:156
int a_height
Definition cfhd.h:167
int subband_num_actual
Definition cfhd.h:183
int band_encoding
Definition cfhd.h:174
int subband_num
Definition cfhd.h:181
uint16_t quantisation
Definition cfhd.h:177
int a_width
Definition cfhd.h:166
int sample_type
Definition cfhd.h:158
int lut[2][256]
Definition cfhd.h:153
int difference_coding
Definition cfhd.h:180
uint8_t lowpass_precision
Definition cfhd.h:176
int level
Definition cfhd.h:182
CFHD_RL_VLC_ELEM table_18_rl_vlc[4572]
Definition cfhd.h:151
CFHDDSPContext dsp
Definition cfhd.h:189
CFHD_RL_VLC_ELEM table_9_rl_vlc[2088]
Definition cfhd.h:150
int coded_height
Definition cfhd.h:161
AVCodecContext * avctx
Definition cfhd.h:148
uint16_t run
Definition cfhd.h:110
int16_t level
Definition cfhd.h:108
int8_t len8
Definition cfhd.h:109
Definition cfhd.h:141
GetByteContext base
Definition cfhd.h:144
int offset
Definition cfhd.h:143
int level
Definition cfhd.h:142
Definition cfhd.h:125
int idwt_size
Definition cfhd.h:132
SubBand band[DWT_LEVELS_3D][4]
Definition cfhd.h:138
int16_t * subband[SUBBAND_COUNT_3D]
Definition cfhd.h:135
ptrdiff_t stride
Definition cfhd.h:128
int width
Definition cfhd.h:126
int height
Definition cfhd.h:127
int16_t * idwt_buf
Definition cfhd.h:130
int16_t * l_h[10]
Definition cfhd.h:136
int16_t * idwt_tmp
Definition cfhd.h:131
ptrdiff_t stride
Definition cfhd.h:117
int a_height
Definition cfhd.h:120
int8_t read_ok
Definition cfhd.h:122
int width
Definition cfhd.h:119
int a_width
Definition cfhd.h:118
int height
Definition cfhd.h:121
TransformType
Definition webp.c:119