Let's have DispatchFlush check for drawcalls before calling DoFlush, too.

This commit is contained in:
Henrik Rydgård committed 2023-05-03 23:49:41 +02:00
1 parent c80671d9ea
commit d56e27aa2c
4 files changed
+20 -4

No files matched your search

+5 -1
View File
@@ -149,7 +149,11 @@ public:
DecodeVerts(decoded);
}
void DispatchFlush() override { Flush(); }
void DispatchFlush() override {
if (!numDrawCalls)
return;
Flush();
}
void ClearTrackedVertexArrays() override;
+5 -1
View File
@@ -139,7 +139,11 @@ public:
DecodeVerts(decoded);
}
void DispatchFlush() override { Flush(); }
void DispatchFlush() override {
if (!numDrawCalls)
return;
Flush();
}
protected:
// Not currently supported.
+5 -1
View File
@@ -97,7 +97,11 @@ public:
DoFlush();
}
void DispatchFlush() override { Flush(); }
void DispatchFlush() override {
if (!numDrawCalls)
return;
Flush();
}
GLPushBuffer *GetPushVertexBuffer() {
return frameData_[render_->GetCurFrame()].pushVertex;
+5 -1
View File
@@ -177,7 +177,11 @@ public:
DoFlush();
}
void DispatchFlush() override { Flush(); }
void DispatchFlush() override {
if (!numDrawCalls)
return;
Flush();
}
VkPipelineLayout GetPipelineLayout() const {
return pipelineLayout_;