platform/upstream/libSkiaSharp.git
15 years agoMake sure we have a non-null FreeType face before dereferencing it.
deanm@chromium.org [Fri, 19 Jun 2009 08:57:16 +0000 (08:57 +0000)]
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

15 years agoreally fix gif movie registration
reed@android.com [Thu, 18 Jun 2009 20:26:58 +0000 (20:26 +0000)]
really fix gif movie registration

git-svn-id: http://skia.googlecode.com/svn/trunk@223 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agofix stupid tabs
reed@android.com [Thu, 18 Jun 2009 18:52:22 +0000 (18:52 +0000)]
fix stupid tabs

git-svn-id: http://skia.googlecode.com/svn/trunk@222 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd registrar for gif movie
reed@android.com [Thu, 18 Jun 2009 17:53:12 +0000 (17:53 +0000)]
add registrar for gif movie

git-svn-id: http://skia.googlecode.com/svn/trunk@221 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoFix MSVC builds by avoiding a uint to bool warning.
deanm@chromium.org [Thu, 18 Jun 2009 14:46:03 +0000 (14:46 +0000)]
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

15 years agofallback to drawing a line if the cubic is still too curvy, even if we've
reed@android.com [Wed, 17 Jun 2009 19:21:01 +0000 (19:21 +0000)]
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

15 years agoadd sample for mipmaps
reed@android.com [Tue, 16 Jun 2009 01:50:25 +0000 (01:50 +0000)]
add sample for mipmaps

git-svn-id: http://skia.googlecode.com/svn/trunk@218 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agows fixes
reed@android.com [Mon, 15 Jun 2009 18:45:19 +0000 (18:45 +0000)]
ws fixes

git-svn-id: http://skia.googlecode.com/svn/trunk@217 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agocreate separate opaque version of rgb16 blitter
reed@android.com [Mon, 15 Jun 2009 15:56:35 +0000 (15:56 +0000)]
create separate opaque version of rgb16 blitter

git-svn-id: http://skia.googlecode.com/svn/trunk@216 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd optional Format* parameter to decoder helper functions.
reed@android.com [Mon, 15 Jun 2009 13:04:45 +0000 (13:04 +0000)]
add optional Format* parameter to decoder helper functions.

git-svn-id: http://skia.googlecode.com/svn/trunk@215 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd shader flag kConstInY_Flag
reed@android.com [Fri, 12 Jun 2009 21:27:03 +0000 (21:27 +0000)]
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

15 years agomake the same prerounding fix for the shadeSpan16 case
reed@android.com [Fri, 12 Jun 2009 20:09:24 +0000 (20:09 +0000)]
make the same prerounding fix for the shadeSpan16 case

git-svn-id: http://skia.googlecode.com/svn/trunk@213 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agopreround our fx fractional coordiante, so we get rounded integers (0..255) when
reed@android.com [Fri, 12 Jun 2009 20:02:50 +0000 (20:02 +0000)]
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

15 years agoadd experimental state tracker for opengl
reed@android.com [Fri, 12 Jun 2009 19:49:30 +0000 (19:49 +0000)]
add experimental state tracker for opengl

git-svn-id: http://skia.googlecode.com/svn/trunk@211 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd equals()
reed@android.com [Fri, 12 Jun 2009 02:06:36 +0000 (02:06 +0000)]
add equals()

git-svn-id: http://skia.googlecode.com/svn/trunk@210 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoSome Linux / 64-bit compile fixes.
deanm@chromium.org [Thu, 11 Jun 2009 12:26:47 +0000 (12:26 +0000)]
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

15 years agocheckpoint for golden master suite (gm)
reed@android.com [Wed, 10 Jun 2009 15:38:48 +0000 (15:38 +0000)]
checkpoint for golden master suite (gm)

git-svn-id: http://skia.googlecode.com/svn/trunk@208 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoonly call SkDevice::gainFocus() if we're actually drawing to a different device.
reed@android.com [Wed, 10 Jun 2009 02:12:47 +0000 (02:12 +0000)]
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

