darthdeus / comfy

Comfy is a fun 2D game engine built in Rust. It's designed to be opinionated, productive, and easy to use.

Home Page:https://comfyengine.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add a way to optionally respect draw call order inside the same Z layer

setzer22 opened this issue · comments

Right now when you draw meshes on the screen, they're sorted by texture and batched. This is generally good for performance but gets inconvenient when you're drawing UI, where you generally want things to be drawn bottom-to-top (what's often called "painter's algorithm").

The performance impact of this for things like UI is generally minimal, so it would be nice to have a way to disable this kind of batching for some Z layers.