#3226
Posted 01 December 2012 - 01:28 AM
Why are we discussing about con features here ?
Anyway, i found (not tested, not used) a method for calculating area of any sector with a good approximation, it works by "counting square elements" in the sector : save maximum and minimum x and y as you mentioned, then start two loops (one inside the other) to scan if the point "x,y" is in the sector, spacing x and y with a constant step between sector extension; when the point is in the sector (updatesector) , the "area" var is increased and you'll get the total area at the end of the process after a proper conversion factor.
The same method could be used to calculate a volume just adding the z scaled by 8 ; It's also possible to choose the dimension of the step, or to get it by sector extension, for optimizing the process and choose between speed or accuracy of the method.
Damn, this "mesh" approach remind me computational fluid dynamic lessons...
This post has been edited by RichardStorm: 01 December 2012 - 01:29 AM
0