ianmackenzie / elm-3d-scene

A high-level 3D rendering engine for Elm, with support for lighting, shadows, and realistic materials.
https://package.elm-lang.org/packages/ianmackenzie/elm-3d-scene/latest/
Mozilla Public License 2.0
207 stars 27 forks source link

Add ability to enable/disable antialiasing #56

Closed ianmackenzie closed 4 years ago

ianmackenzie commented 4 years ago

Big improvement in image quality, but can also have a major impact on performance

ianmackenzie commented 4 years ago

Idea from @w0rm: to make sure antialiasing can be enabled/disabled even after the WebGL context has been initialized, use a keyed HTML node (e.g. with a key of either "antialias" or "noantialias") as the parent of the WebGL node to force the Elm compiler to recreate the WebGL node when necessary