This commit is contained in:
Dragon Fire
2021-04-06 09:36:25 -04:00
parent e89d4374df
commit f7698ebf9b
+2 -2
View File
@@ -64,8 +64,8 @@ module.exports = class EmojiFaceCommand extends Command {
for (const face of faces) {
const landmarks = face.landmark;
const width = landmarks.contour_right1.x - landmarks.contour_left1.x;
const ratio = width / danny.width;
const height = danny.height * ratio;
const ratio = width / emojiImg.width;
const height = emojiImg.height * ratio;
ctx.drawImage(
emojiImg,
landmarks.contour_left1.x - (width * 0.25),