Skip to content

refactor: outline + grid pass overwriting second color attachment #391

@iMeaNz

Description

@iMeaNz

Objective

Ok the render passes are causing problems again.
For some reason on windows, when executing the fullscreen outline and grid pass, those are overwriting the data in the second attachments (the ones containing the entity ids).
I added a temporary fix in them to make it work so that we can still continue to work

renderTarget->bind();
constexpr GLenum singleDrawBuffer[] = { GL_COLOR_ATTACHMENT0 };
glDrawBuffers(1, singleDrawBuffer);
constexpr GLenum allBuffers[] = { GL_COLOR_ATTACHMENT0, GL_COLOR_ATTACHMENT1 };
glDrawBuffers(2, allBuffers);
renderTarget->unbind();

But this need to be changed. I guess render passes at construction should declare what attachments they are planning to write to / clear, then the render pipeline can probably retrieve those before executing and handling that.

Acceptance Criteria

  • 1. No opengl call in the passes themselves
  • 2. The render passes should declare which attachments they plan to clear/write
  • 3. The pipeline should execute + handle the color buffer / clea

Dependencies

No response

Technical Details

No response

Type

Engine

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

Projects

Status

Todo

Relationships

None yet

Development

No branches or pull requests

Issue actions