Commit Graph

10274 Commits

Author SHA1 Message Date
reed@android.com
8433b5db1a more checks for null shapes in pictures
git-svn-id: http://skia.googlecode.com/svn/trunk@249 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-07-03 02:52:27 +00:00
reed@android.com
1c12abe350 fix gradients with alpha to convert to premul *after* the intermediate color
has been computed, othewise we can't distinguish 0x00000000 from 0x00FF0000
Add fast case for index blit where we read 4 src pixels at a time



git-svn-id: http://skia.googlecode.com/svn/trunk@248 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-07-02 15:01:02 +00:00
reed@android.com
ab840b81a9 remove (ack) test code in lineargradient when pos array is null
git-svn-id: http://skia.googlecode.com/svn/trunk@247 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-07-01 17:00:03 +00:00
deanm@chromium.org
bff8e29eaf Fix a precedence error in an assert in the fontconfig host.
Review URL: http://codereview.appspot.com/90060


git-svn-id: http://skia.googlecode.com/svn/trunk@246 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-07-01 07:49:44 +00:00
reed@android.com
a545a5598e fix config check to include SkColorPriv.h so we don't get the warning w/o need
git-svn-id: http://skia.googlecode.com/svn/trunk@245 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-29 17:07:19 +00:00
reed@android.com
4516f4786f use sk_bzero instead of bzero, since it isn't always available.
git-svn-id: http://skia.googlecode.com/svn/trunk@244 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-29 16:25:36 +00:00
reed@android.com
4b7577b042 add unittest for matrix::flatten
define constant for max value flatten/unflatten can return (so clients can put
the buffer on the stack)



git-svn-id: http://skia.googlecode.com/svn/trunk@243 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-29 16:14:41 +00:00
reed@android.com
0ad336f8c6 add shape flatten so they work properly in pictures
add flatten/unflatten to matrix



git-svn-id: http://skia.googlecode.com/svn/trunk@242 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-29 16:02:20 +00:00
reed@android.com
0bfffc59a0 add golden master code for shapes
git-svn-id: http://skia.googlecode.com/svn/trunk@241 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-26 20:22:44 +00:00
reed@android.com
09b84a00f7 add shape recording to pictuures (sans serialization)
git-svn-id: http://skia.googlecode.com/svn/trunk@240 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-26 20:22:26 +00:00
reed@android.com
0baf193754 detect nearly translate-only matrices when drawing bitmaps (for speed)
rename setXfermode(Mode) to setXfermodeMode(Mode) for sanity
fix memory leak in setXfermode(Mode)



git-svn-id: http://skia.googlecode.com/svn/trunk@239 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-24 12:41:42 +00:00
reed@android.com
d66eef7101 fix memory leak in new setXfermode()
git-svn-id: http://skia.googlecode.com/svn/trunk@238 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-24 12:29:16 +00:00
reed@android.com
ee0eb012c5 add new make target "all", to build all known targets
git-svn-id: http://skia.googlecode.com/svn/trunk@237 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-23 17:13:30 +00:00
reed@android.com
048522dd2a remove remaining references to porterduff
git-svn-id: http://skia.googlecode.com/svn/trunk@236 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-23 12:19:41 +00:00
reed@android.com
845fdaca17 remove deprecated use of porterduff enum
git-svn-id: http://skia.googlecode.com/svn/trunk@235 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-23 03:01:32 +00:00
reed@android.com
c9c6422903 update to use new xfermodes
git-svn-id: http://skia.googlecode.com/svn/trunk@234 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-23 00:09:12 +00:00
reed@android.com
8ede49268d merge in change from chrome to detect when the byte order for 8888 requires
additional CGBitmapInfo flags (e.g. for bigendian)



git-svn-id: http://skia.googlecode.com/svn/trunk@233 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-22 20:04:33 +00:00
reed@android.com
a0f5d1546d move xfermode modes from porterduff into xfermode itself
git-svn-id: http://skia.googlecode.com/svn/trunk@232 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-22 17:38:10 +00:00
reed@android.com
1a2fec55d9 add gm for shader tilemodes
git-svn-id: http://skia.googlecode.com/svn/trunk@231 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-22 02:17:34 +00:00
reed@android.com
42309d415e add gm for gradients
git-svn-id: http://skia.googlecode.com/svn/trunk@230 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-22 02:06:35 +00:00
reed@android.com
25b0434908 gm -w 'directory' now works for recording the master images
git-svn-id: http://skia.googlecode.com/svn/trunk@229 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-21 01:40:31 +00:00
reed@android.com
8015dd83ae almost there on gm (need to fix image writes/reads/compares)
move SkAutoGraphics into SkGraphics.h
add [] operators to SkString



git-svn-id: http://skia.googlecode.com/svn/trunk@228 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-21 00:49:18 +00:00
reed@android.com
dd0ac281e9 more progress on golden-master test suite (not finished yet)
git-svn-id: http://skia.googlecode.com/svn/trunk@227 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-20 02:38:16 +00:00
reed@android.com
086f2896e0 add width()/height() getters
git-svn-id: http://skia.googlecode.com/svn/trunk@226 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-20 02:34:55 +00:00
reed@android.com
90e764e3d9 update to latest api (need a test for this port!)
git-svn-id: http://skia.googlecode.com/svn/trunk@225 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-19 20:35:36 +00:00
deanm@chromium.org
5c44d321d0 Make sure we have a non-null FreeType face before dereferencing it.
This prevents a NULL pointer crash in generateFontMetrics with some fonts.

Patch by Lei Zhang.  Original Chromium bug: http://code.google.com/p/chromium/issues/detail?id=13007

Review URL: http://codereview.appspot.com/78056


