aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkMatrix.cpp
Commit message (Collapse)AuthorAge
...
* implement drawAtlas natively on gpu-deviceGravatar reed2015-06-25
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1216433002
* add SkCanvas::drawAtlasGravatar reed2015-06-24
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1181913003
* Fix precision error in https://codereview.chromium.org/1188433011/Gravatar robertphillips2015-06-19
| | | | | | TBR=reed@google.com Review URL: https://codereview.chromium.org/1192853002
* Added check for ill-conditioned invertGravatar robertphillips2015-06-19
| | | | | | | | sk_inv_determinant has a guard that the determinant can't get too big so this CL only checks if the determinant gets too small. BUG=492263 Review URL: https://codereview.chromium.org/1188433011
* Remove SK_SUPPORT_LEGACY_SCALAR_MAPPOINTSGravatar fmalita2015-04-09
| | | | | | | | | | | No longer used in Chromium. Also drop now-unused SkMatrix::Rot_pts() & SkMatrix::RotTrans_pts(). BUG=475022 R=reed@google.com,mtklein@google.com Review URL: https://codereview.chromium.org/1071833002
* Refactor Sk2x<T> + Sk4x<T> into SkNf<N,T> and SkNi<N,T>Gravatar mtklein2015-03-30
| | | | | | | | | | | | | | | | | | | | | The primary feature this delivers is SkNf and SkNd for arbitrary power-of-two N. Non-specialized types or types larger than 128 bits should now Just Work (and we can drop in a specialization to make them faster). Sk4s is now just a typedef for SkNf<4, SkScalar>; Sk4d is SkNf<4, double>, Sk2f SkNf<2, float>, etc. This also makes implementing new specializations easier and more encapsulated. We're now using template specialization, which means the specialized versions don't have to leak out so much from SkNx_sse.h and SkNx_neon.h. This design leaves us room to grow up, e.g to SkNf<8, SkScalar> == Sk8s, and to grown down too, to things like SkNi<8, uint16_t> == Sk8h. To simplify things, I've stripped away most APIs (swizzles, casts, reinterpret_casts) that no one's using yet. I will happily add them back if they seem useful. You shouldn't feel bad about using any of the typedef Sk4s, Sk4f, Sk4d, Sk2s, Sk2f, Sk2d, Sk4i, etc. Here's how you should feel: - Sk4f, Sk4s, Sk2d: feel awesome - Sk2f, Sk2s, Sk4d: feel pretty good No public API changes. TBR=reed@google.com BUG=skia:3592 Review URL: https://codereview.chromium.org/1048593002
* use Sk4f for matrix mathGravatar reed2015-03-29
| | | | | | | | | Need to land SK_SUPPORT_LEGACY_SCALAR_MAPPOINTS in chrome to suppress Affine version which causes slight differences (which will need to be rebaselined) BUG=skia: Review URL: https://codereview.chromium.org/1045493002
* use table of procs (and unrolling) to speed up mapPtsGravatar reed2015-03-27
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1040783002
* remove meaningless matrix benches, add mapPts() and add new benchesGravatar reed2015-03-23
| | | | | | | | | | mapPts definitely faster than mapPoints (identity and perspective same speed). Up to 3x for large values of N. cloned from https://codereview.chromium.org/1031443002/ BUG=skia: Review URL: https://codereview.chromium.org/1030653002
* add SkMatrix::decomposeScaleGravatar reed2015-03-19
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1006173005
* Fix overlap test for 64-bit pointers in SkMatrixGravatar qiankun.miao2015-01-12
| | | | | | BUG=skia:3297 Review URL: https://codereview.chromium.org/803493008
* add get9 and set9 to matrix, to aid in making keysGravatar reed2014-12-13
| | | | | | | | BUG=skia: TBR= NOTREECHECKS=True Review URL: https://codereview.chromium.org/806543002
* don't normalize after perspective concatGravatar reed2014-11-18
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/734513004
* make SkMatrix::dump always availableGravatar reed2014-10-02
| | | | | | | BUG=skia: TBR= Review URL: https://codereview.chromium.org/624783002
* specialize setConcat for scale+translateGravatar reed2014-10-02
| | | | | | | | This reverts commit 2a382f519999109b2e3445e73ddb4f0eae926b51. BUG=skia: Review URL: https://codereview.chromium.org/626583002
* Revert of specialize setConcat for scale+translate (patchset #1 id:1 of ↵Gravatar robertphillips2014-10-02
| | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/620433002/) Reason for revert: Experimental to see if this revert "fixes" nanobench on the main console. Original issue's description: > specialize setConcat for scale+translate, helps drawText perf > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/e8db3ef2a2161084fa8eb1fd1d54c35bfff52d6c TBR=jvanverth@google.com,reed@google.com NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/620973003
* specialize setConcat for scale+translate, helps drawText perfGravatar reed2014-09-30
| | | | | | | | | BUG=skia: R=jvanverth@google.com Author: reed@google.com Review URL: https://codereview.chromium.org/620433002
* update to accommodate latest clang in chrome toolchainGravatar caryclark2014-09-18
| | | | | | | | | | | remove asserts for null pointers to references change var args signature to pointer instead of array R=mtklein@google.com, reed@android.com, reed@google.com, mtklein, reed Author: caryclark@google.com Review URL: https://codereview.chromium.org/577243002
* "NULL !=" = NULLGravatar bsalomon2014-09-05
| | | | | | | | R=reed@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/544233002
* Fix matrix similarity test on arm64Gravatar jvanverth2014-09-02
| | | | | | | | | | | | Addresses precision issue by using a simpler test. Also fixes issues with IvMatrix::preservesRightAngles, and adds unit tests. BUG=skia:2405 R=robertphillips@google.com, egdaniel@google.com, djsollen@google.com, reed@google.com Author: jvanverth@google.com Review URL: https://codereview.chromium.org/520123002
* Compile-time initialize special SkMatrices.Gravatar mtklein2014-06-02
| | | | | | | | | BUG=skia: R=bungeman@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/303263011
* Port most uses of SkOnce to SkLazyPtr.Gravatar mtklein2014-06-02
| | | | | | | | | | | | | | BUG=skia: Committed: http://code.google.com/p/skia/source/detail?r=15006 Committed: http://code.google.com/p/skia/source/detail?r=15014 R=reed@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/304383005
* Revert of Port most uses of SkOnce to SkLazyPtr. ↵Gravatar commit-bot@chromium.org2014-05-31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (https://codereview.chromium.org/304383005/) Reason for revert: linux x86-64 release segfault in src/ports/SkFontHost_fontconfig.cpp:107 http://108.170.220.120:10117/builders/Test-Ubuntu12-ShuttleA-GTX660-x86_64-Release/builds/905/steps/RunTests/logs/stdio Original issue's description: > Port most uses of SkOnce to SkLazyPtr. > > BUG=skia: > > Committed: http://code.google.com/p/skia/source/detail?r=15006 > > Committed: http://code.google.com/p/skia/source/detail?r=15014 R=reed@google.com, mtklein@chromium.org TBR=mtklein@chromium.org, reed@google.com NOTREECHECKS=true NOTRY=true BUG=skia: Author: mtklein@google.com Review URL: https://codereview.chromium.org/306063004 git-svn-id: http://skia.googlecode.com/svn/trunk@15015 2bbb7eff-a529-9590-31e7-b0007b416f81
* Port most uses of SkOnce to SkLazyPtr.Gravatar commit-bot@chromium.org2014-05-30
| | | | | | | | | | | | | | BUG=skia: Committed: http://code.google.com/p/skia/source/detail?r=15006 R=reed@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/304383005 git-svn-id: http://skia.googlecode.com/svn/trunk@15014 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert of Port most uses of SkOnce to SkLazyPtr. ↵Gravatar commit-bot@chromium.org2014-05-30
| | | | | | | | | | | | | | | | | | | | | | | | | | (https://codereview.chromium.org/304383005/) Reason for revert: Leaking refs on SkTypeface on Macs. Original issue's description: > Port most uses of SkOnce to SkLazyPtr. > > BUG=skia: > > Committed: http://code.google.com/p/skia/source/detail?r=15006 R=reed@google.com, mtklein@chromium.org TBR=mtklein@chromium.org, reed@google.com NOTREECHECKS=true NOTRY=true BUG=skia: Author: mtklein@google.com Review URL: https://codereview.chromium.org/304283007 git-svn-id: http://skia.googlecode.com/svn/trunk@15009 2bbb7eff-a529-9590-31e7-b0007b416f81
* Port most uses of SkOnce to SkLazyPtr.Gravatar commit-bot@chromium.org2014-05-30
| | | | | | | | | | | BUG=skia: R=reed@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/304383005 git-svn-id: http://skia.googlecode.com/svn/trunk@15006 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add function to get both min and max scale factors from matrixGravatar commit-bot@chromium.org2014-05-20
| | | | | | | | | | R=reed@google.com, jvanverth@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/298473002 git-svn-id: http://skia.googlecode.com/svn/trunk@14804 2bbb7eff-a529-9590-31e7-b0007b416f81
* Rename SkMatrix::get(Max|Min)Stretch to get(Min|Max)ScaleGravatar commit-bot@chromium.org2014-05-20
| | | | | | | | | | R=reed@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/295713002 git-svn-id: http://skia.googlecode.com/svn/trunk@14798 2bbb7eff-a529-9590-31e7-b0007b416f81
* Remove SkCanvas matrix ops return value.Gravatar commit-bot@chromium.org2014-03-18
| | | | | | | | | | | | | The internal SkMatrix ops can no longer fail -> we can remove the bool return value. R=bsalomon@google.com, reed@google.com, robertphillips@google.com, scroggo@google.com, fmalita@google.com Author: fmalita@chromium.org Review URL: https://codereview.chromium.org/200223008 git-svn-id: http://skia.googlecode.com/svn/trunk@13849 2bbb7eff-a529-9590-31e7-b0007b416f81
* Allow toString capability to be toggled independent of developer mode.Gravatar commit-bot@chromium.org2014-03-13
| | | | | | | | | | | | This change is motivated by the desire to see the text information in the debugger when not in developer mode. It is structured so user's can disable it if the capability is not wanted. R=bsalomon@google.com Author: robertphillips@google.com Review URL: https://codereview.chromium.org/197763008 git-svn-id: http://skia.googlecode.com/svn/trunk@13795 2bbb7eff-a529-9590-31e7-b0007b416f81
* remove (unnecessary) SkScalarMul and SkScalarMulAdd macros from SkMatrix.cpp.Gravatar commit-bot@chromium.org2014-01-30
| | | | | | | | | | | | | SkScalarMulDiv remains, but it can be removed later (though it is slightly clearer to use it at times). BUG=skia: R=caryclark@google.com, mtklein@google.com, halcanary@google.com Author: reed@google.com Review URL: https://codereview.chromium.org/150493002 git-svn-id: http://skia.googlecode.com/svn/trunk@13252 2bbb7eff-a529-9590-31e7-b0007b416f81
* remove remaining references to Sk64 (obsolete)Gravatar reed@google.com2014-01-13
| | | | | | | | BUG= Review URL: https://codereview.chromium.org/136673002 git-svn-id: http://skia.googlecode.com/svn/trunk@13042 2bbb7eff-a529-9590-31e7-b0007b416f81
* remove last remnant of SK_SCALAR_IS_FIXED codeGravatar reed@google.com2013-12-18
| | | | | | | | | | move SkScalarMean into its only caller, reducing out public API exposure BUG= Review URL: https://codereview.chromium.org/117133004 git-svn-id: http://skia.googlecode.com/svn/trunk@12733 2bbb7eff-a529-9590-31e7-b0007b416f81
* move SkScalarMean into its only caller, reducing out public API exposureGravatar reed@google.com2013-12-18
| | | | | | | | BUG= Review URL: https://codereview.chromium.org/117973002 git-svn-id: http://skia.googlecode.com/svn/trunk@12732 2bbb7eff-a529-9590-31e7-b0007b416f81
* remove SK_SCALAR_IS_[FLOAT,FIXED] and assume floatsGravatar reed@google.com2013-12-17
| | | | | | | | | | | | | To keep the CL (slightly) managable, this does not make any changes to existing macros (e.g. SkScalarMul). Just tackling #ifdef constructs this time around. BUG= R=bsalomon@google.com, caryclark@google.com Review URL: https://codereview.chromium.org/117053002 git-svn-id: http://skia.googlecode.com/svn/trunk@12712 2bbb7eff-a529-9590-31e7-b0007b416f81
* remove SkFP.h and replace SkFP with SkScalar stop respecting ↵Gravatar reed@google.com2013-12-16
| | | | | | | | | | | SK_SOFTWARE_FLOAT, assume its always false stop respecting SK_SCALAR_SLOW_COMPARES, assume its always false BUG= R=caryclark@google.com Review URL: https://codereview.chromium.org/116183002 git-svn-id: http://skia.googlecode.com/svn/trunk@12686 2bbb7eff-a529-9590-31e7-b0007b416f81
* remove SkScalarCompare type and headerGravatar reed@google.com2013-12-13
| | | | | | | | | BUG= R=fmalita@chromium.org Review URL: https://codereview.chromium.org/113193004 git-svn-id: http://skia.googlecode.com/svn/trunk@12681 2bbb7eff-a529-9590-31e7-b0007b416f81
* Do not use GrBicubic effect when downscaling. Also, don't use glTexStorage ↵Gravatar commit-bot@chromium.org2013-12-09
| | | | | | | | | | | | as it interferes with deleyed mipmap generation. R=robertphillips@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/105353002 git-svn-id: http://skia.googlecode.com/svn/trunk@12576 2bbb7eff-a529-9590-31e7-b0007b416f81
* I feel like my clang is especially sensitive to unused variables.Gravatar mtklein@google.com2013-11-22
| | | | | | | | BUG= Review URL: https://codereview.chromium.org/82913006 git-svn-id: http://skia.googlecode.com/svn/trunk@12369 2bbb7eff-a529-9590-31e7-b0007b416f81
* fix compiler error where SK_SCALAR_IS_FLOAT is not defined. (attempt 2)Gravatar djsollen@google.com2013-11-21
| | | | | | | | R=reed@google.com Review URL: https://codereview.chromium.org/81323002 git-svn-id: http://skia.googlecode.com/svn/trunk@12352 2bbb7eff-a529-9590-31e7-b0007b416f81
* fix compiler error where SK_SCALAR_IS_FLOAT is not defined.Gravatar djsollen@google.com2013-11-21
| | | | | | Review URL: https://codereview.chromium.org/80993004 git-svn-id: http://skia.googlecode.com/svn/trunk@12349 2bbb7eff-a529-9590-31e7-b0007b416f81
* Checking structure sizes before reading them from memory to avoid ↵Gravatar commit-bot@chromium.org2013-11-05
| | | | | | | | | | | | | | | | | overflowing the buffer's stream. BUG= R=reed@google.com, mtklein@google.com, senorblanco@chromium.org Committed: https://code.google.com/p/skia/source/detail?r=12114 Committed: https://code.google.com/p/skia/source/detail?r=12119 Author: sugoi@chromium.org Review URL: https://codereview.chromium.org/41253002 git-svn-id: http://skia.googlecode.com/svn/trunk@12130 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "Checking structure sizes before reading them from memory to avoid ↵Gravatar reed@google.com2013-11-04
| | | | | | | | overflowing the buffer's stream." This reverts commit 6bc22e8ef1ea70a1b58409aa21254358c50f149a. git-svn-id: http://skia.googlecode.com/svn/trunk@12124 2bbb7eff-a529-9590-31e7-b0007b416f81
* Checking structure sizes before reading them from memory to avoid ↵Gravatar sugoi@google.com2013-11-04
| | | | | | | | | | | | | overflowing the buffer's stream. BUG= R=reed@google.com Committed: https://code.google.com/p/skia/source/detail?r=12114 Review URL: https://codereview.chromium.org/41253002 git-svn-id: http://skia.googlecode.com/svn/trunk@12119 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert r12114 due to https://code.google.com/p/skia/issues/detail?id=1794 ↵Gravatar epoger@google.com2013-11-04
| | | | | | ('Assertion failures on various buildbots as of r12114') git-svn-id: http://skia.googlecode.com/svn/trunk@12115 2bbb7eff-a529-9590-31e7-b0007b416f81
* Checking structure sizes before reading them from memory to avoid ↵Gravatar sugoi@google.com2013-11-04
| | | | | | | | | | | overflowing the buffer's stream. BUG= R=reed@google.com Review URL: https://codereview.chromium.org/41253002 git-svn-id: http://skia.googlecode.com/svn/trunk@12114 2bbb7eff-a529-9590-31e7-b0007b416f81
* SK_ONCE for SkData and SkPathRefGravatar commit-bot@chromium.org2013-10-23
| | | | | | | | | | | | | Adds SK_ONCE_FRIEND, to allow SK_DEF_ONCE code to be friends with a class. This had to go in include/core to be visible to headers there. BUG= R=reed@google.com, bungeman@google.com Author: mtklein@google.com Review URL: https://codereview.chromium.org/26491003 git-svn-id: http://skia.googlecode.com/svn/trunk@11914 2bbb7eff-a529-9590-31e7-b0007b416f81
* Correct 32bit pointer assumption in assert in SkMatrix.Gravatar bungeman@google.com2013-10-11
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@11739 2bbb7eff-a529-9590-31e7-b0007b416f81
* SK_ONCE for SkMatrix::I()Gravatar commit-bot@chromium.org2013-10-10
| | | | | | | | | | | | | | Going to start doing these in progressively larger and larger bulk, but I figured the first few changes probably merit caution. BUG= R=reed@google.com, bungeman@google.com Author: mtklein@google.com Review URL: https://codereview.chromium.org/26905002 git-svn-id: http://skia.googlecode.com/svn/trunk@11721 2bbb7eff-a529-9590-31e7-b0007b416f81
* Make skia almost compile again with clang.Gravatar commit-bot@chromium.org2013-10-07
| | | | | | | | | | | | clang is reporting many unused functions and variables. R=bsalomon@google.com, robertphillips@google.com, reed@google.com Author: tfarina@chromium.org Review URL: https://codereview.chromium.org/26167002 git-svn-id: http://skia.googlecode.com/svn/trunk@11630 2bbb7eff-a529-9590-31e7-b0007b416f81