omni360 / dat-gui

Automatically exported from code.google.com/p/dat-gui
0 stars 0 forks source link

changing bounds of variable dynamically #45

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Not a issue, more like a feature reques.

Is it possible to update a max bound value when another variable changes?

Example:

var settings = { max: 10, totalPoints: 10 }

gui.add(settings, 'max', 0, 10);
gui.add(settings, 'totalPoints, 0, @settings.max)

So when I change the max value to 6, I wanted the same behaviour like:
gui.add(settings, 'totalPoints, 0, 6)

Original issue reported on code.google.com by venancio...@gmail.com on 12 Dec 2013 at 12:37