Commit Graph

938 Commits

Author SHA1 Message Date
borenet@google.com
bc293c4aa4 Added SK_BUILD_FOR_NACL to SkPreConfig.h
Submitted on behalf of bmilnor@

git-svn-id: http://skia.googlecode.com/svn/trunk@6656 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-03 21:38:58 +00:00
reed@google.com
7d68335eb4 add getTypes() to SkMatrix44, to cache how complex the matrix is.
add bench

optimize operator== by performing 4 compares in a row before checking
optimize setconcat by noting when we can write the answer directly into this

At least on this macbook, I had to mark helpers like isIdentity() as inline to get them inlined.
Review URL: https://codereview.appspot.com/6863053

git-svn-id: http://skia.googlecode.com/svn/trunk@6655 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-03 21:19:52 +00:00
bsalomon@google.com
dd3f7a9efe Reland r6649 with fix for build errors.
git-svn-id: http://skia.googlecode.com/svn/trunk@6653 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-03 19:47:41 +00:00
bsalomon@google.com
acc71aa5c2 Revert 6649 due to build breaks.
git-svn-id: http://skia.googlecode.com/svn/trunk@6651 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-03 19:18:57 +00:00
bsalomon@google.com
4928f86eda Insert in middle of SkTInternalLList and SkTLList, in place cons for
SkTLList.

R=robertphillips@google.com
Review URL: https://codereview.appspot.com/6870050

git-svn-id: http://skia.googlecode.com/svn/trunk@6649 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-03 19:05:44 +00:00
bsalomon@google.com
42619d8df2 Rename SkTDLinkedList to SkTInternalLinked list, add some methods useful for forthcoming SkTLList.
Review URL: https://codereview.appspot.com/6858101

git-svn-id: http://skia.googlecode.com/svn/trunk@6643 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-03 14:54:59 +00:00
tomhudson@google.com
0da23a5184 Tweak an enum declaration to make the clang compiler happy.
This exposes our "unknown type" to users, which is a loss of encapsulation.
TBR=robertphillips

http://codereview.appspot.com/6865050/



git-svn-id: http://skia.googlecode.com/svn/trunk@6641 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-03 11:41:21 +00:00
reed@google.com
9f0af0a285 Create aliases AddRef() and Release() to SkRefCnt for compatibility with scoped_refptr
Review URL: https://codereview.appspot.com/6844116

git-svn-id: http://skia.googlecode.com/svn/trunk@6639 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-30 21:30:42 +00:00
skia.committer@gmail.com
c3d7d90973 Sanitizing source files in Skia_Periodic_House_Keeping
git-svn-id: http://skia.googlecode.com/svn/trunk@6632 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-30 02:01:24 +00:00
bsalomon@google.com
5fac58c91d Remove SkClipStack::Iter::combinedNext.
Review URL: https://codereview.appspot.com/6844114

git-svn-id: http://skia.googlecode.com/svn/trunk@6619 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-29 21:14:59 +00:00
bsalomon@google.com
8a98e3bd18 Make SkClipStack::Element public.
R=robertphillips@google.com
Review URL: https://codereview.appspot.com/6858096

git-svn-id: http://skia.googlecode.com/svn/trunk@6617 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-29 21:05:13 +00:00
bsalomon@google.com
9128edc700 Rename SkClipStack::Rec to SkClipStack::Element
R=robertphillips@google.com
Review URL: https://codereview.appspot.com/6854115

git-svn-id: http://skia.googlecode.com/svn/trunk@6605 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-29 18:58:19 +00:00
robertphillips@google.com
852030103e Add newline at end of SkRRect.h
git-svn-id: http://skia.googlecode.com/svn/trunk@6596 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-29 13:49:33 +00:00
robertphillips@google.com
5985e7c4d1 SkRoundRect start
https://codereview.appspot.com/6815058/



git-svn-id: http://skia.googlecode.com/svn/trunk@6595 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-29 13:24:55 +00:00
skia.committer@gmail.com
687c57c7d5 Sanitizing source files in Skia_Periodic_House_Keeping
git-svn-id: http://skia.googlecode.com/svn/trunk@6594 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-29 02:01:19 +00:00
reed@google.com
5e5885a63d update dox
git-svn-id: http://skia.googlecode.com/svn/trunk@6591 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-28 21:28:57 +00:00
robertphillips@google.com
629ab54066 Added dashing fast path
https://codereview.appspot.com/6844067/



