1

smart measuring tape in Blackberry 6 and 7.

I want to measures the Distance and Height of a target by trigonometry using camera. I found this app in google play. I want to make this type of application not exactly same but quite same but for my requirement

Can anyone give me/suggest me the right way or any example so that I can get more idea about this requirement.

This image will give you my clear requirement enter image description here

OR click this video link to understand the requirements video.

i want to get height of object and distance (c) .
Brad Koch
  • 19,267
  • 19
  • 110
  • 137
askquestion
  • 171
  • 1
  • 14

1 Answers1

1

First step for this app should be to get angle to which point mobile(camera) is inclined. If it is possible to get inclined angle a, then as per your given link by formula of tangent you will get distance of the object from the camera , here you have to consider cameras height(h).Once you get height then again incline your mobile to the top of the object,and calculate height.

In short most important step is to get angle of inclination of the mobile to the object, after that all remaining part is trigonometric calculations.

After all it will give approximate results not accurate.

enter image description here

If you are able to calculate angle to which mobile is inclined

Step First: calculate distance

1) Incline your mobile to the bottom of the object it will give you angle A(as shown in diagram) 2) consider height h at what you have held your mobile (consider standard as 5ft ) or

You may use SONAR system to get height where you have held the phone or this may help you

3) Now by formula of tangent you will get distance d as shown in figure

Step 2: Calculate height

1) Incline your mobile to the top of the object and get angle B as shown in figure. 2) As you have calculated d in previous step, put the angle b and d in tangent formula you will get h1 3) Add h and h1, you will get height of the object

Community
  • 1
  • 1
swapnil7
  • 808
  • 1
  • 9
  • 22
  • 1
    Are you sure this correct? "If it is possible to get inclined angle a, then as per your given link by formula of tangent you will get distance of the object". Even if you know the angle, don't you need to know the distance to get the height, or the height to get the distance? Just as a for example, let me say the angle B is 30 degrees. What is the distance? – Peter Strange Feb 25 '14 at 16:24
  • @PeterStrange ,yes i am sure to get distance of the object, you have assume height(where u have held the phone for e.g. you can consider it as 5 ft avg. height) and you will get the distance. – swapnil7 Feb 26 '14 at 05:39
  • @swapnil7 i am getting angle now how can i detect the object from camera and get the height? – askquestion Feb 27 '14 at 09:33
  • @swapnil7 which link you taking about and what you are trying to explain? – askquestion Feb 27 '14 at 10:26
  • @askquestion got answer? – swapnil7 Feb 28 '14 at 06:48
  • @askquestion now what is problem? – swapnil7 Feb 28 '14 at 06:51
  • @swapnil7 not able to get height? – askquestion Feb 28 '14 at 06:54
  • @askquestion my answer is giving clarification about how to get height – swapnil7 Feb 28 '14 at 06:56
  • @swapnil7 your answer consider height h at what you have held your mobile (consider standard as 5ft ) i don' want to hard code height i want to get it from sensor like i am getting angle from device. – askquestion Feb 28 '14 at 07:02
  • @askquestion now that is the only challenge remaining for your question, need to search about how to get height where your phone is held. In the first prototype of your application you may use avg. height.Please Tell me if i am wrong/correct in my solution. – swapnil7 Feb 28 '14 at 07:07
  • let us [continue this discussion in chat](http://chat.stackoverflow.com/rooms/48750/discussion-between-askquestion-and-swapnil7) – askquestion Mar 01 '14 at 06:41