-
-
Notifications
You must be signed in to change notification settings - Fork 4k
Description
Certain types of rendering are made much easier by an immediate mode api (canvases, text, etc).
I also think there is potential here to make the "immediate mode" api the foundation for the following:
- The existing
Renderable
abstraction - A "canvas" style api
- Batching
- Text
- IMGui
I like the idea of having a core set of "batchable" draw calls and building Drawable
abstractions on top. A breadth of engines use this approach and it works quite well.
Draw calls would be scoped to entities in some ImmediateMode
or DrawCall
component. Then during render graph execution a draw call list would be generated based on some draw order algorithm (ex: z-sort). State changes could then be reduced as much as possible according to the draw call ordering.
This would probably remove the need for the existing DrawTarget
abstraction. Instead, the current graph nodes would be fully responsible for producing an ordered list of draw calls from the input World.