transformation-matrix
Advanced tools
Comparing version 2.3.0 to 2.4.0
{ | ||
"name": "transformation-matrix", | ||
"version": "2.3.0", | ||
"version": "2.4.0", | ||
"description": "2d transformation matrix functions written in ES6 syntax. Tree shaking ready!", | ||
@@ -20,4 +20,3 @@ "main": "./build-commonjs/index.js", | ||
"coverage": "jest --coverage --coveragePathIgnorePatterns autogenerated", | ||
"coveralls": "jest --coverage --coveragePathIgnorePatterns autogenerated --coverageReporters=text-lcov | coveralls", | ||
"test:ci": "npm-run-all standard test build typescript coveralls", | ||
"ci": "npm-run-all standard coverage typescript", | ||
"test": "jest", | ||
@@ -30,5 +29,3 @@ "build-commonjs": "babel src --out-dir build-commonjs", | ||
"clean": "del build-*", | ||
"version": "npm-run-all clean test build add-readme-to-vcs", | ||
"build": "npm-run-all clean build-commonjs build-docs build-umd build-umd-min build-parser", | ||
"add-readme-to-vcs": "git add -A README.md", | ||
"standard": "standard", | ||
@@ -64,3 +61,2 @@ "typescript": "tsc --strict transformation-matrix.d.ts" | ||
"babel-loader": "^8.1.0", | ||
"coveralls": "^3.0.11", | ||
"del-cli": "^3.0.0", | ||
@@ -67,0 +63,0 @@ "jest": "^25.3.0", |
@@ -15,3 +15,3 @@ <!--------------------------------------------------------------------> | ||
[](https://chrvadala.github.io) | ||
[](https://travis-ci.org/chrvadala/transformation-matrix) | ||
[](https://github.com/chrvadala/transformation-matrix/actions) | ||
[](https://coveralls.io/github/chrvadala/transformation-matrix?branch=master) | ||
@@ -22,2 +22,3 @@ [](https://www.npmjs.com/package/transformation-matrix) | ||
Transformations, i.e. *linear invertible automorphisms*, are used to map a picture into another one with different size, position and orientation. Given a basis, transformations are represented by means of squared invertible matrices, called **transformation matrices**. | ||
@@ -160,3 +161,3 @@ A geometric transformation is defined as a one-to-one mapping of a point space to itself, which preservers some geometric relations of figures. - [Geometric Programming for Computer Aided Design](https://books.google.it/books?vid=ISBN9780471899426) | ||
- **2.3**- Adds `(cx,cy)` on `scale` function [#62](https://github.com/chrvadala/transformation-matrix/pull/62); Improves typescript definition [#66](https://github.com/chrvadala/transformation-matrix/pull/67); Upgrades deps | ||
- **2.4**- Improves typescript definition [#75](https://github.com/chrvadala/transformation-matrix/pull/75) | ||
# API | ||
@@ -532,2 +533,5 @@ | ||
- [estollnitz](https://github.com/estollnitz) | ||
- [rodrigoapereira](https://github.com/rodrigoapereira) | ||
- [formatlos](https://github.com/formatlos) | ||
- [benhjames](https://github.com/benhjames) | ||
@@ -110,6 +110,9 @@ type PointObjectNotation = { x: number; y: number }; | ||
* Calculate a scaling matrix | ||
* @param sx Scaling on axis x | ||
* @param sy Scaling on axis y (default `sx`) | ||
* @param sx {number} Scaling on axis x | ||
* @param [sy = sx] {number} Scaling on axis y (default `sx`) | ||
* @param [cx] {number} If (cx,cy) are supplied the scale is relative to this point | ||
* @param [cy] {number} If (cx,cy) are supplied the scale is relative to this point | ||
* @returns {Matrix} Affine Matrix | ||
*/ | ||
export function scale(sx: number, sy?: number): Matrix; | ||
export function scale(sx: number, sy?: number, cx?: number, cy?: number): Matrix; | ||
} | ||
@@ -116,0 +119,0 @@ |
Sorry, the diff of this file is not supported yet
424436
16
6105
534