I read here about LayOut now has precision to match Sketchup of 0.000001" (inches). I thought Sketchup had precision of 0.001" (1/1000th of an inch). When did this change? Is is documented anywhere in the developer docs? Am I getting confused with the concept of tolerances?
I am of the opinion that the precision value ought to be accessible as a variable (I suppose constant) in the C API and Ruby API. Having a change of precision can have an impact on some plugins (mine at least), and keeping a plugin compatible across several versions of Sketchup becomes harder without knowing the precision of each version of SU.
We’ve improved the way LayOut calculates measurements, so it can now display dimensions as precisely as SketchUp can model: up to 0.000001 inches.
Eneroth, when you say 1/1000th of an inch for “unit tests”, is that to say that an operation of say (Point3D == Point3D) will return true if they are different by less than 0.0005" (1/2000th")?
The statement from the blog makes it clear that SketchUp is precise to 1,000,000th of an inch. So tolerances and precision are different concepts, I guess? Would be great to have a SketchUp developer clear this up.
…but it also says that Sketchup can model up to a precision of 0.000001 inches.
This is important to me in my plugin, which among other things uses a polygon merging algorithm which only takes integer coordinates, so I have to scale from the doubles (decimal) coordinates taking the precision (or tolerance!) of SketchUp into account.
Do you think I am right in the following assumptions:
all vertices are accurate to 0.000001 inches (precision), and SketchUp can model them and display them at that precision
when two vertices are within 0.001 inches (tolerance) of each other, SU merges them into one vertex (which vertex coordinate to use in this case?)
the vertices of a face can be off the face plane by up to 0.001 inches - otherwise, the face would be triangulated further.
In the Ruby API: Vector3D == Vector3D and Point3D == Point3D return true if they are within 0.001 inches of each other (actually to be precise, they would have to be 0.0005 inches of each other).
I haven’t seen any changes in SketchUp’s ability to create tiny faces. If the vertices are too close together edges won’t be formed and there’ll be holes in the surface. Those short edges and faces can exist but SketchUp doesn’t make them. The the reason for the “Dave Method” as described by Box in his tutorial.
Tommy, Dave is correct (and Julia is using the wrong terms above.)
(1) Precision and Tolerance are two separate but related things.
For example in the title block of the standard ANSI drawing form, is a Tolerance sub-form in which several tolerances can be specified for different precisions (as well as an angular tolerance.)
(2) The blog statement is incorrect, and someone should have asked the SketchUp side of the office to proofread it before publication.
(The blog post reads like marketing hype and reflects poorly on the writer, the team and the product. If a company is going produce a product for engineers, … get your engineering terms correct.)
From a recent thread in the GitHub API Issue Tracker database, I repost my test of SketchUp edge lengths …