From 5ed2e15a4e27d10d4d0866bb40a9ec4e484b4f3a Mon Sep 17 00:00:00 2001 From: Vladimir Mandic Date: Fri, 26 Nov 2021 11:55:52 -0500 Subject: [PATCH] add offscreencanvas typedefs --- CHANGELOG.md | 3 ++- api-extractor.json | 2 +- package.json | 2 +- src/face/angles.ts | 2 +- src/tfjs/tfjs.esm.d.ts | 2 -- 5 files changed, 5 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index fc904112..c2d5edf6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,8 +9,9 @@ ## Changelog -### **HEAD -> main** 2021/11/23 mandic00@live.com +### **HEAD -> main** 2021/11/24 mandic00@live.com +- release preview - fix face box scaling on detection - cleanup diff --git a/api-extractor.json b/api-extractor.json index 037280f7..9ca969a2 100644 --- a/api-extractor.json +++ b/api-extractor.json @@ -1,7 +1,7 @@ { "$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json", "mainEntryPointFilePath": "types/lib/src/human.d.ts", - "bundledPackages": ["@tensorflow/tfjs-core", "@tensorflow/tfjs-converter"], + "bundledPackages": ["@tensorflow/tfjs-core", "@tensorflow/tfjs-converter", "@types/offscreencanvas"], "compiler": { "skipLibCheck": false }, diff --git a/package.json b/package.json index 0ad5361d..122d2601 100644 --- a/package.json +++ b/package.json @@ -86,7 +86,7 @@ "rimraf": "^3.0.2", "seedrandom": "^3.0.5", "tslib": "^2.3.1", - "typedoc": "0.22.9", + "typedoc": "0.22.10", "typescript": "4.5.2" } } diff --git a/src/face/angles.ts b/src/face/angles.ts index 5be7894f..9e23f5cb 100644 --- a/src/face/angles.ts +++ b/src/face/angles.ts @@ -78,7 +78,7 @@ export const calculateFaceAngle = (face, imageSize): { if (isNaN(thetaX)) thetaX = 0; if (isNaN(thetaY)) thetaY = 0; if (isNaN(thetaZ)) thetaZ = 0; - return { pitch: -thetaX, yaw: -thetaY, roll: -thetaZ }; + return { pitch: 2 * -thetaX, yaw: 2 * -thetaY, roll: 2 * -thetaZ }; }; // simple Euler angle calculation based existing 3D mesh // eslint-disable-next-line no-unused-vars, @typescript-eslint/no-unused-vars diff --git a/src/tfjs/tfjs.esm.d.ts b/src/tfjs/tfjs.esm.d.ts index 91200e44..9ac6591c 100644 --- a/src/tfjs/tfjs.esm.d.ts +++ b/src/tfjs/tfjs.esm.d.ts @@ -1,5 +1,3 @@ -/// - export declare const version: { 'tfjs-core': string; 'tfjs-backend-cpu': string;