Grok 10.0.5
Subband.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2016-2023 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#pragma once
18
19#include "grk_includes.h"
20#include <map>
21
22namespace grk
23{
24
25struct Subband : public grk_rect32
26{
27 Subband();
28 Subband(const Subband& rhs);
29 virtual ~Subband() = default;
30 Subband& operator=(const Subband& rhs);
31 void print() const override;
32 bool empty();
33 Precinct* getPrecinct(uint64_t precinctIndex);
34 grk_rect32 generatePrecinctBounds(uint64_t precinctIndex, grk_pt32 precinctPartitionTopLeft,
35 grk_pt32 precinctExpn, uint32_t precinctGridWidth);
36 Precinct* createPrecinct(TileProcessor* tileProcessor, uint64_t precinctIndex,
37 grk_pt32 precinctPartitionTopLeft, grk_pt32 precinctExpn,
38 uint32_t precinctGridWidth, grk_pt32 cblk_expn);
39 eBandOrientation orientation;
40 std::vector<Precinct*> precincts;
41 // maps global precinct index to precincts vector index
42 std::map<uint64_t, uint64_t> precinctMap;
43 uint64_t numPrecincts;
44 uint8_t numbps;
45 float stepsize;
46};
47
48} // namespace grk
uint64_t precinctIndex
Definition BlockExec.h:78
float stepsize
Definition BlockExec.h:34
uint8_t numbps
Definition Codeblock.h:115
TileProcessor * tileProcessor
Definition PacketManager.h:100
grk_pt32 precinctPartitionTopLeft
Definition Resolution.h:37
uint32_t precinctGridWidth
Definition Resolution.h:35
grk_pt32 precinctExpn
Definition Resolution.h:38
std::map< uint64_t, uint64_t > precinctMap
Definition Subband.h:42
std::vector< Precinct * > precincts
Definition Subband.h:40
uint64_t numPrecincts
Definition Subband.h:43
grk_rect< uint32_t > grk_rect32
Definition TileCache.h:61
Copyright (C) 2016-2023 Grok Image Compression Inc.
Definition ICacheable.h:20
grk_rect< uint32_t > grk_rect32
Definition geometry.h:61
uint8_t orientation
Definition plugin_interface.h:42