javascript - Add Attribute to Three.js Object -


i want maintain information shapes i'm creating. use html canvas texture, know can keep values in element attributes arrays of canvases. i'm wondering though, there more straight-forward way of maintaining attributes works three.js shapes regardless of how constructed?

the advantage (or problem) javascript, can objects. can add, or delete attributes as want time.

thus, can add every property want 3 objects giving value :

 mythreeobject.myproperty = myvalue ; 

be careful though, if haven't assigned value property, property not exist (yet), thus, don't forget check if value exist before reading :

if( "undefined" !== typeof mythreeobject.myproperty )     // ... 

Comments

Popular posts from this blog

asp.net - How to correctly use QUERY_STRING in ISAPI rewrite? -

jsf - "PropertyNotWritableException: Illegal Syntax for Set Operation" error when setting value in bean -

arrays - Algorithm to find ideal starting spot in a circle -