Grok
7.6.0
build
libgrokj2k-CKORTy
libgrokj2k-7.6.0
src
lib
jp2
transform
dwt97.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2016-2020 Grok Image Compression Inc.
3
*
4
* This source code is free software: you can redistribute it and/or modify
5
* it under the terms of the GNU Affero General Public License, version 3,
6
* as published by the Free Software Foundation.
7
*
8
* This source code is distributed in the hope that it will be useful,
9
* but WITHOUT ANY WARRANTY; without even the implied warranty of
10
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11
* GNU Affero General Public License for more details.
12
*
13
* You should have received a copy of the GNU Affero General Public License
14
* along with this program. If not, see <http://www.gnu.org/licenses/>.
15
*
16
*
17
* This source code incorporates work covered by the BSD 2-clause license.
18
* Please see the LICENSE file in the root directory for details.
19
*
20
*/
21
22
#pragma once
23
24
#include <stdint.h>
25
26
namespace
grk
{
27
28
typedef
union
{
29
float
f[4];
30
}
grk_dwt_4vec
;
31
32
struct
grk_dwt97_info
{
33
grk_dwt_4vec
*
mem
;
34
uint32_t
d_n
;
35
uint32_t
s_n
;
36
uint8_t
cas
;
37
};
38
39
/* process four coefficients at a time*/
40
typedef
union
{
41
float
f[4];
42
}
grk_coeff97
;
43
44
struct
grk_dwt97
{
45
int64_t
bufferShiftEven
();
46
int64_t
bufferShiftOdd
();
47
grk_coeff97
*
data
;
48
size_t
dataSize
;
// number of floats (four per grk_coeff97 struct)
49
uint32_t
d_n
;
50
uint32_t
s_n
;
51
grk_pt
range_even
;
52
grk_pt
range_odd
;
53
int64_t
interleaved_offset
;
54
uint8_t
odd_top_left_bit
;
55
};
56
57
class
dwt97
{
58
public
:
59
63
void
encode_line
(int32_t*
GRK_RESTRICT
a, int32_t d_n, int32_t s_n, uint8_t cas);
64
65
};
66
}
grk::grk_point< int64_t >
grk::grk_dwt97::range_even
grk_pt range_even
Definition:
dwt97.h:51
grk::grk_dwt97_info::s_n
uint32_t s_n
Definition:
dwt97.h:35
grk::grk_dwt97_info::mem
grk_dwt_4vec * mem
Definition:
dwt97.h:33
grk::dwt97
Definition:
dwt97.h:57
grk::grk_dwt97::s_n
uint32_t s_n
Definition:
dwt97.h:50
grk::grk_dwt97_info
Definition:
dwt97.h:32
grk::grk_dwt97
Definition:
dwt97.h:44
grk::grk_dwt97::interleaved_offset
int64_t interleaved_offset
Definition:
dwt97.h:53
grk::grk_dwt97::dataSize
size_t dataSize
Definition:
dwt97.h:48
grk::grk_coeff97
Definition:
dwt97.h:40
grk::grk_dwt97_info::cas
uint8_t cas
Definition:
dwt97.h:36
grk::grk_dwt97::bufferShiftEven
int64_t bufferShiftEven()
GRK_RESTRICT
#define GRK_RESTRICT
Definition:
grok_includes.h:102
grk
Copyright (C) 2016-2020 Grok Image Compression Inc.
Definition:
BitIO.h:27
grk::dwt97::encode_line
void encode_line(int32_t *GRK_RESTRICT a, int32_t d_n, int32_t s_n, uint8_t cas)
Forward 9-7 wavelet transform in 1-D.
grk::grk_dwt97::range_odd
grk_pt range_odd
Definition:
dwt97.h:52
grk::grk_dwt97_info::d_n
uint32_t d_n
Definition:
dwt97.h:34
grk::grk_dwt97::d_n
uint32_t d_n
Definition:
dwt97.h:49
grk::grk_dwt97::odd_top_left_bit
uint8_t odd_top_left_bit
Definition:
dwt97.h:54
grk::grk_dwt97::bufferShiftOdd
int64_t bufferShiftOdd()
grk::grk_dwt97::data
grk_coeff97 * data
Definition:
dwt97.h:47
grk::grk_dwt_4vec
Definition:
dwt97.h:28
Generated by
1.8.18