ConfettiFX / The-Forge

The Forge Cross-Platform Rendering Framework PC Windows, Steamdeck (native), Ray Tracing, macOS / iOS, Android, XBOX, PS4, PS5, Switch, Quest 2
Apache License 2.0
4.65k stars 491 forks source link

Request: merge render command encoders which sharing the same color attachments #223

Closed Michael-Lfx closed 2 years ago

Michael-Lfx commented 2 years ago

https://github.com/ConfettiFX/The-Forge/blob/076aa5dcd8fd71cc83905431c92360183c7027d9/Common_3/Renderer/Metal/MetalRenderer.mm#L3618-L3620

As Xcode suggested we should merge render command encoders when they share the same color attachments. We can get the message by Capturing GPU Frame of 01_Transformations demo.

manas-kulkarni commented 2 years ago

Isn't this more of app responsibility :)

Michael-Lfx commented 2 years ago

The 01_Transformations.cpp should not use cmdBindRenderTargets() to emit multiple MTLRenderCommandEncoders for example?

manas-kulkarni commented 2 years ago

Yes.