simplify legacy-support polyfills #28

Merged
embeddedt merged 2 commits from rdh/celeritas:stonecutter into stonecutter 2026-07-29 21:27:59 -04:00
Showing only changes of commit 1352f85d9c - Show all commits
@@ -21,8 +21,6 @@ public class GLRenderDevice implements RenderDevice {
private final DrawCommandList drawCommandList = new ImmediateDrawCommandList(); private final DrawCommandList drawCommandList = new ImmediateDrawCommandList();
private final DeviceFunctions functions = new DeviceFunctions(this); private final DeviceFunctions functions = new DeviceFunctions(this);
private final boolean supportsMultiDrawElementsBaseVertex = LWJGL.isOpenGLVersionSupported(3, 2)
|| LWJGL.isExtensionSupported(GLExtension.ARB_draw_elements_base_vertex);
private boolean isActive; private boolean isActive;
private GlTessellation activeTessellation; private GlTessellation activeTessellation;
@@ -270,9 +268,6 @@ public class GLRenderDevice implements RenderDevice {
@Override @Override
public void multiDrawElementsBaseVertex(MultiDrawBatch batch, GlPrimitiveType primitiveType, GlIndexType indexType) { public void multiDrawElementsBaseVertex(MultiDrawBatch batch, GlPrimitiveType primitiveType, GlIndexType indexType) {
if (!GLRenderDevice.this.supportsMultiDrawElementsBaseVertex) {
throw new UnsupportedOperationException("Platform does not support DrawElementsBaseVertex");
}
LWJGL.glMultiDrawElementsBaseVertex(primitiveType.getId(), LWJGL.glMultiDrawElementsBaseVertex(primitiveType.getId(),
batch.pElementCount, batch.pElementCount,
indexType.getFormatId(), indexType.getFormatId(),