pmndrs / maath

🪶 Math helpers for the rest of us
https://maath.pmnd.rs
801 stars 15 forks source link

RFC Buffer API #7

Open gsimone opened 2 years ago

gsimone commented 2 years ago

Right now most buffer methods require manual passing of the stride of the buffer (eg. if it's a 2D points buffer or a 3D one).

An alternative approach would be to make 2 separate buffer entry points ( buffer2D, buffer3D ) but that feels overkill.

Composing buffers right now is confusing as you end up with a lot of stride repetition.

Babel macros might be an option, but that feels forced.