[core] remove Renderer::flush

This commit is contained in:
Konstantin Käfer
2019-04-05 11:00:56 +02:00
parent 5cc3d7a733
commit 1d58850d0c
7 changed files with 0 additions and 26 deletions

View File

@@ -35,8 +35,6 @@ public:
void render(const UpdateParameters&);
void flush();
// Feature queries
std::vector<Feature> queryRenderedFeatures(const ScreenLineString&, const RenderedQueryOptions& options = {}) const;
std::vector<Feature> queryRenderedFeatures(const ScreenCoordinate& point, const RenderedQueryOptions& options = {}) const;

View File

@@ -1341,8 +1341,6 @@ public:
// In iOS 12.2, CAEAGLLayer.presentsWithTransaction can cause dramatic
// slow down. The exact cause of this is unknown, but this work around
// appears to lessen the effects.
//
// Also, consider calling the new mbgl::Renderer::flush()
CAEAGLLayer *eaglLayer = MGL_OBJC_DYNAMIC_CAST(_glView.layer, CAEAGLLayer);
eaglLayer.presentsWithTransaction = NO;

View File

@@ -811,9 +811,5 @@ void Context::performCleanup() {
}
}
void Context::flush() {
MBGL_CHECK_ERROR(glFinish());
}
} // namespace gl
} // namespace mbgl

View File

@@ -107,11 +107,6 @@ public:
// Only call this while the OpenGL context is exclusive to this thread.
void reset();
// Flush pending graphics commands. Will block until the pipeline
// is empty. Should be used only with a very good reason because
// it will have a performance impact.
void flush();
bool empty() const {
return pooledTextures.empty()
&& abandonedPrograms.empty()

View File

@@ -36,10 +36,6 @@ void Renderer::render(const UpdateParameters& updateParameters) {
impl->render(updateParameters);
}
void Renderer::flush() {
impl->flush();
}
std::vector<Feature> Renderer::queryRenderedFeatures(const ScreenLineString& geometry, const RenderedQueryOptions& options) const {
return impl->queryRenderedFeatures(geometry, options);
}

View File

@@ -598,13 +598,6 @@ void Renderer::Impl::render(const UpdateParameters& updateParameters) {
// CommandEncoder destructor submits render commands.
}
void Renderer::Impl::flush() {
assert(gfx::BackendScope::exists());
gl::Context& glContext = static_cast<gl::Context&>(backend.getContext());
glContext.flush();
}
std::vector<Feature> Renderer::Impl::queryRenderedFeatures(const ScreenLineString& geometry, const RenderedQueryOptions& options) const {
std::vector<const RenderLayer*> layers;
if (options.layerIDs) {

View File

@@ -55,8 +55,6 @@ public:
void render(const UpdateParameters&);
void flush();
std::vector<Feature> queryRenderedFeatures(const ScreenLineString&, const RenderedQueryOptions&) const;
std::vector<Feature> querySourceFeatures(const std::string& sourceID, const SourceQueryOptions&) const;
std::vector<Feature> queryShapeAnnotations(const ScreenLineString&) const;