Oliver Markowski Posted June 19, 2014 Share Posted June 19, 2014 (edited) Hey guys, i am giving up on this problem for today...can someone please point me to the correct trigonometric functions to use if i want to find the RED point in the attached screenshot? i do know the positions of all three GREEN points and also the two GREEN angles around the RED point that i am looking for. EDIT: The GREEN points are NOT on a circle around RED even if this screenshot might look like this is the case. The background of this question is to find the position of the camera which shot an hdr on a set filmset where i also have lidar data. I can do it by hand to some extend but I want to solve this problem properly once and for all...i hope you are able to help me out! thx in advance Oli Edited June 19, 2014 by Oliver Markowski Quote Link to comment Share on other sites More sharing options...
Pilou Posted June 19, 2014 Share Posted June 19, 2014 (edited) I would use the formula of the Al Kashi theorem. It's a litlle late to expose it here but I suggest you google it and you'll find it really easily. It the general case used to calculate any angle cosinus in any kind of triangle of the well known formula used in a rectangular triangle : cos(A) = adjacent side / hypothenuse because you already know the angle you just need to get the sides of the triangle you're considering. And because those sides are calculated using the position of the green and red dot you will be able to figure out the position of the red one. I link you the page of the formula with a good picture (sorry it's french - I can't get you the english one ) c² = a² + b² -2ab*cos(gamma) Maybe a bit hard but I think that's how I would do it. Hope this helps Edited June 19, 2014 by Pilou Quote Link to comment Share on other sites More sharing options...
Oliver Markowski Posted June 20, 2014 Author Share Posted June 20, 2014 Hey Pilou, thx for getting me back on track....of course i know the law of cosines, but i thought i do not know the edge lengths. but acttually i can substitute the edgelength with another formula which is only missing my RED point... sometimes you just need a break to re-organize your thoughts...thx again and stay tuned for updates - or another question cheers Oli Quote Link to comment Share on other sites More sharing options...
Pilou Posted June 20, 2014 Share Posted June 20, 2014 I'd love to know how you went to the bottom of it Quote Link to comment Share on other sites More sharing options...
Oliver Markowski Posted June 22, 2014 Author Share Posted June 22, 2014 I'd love to know how you went to the bottom of it I'm on it, but solving all the equations is kind of hard...i guess i need to get my head around Octave/Scilab first, which might take some time... I'll make the solution of this publicly available anyway...if I find one cheers Oli Quote Link to comment Share on other sites More sharing options...
edward Posted July 10, 2014 Share Posted July 10, 2014 c² = a² + b² -2ab*cos(gamma) Maybe a bit hard but I think that's how I would do it. If you just use that naively, then you end up with 2 equations (cosine laws) and 3 unknowns (the lengths of the red line segments). So you need something other piece of knowledge to deduce those lengths. I don't know what that 3rd piece of info though but I'm probably missing something. EDIT: Probably use the fact that the red lines intersect. Quote Link to comment Share on other sites More sharing options...
Pilou Posted August 7, 2014 Share Posted August 7, 2014 (edited) I think you're right Edward. Knowing that the three sides intersect, it could be nice to find the equation of the three straights lines. And you can pose another equation : A - B = 0, B - C = 0 and A - C = 0 with A B and C the equation of the three red straight lines. the only solution of this equation system will give you the intesect point which in that case, is the red point. something like that. I'll think about it on paper. I think it's a better option than al kashi theorem. Just a rough thought. but good point Edward, indeed. I'm wondering Oliver, if you're still here, do all points are in the same plane ? If it's the case then you can get a third equation with an angle which is the sum of the two former angles. The left and right green dot and the red one will give you the triangle. Edited August 7, 2014 by Pilou Quote Link to comment Share on other sites More sharing options...
Oliver Markowski Posted September 9, 2014 Author Share Posted September 9, 2014 hey guys, yes i am still in but i got married 2 weeks ago and besides that i am working fulltime on a project at the moment. i hope i'll find some weeks of spare time in october...i still want to solve this!!! cheers Oli Quote Link to comment Share on other sites More sharing options...
Fenolis Posted November 17, 2014 Share Posted November 17, 2014 A really interesting question. Assuming all four points are in the same plane, you can use the sine rule to solve for your fourth point. Consider this an extension to Pierre's comment. Quote Link to comment Share on other sites More sharing options...
Oliver Markowski Posted February 17, 2015 Author Share Posted February 17, 2015 (edited) hey guys, just a quick follow up on this! I haven't found a resolution for this myself, but there are a lot of tools out there that already do this. My current favourite is the Nuke ProjectionSolver (NukeX only), but I am evaluating other tools as well at the moment... basically it's all here already http://docs.opencv.org/trunk/modules/reg/doc/registration.html Have fun! Oli Edited February 17, 2015 by Oliver Markowski Quote Link to comment Share on other sites More sharing options...
Guest tar Posted February 17, 2015 Share Posted February 17, 2015 Photoscan should be able to do this too: http://www.agisoft.com Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.