+ 1

Canvas drawing issue, why not the correct triangular shape?

Why the following code produce a right angle triangle? i want a triangle less then 90deg, around 30deg, but from the points i set, it should not be right angle triangle. var canvas = document.getElementById("canvas"); context = canvas.getContext("2d"); context.beginPath(); context.moveTo(30,100); context.lineTo(30,200); context.lineTo(100, 150); context.fill(); https://code.sololearn.com/WCwZKX5DX5uV/?ref=app

8th Oct 2017, 11:32 AM
SuperIntel
SuperIntel - avatar
1 Respuesta
+ 4
Try to rearrange the coordinates
3rd Nov 2017, 9:50 AM
Muhd Khairul Amirin
Muhd Khairul Amirin - avatar