Uploads decoded image Tensors to OpenGL textures, keyed and cached by an arbitrary integer key (e....
Definition texture_cache.hpp:26
TextureCache(const TextureCache &)=delete
TextureCache & operator=(const TextureCache &)=delete
TextureId GetOrUpload(int64_t key, const Tensor &image_chw)
Returns the cached texture for key, uploading image_chw first if not cached.
void Clear()
Deletes every cached GL texture and clears the cache.