MCPcopy Create free account
hub / github.com/ChartGPU/ChartGPU / render

Function render

src/renderers/createScatterDensityRenderer.ts:507–521  ·  view source on GitHub ↗
(passEncoder)

Source from the content-addressed store, hash-verified

505 };
506
507 const render: ScatterDensityRenderer['render'] = (passEncoder) => {
508 assertNotDisposed();
509 if (!hasPrepared) return;
510 if (!renderBindGroup || !lastPlotScissor || !lutView) return;
511 if (lastPlotScissor.w <= 0 || lastPlotScissor.h <= 0) return;
512
513 passEncoder.setScissorRect(lastPlotScissor.x, lastPlotScissor.y, lastPlotScissor.w, lastPlotScissor.h);
514 passEncoder.setPipeline(renderPipeline);
515 passEncoder.setBindGroup(0, renderBindGroup);
516 passEncoder.draw(3);
517
518 if (lastCanvasWidth > 0 && lastCanvasHeight > 0) {
519 passEncoder.setScissorRect(0, 0, lastCanvasWidth, lastCanvasHeight);
520 }
521 };
522
523 const dispose: ScatterDensityRenderer['dispose'] = () => {
524 if (disposed) return;

Callers

nothing calls this directly

Calls 1

assertNotDisposedFunction · 0.70

Tested by

no test coverage detected