git-svn-id: http://skia.googlecode.com/svn/trunk@224 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-19 08:57:16 +00:00
reed@android.com
a16cb97c89 really fix gif movie registration
git-svn-id: http://skia.googlecode.com/svn/trunk@223 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-18 20:26:58 +00:00
reed@android.com
5df93eada5 fix stupid tabs
git-svn-id: http://skia.googlecode.com/svn/trunk@222 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-18 18:52:22 +00:00
reed@android.com
8540a79396 add registrar for gif movie
git-svn-id: http://skia.googlecode.com/svn/trunk@221 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-18 17:53:12 +00:00
deanm@chromium.org
81aaa9d8c0 Fix MSVC builds by avoiding a uint to bool warning.
warning C4800: 'const uint8_t' : forcing value to bool 'true' or 'false' (performance warning)

Review URL: http://codereview.appspot.com/79043


git-svn-id: http://skia.googlecode.com/svn/trunk@220 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-18 14:46:03 +00:00
reed@android.com
0ea42c1d2c fallback to drawing a line if the cubic is still too curvy, even if we've
exhausted our recursive attempts to subdivide.

Fixes trying to stroke this cubic (width==1.0)

    path.moveTo(460.2881309415525, 303.250847066498);
    path.cubicTo(463.36378422175284, 302.1169735073363,
                 456.32239330810046, 304.720354932878,
                 453.15255460013304, 305.788586869862);



git-svn-id: http://skia.googlecode.com/svn/trunk@219 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-17 19:21:01 +00:00
reed@android.com
ad687ceae2 add sample for mipmaps
git-svn-id: http://skia.googlecode.com/svn/trunk@218 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-16 01:50:25 +00:00
reed@android.com
31d1c64bd5 ws fixes
git-svn-id: http://skia.googlecode.com/svn/trunk@217 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-15 18:45:19 +00:00
reed@android.com
9a74d31345 create separate opaque version of rgb16 blitter
git-svn-id: http://skia.googlecode.com/svn/trunk@216 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-15 15:56:35 +00:00
reed@android.com
b3ade9d1b0 add optional Format* parameter to decoder helper functions.
git-svn-id: http://skia.googlecode.com/svn/trunk@215 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-15 13:04:45 +00:00
reed@android.com
5119bdb952 add shader flag kConstInY_Flag
this signals blitters that the shader will return the same results for a given
x value, independent of y. Useful inside blitRect(), where it can cache the
first call to shadeSpan() and reuse it on all subsequent scans. Works with
(non-rotated) linear-gradients, and Nx1 bitmaps.



git-svn-id: http://skia.googlecode.com/svn/trunk@214 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-12 21:27:03 +00:00
reed@android.com
b2c5f2d260 make the same prerounding fix for the shadeSpan16 case
git-svn-id: http://skia.googlecode.com/svn/trunk@213 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-12 20:09:24 +00:00
reed@android.com
c552a43c7f preround our fx fractional coordiante, so we get rounded integers (0..255) when
stepping through the gradient.



git-svn-id: http://skia.googlecode.com/svn/trunk@212 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-12 20:02:50 +00:00
reed@android.com
b34086a37f add experimental state tracker for opengl
git-svn-id: http://skia.googlecode.com/svn/trunk@211 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-12 19:49:30 +00:00
reed@android.com
f16c899a74 add equals()
git-svn-id: http://skia.googlecode.com/svn/trunk@210 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-12 02:06:36 +00:00
deanm@chromium.org
1220e1c28a Some Linux / 64-bit compile fixes.
Review URL: http://codereview.appspot.com/63189


git-svn-id: http://skia.googlecode.com/svn/trunk@209 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-11 12:26:47 +00:00
reed@android.com
00dae86f58 checkpoint for golden master suite (gm)
git-svn-id: http://skia.googlecode.com/svn/trunk@208 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-10 15:38:48 +00:00
reed@android.com
199f108f14 only call SkDevice::gainFocus() if we're actually drawing to a different device.
Saves overhead when using GL.



git-svn-id: http://skia.googlecode.com/svn/trunk@207 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-10 02:12:47 +00:00
reed@android.com
829c83c7c9 fix odd-pixel bug in mipmap downsamplers (thanks brett)
git-svn-id: http://skia.googlecode.com/svn/trunk@204 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-08 12:05:31 +00:00
reed@android.com
bbff1d507a add SkParsePath to go to/from SVG strings (e.g. "M0,0 L10,20")
git-svn-id: http://skia.googlecode.com/svn/trunk@203 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-05 16:21:03 +00:00
reed@android.com
ec3d6e5a2f update for cache updates
git-svn-id: http://skia.googlecode.com/svn/trunk@202 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-05 14:43:55 +00:00
reed@android.com
9b46e77ec2 fix dumpcanvas to recurse on pictures and shapes
add cached bitmap for gradients to avoid thrashing textures in gl



git-svn-id: http://skia.googlecode.com/svn/trunk@201 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-05 12:24:41 +00:00
deanm@chromium.org
1599a4332a Replace nil -> NULL in the views code.
Review URL: http://codereview.appspot.com/67139


git-svn-id: http://skia.googlecode.com/svn/trunk@200 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-04 15:37:11 +00:00
reed@android.com
6b82d1adc6 add isConvex() hit to SkPath, to be used to speed up fills and opengl
set linewidth in gldevice for hair rects
remove some cruft from samples
add more gl-unimpl messages



git-svn-id: http://skia.googlecode.com/svn/trunk@199 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-03 02:35:01 +00:00
reed@android.com
4a7fd2bd27 initialize fFlags in gradients
fix trailing WS in SkGLDevice



git-svn-id: http://skia.googlecode.com/svn/trunk@198 2bbb7eff-a529-9590-31e7-b0007b416f81
2009-06-02 19:46:20 +00:00