21template<
typename T,
typename P>
22class BlockCache :
public SparseCache<T>
25 BlockCache(uint16_t numLayers, uint64_t maxChunkSize, P* blockInitializer)
28 virtual ~BlockCache() =
default;
31 virtual T* create(uint64_t index)
override
50 bool initCodeBlock(T* block, uint64_t
cblkno);
51 void deleteTagTrees();
54 BlockCache<CompressCodeblock, PrecinctImpl>*
enc;
55 BlockCache<DecompressCodeblock, PrecinctImpl>*
dec;
69 void deleteTagTrees();
73 uint32_t getCblkGridwidth(
void);
74 uint32_t getCblkGridHeight(
void);
75 uint32_t getNominalBlockSize(
void);
76 uint64_t getNumCblks(
void);
77 CompressCodeblock* getCompressedBlockPtr(uint64_t
cblkno);
78 DecompressCodeblock* getDecompressedBlockPtr(uint64_t
cblkno);
79 DecompressCodeblock* tryGetDecompressedBlockPtr(uint64_t
cblkno);
88 PrecinctImpl* getImpl(
void)
uint64_t precinctIndex
Definition BlockExec.h:78
uint64_t cblkno
Definition BlockExec.h:79
TileProcessor * tileProcessor
Definition PacketManager.h:100
grk_pt32 cblk_expn_
Definition Precinct.h:58
bool isCompressor_
Definition Precinct.h:59
BlockCache< CompressCodeblock, PrecinctImpl > * enc
Definition Precinct.h:54
TagTreeU16 * incltree
Definition Precinct.h:62
PrecinctImpl * impl
Definition Precinct.h:86
P * blockInitializer_
Definition Precinct.h:39
uint16_t numLayers_
Definition Precinct.h:40
grk_rect32 cblk_grid_
Definition Precinct.h:56
TagTreeU8 * imsbtree
Definition Precinct.h:63
grk_rect32 bounds_
Definition Precinct.h:57
BlockCache< DecompressCodeblock, PrecinctImpl > * dec
Definition Precinct.h:55
grk_rect32 bounds
Definition SparseCanvas.h:275
TagTree< uint16_t > TagTreeU16
Definition TileCache.h:259
TagTree< uint8_t > TagTreeU8
Definition TileCache.h:258
grk_rect< uint32_t > grk_rect32
Definition TileCache.h:61
grk_pt< uint32_t > grk_pt32
Definition TileCache.h:40
Copyright (C) 2016-2023 Grok Image Compression Inc.
Definition ICacheable.h:20
grk_rect< uint32_t > grk_rect32
Definition geometry.h:61