Make the torus pick in its local space to look forward , then make it
lookAt() = center of the sphere .Then use relation between  magnitude of the
position vector of the cone around the sphere and it's scale . I don't think
there is much trig here . May be I did not get you right

On Mon, May 24, 2010 at 7:45 PM, dyc <[email protected]> wrote:

> Hey guys,
>
> So I have this sphere  sitting at 0,0,0 in my View. I want to allow a
> user to click anywhere on the sphere, and have a Torus appear where
> they clicked, and as they drag, it would get bigger or smaller
> depending on how far from the initial click they moved their mouse.
>
> I have this part all figured out and its working perfectly...however,
> I need the torus to "hug" the sphere as it get bigger or smaller,
> literally moving closer to the center of the sphere as it gets bigger,
> or further away as it gets smaller, so it seems that the torus is a
> ring around the sphere at different places as you drag. For this to
> happen, the torus will need to rotate on its axis' to keep "pointing"
> directly at the center of the sphere.
>
> This is way over my head, and my boss really needs this to get
> finished this week, and there are tons of other parts to getting this
> done. I could sure use some ideas.
>
> Thanks SO much for all your help in advance! You guys always save my
> butt!
>
> `Scott
>
> p.s. im trying to place this torus like this so I can use the data
> from it in some crazy trig functionality I need to do to get the
> proper distances between thing & the right FOV & angle from the
> distances & angles that are there...
>
>
>


-- 
Michael Ivanov ,Programmer
Neurotech Solutions Ltd.
Flex|Air |3D|Unity|
www.neurotechresearch.com
http://blog.alladvanced.net
http://www.meetup.com/GO3D-Games-Opensource-3D/
Tel:054-4962254
[email protected]
[email protected]

Reply via email to