[transform] add perspective property to transform

Summary:
![matrixflip](https://cloud.githubusercontent.com/assets/1509831/8701143/607b069c-2b10-11e5-9c54-8b9767e74e16.gif)

cc @sahrens @vjeux
Closes https://github.com/facebook/react-native/pull/1980
Github Author: chirag04 <jain_chirag04@yahoo.com>
This commit is contained in:
chirag04
2015-07-15 07:57:25 -07:00
parent 64c00dcd7a
commit 915540d237
5 changed files with 180 additions and 44 deletions

View File

@@ -65,6 +65,10 @@ var MatrixMath = {
matrixCommand[10] = z;
},
reusePerspectiveCommand: function(matrixCommand, p) {
matrixCommand[11] = -1 / p;
},
reuseScaleXCommand(matrixCommand, factor) {
matrixCommand[0] = factor;
},