15 years agofix odd-pixel bug in mipmap downsamplers (thanks brett)
reed@android.com [Mon, 8 Jun 2009 12:05:31 +0000 (12:05 +0000)]
fix odd-pixel bug in mipmap downsamplers (thanks brett)

git-svn-id: http://skia.googlecode.com/svn/trunk@204 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd SkParsePath to go to/from SVG strings (e.g. "M0,0 L10,20")
reed@android.com [Fri, 5 Jun 2009 16:21:03 +0000 (16:21 +0000)]
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

15 years agoupdate for cache updates
reed@android.com [Fri, 5 Jun 2009 14:43:55 +0000 (14:43 +0000)]
update for cache updates

git-svn-id: http://skia.googlecode.com/svn/trunk@202 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agofix dumpcanvas to recurse on pictures and shapes
reed@android.com [Fri, 5 Jun 2009 12:24:41 +0000 (12:24 +0000)]
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

15 years agoReplace nil -> NULL in the views code.
deanm@chromium.org [Thu, 4 Jun 2009 15:37:11 +0000 (15:37 +0000)]
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

15 years agoadd isConvex() hit to SkPath, to be used to speed up fills and opengl
reed@android.com [Wed, 3 Jun 2009 02:35:01 +0000 (02:35 +0000)]
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

15 years agoinitialize fFlags in gradients
reed@android.com [Tue, 2 Jun 2009 19:46:20 +0000 (19:46 +0000)]
initialize fFlags in gradients
fix trailing WS in SkGLDevice

git-svn-id: http://skia.googlecode.com/svn/trunk@198 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agofix break in setConfig() where we always reset the bitmap
reed@android.com [Tue, 2 Jun 2009 18:54:28 +0000 (18:54 +0000)]
fix break in setConfig() where we always reset the bitmap
remove use of non-standard ssize_t in SkSfntUtils.cpp

git-svn-id: http://skia.googlecode.com/svn/trunk@197 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoStyle only change to make SkBitmap to make it build with VC2005.
agl@chromium.org [Mon, 1 Jun 2009 23:52:37 +0000 (23:52 +0000)]
Style only change to make SkBitmap to make it build with VC2005.

TBR=reed

git-svn-id: http://skia.googlecode.com/svn/trunk@196 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd unimpl macro to help track bugs
reed@android.com [Mon, 1 Jun 2009 21:18:36 +0000 (21:18 +0000)]
add unimpl macro to help track bugs

git-svn-id: http://skia.googlecode.com/svn/trunk@195 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoupdate includes for android for gl backend
reed@android.com [Mon, 1 Jun 2009 19:48:56 +0000 (19:48 +0000)]
update includes for android for gl backend

git-svn-id: http://skia.googlecode.com/svn/trunk@194 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agofontconfig: allow fallback for certain magical font names.
agl@chromium.org [Mon, 1 Jun 2009 19:20:38 +0000 (19:20 +0000)]
fontconfig: allow fallback for certain magical font names.

http://codereview.appspot.com/63169
http://code.google.com/p/chromium/issues/detail?id=10665

Patch-by: Evan Martin
git-svn-id: http://skia.googlecode.com/svn/trunk@193 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agocall notifyPixelsChanged() when the pages are flipped in pageflippixelref
reed@android.com [Sat, 30 May 2009 02:40:28 +0000 (02:40 +0000)]
call notifyPixelsChanged() when the pages are flipped in pageflippixelref
update samples

git-svn-id: http://skia.googlecode.com/svn/trunk@192 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agofix trailing-ws
reed@android.com [Fri, 29 May 2009 21:30:42 +0000 (21:30 +0000)]
fix trailing-ws
initialize fFlags in bitmapprocshader

git-svn-id: http://skia.googlecode.com/svn/trunk@191 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoupdate SDL port to support OpenGL
reed@android.com [Fri, 29 May 2009 03:40:05 +0000 (03:40 +0000)]
update SDL port to support OpenGL
need to separate out SK_BUILD_FOR_MAC when we need to know where certain OS
headers are, and SK_BUILD_FOR_SDL when we are choosing an SkOSWindow variant...

