Newbie help - getting dimensions of a simple object
-
Hi there!
I have a write a big code and I am a ruby newbie.. i have done some fair amount of c++..i have drawn up a cuboid, i have to do some calculations on it..
basically i have programmed it so far, i right click on the group and i should get dimensions of the object.. i just want to know what class to use..to honest i've spent the last week on the google sketchup api website.. i have no clue what to use..
thanks for your help
Cheers! -
That is because there is no built in dimensioning class or method.
You will probably need to be looking at all edges and then find their lengths. You can write those lengths to a UI.messagebox, or to the screen, or to text entities in the model, or back to a webdialog box. So displaying the info will require choosing what works best for you.
But start by iterating over all the edges and finding their lengths. That would be the Edge class
Chris
-
Try the BoundingBox Class.
A bounding box contains the dimensions of an object.
-
wow bounding box is such a neat thing.. thanks for pointing it out!!
Advertisement