Shapes method - GeorgeGkas/isometricObelisk.js GitHub Wiki
To create a primitive you should use the appropriate primitive method ( cube()
, pyramid()
, etc ). The method accepts an object with the following keys as parameter:
x: Number,
y: Number,
z: Number,
border: Boolean
The x
,y
,z
keys represent the dimensions of the primitive in x, y and z axis respectively. Border key takes as value a Boolean (true
/false
) and enables you to show or hide object border.
In this point you should be informed that, not all primitives accept every of the above keys. Consider a primitive like brick. There is no meaning to add a z
axis dimension as the brick has constant z
size. Nevertheless, If you add it will not be taking into account.
Default values
Keep in mind that the above explained parameters are optional. All the shapes use the same default values. For isometricObelisk these are:
x: 80,
y: 80,
z: 80,
border: true
Although, remember to call the appropriate primitive method ( eg. cube()
, pyramid()
), so the module can unidentified what shape you want to create.
For a full map of the exact available primitive options visit [https://github.com/GeorgeGks/isometricObelisk.js/wiki/Appendix-A](Appendix A).