git-svn-id: http://skia.googlecode.com/svn/trunk@190 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoanimate matrixref in sample shapes
reed@android.com [Wed, 27 May 2009 01:44:24 +0000 (01:44 +0000)]
animate matrixref in sample shapes

git-svn-id: http://skia.googlecode.com/svn/trunk@189 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agomove shapes subclasses into effects
reed@android.com [Wed, 27 May 2009 01:20:10 +0000 (01:20 +0000)]
move shapes subclasses into effects

git-svn-id: http://skia.googlecode.com/svn/trunk@188 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agocreate offscreen surface so we can set its RGB ordering to match our internals
reed@android.com [Tue, 26 May 2009 13:27:48 +0000 (13:27 +0000)]
create offscreen surface so we can set its RGB ordering to match our internals

git-svn-id: http://skia.googlecode.com/svn/trunk@187 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agomake include search paths relative
reed@android.com [Fri, 22 May 2009 21:07:11 +0000 (21:07 +0000)]
make include search paths relative

git-svn-id: http://skia.googlecode.com/svn/trunk@186 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoupdate relative paths for sample code
reed@android.com [Fri, 22 May 2009 21:01:38 +0000 (21:01 +0000)]
update relative paths for sample code

git-svn-id: http://skia.googlecode.com/svn/trunk@185 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd actual sdl project file
reed@android.com [Fri, 22 May 2009 20:57:52 +0000 (20:57 +0000)]
add actual sdl project file

git-svn-id: http://skia.googlecode.com/svn/trunk@184 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd sampleapp_sdl
reed@android.com [Fri, 22 May 2009 20:53:55 +0000 (20:53 +0000)]
add sampleapp_sdl

git-svn-id: http://skia.googlecode.com/svn/trunk@183 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd SDL support
reed@android.com [Fri, 22 May 2009 20:44:12 +0000 (20:44 +0000)]
add SDL support

git-svn-id: http://skia.googlecode.com/svn/trunk@182 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd SkSafeRef / SkSafeUnref as inline static functions, to use in place of our
reed@android.com [Fri, 22 May 2009 14:39:03 +0000 (14:39 +0000)]
add SkSafeRef / SkSafeUnref as inline static functions, to use in place of our
existing obj->safeRef(), which is unsafe since it can its 'if (this)' can be
optimized away by some compilers.

fix some overflows in mimpmap generation

git-svn-id: http://skia.googlecode.com/svn/trunk@181 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd sample effects
reed@android.com [Fri, 22 May 2009 13:48:35 +0000 (13:48 +0000)]
add sample effects

git-svn-id: http://skia.googlecode.com/svn/trunk@180 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoinit bounds to empty if we return false from getClipBounds()
reed@android.com [Mon, 18 May 2009 15:46:29 +0000 (15:46 +0000)]
init bounds to empty if we return false from getClipBounds()

We were already doing that in one place (empty clip), but now we do it in the
other as well (matrix not invertible).

git-svn-id: http://skia.googlecode.com/svn/trunk@179 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoshapes checkpoint: move matrix into groupshape and out of shape
reed@android.com [Mon, 18 May 2009 04:20:55 +0000 (04:20 +0000)]
shapes checkpoint: move matrix into groupshape and out of shape

git-svn-id: http://skia.googlecode.com/svn/trunk@178 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agofix parse error:
reed@android.com [Mon, 18 May 2009 00:47:46 +0000 (00:47 +0000)]
fix parse error:

Issue 63053: Fixed parse error in XML

git-svn-id: http://skia.googlecode.com/svn/trunk@177 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoFix reference count on openStream
reed@android.com [Mon, 18 May 2009 00:43:58 +0000 (00:43 +0000)]
Fix reference count on openStream

Issue 62067: SkFontHost_linux.cpp: Reference counting problem

git-svn-id: http://skia.googlecode.com/svn/trunk@176 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agofix impl of drawPicture
reed@android.com [Wed, 13 May 2009 21:01:21 +0000 (21:01 +0000)]
fix impl of drawPicture

