Files
obsidian-notes/3Resources/游戏开发/性能优化/卡片/Batch.md
2025-09-30 10:01:57 +08:00

7 lines
836 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
tags:
- Batch
---
把数据加载到显存设置渲染状态CPU调用GPU渲染的过程称之为一个Batch。这其实就是渲染流程的运用阶段最终输出一个渲染图元(点、线、面等)再传递给GPU进行几何阶段和光栅化阶段的渲染显示。一个Batch必然会触发一次或多次DrawCal目包含了该对象的所有的网格和顶点数据以及材质信息。把数据加载到显存是指把清染所蛋的数据从硬盘加载到内存(RAM),再将网格和纹理等加载到显卡 VRAM),这一步比较释时。设置清染状态就是设置场景中的网格的顶点 Verex)片元(Fragment)着色器光源属性材质等。Unitv提供的动态合批(Dvnamic Batching)合并的就是这一过程,将清染状态相同的对象合并成-个Batch减少DrawCall。