I am thinking already about a little different approach , because intersectBoundingRadius would not give me a face of intersection . Actually the easiest is to assign mouse listeners to all the faces and that is all ! Just need to figure out how to detect the adjacent face that forms a polygon together with the first . Then it is possible to change material on cells like I said before .
On Tue, May 4, 2010 at 1:09 AM, Reinorvak <[email protected]> wrote: > It should work for any face based on the 3 vertices, not sure though > since I didn't write it. > > Just took a quick look at it and the method should work for any face > object. For a sphere though it has a different function entirely. > > intersectBoundingRadius(pos:Number3D, radius:Number):Boolean > > Maybe not so good to test with a sphere and try a cube instead? > > On May 3, 5:38 pm, Michael Iv <[email protected]> wrote: > > Also I agree with you on those Ray---> Mouse anomalies . I see that when > I > > cast the ray it's direction Z part is growing (that is should be ) but > when > > I am on Object3D it stops Z on the Object's surface and then continues to > > grow . So if you append some Object to these coords you will see that > that > > object is like a ball spinning back and forth on Z . > > > > Strange stuff . > > > > On Tue, May 4, 2010 at 12:16 AM, Reinorvak <[email protected] > >wrote: > > > > > > > > > One of the strange quirks of Away3D that I've discovered working on > > > enclosed spaces, is that the mouse X,Y,Z stops at the first object it > > > hits and doesn't continue farther into the scene. I've also tried my > > > own C++ versions of ray casting in Away3D to come up fruitless. What > > > exactly are you trying to achieve with this ray intersection? > > > > > On May 3, 4:43 pm, Michael Iv <[email protected]> wrote: > > > > Yes , but the problem is that there has to be one because I am > casting a > > > ray > > > > from cam position to the mouse screen X Y Z coords . So I am pointing > to > > > the > > > > very Face where I should get the intersection > > > > > > On Mon, May 3, 2010 at 11:10 PM, Reinorvak < > [email protected] > > > >wrote: > > > > > > > The number3D that the function returns, I believe, is the point of > > > > > intersection. If the return should show up blank, there is no > > > > > intersection. > > > > > > > On May 3, 4:03 pm, Michael Iv <[email protected]> wrote: > > > > > > I thought about it and tried to test against face v0 v1 v2 of > sphere > > > . > > > > > Got > > > > > > nothing of this . > > > > > > > > On Mon, May 3, 2010 at 10:50 PM, Reinorvak < > > > [email protected] > > > > > >wrote: > > > > > > > > > v0-2, are the vertices used in a triangle. getIntersect is > testing > > > if > > > > > > > the starting point p0, and the ending point p1, intersect the > > > triangle > > > > > > > defined by v0, v1, and v2. > > > > > > > > > On May 3, 3:43 pm, Michael Iv <[email protected]> wrote: > > > > > > > > Someone can tell me what are* v0,v1,v2* in* > > > > > Ray.getIntersect(p0:Number3D, > > > > > > > > p1:Number3D, v0:Number3D, v1:Number3D, v2:Number3D):Number3D* > ??? > > > > > > > > Just can't find any example explaining these > > > > > > > > > > Thanks! > > > > > > > > > > -- > > > > > > > > Michael Ivanov ,Programmer > > > > > > > > Neurotech Solutions Ltd. > > > > > > > > Flex|Air |3D|Unity|www.neurotechresearch.com > > > > > > > > Tel:054-4962254 > > > > > > > > [email protected] > > > > > > > > [email protected] > > > > > > > > -- > > > > > > Michael Ivanov ,Programmer > > > > > > Neurotech Solutions Ltd. > > > > > > Flex|Air |3D|Unity|www.neurotechresearch.com > > > > > > Tel:054-4962254 > > > > > > [email protected] > > > > > > [email protected] > > > > > > -- > > > > Michael Ivanov ,Programmer > > > > Neurotech Solutions Ltd. > > > > Flex|Air |3D|Unity|www.neurotechresearch.com > > > > Tel:054-4962254 > > > > [email protected] > > > > [email protected] > > > > -- > > Michael Ivanov ,Programmer > > Neurotech Solutions Ltd. > > Flex|Air |3D|Unity|www.neurotechresearch.com > > Tel:054-4962254 > > [email protected] > > [email protected] > -- Michael Ivanov ,Programmer Neurotech Solutions Ltd. Flex|Air |3D|Unity| www.neurotechresearch.com Tel:054-4962254 [email protected] [email protected]
