Select to view content in your preferred language

How to plot a point if I know distance and angle

920
3
08-16-2019 05:36 AM
Girishchandra_Yendargaye
Occasional Contributor

Hello Team,

I am using c++ api for development.

Can you please tell how to plot a point with known distance and angle here...

Also I would like to draw a line passing through it till map extend.

Thanks,

Tags (1)
0 Kudos
3 Replies
JamesBallard1
Esri Regular Contributor

Hi Girishchandra Yendargaye‌,

    Sorry the delay in responding. Can you please provide a bit more details on what you're trying to accomplish?

We do have PolylineBuilder class that allows you to build a Polyline programatically. You can then visualize the Polyline by using a GraphicsOverlay, Graphic and a SimpleRenderer.

PolylineBuilder Class | ArcGIS for Developers 

Graphic Class | ArcGIS for Developers 

GraphicsOverlay Class | ArcGIS for Developers 

SimpleRenderer Class | ArcGIS for Developers 

I hope this helps. Please provide some more info so that we can help with some more specific information if this doesn't match your workflow.

Thanks

0 Kudos
Girishchandra_Yendargaye
Occasional Contributor

Thank you for your response.

In order to draw a Polyline we need 02 points .....

Current situation is I have Buffer Geodetic with radius 10 say.....and point1(x0,y0) which is center of that buffer.

But I dont know point2  Instead I have distance from point1 and angle for point2.

In this case How to calculate Point2(x1,y1)

I want plot Point2 using Graphics Overlay

Thanks,

0 Kudos
NorbertThoden
Frequent Contributor

Hi!

I am not sure if i understand the question. Maybe you can provide a picture?

In my words:

You have a point x0,y0. For the second coordinate you know the distance to p0 and the angle, right?

I assume that the GeometryEngine Class | ArcGIS for Developers  can help you. Maybe moveGeodetic.

Hope it helps