We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
To add controllers, first you must have a GUI to add it to.
const gui = dat.GUIVR.create( 'settings' ); scene.add( gui );
gui.add( object, 'numericProperty', min, max );
Sliders have a step function which forces the value to be within the specified increment.
gui.add( object, 'property', min, max ).step( 0.1 );
gui.add( state, 'boolProperty' );
If state.boolProperty = true or false then the controller will become a checkbox.
state.boolProperty = true
false
folder.add( state, 'anyProperty', arrayOrObject );
If the third argument is an array or object, the controller will become a dropdown with those options.
gui.add( state, 'functionProperty' );
If state.functionProperty is a function then the controller will become a button and the function will run whenever you press it.
state.functionProperty