npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@bimdata/engine-2d

v0.0.21

Published

Draw shapes and texts using webgl2

Readme

DEV

For development, just serve the index.js root file.

GLSL syntax highlighting

To Add GLSL syntax highlighting for JavaScript template literals, use the VSCode extension: glsl-literal

Unit testing

VSCode Vitest extension is highly recommended.

npm run test

Types

npm run types

Roadmap

LOW PRIORITY TODOs

  • [ ] move/translate/rotate/scale methods on dynamic entity
  • [ ] tests
  • [ ] fill holes
  • [ ] b2d binary format
  • [ ] compressed textures

DONE

  • [x] cleaner SVG parser (the current one is the previous 2d-engine version + adapter) https://github.com/bimdata/engine-2d/pull/43

  • [x] Better Inputs API (handle "click" and picking) https://github.com/bimdata/engine-2d/pull/42

  • [x] select and highlight rendering logic rework https://github.com/bimdata/engine-2d/pull/41

  • [x] renderer offset or model/entity origin to handle full f64 precision for point coordinate https://github.com/bimdata/engine-2d/pull/40 + FIX

  • [x] touch controller https://github.com/bimdata/engine-2d/pull/39

  • [x] groups (entity.group and max texture units exceeded) PART 1 https://github.com/bimdata/engine-2d/pull/35 PART 2 https://github.com/bimdata/engine-2d/pull/37

  • [x] texts https://github.com/bimdata/engine-2d/pull/29

  • [x] TypedArrays in Builder.js https://github.com/bimdata/engine-2d/pull/28

  • [x] remove de-instancing feature if not useful https://github.com/bimdata/engine-2d/pull/27

  • [x] dash rework https://github.com/bimdata/engine-2d/pull/26

  • [x] snap picking (edge + vertex) https://github.com/bimdata/engine-2d/pull/14

  • [x] shape attribute change => scene redraw + proper resource cleaning --- hard update https://github.com/bimdata/engine-2d/pull/18

  • [x] better picking API https://github.com/bimdata/engine-2d/pull/19

  • [x] camera fit view https://github.com/bimdata/engine-2d/pull/23

  • [x] packed color https://github.com/bimdata/engine-2d/pull/3

  • [x] picking https://github.com/bimdata/engine-2d/pull/6

  • [x] entity flags update (performant batch update + tint for selected or highlighted entities & need redraw) - soft update https://github.com/bimdata/engine-2d/pull/4

  • [x] render target resize = redraw (cache projection matrix) https://github.com/bimdata/engine-2d/pull/13

  • [x] fill style texture https://github.com/bimdata/engine-2d/pull/12

  • [x] line style dash array + dash offset https://github.com/bimdata/engine-2d/pull/7

  • [x] properly manage WebGL integer buffer & texture precision https://github.com/bimdata/pixi-lines/pull/2

  • [x] auto generated types d.ts https://github.com/bimdata/engine-2d/pull/4

  • [ ] compositing with canvas2D for texts https://css-tricks.com/techniques-for-rendering-text-with-webgl/ Replaced by simple "texts"

  • [ ] model entities sorting by z-index last added object drawn last

  • [ ] picking margin & picking z-index https://github.com/bimdata/engine-2d/pull/11

Core

Main Buffers

Indexes

They are point indices read by four. The "reading window" (represented by the "|- - - -|" symbol) comes forward of one index for the subsequent segment. Zero means a cap. -(index) is for closed path.