Commit Graph

1556 Commits

Author SHA1 Message Date
djsollen@google.com
000dea7573 Disabling validation of the glyph cache for standard debug builds.
The validation step is adding 50% overhead to the rendering of
text heavy SkPicture files.

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

git-svn-id: http://skia.googlecode.com/svn/trunk@6635 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-30 16:19:32 +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
jamesr@chromium.org
deb4c16969 Keep track of identity SkMatrix44s
This keeps a bool on SkMatrix44 indicating if we know for sure that the matrix
is identity, similar to the TypeMask on SkMatrix. This is useful to early-out
of potentially expensive matrix math at the cost of some memory.
Review URL: https://codereview.appspot.com/6854113

git-svn-id: http://skia.googlecode.com/svn/trunk@6620 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-29 21:17:16 +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
scroggo@google.com
9f686f3639 Create a factory to decode an SkBitmap from an SkData.
Add a test and a GM for the factory, and a PNG file for it to decode.
The PNG file is copyright-free, obtained from
http://openclipart.org/detail/29213/paper-plane-by-ddoo

In cmykjpeg, do not attempt to decode in the constructor, since it
currently crashes on Mac (if you provide the correct resource path).
Even when we fix this crash there is no need to do it in the
constructor, since we create all of the gms in order to
get their names (to determine whether to run them).

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

git-svn-id: http://skia.googlecode.com/svn/trunk@6618 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-29 21:05:37 +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
reed@google.com
fe7b1ed30a add SkPictureUtils::GatherPixelRefs()
Review URL: https://codereview.appspot.com/6845106

git-svn-id: http://skia.googlecode.com/svn/trunk@6615 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-29 21:00:39 +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
senorblanco@chromium.org
91f489a65d Modify the blur bench to add tests for high-quality blurs, and large non-integer blurs. Change the Coarse flag (which just turns on separable blurs) to an #ifdef, since separable is no longer just Coarse. (This #ifdef will hopefully be shortlived, once Chrome has switched).
The separable blur algorithm gives +45% on SampleBlur, +84% on SampleBigBlur, +31% on TheVerge, +35 to +85% on blurbench in HQ (depending on size), +8 to +35% in low quality.  (All of these on 32bit MacPro).

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

git-svn-id: http://skia.googlecode.com/svn/trunk@6601 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-29 17:09:27 +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
skia.committer@gmail.com
ab38f7acb3 Sanitizing source files in Skia_Periodic_House_Keeping
git-svn-id: http://skia.googlecode.com/svn/trunk@6577 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-28 02:02: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
reed@google.com
631940c8c4 don't use bit-wise test for equality when using floats.
git-svn-id: http://skia.googlecode.com/svn/trunk@6557 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-27 13:13:22 +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
sugoi@google.com
5347de1611 Simple change to remove unnecessary #define statement.
BUG=http://code.google.com/p/chromium/issues/detail?id=137924
TEST=TestDeferredCanvasBitmapSizeThreshold unit test
Review URL: https://codereview.appspot.com/6845071

git-svn-id: http://skia.googlecode.com/svn/trunk@6531 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-21 16:44:45 +00:00
sugoi@google.com
7775fd5779 Deferred canvas can now be flushed if an image is beyond a certain size to avoid a costly image copy.
BUG=http://code.google.com/p/chromium/issues/detail?id=137924
TEST=TestDeferredCanvasBitmapSizeThreshold unit test
Review URL: https://codereview.appspot.com/6852071

git-svn-id: http://skia.googlecode.com/svn/trunk@6527 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-21 15:47:04 +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
senorblanco@chromium.org
336b4da6b0 Separable mask blurs: Add compile-time flag. Fix reversed offsets in asymmetrical blurs (this bug cancels itself out, but I thought it might be confusing for future readers). Use correct stride in asymmetrical blurs (this is a real bug).
Review URL: https://codereview.appspot.com/6782089

git-svn-id: http://skia.googlecode.com/svn/trunk@6508 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-20 17:09:40 +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
vollick@chromium.org
f11cf9ff88 Add SkMatrix44::setColMajord, etc.
We have accessors for efficiently getting the matirx data, and it would be nice
if we had similar methods for setting the matrix entries.

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

git-svn-id: http://skia.googlecode.com/svn/trunk@6494 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-19 21:02:06 +00:00
senorblanco@chromium.org
e0d44ff614 Add support for new glShaderSource() signature from Khronos. Disabled by default.
Review URL: https://codereview.appspot.com/6853068

git-svn-id: http://skia.googlecode.com/svn/trunk@6491 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-19 20:43:10 +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
epoger@google.com
4ce738b98e Extract transform_scanline_XXXX functions into transform_scanline.h for code-sharing
Review URL: https://codereview.appspot.com/6849065

git-svn-id: http://skia.googlecode.com/svn/trunk@6468 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-16 18:44:18 +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
vollick@chromium.org
9b21c25e74 Add SkMatrix44::setTranspose
It turned out that adding getDouble(...) and setDouble(...) made this change
easier, so I've included that in this cl as well.

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

git-svn-id: http://skia.googlecode.com/svn/trunk@6424 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-14 21:33:55 +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
vollick@chromium.org
3959a76ab0 Changing the visibility of SkMatrix44::determinant().
Review URL: https://codereview.appspot.com/6819080

git-svn-id: http://skia.googlecode.com/svn/trunk@6395 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-13 15:08:22 +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
reed@google.com
dd31131021 add const to src parameter for mapMScalars()
git-svn-id: http://skia.googlecode.com/svn/trunk@6386 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-12 20:43:59 +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