git-svn-id: http://skia.googlecode.com/svn/trunk@175 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd SkSize for dimensions
reed@android.com [Wed, 13 May 2009 14:00:33 +0000 (14:00 +0000)]
add SkSize for dimensions
add SkShape baseclass, in the hopes of having SkPicture inherit from that, and
also using shapes as the extension mechanism for things like animated-gif

git-svn-id: http://skia.googlecode.com/svn/trunk@174 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoHonor pref config in image decoding whenever possible.
weita@google.com [Mon, 11 May 2009 16:06:22 +0000 (16:06 +0000)]
Honor pref config in image decoding whenever possible.

git-svn-id: http://skia.googlecode.com/svn/trunk@173 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd SkSize for dimensions
reed@android.com [Fri, 8 May 2009 16:45:52 +0000 (16:45 +0000)]
add SkSize for dimensions

git-svn-id: http://skia.googlecode.com/svn/trunk@172 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd SK_USE_OLD_255_TO_256 define to disable alpha+1 change to SkAlpha255To256
reed@android.com [Fri, 8 May 2009 13:10:38 +0000 (13:10 +0000)]
add SK_USE_OLD_255_TO_256 define to disable alpha+1 change to SkAlpha255To256

git-svn-id: http://skia.googlecode.com/svn/trunk@171 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoTypo fix for VDMX parsing in Chromium.
agl@chromium.org [Thu, 7 May 2009 00:48:12 +0000 (00:48 +0000)]
Typo fix for VDMX parsing in Chromium.

TBR=reed

git-svn-id: http://skia.googlecode.com/svn/trunk@170 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd canCopyTo(), to preflight if copyTo can succeed. update unittests for it
reed@android.com [Wed, 6 May 2009 17:44:34 +0000 (17:44 +0000)]
add canCopyTo(), to preflight if copyTo can succeed. update unittests for it

git-svn-id: http://skia.googlecode.com/svn/trunk@169 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agofix copyTo to only copy the minimum pixels per row, and to lock the src before
reed@android.com [Tue, 5 May 2009 23:13:23 +0000 (23:13 +0000)]
fix copyTo to only copy the minimum pixels per row, and to lock the src before
trying to access its colorTable. Update unittest for copyTo. Add sample for
using a mask to clip a layer.

git-svn-id: http://skia.googlecode.com/svn/trunk@168 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd simple port of memory APIs, to be used as a template for other platforms
reed@android.com [Mon, 4 May 2009 19:24:56 +0000 (19:24 +0000)]
add simple port of memory APIs, to be used as a template for other platforms
that may want to add new_handler logic or other hooks.

git-svn-id: http://skia.googlecode.com/svn/trunk@167 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoupdate license header
reed@android.com [Mon, 4 May 2009 18:52:54 +0000 (18:52 +0000)]
update license header

git-svn-id: http://skia.googlecode.com/svn/trunk@166 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agocheck for 0 upem in freetype
reed@android.com [Mon, 4 May 2009 15:00:11 +0000 (15:00 +0000)]
check for 0 upem in freetype
add 32bit-overflow check

git-svn-id: http://skia.googlecode.com/svn/trunk@165 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoAllow copying an Index8 bitmap when srcConfig and dstConfig are both
weita@google.com [Sun, 3 May 2009 18:23:30 +0000 (18:23 +0000)]
Allow copying an Index8 bitmap when srcConfig and dstConfig are both
Index8.

Also, change the logic of SkBitmap.copyTo() to do memcpy() if srcConfig
and dstConfig are the same.

git-svn-id: http://skia.googlecode.com/svn/trunk@164 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd BitmapCopyTest. Still need to consider the src==no_config case
reed@android.com [Fri, 1 May 2009 04:00:01 +0000 (04:00 +0000)]
add BitmapCopyTest. Still need to consider the src==no_config case

git-svn-id: http://skia.googlecode.com/svn/trunk@163 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoAdd fontconfig support.
agl@chromium.org [Tue, 28 Apr 2009 17:30:01 +0000 (17:30 +0000)]
Add fontconfig support.

Fontconfig is usually found on Linux systems and handles
configuration, parsing and caching issues involved with enumerating
and matching fonts.

