private static RayMeshGeometry3DHitTestResult rayHit; public static RayMeshGeometry3DHitTestResult SurfaceRayHit(Point3D p, Vector3D v) { RayHitTestParameters hitParams = new RayHitTestParameters(p,v); VisualTreeHelper.HitTest(App.AppDemModel, null, new HitTestResultCallback(MainDemHitPoint), hitParams); return rayHit; } public static HitTestResultBehavior MainDemHitPoint(HitTestResult result) { if (result.VisualHit == App.AppDemModel) { rayHit = (RayMeshGeometry3DHitTestResult)result; //rList.Add(hit); return HitTestResultBehavior.Stop; } return HitTestResultBehavior.Continue; }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)