I
I
Inteli Sense2015-10-21 21:01:12
JavaScript
Inteli Sense, 2015-10-21 21:01:12

How to draw an arc between straight lines in Canvas?

There are two lines to draw an arc like here the
he2zj.png
problem is that I can't find these points on the lines. Tell me how to do it right
question.ikende.com/question/31353033363036383631
there is a solution here - but the person already has points.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Aves, 2015-10-22
@Aios

Javascript has a great atan2 function that allows you to easily get the angle without bothering with determining the sign, with it it is easy to get parameters for the canvas arc.
example on JSBin

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question