Skip to content

Material batching: reduce redundant Material::Bind invocations #445

@adriengivry

Description

@adriengivry

Problem this feature should fix
Material::Bind is being called for each draw call, even in cases where 2 entities using the same material are drawn consecutively.

Image

Expected solution
We should implement a solution to avoid redundant Material::Bind invocations in 2 steps:

  1. If the material isn't changing for n numbers of draw calls, keep it bound and don't re-bind it for every draw call
  2. Batch/reorder opaque draw calls to limit Bind/Unbind call count.

Metadata

Metadata

Assignees

No one assigned

    Labels

    GraphicsGraphical feature

    Type

    No fields configured for Task.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions