flekschas / regl-scatterplot

Scalable WebGL-based scatter plot library build with Regl
https://flekschas.github.io/regl-scatterplot/
MIT License
184 stars 21 forks source link

feat: Ability to pass `scaleBounds` to camera #160

Closed insertmike closed 7 months ago

insertmike commented 7 months ago

It would be very nice if we can provide scaleBounds argument to camera, to limit the zoom-in and out.

flekschas commented 7 months ago

You can set the camera's scale bounds as follows:

scatterplot.get('camera').setScaleBounds([1, 10]);
flekschas commented 7 months ago

See https://github.com/flekschas/dom-2d-camera#api and https://github.com/flekschas/camera-2d#api for the camera API docs