git-svn-id: http://skia.googlecode.com/svn/trunk@6585 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-28 17:18:11 +00:00
reed@google.com
68d6bb0c11 revert prev change to reset
git-svn-id: http://skia.googlecode.com/svn/trunk@6571 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-27 18:37:52 +00:00
reed@google.com
4efd9d9872 guard for self-assignment in reset()
git-svn-id: http://skia.googlecode.com/svn/trunk@6568 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-27 17:20:39 +00:00
bsalomon@google.com
705e840944 Make the clip stack reduction test generate inverse filled paths.
Also adds some comments to GrReduceClipStack.

R=robertphillips@google.com
Review URL: https://codereview.appspot.com/6847109

git-svn-id: http://skia.googlecode.com/svn/trunk@6561 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-27 15:43:57 +00:00
bsalomon@google.com
51a6286c24 Add a function that computes a reduced representation of the clip stack.
Also adds a unit test. The function is not yet used other than in the test.
Review URL: https://codereview.appspot.com/6855098

git-svn-id: http://skia.googlecode.com/svn/trunk@6553 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-26 21:19:43 +00:00
reed@google.com
971aca7557 change SkDrawFilter::filter to return a bool, where false means don't-draw
Review URL: https://codereview.appspot.com/6851111

git-svn-id: http://skia.googlecode.com/svn/trunk@6551 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-26 20:26:54 +00:00
reed@google.com
db3f0fda68 must always include another skia header (unless you're SkTypes.h). In this case,
we need SkScalar.h earlier so we can be sure to have int32_t defined.

inspired by https://codereview.appspot.com/6782122/



git-svn-id: http://skia.googlecode.com/svn/trunk@6548 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-26 20:18:00 +00:00
reed@google.com
a8a3b3d9a0 check for bad enum use when adding contours
Review URL: https://codereview.appspot.com/6849103

git-svn-id: http://skia.googlecode.com/svn/trunk@6547 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-26 18:16:27 +00:00
tfarina@chromium.org
223137f49d Remove GrRandom API in favor of SkRandom.
TEST=tests
R=bsalomon@google.com

Review URL: https://codereview.appspot.com/6855062

git-svn-id: http://skia.googlecode.com/svn/trunk@6539 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-21 22:38:36 +00:00
caryclark@google.com
f68154a3cf Add isRect variant that returns path closure and direction.
Add path test to verify that when isRect() returns false,
output parameters are unchanged.
Review URL: https://codereview.appspot.com/6855074

git-svn-id: http://skia.googlecode.com/svn/trunk@6524 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-21 15:18:06 +00:00
reed@google.com
f6c9a5ba5c add restore() to SkAutoCanvasRestore
git-svn-id: http://skia.googlecode.com/svn/trunk@6505 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-20 15:12:21 +00:00
skia.committer@gmail.com
3458716b52 Sanitizing source files in Skia_Periodic_House_Keeping
git-svn-id: http://skia.googlecode.com/svn/trunk@6500 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-20 02:01:23 +00:00
robertphillips@google.com
866ff8787a Reverting r6489 to fix compiler error in Chrome
143>  LINK : program database E:\b\build\slave\win_layout\build\src\build\Debug\ui.dll.pdb missing; performing full link
143>     Creating library ..\build\Debug\lib\ui.lib and object ..\build\Debug\lib\ui.exp
143>throb_animation.obj : error LNK2001: unresolved external symbol "private: static void (__cdecl*const * const SkMatrix::gMapXYProcs)(class SkMatrix const &,float,float,struct SkPoint *)" (?gMapXYProcs@SkMatrix@@0QBQ6AXABV1@MMPAUSkPoint@@@ZB)

etc 



git-svn-id: http://skia.googlecode.com/svn/trunk@6499 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-20 01:40:45 +00:00
tfarina@chromium.org
15393c7f34 Add missing SK_API define.
For a detailed explanation of this, please refer to Nico Weber description
here: https://chromiumcodereview.appspot.com/10386108

R=bsalomon@google.com

Review URL: https://codereview.appspot.com/6849075

git-svn-id: http://skia.googlecode.com/svn/trunk@6489 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-19 19:43:18 +00:00
reed@google.com
dab9b4fe03 use SkPath::isNestedRects() to apply blurred nine-patch
Review URL: https://codereview.appspot.com/6855063

git-svn-id: http://skia.googlecode.com/svn/trunk@6483 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-19 16:45:14 +00:00
caryclark@google.com
56f233ab54 add two nested rect detector to path
Tease apart existing one rect path detector so
that a new variant can detect two nested rects as well.

Add tests to verify that both one and two rect
detectors both work and return the correct results.

Suppress other warnings in PathTest.
Review URL: https://codereview.appspot.com/6850059

git-svn-id: http://skia.googlecode.com/svn/trunk@6475 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-19 13:06:06 +00:00
mike@reedtribe.org
b947625800 remove unused (and undefined) SkColorSpace parameter.
git-svn-id: http://skia.googlecode.com/svn/trunk@6427 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-15 02:37:45 +00:00
scroggo@google.com
459e6623f1 Remove a warning for comparing signed and unsigned integers.
Review URL: https://codereview.appspot.com/6851050

git-svn-id: http://skia.googlecode.com/svn/trunk@6420 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-14 21:08:53 +00:00
reed@google.com
260eae59b4 move setDevice() to protected: in preparation for its eventual demise
git-svn-id: http://skia.googlecode.com/svn/trunk@6416 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-14 19:07:24 +00:00
reed@google.com
cd5f7e2222 mark SkCanvas::setDevice as DEPRECATED -- need to remove all callers in chrome
git-svn-id: http://skia.googlecode.com/svn/trunk@6414 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-14 14:40:07 +00:00
bsalomon@google.com
9bee33afbe Add a conservativelyContainsRect function to SkPath.
Review URL: https://codereview.appspot.com/6852044

git-svn-id: http://skia.googlecode.com/svn/trunk@6411 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-13 21:51:38 +00:00
skia.committer@gmail.com
fbb0ed959d Sanitizing source files in Skia_Periodic_House_Keeping
git-svn-id: http://skia.googlecode.com/svn/trunk@6409 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-13 21:46:06 +00:00
robertphillips@google.com
9a5b570e5c Allow SkPicture-derived classes install their own SkPicturePlayback-derived object
https://codereview.appspot.com/6851048/



git-svn-id: http://skia.googlecode.com/svn/trunk@6405 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-13 20:41:18 +00:00
vollick@chromium.org
5596a69e9f Add support for SK_MSCALAR_IS_FLOAT
The default is SK_MSCALAR_IS_FLOAT. You'll have to explicitly define SK_MSCALAR_IS_DOUBLE if that's what you want.

BUG=None

Review URL: https://codereview.appspot.com/6843049

git-svn-id: http://skia.googlecode.com/svn/trunk@6403 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-13 20:12:00 +00:00
bsalomon@google.com
30c174b9ce Make SkPath cache the result of cheapComputeDirection.
Review URL: https://codereview.appspot.com/6810111

git-svn-id: http://skia.googlecode.com/svn/trunk@6394 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-13 14:36:42 +00:00
bsalomon@google.com
2e0c79fb63 Revert 6351 due to bugs.
git-svn-id: http://skia.googlecode.com/svn/trunk@6377 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-12 13:38:57 +00:00
reed@google.com
d729b3e504 add entry-point to SkMaskFilter to fast-path rectangles.
have blurmaskfilter override this new method.

#define SK_IGNORE_FAST_BLURRECT if you want to disable this (not sure if we'll need this)
Review URL: https://codereview.appspot.com/6815087

git-svn-id: http://skia.googlecode.com/svn/trunk@6363 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-09 14:30:48 +00:00
skia.committer@gmail.com
d9f7503e0c Sanitizing source files in Skia_Periodic_House_Keeping
git-svn-id: http://skia.googlecode.com/svn/trunk@6362 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-09 02:01:24 +00:00
reed@google.com
6898d52c37 add centerX() and centerY() to SkIRect (because they made me)
Review URL: https://codereview.appspot.com/6826078

git-svn-id: http://skia.googlecode.com/svn/trunk@6360 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-08 22:36:19 +00:00
bsalomon@google.com
6794a258e3 Apply intersect rects to earlier clip elements and skip rects when possible.
R=robertphillips@google.com
Review URL: https://codereview.appspot.com/6814105

git-svn-id: http://skia.googlecode.com/svn/trunk@6351 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-08 15:30:53 +00:00
skia.committer@gmail.com
72b2e6fff3 Sanitizing source files in Skia_Periodic_House_Keeping
git-svn-id: http://skia.googlecode.com/svn/trunk@6344 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-08 02:03:56 +00:00
bsalomon@google.com
e8ca6c6e3a Combine multiple intersecting rects in SkClipStack::Iter.
R=robertphillips@google.com
Review URL: https://codereview.appspot.com/6816104

git-svn-id: http://skia.googlecode.com/svn/trunk@6339 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-07 21:19:10 +00:00
reed@google.com
2a7579d117 CG imagedecoder never sets isOpaque, so add method to SkBitmap to compute that,
and call it from CG imagedecoder.
Review URL: https://codereview.appspot.com/6816101

git-svn-id: http://skia.googlecode.com/svn/trunk@6334 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-07 18:30:18 +00:00
bsalomon@google.com
7b7cdd147f Some improvements to reduce the number of pixels touched in generating alpha clip masks
Review URL: https://codereview.appspot.com/6828043

git-svn-id: http://skia.googlecode.com/svn/trunk@6329 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-07 16:17:24 +00:00