title: Best approach for extending or defining new dat.gui property controllers?
body: <p>I want to add a few new property controller types to a DAT.GUI instance.</p>
  
  <p>I've spent ages hacking around in the source code getting nowhere, nor can I find any information on the web regarding the minimal path to create a new controller type.</p>
  
  <p>Specifically, I'd like DAT.GUI to use one of my new controllers whenever the controlled property is an Object which has a "flag" property (to denote a custom control be used, and which specific variety of custom control the object requires.)</p>
  
  <p>My previous approaches have been to use code for an existing controller as the basis for my new custom controller, copying &amp; modifying where I can see is applicable.  I copied all references to the Boolean type (for its simplicity) but ended up copy-pasting swathes of code and poking around hopelessly making patches I don't really understand just trying to get my objects not to cause the whole thing to break.  And so far without success.</p>
  
  <p>Then I tried to piggy-back off the Color controller functions, as it occurred to me that they are already set up to detect 'Object'-type properties, but the complexity of the Color functions was overwhelming, so now I've come here as my last resort.</p>
  
  <p>I can understand how all the events and updates are handled in the controllers themselves,  it's just the steps required to properly define a new controller and register it with DAT.GUI that are confounding me.</p>
  
  <p>Can anyone offer, if not a solution, even some advice on the approach to take?  Or perhaps someone knows of an online resource that provides more detail about the API, and how to extend it.</p>