#pragma once #include #include #include namespace mbgl { class RenderLayer; class PaintParameters; class RasterBucket; namespace gl { class Context; } // namespace gl class RenderImageSource : public RenderSource { public: RenderImageSource(Immutable); ~RenderImageSource() override; bool isLoaded() const final; void upload(gl::Context&); void startRender(algorithm::ClipIDGenerator&, const mat4& projMatrix, const mat4& clipMatrix, const TransformState&) final; void render(Painter&, PaintParameters&, const RenderLayer&); void finishRender(Painter&) final; void updateTiles(const TileParameters&) final; void removeTiles() final { } void invalidateTiles() final { } void reloadTiles() final { } std::map& getRenderTiles() final { return tiles; } std::unordered_map> queryRenderedFeatures(const ScreenLineString& geometry, const TransformState& transformState, const RenderedQueryOptions& options) const final; std::vector querySourceFeatures(const SourceQueryOptions&) const final; void setCacheSize(size_t) final { } void onLowMemory() final { } void dumpDebugLogs() const final; private: const style::ImageSource::Impl& impl() const; std::map tiles; std::vector tileIds; std::unique_ptr bucket; std::vector matrices; bool shouldRender; }; } // namespace mbgl