mirror of
https://github.com/overte-org/overte.git
synced 2025-08-05 17:53:49 +02:00
Add renderQuad to DeferredLighting
This commit is contained in:
parent
9b49936d29
commit
ee264368c0
2 changed files with 11 additions and 1 deletions
|
@ -148,7 +148,14 @@ void DeferredLightingEffect::renderWireCube(gpu::Batch& batch, float size, const
|
|||
releaseSimpleProgram(batch);
|
||||
}
|
||||
|
||||
void DeferredLightingEffect::renderLine(gpu::Batch& batch, const glm::vec3& p1, const glm::vec3& p2,
|
||||
void DeferredLightingEffect::renderQuad(gpu::Batch& batch, const glm::vec3& minCorner, const glm::vec3& maxCorner,
|
||||
const glm::vec4& color) {
|
||||
bindSimpleProgram(batch);
|
||||
DependencyManager::get<GeometryCache>()->renderQuad(batch, minCorner, maxCorner, color);
|
||||
releaseSimpleProgram(batch);
|
||||
}
|
||||
|
||||
void DeferredLightingEffect::renderLine(gpu::Batch& batch, const glm::vec3& p1, const glm::vec3& p2,
|
||||
const glm::vec4& color1, const glm::vec4& color2) {
|
||||
bindSimpleProgram(batch);
|
||||
DependencyManager::get<GeometryCache>()->renderLine(batch, p1, p2, color1, color2);
|
||||
|
|
|
@ -57,6 +57,9 @@ public:
|
|||
// FIXME Remove non Batch version once Cube3DOverlay uses the render pipeline
|
||||
void renderWireCube(float size, const glm::vec4& color);
|
||||
void renderWireCube(gpu::Batch& batch, float size, const glm::vec4& color);
|
||||
|
||||
//// Renders a quad with the simple program.
|
||||
void renderQuad(gpu::Batch& batch, const glm::vec3& minCorner, const glm::vec3& maxCorner, const glm::vec4& color);
|
||||
|
||||
//// Renders a line with the simple program.
|
||||
void renderLine(gpu::Batch& batch, const glm::vec3& p1, const glm::vec3& p2,
|
||||
|
|
Loading…
Reference in a new issue