fix
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
1a9e11b1cd
commit
ce38672201
|
@ -38,16 +38,23 @@ const render = () => {
|
||||||
var rotationDelta = imageHeightPx / Math.tan(vRotation / 180 * Math.PI);
|
var rotationDelta = imageHeightPx / Math.tan(vRotation / 180 * Math.PI);
|
||||||
|
|
||||||
if (ctx.value) {
|
if (ctx.value) {
|
||||||
|
var x = 0;
|
||||||
var y = 0;
|
var y = 0;
|
||||||
for (let i = 0; i < 100; i++) {
|
|
||||||
|
let i = 0;
|
||||||
|
while (y < imageHeightPx) {
|
||||||
y += hMargins[i % 2] * ONE_MM;
|
y += hMargins[i % 2] * ONE_MM;
|
||||||
ctx.value.moveTo(0, y);
|
ctx.value.moveTo(0, y);
|
||||||
ctx.value.lineTo(imageWidthPx, y);
|
ctx.value.lineTo(imageWidthPx, y);
|
||||||
ctx.value.stroke();
|
ctx.value.stroke();
|
||||||
|
i++;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (let i = 1; i < 100; i++) {
|
x = 0;
|
||||||
const x = i * vMarginPx;
|
y = 0;
|
||||||
|
i = 0;
|
||||||
|
while (x - rotationDelta < imageWidthPx) {
|
||||||
|
x = i * vMarginPx;
|
||||||
var x0 = x;
|
var x0 = x;
|
||||||
var y0 = 0;
|
var y0 = 0;
|
||||||
var x1 = x - rotationDelta;
|
var x1 = x - rotationDelta;
|
||||||
|
@ -55,6 +62,7 @@ const render = () => {
|
||||||
ctx.value.moveTo(x0, y0);
|
ctx.value.moveTo(x0, y0);
|
||||||
ctx.value.lineTo(x1, y1);
|
ctx.value.lineTo(x1, y1);
|
||||||
ctx.value.stroke();
|
ctx.value.stroke();
|
||||||
|
i++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue