junov@chromium.org
3cb834bd27
Modifying SkTileGrid to support arbitrary query rectangles.
...
Exposing SkTileGrid functionality in the public API through SkTileGridPicture.
This patch also makes TileGrid and Rtree testable in gm, which revealed errors.
TEST=gm with '--tileGrid'
BUG=http://code.google.com/p/chromium/issues/detail?id=164636
Review URL: https://codereview.appspot.com/6933044
git-svn-id: http://skia.googlecode.com/svn/trunk@6783 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-13 16:39:53 +00:00
junov@chromium.org
8f0ca06ef4
Fixing clip region test in deferred canvas, used to determine whether a draw operation occludes the entire canvas.
...
BUG=http://code.google.com/p/chromium/issues/detail?id=164580
TEST=unit test DeferredCanvas/TestDeferredCanvasFreshFrame
Review URL: https://codereview.appspot.com/6934045
git-svn-id: http://skia.googlecode.com/svn/trunk@6780 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-13 16:30:39 +00:00
skia.committer@gmail.com
306ab9d5de
Sanitizing source files in Skia_Periodic_House_Keeping
...
git-svn-id: http://skia.googlecode.com/svn/trunk@6774 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-13 02:01:33 +00:00
fmalita@google.com
bfa0401ab6
Use double precision when iterating in SkDashPathEffect::filterPath()
...
Extremely large path_length/dash_length ratios may cause us to loop
indefinitely otherwise.
R=reed@google.com
BUG=
Review URL: https://codereview.appspot.com/6926051
git-svn-id: http://skia.googlecode.com/svn/trunk@6773 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-12 22:13:58 +00:00
junov@chromium.org
8cdf0f52ff
Adding quickContains API method to SkClipStack
...
BUG=http://code.google.com/p/chromium/issues/detail?id=164580
TEST=unit test ClipStack/quickContains
Review URL: https://codereview.appspot.com/6919044
git-svn-id: http://skia.googlecode.com/svn/trunk@6760 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-12 17:58:15 +00:00
epoger@google.com
31114c69f3
Create SkBitmapChecksummer and associated SkBitmapTransformer
...
As needed to start capturing gm image checksums.
Review URL: https://codereview.appspot.com/6920050
git-svn-id: http://skia.googlecode.com/svn/trunk@6759 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-12 17:22:23 +00:00
robertphillips@google.com
ca47aae7ec
Minor cleanup
...
https://codereview.appspot.com/6927054/
git-svn-id: http://skia.googlecode.com/svn/trunk@6756 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-12 15:58:25 +00:00
skia.committer@gmail.com
c7b4be7f11
Sanitizing source files in Skia_Periodic_House_Keeping
...
git-svn-id: http://skia.googlecode.com/svn/trunk@6746 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-11 02:01:20 +00:00
junov@chromium.org
41e850f074
Fixing logic error in deferred canvas unittest.
...
Fixing an inverted test condition. The tested feature is not broken, but the test was passing the inverted test because code just above was missing a restore call, which was affecting the test.
Review URL: https://codereview.appspot.com/6921044
git-svn-id: http://skia.googlecode.com/svn/trunk@6745 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-10 21:24:38 +00:00
vollick@chromium.org
57a54e33cf
Add SkMatrix44 constructor that allows user to control the initialization
...
method. Preliminary results using Chromium's cc_perftests
show that we can avoid almost half of the default constructors from
redundantly/unnecessarily initializing the matrix to identity.
Review URL: https://codereview.appspot.com/6872056
git-svn-id: http://skia.googlecode.com/svn/trunk@6742 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-10 20:16:10 +00:00
bsalomon@google.com
45a15f551b
Modifications to GrPatherRenderer(Chain) interfaces to support clip mask manager.
...
R=robertphillips@google.com
Review URL: https://codereview.appspot.com/6904069
git-svn-id: http://skia.googlecode.com/svn/trunk@6741 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-10 19:10:17 +00:00
bsalomon@google.com
7f805fff69
Disable failing test on android.
...
Review URL: https://codereview.appspot.com/6899059
git-svn-id: http://skia.googlecode.com/svn/trunk@6738 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-10 17:32:07 +00:00
scroggo@google.com
7c9d539d88
In SKP serialization, use existing encoded data.
...
If an SkBitmap has encoded data, write that during serialization
rather than reencoding it.
Add a test to ensure that this does not modify the output stream,
so the reader need not know the difference.
Review URL: https://codereview.appspot.com/6884054
git-svn-id: http://skia.googlecode.com/svn/trunk@6732 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-10 15:40:55 +00:00
junov@chromium.org
edf32d5b0e
Fixing SkClipStack::clipDevPath so that it will not convert rectangular paths to rectangle clips if inverse fill.
...
BUG=http://code.google.com/p/chromium/issues/detail?id=164580
TEST=unit test ClipStackTest/test_rect_inverse_fill
Review URL: https://codereview.appspot.com/6880044
git-svn-id: http://skia.googlecode.com/svn/trunk@6731 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-10 14:57:54 +00:00
scroggo@google.com
a2a3192847
Fix some extract subset bugs.
...
In SkBitmap::extractSubset, perform a deepCopy, if the pixelRef supports it.
Fixes a bug in the 'extractbitmap' gm, which attempts to draw a subset of a texture backed bitmap (if the canvas is really an SkGpuCanvas).
Also fix some bugs that happen when there is a pixel offset. These fixes get bypassed by the deepCopy, but a user can still set a pixel offset manually.
When copying GPU backed bitmap with a pixel offset, copy the offset.
If the new config is the same as the old, copy fRowBytes as well.
Add a function to SkBitmap.cpp (getUpperLeftFromOffset) to find the x,y coordinate to use when copying to a new config.
Fix a bug where readPixels copied to the correct desired config and we were setting the generation ID to match even though the desired config was not the same as the original config (caught by my new tests!).
Add some tests to verify the correct behavior.
Review URL: https://codereview.appspot.com/6839043
git-svn-id: http://skia.googlecode.com/svn/trunk@6710 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-07 19:14:45 +00:00
epoger@google.com
b485832b66
Mark 64-bit constants as ULL to fix broken 32-bit Mac 10.6 build
...
TBR=bungeman
Review URL: https://codereview.appspot.com/6867079
git-svn-id: http://skia.googlecode.com/svn/trunk@6704 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-07 15:54:01 +00:00
epoger@google.com
0bba6bd78a
Replace SkConsistentChecksum with SkCityHash (now including CityHash via DEPS)
...
Alternative to https://codereview.appspot.com/6847087/ ('Change SkConsistentChecksum to use SuperFastHash')
Review URL: https://codereview.appspot.com/6867060
git-svn-id: http://skia.googlecode.com/svn/trunk@6701 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-07 15:12:01 +00:00
skia.committer@gmail.com
d21444aab7
Sanitizing source files in Skia_Periodic_House_Keeping
...
git-svn-id: http://skia.googlecode.com/svn/trunk@6699 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-07 02:01:25 +00:00
junov@google.com
dbfac8a723
Defining new color constat for transparent color
...
Review URL: https://codereview.appspot.com/6901044
git-svn-id: http://skia.googlecode.com/svn/trunk@6696 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-06 21:47:40 +00:00
bsalomon@google.com
4c2443e36f
Use ReduceClipStack in ClipMaskManager.
...
R=robertphillips@google.com
This will require some gpu rebaselining (complexclip_rect_aa, complexclip_aa, aaclip, simpleaaclip, complexclip_aa_layer)xy
Review URL: https://codereview.appspot.com/6884051
git-svn-id: http://skia.googlecode.com/svn/trunk@6694 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-06 20:58:57 +00:00
bsalomon@google.com
34cd70a581
Make the clip reducer operate on int rects. Remove redundant Gr from func
...
name.
R=robertphillips@google.com
Review URL: https://codereview.appspot.com/6890045
git-svn-id: http://skia.googlecode.com/svn/trunk@6688 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-06 14:23:20 +00:00
skia.committer@gmail.com
0264fb4543
Sanitizing source files in Skia_Periodic_House_Keeping
...
git-svn-id: http://skia.googlecode.com/svn/trunk@6687 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-06 02:01:25 +00:00
bsalomon@google.com
170bd792e1
Move GrReducedClip to its own files.
...
R=robertphillips@google.com
Review URL: https://codereview.appspot.com/6891045
git-svn-id: http://skia.googlecode.com/svn/trunk@6686 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-05 22:26:11 +00:00
reed@google.com
99b5c7f94b
optimize translate and scale
...
add map2() to optimize for mapping an array of 2D points into homogeneous 4-vector
Review URL: https://codereview.appspot.com/6874064
git-svn-id: http://skia.googlecode.com/svn/trunk@6685 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-05 22:13:59 +00:00
skia.committer@gmail.com
73b140a9f6
Sanitizing source files in Skia_Periodic_House_Keeping
...
git-svn-id: http://skia.googlecode.com/svn/trunk@6669 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-05 02:01:21 +00:00
bsalomon@google.com
a444430281
Make GrReduceClipStack use a caller provided query rect rather than return a
...
bounds.
R=robertphillips@google.com
Review URL: https://codereview.appspot.com/6865059
git-svn-id: http://skia.googlecode.com/svn/trunk@6665 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-04 15:22:12 +00:00
scroggo@google.com
4b90b1122c
Handle recording a bitmap if copy fails.
...
If SkBitmapHeap::insert() returns INVALID_SLOT, assert at picture
record time so we can debug, but allow it to continue in release
mode, so that we can still capture a picture. At playback time,
print a message so we know that there was an error.
Review URL: https://codereview.appspot.com/6873050
git-svn-id: http://skia.googlecode.com/svn/trunk@6664 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-04 15:08:56 +00:00
bsalomon@google.com
ebce030108
Fix stale iterators in LList test. Add newline to end of SkTLList.h
...
git-svn-id: http://skia.googlecode.com/svn/trunk@6663 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-04 14:48:57 +00:00
bsalomon@google.com
8182fa0cac
Make SkClipStack::Iter use SkClipStack::Element.
...
R=robertphillips@google.com
Review URL: https://codereview.appspot.com/6871051
git-svn-id: http://skia.googlecode.com/svn/trunk@6661 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-04 14:06:06 +00:00
skia.committer@gmail.com
e659c2e820
Sanitizing source files in Skia_Periodic_House_Keeping
...
git-svn-id: http://skia.googlecode.com/svn/trunk@6660 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-04 02:01:25 +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
bbe52908a2
Add SkTLList, linked list class implemented on top of the internal llist class.
...
R=robertphillips@google.com
Committed: https://code.google.com/p/skia/source/detail?r=6644
Review URL: https://codereview.appspot.com/6869049
git-svn-id: http://skia.googlecode.com/svn/trunk@6647 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-03 18:01:45 +00:00
robertphillips@google.com
93f0332418
Fixed remaining clang compiler warnings
...
https://codereview.appspot.com/6865053/
git-svn-id: http://skia.googlecode.com/svn/trunk@6646 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-03 17:35:19 +00:00
bsalomon@google.com
08cb7286c6
Revert change accidentally committed.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@6645 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-03 15:59:52 +00:00
bsalomon@google.com
d29902e0d7
Add SkTLList, linked list class implemented on top of the internal llist class.
...
R=robertphillips@google.com
Review URL: https://codereview.appspot.com/6869049
git-svn-id: http://skia.googlecode.com/svn/trunk@6644 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-12-03 15:54:12 +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
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
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
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
83a853aa65
Fix the gr/gl destruction order in Test.cpp
...
R=djsollen@google.com
Review URL: https://codereview.appspot.com/6851126
git-svn-id: http://skia.googlecode.com/svn/trunk@6602 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-29 17:27:37 +00:00
djsollen@google.com
f4d1b39118
Remove legacy flag for android from tests
...
Review URL: https://codereview.appspot.com/6782133
git-svn-id: http://skia.googlecode.com/svn/trunk@6600 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-29 16:29:58 +00:00
djsollen@google.com
0945bde599
Fix test app to ensure that we destroy our GPU resources.
...
The problem arises on devices like the Nexus 10 where we allow the
destruction of resources using the destructor of a static variable.
However, we have no guarentee that the GPU driver has not already
cleaned up it's resources prior to our static destructor.
Review URL: https://codereview.appspot.com/6851124
git-svn-id: http://skia.googlecode.com/svn/trunk@6599 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-29 15:28:45 +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
bsalomon@google.com
edb26fdb83
Set empty/wide-open genID on clip stack in more places and fix a bug in GrReduceClipStack.
...
R=robertphillips@google.com
Review URL: https://codereview.appspot.com/6847116
git-svn-id: http://skia.googlecode.com/svn/trunk@6579 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-28 14:42:41 +00:00
bsalomon@google.com
26daa8bbee
Temporarily disable clip stack reduce test while working on fix.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@6567 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-11-27 16:50:14 +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