I hope this is not a stupid question but...
I want to be able to import geometry (in this case STL) and then for any X and Y coordinate I need to find the Z
I have created teh GUI and inported the STIL file fine. I have also looked at the thread below which shows me how to get a point via pick but I need to evaulate potentially thousands or points over the "surface" and want to to it programatically.
http://www3.math.tu-berlin.de/jreality/ ... inate#p927
Any help is greatly appreciated.
DoZ
Evaulating solid geometry
Re: Evaulating solid geometry
What if there are several pieces of geometry with the same (x,y) coordinates but different z? Do you want only the "first" one? Then you'll also need to define what you mean by "first".
Or you can get a whole list. Look at the class de.jreality.scene.pick.AABBPickSystem. It can be used to calculate such a list of hits. Use the method setSceneRoot(SceneGraphComponent root) to set the scene graph you want to pick; then call computePick(double[] from, double[] to), which returns a list of the hit points along the ray beginning at the point "from" and going in the direction of "to". The class de.jreality.tools.ShipNavigationTool uses this method, as does de.jreality.toolsystem.ToolSystem, you can look there to see how it's used.
Good luck!
Or you can get a whole list. Look at the class de.jreality.scene.pick.AABBPickSystem. It can be used to calculate such a list of hits. Use the method setSceneRoot(SceneGraphComponent root) to set the scene graph you want to pick; then call computePick(double[] from, double[] to), which returns a list of the hit points along the ray beginning at the point "from" and going in the direction of "to". The class de.jreality.tools.ShipNavigationTool uses this method, as does de.jreality.toolsystem.ToolSystem, you can look there to see how it's used.
Good luck!
jReality core developer