This patch adds SkFontHost methods based on fontconfig.

git-svn-id: http://skia.googlecode.com/svn/trunk@162 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agohandle interlacing
reed@android.com [Tue, 28 Apr 2009 15:27:07 +0000 (15:27 +0000)]
handle interlacing

git-svn-id: http://skia.googlecode.com/svn/trunk@161 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd skiamge (in tools/) that decodes and encodes images
reed@android.com [Fri, 24 Apr 2009 19:52:53 +0000 (19:52 +0000)]
add skiamge (in tools/) that decodes and encodes images

git-svn-id: http://skia.googlecode.com/svn/trunk@160 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd ADD xfermode
reed@android.com [Fri, 24 Apr 2009 12:43:40 +0000 (12:43 +0000)]
add ADD xfermode
safely handle (don't draw) if the size of SkMask exceeds 31bits

git-svn-id: http://skia.googlecode.com/svn/trunk@159 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agofix mac build
reed@android.com [Thu, 23 Apr 2009 05:06:33 +0000 (05:06 +0000)]
fix mac build

git-svn-id: http://skia.googlecode.com/svn/trunk@158 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoSync with Chromium's fork
agl@chromium.org [Wed, 22 Apr 2009 22:09:04 +0000 (22:09 +0000)]
Sync with Chromium's fork

* Add the following font metrics fields:
    + fAvgCharWidth
    + fXMin
    + fXMax
    + fXHeight

* Add \#if 0'ed includes for the Freetype headers for Xcode, scons and
  other tools which chase headers.

* Correctly render 1bpp fonts (mostly Chinese fonts at small sizes)

git-svn-id: http://skia.googlecode.com/svn/trunk@157 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agotrivial: fix ws
reed@android.com [Tue, 14 Apr 2009 15:10:55 +0000 (15:10 +0000)]
trivial: fix ws

git-svn-id: http://skia.googlecode.com/svn/trunk@156 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd SkSfntUtils to parse some known truetype tables
reed@android.com [Tue, 14 Apr 2009 14:28:22 +0000 (14:28 +0000)]
add SkSfntUtils to parse some known truetype tables
add comments and cleanup to count_tables in SkFontHost_tables.cpp
fix transparency bug in gifs
use (alpha+1) for blending in srcover mode, to ensure opaque results

git-svn-id: http://skia.googlecode.com/svn/trunk@155 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoSkFontHost_tables: fix minor bugs
agl@chromium.org [Mon, 13 Apr 2009 21:43:40 +0000 (21:43 +0000)]
SkFontHost_tables: fix minor bugs

http://codereview.appspot.com/33092

git-svn-id: http://skia.googlecode.com/svn/trunk@154 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoupdate for config/ directory
reed@android.com [Sun, 12 Apr 2009 01:49:38 +0000 (01:49 +0000)]
update for config/ directory

git-svn-id: http://skia.googlecode.com/svn/trunk@153 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agosupport -android mode when running tests, which spews out android specific
reed@android.com [Thu, 9 Apr 2009 04:06:54 +0000 (04:06 +0000)]
support -android mode when running tests, which spews out android specific
formatting for their testing env.

git-svn-id: http://skia.googlecode.com/svn/trunk@152 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agomove SkUserConfig.h into include/config/ so it can be replaced by changing the
reed@android.com [Wed, 8 Apr 2009 18:05:24 +0000 (18:05 +0000)]
move SkUserConfig.h into include/config/ so it can be replaced by changing the
include search list at the Makefile level

git-svn-id: http://skia.googlecode.com/svn/trunk@151 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoimplement generateCountGlyphs using new font table apis
reed@android.com [Wed, 8 Apr 2009 05:27:00 +0000 (05:27 +0000)]
implement generateCountGlyphs using new font table apis

git-svn-id: http://skia.googlecode.com/svn/trunk@150 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd Table apis to SkFontHost
reed@android.com [Wed, 8 Apr 2009 05:03:52 +0000 (05:03 +0000)]
add Table apis to SkFontHost
need to implement in _win backend

git-svn-id: http://skia.googlecode.com/svn/trunk@149 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoupdate SkPostConfig.h to unset LEAN_AND_MEAN if it set it before including <windows.h>
reed@android.com [Mon, 6 Apr 2009 16:09:53 +0000 (16:09 +0000)]
update SkPostConfig.h to unset LEAN_AND_MEAN if it set it before including <windows.h>

git-svn-id: http://skia.googlecode.com/svn/trunk@148 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoimport portability fixes from Chrome around floats
reed@android.com [Fri, 3 Apr 2009 14:26:10 +0000 (14:26 +0000)]
import portability fixes from Chrome around floats
move porting functions for SkDebugf into /ports directory

git-svn-id: http://skia.googlecode.com/svn/trunk@147 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoextend gradients to handle (by clamping) the first and last color position if
reed@android.com [Fri, 3 Apr 2009 13:33:51 +0000 (13:33 +0000)]
extend gradients to handle (by clamping) the first and last color position if
it is not at 0 or 1.

git-svn-id: http://skia.googlecode.com/svn/trunk@146 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoreplace floorf() with sk_float_floor(), so it builds on platforms w/o floorf
reed@android.com [Thu, 2 Apr 2009 21:11:14 +0000 (21:11 +0000)]
replace floorf() with sk_float_floor(), so it builds on platforms w/o floorf

git-svn-id: http://skia.googlecode.com/svn/trunk@145 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd sample for gradients
reed@android.com [Thu, 2 Apr 2009 20:49:39 +0000 (20:49 +0000)]
add sample for gradients

git-svn-id: http://skia.googlecode.com/svn/trunk@144 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agocleanup formating (e.g. no trailing spaces)
reed@android.com [Thu, 2 Apr 2009 16:59:40 +0000 (16:59 +0000)]
cleanup formating (e.g. no trailing spaces)

git-svn-id: http://skia.googlecode.com/svn/trunk@143 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agorename tests/main to testmain.cpp
reed@android.com [Wed, 1 Apr 2009 20:26:42 +0000 (20:26 +0000)]
rename tests/main to testmain.cpp
add ANDROID specific work-around for double-cinit bug

git-svn-id: http://skia.googlecode.com/svn/trunk@142 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agorename bench's main to benchmain.cpp, to avoid multiple files with same name
reed@android.com [Wed, 1 Apr 2009 18:38:43 +0000 (18:38 +0000)]
rename bench's main to benchmain.cpp, to avoid multiple files with same name

git-svn-id: http://skia.googlecode.com/svn/trunk@141 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoAPI change: SkPath computeBounds -> getBounds
reed@android.com [Wed, 1 Apr 2009 18:31:44 +0000 (18:31 +0000)]
API change: SkPath computeBounds -> getBounds

git-svn-id: http://skia.googlecode.com/svn/trunk@140 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd -pict option to bench, which draws everything through a picture, and then
reed@android.com [Tue, 31 Mar 2009 03:48:49 +0000 (03:48 +0000)]
add -pict option to bench, which draws everything through a picture, and then
compares the result to the original draws

git-svn-id: http://skia.googlecode.com/svn/trunk@139 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoAdd SkChunkAlloc::unalloc() to undo the last allocation, useful if the caller wants...
reed@android.com [Mon, 30 Mar 2009 21:02:14 +0000 (21:02 +0000)]
Add SkChunkAlloc::unalloc() to undo the last allocation, useful if the caller wants to treat the allocats like temp memory (see PictureRecord)
Call unalloc if a paint (or other cached object) is already in our list for picture recording
Use correct CompareType macro in SkCanvas::quickReject

git-svn-id: http://skia.googlecode.com/svn/trunk@138 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agomake bitmap width/height 32bits, matching the API
reed@android.com [Fri, 27 Mar 2009 12:33:50 +0000 (12:33 +0000)]
make bitmap width/height 32bits, matching the API

git-svn-id: http://skia.googlecode.com/svn/trunk@137 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agorename drawable to drawing for now, so we don't collide with animator
reed@android.com [Tue, 24 Mar 2009 18:47:35 +0000 (18:47 +0000)]
rename drawable to drawing for now, so we don't collide with animator
remove sk_throw in pixelref. a debug statement is enough.

git-svn-id: http://skia.googlecode.com/svn/trunk@136 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agouse static_cast
reed@android.com [Mon, 23 Mar 2009 20:11:11 +0000 (20:11 +0000)]
use static_cast
fix comments

git-svn-id: http://skia.googlecode.com/svn/trunk@135 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd check/hack to avoid drawing outside of the clip for hairlines
reed@android.com [Mon, 23 Mar 2009 16:05:19 +0000 (16:05 +0000)]
add check/hack to avoid drawing outside of the clip for hairlines

git-svn-id: http://skia.googlecode.com/svn/trunk@134 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agocheck-point for drawables (experimental)
reed@android.com [Mon, 23 Mar 2009 03:27:38 +0000 (03:27 +0000)]
check-point for drawables (experimental)

git-svn-id: http://skia.googlecode.com/svn/trunk@133 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agopull latest from android
reed@android.com [Fri, 20 Mar 2009 12:23:07 +0000 (12:23 +0000)]
pull latest from android

git-svn-id: http://skia.googlecode.com/svn/trunk@132 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agocheck for NaN in path iterator (otherwise we have an infinite loop)
reed@android.com [Fri, 20 Mar 2009 12:16:09 +0000 (12:16 +0000)]
check for NaN in path iterator (otherwise we have an infinite loop)

git-svn-id: http://skia.googlecode.com/svn/trunk@131 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoforgot to initialize fFactory in the unflatten constructor
reed@android.com [Fri, 20 Mar 2009 12:08:57 +0000 (12:08 +0000)]
forgot to initialize fFactory in the unflatten constructor

git-svn-id: http://skia.googlecode.com/svn/trunk@130 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agobuild with -Wall
reed@android.com [Fri, 20 Mar 2009 04:59:37 +0000 (04:59 +0000)]
build with -Wall
fix associated warnings (at least on gcc 4.0.1)

git-svn-id: http://skia.googlecode.com/svn/trunk@129 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agopromote SkMask's rowBytes to 32bits, since its bounds is a 32bit rect
reed@android.com [Thu, 19 Mar 2009 21:52:42 +0000 (21:52 +0000)]
promote SkMask's rowBytes to 32bits, since its bounds is a 32bit rect
be sure a rect is sorted before using it as the path's bounds cache

git-svn-id: http://skia.googlecode.com/svn/trunk@128 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agofix capitalization for system includes
reed@android.com [Wed, 18 Mar 2009 19:10:34 +0000 (19:10 +0000)]
fix capitalization for system includes

git-svn-id: http://skia.googlecode.com/svn/trunk@127 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agofix heapsort
reed@android.com [Wed, 18 Mar 2009 03:08:15 +0000 (03:08 +0000)]
fix heapsort

git-svn-id: http://skia.googlecode.com/svn/trunk@126 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoSimplify font-chaining (fallbacks) to have fonthost just return the next
reed@android.com [Tue, 17 Mar 2009 17:59:53 +0000 (17:59 +0000)]
Simplify font-chaining (fallbacks) to have fonthost just return the next
logical fontID.
Extend ImageRef to accept an imagedecoder factory, to replace calling the std
one.

git-svn-id: http://skia.googlecode.com/svn/trunk@125 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agodisable cubic test for now (currently broken)
reed@android.com [Mon, 16 Mar 2009 18:47:55 +0000 (18:47 +0000)]
disable cubic test for now (currently broken)

git-svn-id: http://skia.googlecode.com/svn/trunk@124 2bbb7eff-a529-9590-31e7-b0007b416f81

15 years agoadd sanity checks to handles extremely large coordinates or filter margins.
reed@android.com [Mon, 16 Mar 2009 18:46:55 +0000 (18:46 +0000)]
add sanity checks to handles extremely large coordinates or filter margins.
Should not hurt features (we hope), but is an easy way to survive malicious
values on a small-memory machine like a handset.

git-svn-id: http://skia.googlecode.com/svn/trunk@123 2bbb7eff-a529-9590-31e7-b0007b416f81