02.11.2019, 07:37
(27.10.2019, 22:39)buuuudzik Wrote: You can do this like below:
Code:const cvs = document.querySelector("icanvas2")
const ctx = cvs.getContext("2d");
console.log(cvs);
Hello:
I am trying to draw a simple line, in an element "Frame" in LogicMachine, but I think something is wrong
I try to do this, but it doesnt work:
const cvs = document.querySelector(".icanvas3")
console.log(cvs);
const ctx = cvs.getContext("2d");
console.log(ctx);
ctx.moveTo(0,0);
ctx.lineTo(200,100);
ctx.stroke();
Could you help me please?
best regards