3rd point on a triangle given lengths and 2 points

 Posts: 496
 Joined: 27 Aug 2010, 22:25
Re: 3rd point on a triangle given lengths and 2 points
Would somebody please try doing this in ICE.. I must be totally thick but I cannot work it out even based upon all the clear sounding explanations here.

 Posts: 496
 Joined: 27 Aug 2010, 22:25
Re: 3rd point on a triangle given lengths and 2 points
But we dont have the A to B direction or B to C direction, just the length of both and the angle between them. Thats whats confusing me.Daniel Brassard wrote:See it this way .... vector addition
vector A to B (length and direction) add vector B to C (length and direction) will give you vector A to C (length and direction).
Dan
What I really want is the angle between A to C and A to B, then I can work the other out easily
just to remind you who you're dealing with here.
https://vimeo.com/20840644

 Moderator
 Posts: 754
 Joined: 25 Nov 2009, 01:41
Re: 3rd point on a triangle given lengths and 2 points
I'll try to draw something once I get to work that will hopefully help.

 Posts: 56
 Joined: 09 Nov 2009, 10:58
Re: 3rd point on a triangle given lengths and 2 points
You don't need the direction. Just assume it's any arbitrary axis. Create 2 vectors with the lengths that you know represented in their Y axis. Rotate one around X or Z (in this example) by your angle (that you know). Now add one vector to the other. There is your missing vector, then you can just use a 'Get Angle Between' node.Pooby wrote: But we dont have the A to B direction or B to C direction, just the length of both and the angle between them. Thats whats confusing me.
What I really want is the angle between A to C and A to B, then I can work the other out easily
just to remind you who you're dealing with here.
https://vimeo.com/20840644
Hope that helps.

 Posts: 834
 Joined: 18 Mar 2010, 23:38
 Location: St. Thomas, Ontario
Re: 3rd point on a triangle given lengths and 2 points
By Daryl Dunlap
$ifndef "Softimage"
set "Softimage" "true"
$endif
set "Softimage" "true"
$endif

 Moderator
 Posts: 2450
 Joined: 24 May 2012, 09:44
Re: 3rd point on a triangle given lengths and 2 points
That i didn't found out yet how to do. Maybe spawn a point when that happens and get its position.
You do not have the required permissions to view the files attached to this post.

 Moderator
 Posts: 754
 Joined: 25 Nov 2009, 01:41
Re: 3rd point on a triangle given lengths and 2 points
My solution to finding the first bones rotation, hopefully you can see the correlation between the colors of the objects and the ICE Tree.
Once you find that rotation, you set the rotation of the first bone. The position of the first bone is the same position as the root objects position. Then you create a vector that is the same length as the first bone and rotate it by the first bone rotation angle which gives you the position of the second bone.
To find the rotation of the second bone you can cheat and use the direction to rotation node in ICE and plug in the subtraction of the effector position from the second bone position. I have another way of finding that angle if you want me to post it.
The final thing you'll need to do is to get all of that transforming by a transform that is looking at the effector and stabilized by an up vector object. Basically create a "direction constraint" which will give you a transform which you then multiply the first bone and second bone transforms by.
Hope this helps.
Eric T.
Once you find that rotation, you set the rotation of the first bone. The position of the first bone is the same position as the root objects position. Then you create a vector that is the same length as the first bone and rotate it by the first bone rotation angle which gives you the position of the second bone.
To find the rotation of the second bone you can cheat and use the direction to rotation node in ICE and plug in the subtraction of the effector position from the second bone position. I have another way of finding that angle if you want me to post it.
The final thing you'll need to do is to get all of that transforming by a transform that is looking at the effector and stabilized by an up vector object. Basically create a "direction constraint" which will give you a transform which you then multiply the first bone and second bone transforms by.
Hope this helps.
Eric T.

 Moderator
 Posts: 2450
 Joined: 24 May 2012, 09:44
Re: 3rd point on a triangle given lengths and 2 points
A further advance but only by aproximation. Where points intersect is the 3rd point.
I emit the particles from another ice tree with pointpositionC data. The point ID isn't doing anything since the logic as is isn't enough.
This probably needs to be made with trignometry. Or maybe if there is a way to use strands or curve and get their intersection point.
I emit the particles from another ice tree with pointpositionC data. The point ID isn't doing anything since the logic as is isn't enough.
This probably needs to be made with trignometry. Or maybe if there is a way to use strands or curve and get their intersection point.
You do not have the required permissions to view the files attached to this post.

 Posts: 496
 Joined: 27 Aug 2010, 22:25
Re: 3rd point on a triangle given lengths and 2 points
That helps a lot.. I did manage to get something that works yesterday, but yours seems a lot more elegant, thanksEricTRocks wrote:My solution to finding the first bones rotation, hopefully you can see the correlation between the colors of the objects and the ICE Tree.
Once you find that rotation, you set the rotation of the first bone. The position of the first bone is the same position as the root objects position. Then you create a vector that is the same length as the first bone and rotate it by the first bone rotation angle which gives you the position of the second bone.
To find the rotation of the second bone you can cheat and use the direction to rotation node in ICE and plug in the subtraction of the effector position from the second bone position. I have another way of finding that angle if you want me to post it.
The final thing you'll need to do is to get all of that transforming by a transform that is looking at the effector and stabilized by an up vector object. Basically create a "direction constraint" which will give you a transform which you then multiply the first bone and second bone transforms by.
Hope this helps.
Eric T.