reed@google.com
68bc6f7b45
add kUTF32_TextEncoding
...
git-svn-id: http://skia.googlecode.com/svn/trunk@3387 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-03-14 19:41:55 +00:00
vandebo@chromium.org
610f716b00
Fix four memory leaks uncovered by valgrinding gm tests.
...
All are triggered by PDF code.
Two are missing unref's on SkData.
One is a missing unref on a SkAdvancedTypefaceMetrics.
The last is missing destruction of SkClipStack internal state.
BUG=526
Review URL: https://codereview.appspot.com/5824049
git-svn-id: http://skia.googlecode.com/svn/trunk@3386 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-03-14 18:34:15 +00:00
reed@google.com
6adf79746f
add SkFourByteInterp256 variant, when the caller has already scaled the last
...
parameter to 0..256
git-svn-id: http://skia.googlecode.com/svn/trunk@3362 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-03-12 14:25:18 +00:00
reed@google.com
4bc0a9db18
use higher precision (64bit) fixed-point for matrix proc
...
Review URL: https://codereview.appspot.com/5772044
git-svn-id: http://skia.googlecode.com/svn/trunk@3336 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-03-07 21:47:41 +00:00
senorblanco@chromium.org
05054f1a78
Erode and dilate image filter effects, CPU and GPU implementations.
...
Review URL: http://codereview.appspot.com/5656067/
git-svn-id: http://skia.googlecode.com/svn/trunk@3310 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-03-02 21:05:45 +00:00
reed@google.com
10d2d4d106
move the post cleanup of the rec until after we wack it for maskfilter
...
git-svn-id: http://skia.googlecode.com/svn/trunk@3297 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-03-01 22:32:51 +00:00
reed@google.com
48a4cbc668
add experimental files to encapsulate device-level font settings
...
git-svn-id: http://skia.googlecode.com/svn/trunk@3292 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-03-01 19:21:11 +00:00
reed@google.com
aefdd06271
move SKPaint's defaults (that might be configurable) into a header
...
git-svn-id: http://skia.googlecode.com/svn/trunk@3280 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-29 13:03:00 +00:00
djsollen@google.com
92d2a299d2
reapply r3259 (that was reverted) with fix.
...
The SkASSERT was incorrect and failing on debug runs.
Review URL: https://codereview.appspot.com/5699071
git-svn-id: http://skia.googlecode.com/svn/trunk@3263 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-27 16:17:59 +00:00
junov@chromium.org
a907ac3e3e
Modify SkDeferredCanvas so that it uses its inherited SkCanvas to track matrix and clipping state
...
Removed 'virtual' from a few canvas methods that no longer need it thanks to this change.
BUG=http://code.google.com/p/skia/issues/detail?id=506
TEST=Canvas unit test
REVIEW=http://codereview.appspot.com/5697052/
git-svn-id: http://skia.googlecode.com/svn/trunk@3261 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-24 21:54:07 +00:00
djsollen@google.com
3cc0d8a6f0
reverting r3259 because of gm/test failure.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@3260 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-24 21:21:51 +00:00
djsollen@google.com
42bbef71c7
Enable quickRejectY in SkCanvas to be inlined.
...
This CL was tested against the picturePlayback bench and
showed an approx 10-13% improvement on Android when playing
back text.
Review URL: https://codereview.appspot.com/5687083
git-svn-id: http://skia.googlecode.com/svn/trunk@3259 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-24 21:03:42 +00:00
junov@chromium.org
0b5b0ce39c
reverting r3257 because of gm failure.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@3258 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-24 20:44:56 +00:00
junov@chromium.org
421bcc375a
Modify SkDeferredCanvas so that it uses its inherited SkCanvas to track matrix and clipping state
...
Removed 'virtual' from a few canvas methods that no longer need it thanks to this change.
BUG=http://code.google.com/p/skia/issues/detail?id=506
TEST=Canvas unit test
REVIEW=http://codereview.appspot.com/5697052/
git-svn-id: http://skia.googlecode.com/svn/trunk@3256 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-24 20:07:08 +00:00
bungeman@google.com
ddd0ed5607
Remove SkFontHost::ValidFontID PART 2: remove definition and skia callers not that Chrome's font host has been updated.
...
See also https://chromiumcodereview.appspot.com/9347043/
http://codereview.appspot.com/5654055/
git-svn-id: http://skia.googlecode.com/svn/trunk@3255 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-24 19:56:33 +00:00
junov@chromium.org
1cc8f6f3c4
Adding more unit testing for SkCanvas and derived classes.
...
BUG=http://code.google.com/p/skia/issues/detail?id=481
REVIEW=http://codereview.appspot.com/5674077/
TEST=unit test CanvasTest
git-svn-id: http://skia.googlecode.com/svn/trunk@3228 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-22 21:00:42 +00:00
djsollen@google.com
60abb078e5
Merge changes from the android repo upstream to Skia
...
Review URL: https://codereview.appspot.com/5545070
git-svn-id: http://skia.googlecode.com/svn/trunk@3199 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-15 18:49:15 +00:00
bsalomon@google.com
278dc6929b
Use cheapComputeDirection to determine normal facing in GrAAConvexPathRenderer
...
Review URL: http://codereview.appspot.com/5649083/
git-svn-id: http://skia.googlecode.com/svn/trunk@3198 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-15 16:52:51 +00:00
bsalomon@google.com
178964b6f6
Misc small fixes to unblock skia roll.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@3196 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-15 14:10:42 +00:00
tomhudson@google.com
d6770e69e0
SSE2 version of blit_lcd16, courtesy of Jin Yang.
...
Yields 25-30% speedup on Windows (32b), 4-7% on Linux (64b, less register
pressure), not invoked on Mac (lcd text is 32b instead of 16b).
Followup: GDI system settings on Windows can suppress LCD text for small
fonts, interfering with our benchmarks.
(http://code.google.com/p/skia/issues/detail?id=483 )
http://codereview.appspot.com/5617058/
git-svn-id: http://skia.googlecode.com/svn/trunk@3189 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-14 16:01:15 +00:00
junov@chromium.org
8f9ecbd346
Adding API and unit testing for deferred canvas clearing/purging
...
REVIEW=http://codereview.appspot.com/5646057/
TEST=DeferredCanvas unit test
git-svn-id: http://skia.googlecode.com/svn/trunk@3181 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-13 21:53:45 +00:00
reed@google.com
813d38b7a0
if SK_USE_COLOR_LUMINANCE is defined, then we store 2 bits of each component
...
to create a per-component-luminance value for the fonthost to use. Only supported
on Mac at the moment (but still disabled by default)
git-svn-id: http://skia.googlecode.com/svn/trunk@3180 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-13 21:37:57 +00:00
reed@google.com
ce6dbb6b4c
enable color-luminance in font cache (disabled by default)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@3168 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-10 22:01:45 +00:00
senorblanco@chromium.org
dfad3832cb
Add SK_API to SkPixelRef and TextureCacheEntry.
...
Review URL: http://codereview.appspot.com/5649044/
git-svn-id: http://skia.googlecode.com/svn/trunk@3158 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-09 16:07:08 +00:00
reed@google.com
e7a0a16599
store luminance in a new field
...
Review URL: https://codereview.appspot.com/5644047
git-svn-id: http://skia.googlecode.com/svn/trunk@3149 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-07 21:25:33 +00:00
junov@chromium.org
1f9767c03b
Fixing backing store access in SkDeferredCanvas.
...
Chromium CL required for rolling skia DEPS past this change is posted here: https://chromiumcodereview.appspot.com/9341003/
BUG=http://code.google.com/p/skia/issues/detail?id=475
REVIEW=http://codereview.appspot.com/5626047/
TEST=DeferredCanvas unit test
git-svn-id: http://skia.googlecode.com/svn/trunk@3147 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-07 16:27:57 +00:00
bungeman@google.com
f8d1aee252
Open type table definitions.
...
http://codereview.appspot.com/5577064/
git-svn-id: http://skia.googlecode.com/svn/trunk@3131 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-02 19:15:21 +00:00
reed@google.com
9efd9a048a
extend fastbounds impls to include maskfilters and drawloopers. This allows
...
us to perform quick-rejects when drawing objects with shadows (esp. text).
WebKit draws shadows w/ a looper (fg and shadow) and a maskfilter on the
shadow layer.
git-svn-id: http://skia.googlecode.com/svn/trunk@3103 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-30 15:41:43 +00:00
junov@chromium.org
bf6c1e4aff
Adding a flush method to SkCanvas
...
BUG=http://code.google.com/p/skia/issues/detail?id=467
REVIEW=http://codereview.appspot.com/5600044/
TEST=gm uses the new code path on all its test cases
git-svn-id: http://skia.googlecode.com/svn/trunk@3102 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-30 14:53:22 +00:00
vandebo@chromium.org
74b4619616
Formatting cleanup: remove extra whitespace
...
Change by arthurhsu@chromium.org , original CL: http://codereview.appspot.com/5587049/
Review URL: https://codereview.appspot.com/5594043
git-svn-id: http://skia.googlecode.com/svn/trunk@3098 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-28 01:45:11 +00:00
digit@google.com
1771cbf43d
posix: Avoid static initializers in static/global mutexes
...
This patch removes static initializers related to static and
global mutexes from the final library's machine code when
building on a pthread-capable system.
We use PTHREAD_MUTEX_INITIALIZER to perform POD-style
initialization. You need a line like the following to declare
a global mutex with it:
SkBaseMutex gMutex = { PTHREAD_MUTEX_INITIALIZER };
We introduce the SK_DECLARE_STATIC_MUTEX and SK_DECLARE_GLOBAL_MUTEX
macros to be able to declare static/global mutexes in the source tree
uniformly.
SkMutex is now defined as a sub-class of SkBaseMutex, with standard
construction/destruction semantics. This is useful if the mutex
object is a member of another C++ class, or allocated dynamically.
We also modify a few places to refer to SkBaseMutex instead of a
SkMutex, where it makes sense. Generally speaking, client code
should hold and use pointers to SkBaseMutex whenever they can
now.
We defined a new built-time macro named SK_USE_POSIX_THREADS
to indicate that we're using a pthread-based SkThread.h
interface. The macro will also be used in future patches
to implement other helper thread synchronization classes.
Finally, we inline the acquire() and release() functions in the
case of Posix to improve performance a bit.
Running: 'bench -repeat 10 -match mutex' on an Android device or
a 2.4GHz Xeon Linux desktop shows the following improvements:
Before After
Galaxy Nexus 1.64 1.45
Nexus S 1.47 1.16
Xoom 1.86 1.66
Xeon 0.36 0.31
This removes 5 static mutex initializers from the library
Review URL: https://codereview.appspot.com/5501066
git-svn-id: http://skia.googlecode.com/svn/trunk@3091 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-26 21:26:40 +00:00
reed@google.com
6d428d3e6e
Make SkRegion::operator== a member function, rather than a privately-declared
...
friend. Without this, calling code has access to operator==, but can fail to
link because the implementation is assumed to have static linkage.
http://codereview.appspot.com/5577047/
git-svn-id: http://skia.googlecode.com/svn/trunk@3088 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-25 21:53:53 +00:00
tomhudson@google.com
13e812c69a
Interpolate vertical linear gradients for improved quality.
...
Consolidate interpolation functions, add new faster more accurate dithering
interpolator.
git-svn-id: http://skia.googlecode.com/svn/trunk@3072 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-18 21:28:01 +00:00
schenney@chromium.org
f4b07328df
Somehow this change was missing from the previous commit.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@3063 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-18 18:06:10 +00:00
schenney@chromium.org
a6d04d90e2
Fixing the behavior of SkPathMeasure to reflect changes in SkPath::Iter.
...
This implementation modifies SkPath::Iter extensively to avoid copying
the points when used to measure path length.
BUG=446
TEST=tests/PathMeasureTest.cpp
Review URL: https://codereview.appspot.com/5533074
git-svn-id: http://skia.googlecode.com/svn/trunk@3062 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-18 18:02:10 +00:00
reed@google.com
8351aabbfe
add GenA8FromLCD as a hack to force GDI to create the A8 mask from the LCD
...
results, rather than asking GDI directly for A8 (which it sometimes decides
to interpret as BW)
git-svn-id: http://skia.googlecode.com/svn/trunk@3061 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-18 17:06:35 +00:00
junov@google.com
4370aedf7f
Adding class SkDeferredCanvas for deferred rendering.
...
TEST=added a new pass to gm, so all gm tests are run through SkDeferredCanvas
REVIEW=http://codereview.appspot.com/5430058/
git-svn-id: http://skia.googlecode.com/svn/trunk@3059 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-18 16:21:08 +00:00
reed@google.com
d335d1d784
automatically inject a moveTo if we see a close followed by a line/quad/cubic
...
git-svn-id: http://skia.googlecode.com/svn/trunk@3027 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-12 18:17:11 +00:00
reed@google.com
dcbd6e358a
remove unused bool param to SkMutex constructor
...
git-svn-id: http://skia.googlecode.com/svn/trunk@3025 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-12 15:21:16 +00:00
digit@google.com
f66436cff7
android: optimize atomics routines
...
This patch provides a slightly optimized implementation of
atomic increment/decrement functions by using static inlined
versions of the gcc intrinsics.
Review URL: http://codereview.appspot.com/5498069
git-svn-id: http://skia.googlecode.com/svn/trunk@3012 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-11 17:44:41 +00:00
reed@google.com
69a9943b67
add SkPath::cheapComputeDirection() plus unittests
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2996 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-10 18:00:10 +00:00
reed@google.com
63d73749fb
add SkPath::reverseAddPath()
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2995 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-10 15:33:12 +00:00
djsollen@google.com
a44e6c6b53
Add ARM optimizations to the build.
...
Also had to fix a problem in the ARM memset code that was
causing some tests and bench to fail.
Review URL: http://codereview.appspot.com/5522052
git-svn-id: http://skia.googlecode.com/svn/trunk@2989 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-09 14:38:25 +00:00
reed@google.com
b55deeb1c7
add allowImageFilter() so a device can allow/disallow filters
...
(esp. for printing)
git-svn-id: http://skia.googlecode.com/svn/trunk@2981 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-06 14:43:09 +00:00
reed@google.com
76dd277b1f
add filterImage() entry-point to SkDevice, to allow it to specialize on subclasses
...
of SkImageFilter. If that returns false, then the filter itself is invoked.
git-svn-id: http://skia.googlecode.com/svn/trunk@2977 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-05 21:15:07 +00:00
reed@google.com
7191840eec
add asComponentTable() query (will impl in SkTableColorFilter next)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2971 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-05 17:24:35 +00:00
caryclark@google.com
d53f7c28bf
make getOrigin() public so callers can adjust layer
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2970 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-05 17:05:05 +00:00
schenney@chromium.org
6630d8d8ea
Add the ability to iterate through a path without modification. This change is
...
required by WebKit SVG in order to correctly draw markers and endcaps.
BUG=415
TEST=TestPath in the unit tests
Review URL: http://codereview.appspot.com/5505097
git-svn-id: http://skia.googlecode.com/svn/trunk@2962 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-04 21:05:51 +00:00
reed@google.com
abf00aaaa0
expose isSubpixel() on the cache, so SkDraw can know if it should expect
...
subpixel text (it may be that the paint requested it, but the scaler ignored it)
git-svn-id: http://skia.googlecode.com/svn/trunk@2946 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-03 19:43:20 +00:00
tomhudson@google.com
d5d9dadcdd
Update header comments to more accurately describe behavior of
...
SkRegion::getBoundaryPath(). Add SkASSERT of SkPath argument for safety.
codereview.appspot.com/5504095/
git-svn-id: http://skia.googlecode.com/svn/trunk@2942 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-01-03 14:52:37 +00:00
schenney@chromium.org
72785c4c89
Fix problems with SampleApp Fuzzer due to issues in iterating over degenerate paths.
...
The fuzzer gets my vote as best test tool ever.
There are several issues outstanding: crashes in FixedPoint and a crash in the
path filling code that is most likely due to clipping problems (but maybe not).
BUG=425
Review URL: http://codereview.appspot.com/5503080
git-svn-id: http://skia.googlecode.com/svn/trunk@2936 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-29 21:03:28 +00:00
tomhudson@google.com
a31ac73b8e
Tighten up restrictions on blit width: some shaders assert that they
...
are addressing more than 0 pixels.
codereview.appspot.com/5489125/
git-svn-id: http://skia.googlecode.com/svn/trunk@2935 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-29 16:09:31 +00:00
tomhudson@google.com
4714359ec0
Bugfixes to antialiased blitting.
...
More details of blitter contracts in function headers.
New precautionary assert in one high-level default blitter.
git-svn-id: http://skia.googlecode.com/svn/trunk@2928 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-28 17:58:07 +00:00
tomhudson@google.com
0c00f21fee
Add SkDEBUGFAIL to clean up use of SkASSERT(!"text");
...
catch a couple of latent SkASSERT("text") bugs.
http://codereview.appspot.com/5504090/
git-svn-id: http://skia.googlecode.com/svn/trunk@2926 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-28 14:59:50 +00:00
tomhudson@google.com
49eac192fa
New 'blitAntiRect' entry point for blitters, specialized in supersampling
...
code to avoid quarter-scanline-at-a-time building of large rectangular
clips.
Speeds up aa_clip_build_path_AA benchmark 2x, aa_clip_build_rect_AA benchmark
10x or more. This is a sufficient performance gain to let Chromium reenable
WebKit's soft clipping code. Rolling into Chromium will require ~18
rebaselines.
git-svn-id: http://skia.googlecode.com/svn/trunk@2924 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-27 13:59:20 +00:00
schenney@chromium.org
b0af6dad94
Protecting changes to the SkPath iteration with an ifdef for Chromium.
...
Something is broken, and this will protect us while we sort it out.
Unreviewed.
git-svn-id: http://skia.googlecode.com/svn/trunk@2922 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-21 20:43:13 +00:00
reed@google.com
cf4b8181c9
declare IsVariationSelector to be inline, to fix warning
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2917 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-21 16:31:23 +00:00
reed@google.com
419f43348a
add SkUnichar_IsVariationSelector()
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2915 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-21 15:21:32 +00:00
senorblanco@chromium.org
e5ff3cefe0
Implement SkColorFilter::asColorMatrix() virtual, and override in
...
SkColorMatrixFilter. Implement missing SkColorMatrixFilter::setMatrix() and
setArray() functions (were in .h, just not implemented). Add a gm for color
matrix filters.
Review URL: http://codereview.appspot.com/5500044/
git-svn-id: http://skia.googlecode.com/svn/trunk@2909 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-20 20:58:18 +00:00
caryclark@google.com
9d0c6ecb84
fix 'no static globals' for chromium
...
M include/core/SkFlattenable.h
M include/core/SkPixelRef.h
M src/core/SkGraphics.cpp
git-svn-id: http://skia.googlecode.com/svn/trunk@2908 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-20 20:26:56 +00:00
reed@google.com
32d25b6f5f
initial impl of SkImageFilters : virtual signature will change!
...
Do not invest too much in other subclasses until this API solidifies.
git-svn-id: http://skia.googlecode.com/svn/trunk@2903 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-20 16:19:00 +00:00
schenney@chromium.org
4da06ab335
Modifying SkPath to store all verbs provided by the user, and to give
...
correct results for all stroke and fill modes even on the various types
of degenerate paths.
The goals of this patch include:
1. Have Skia store all of the verbs implied by path construction methods, even
if those define degenerate paths. The SVG implementation in WebKit, which is
backed by Skia, needs to know about all elements of the path, even degenerate
ones, for the correct drawing of markers and line caps. For example, in SVG you
should be able to draw a scatter plot by specifying a marker for vertices and
then giving a sequence of moveTo commands. Skia will not store the moveTos,
requiring a different storage mechanism.
2. Assuming 1, maintain the current Skia behavior. That is, make Skia robust to
degenerate paths.
3. Fix an existing bug in Skia where a degenerate moveTo-lineTo pair spits out
warnings from rasterization and produces incorrect results in inverse-fill
renderings.
4. Adds extensive testing for degenerate paths and path rendering in general.
To meet these goals, the patch I am proposing will result in minor additional
storage for degenerate paths (a few bytes per degenerate path, only if the user
defines such paths). There is also some additional overhead in the iteration
code, with the path now cleaned to remove degenerate segments as part of the
iteration process. I suspect this will also fix issues with computing normal
vectors to degenerate segments. Benchmarking suggests that this change may
result in slightly (< 1%) slower path drawing due to the checks for
degeneracy. This overhead could be removed (in fact, a significant speedup
could occur) if the results of iterating to clean up the path were cached.
This would cost memory, of course, and quite a bit of it.
BUG=398
TEST=tests/PathTest.cpp
gm/cubicpaths.cpp
gm/degeneratesegments.cpp
gm/movepaths.cpp
gm/linepaths.cpp
gm/quadpaths.cpp
Review URL: http://codereview.appspot.com/5482051
git-svn-id: http://skia.googlecode.com/svn/trunk@2901 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-20 15:14:18 +00:00
reed@google.com
24569b5bad
sk_float_round isn't a function, so call this instead: sk_float_floor((x) + 0.5f)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2895 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-16 20:53:22 +00:00
caryclark@google.com
f86ab8472e
cleanup font purging functions
...
M include/core/SkGraphics.h
M src/core/SkGraphics.cpp
git-svn-id: http://skia.googlecode.com/svn/trunk@2887 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-16 17:11:17 +00:00
junov@chromium.org
b052129a41
Exposing the isImmutable/setImmutable API of SkPixelRef in SkBitmap
...
REVIEW=http://codereview.appspot.com/5491055/
git-svn-id: http://skia.googlecode.com/svn/trunk@2883 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-15 20:14:06 +00:00
caryclark@google.com
d26147adbb
add optional manual global initialization
...
M include/effects/SkAvoidXfermode.h
M include/effects/SkDiscretePathEffect.h
M include/effects/Sk1DPathEffect.h
M include/effects/Sk2DPathEffect.h
M include/effects/SkBlurDrawLooper.h
M include/effects/SkPixelXorXfermode.h
M include/effects/SkDashPathEffect.h
M include/effects/SkColorMatrixFilter.h
M include/effects/SkEmbossMaskFilter.h
M include/effects/SkLayerDrawLooper.h
M include/effects/SkGroupShape.h
M include/effects/SkBlurImageFilter.h
M include/effects/SkRectShape.h
A include/effects/SkEffects.h
M include/effects/SkCornerPathEffect.h
M include/effects/SkGradientShader.h
M include/effects/SkBlurMaskFilter.h
M include/effects/SkLayerRasterizer.h
M include/core/SkMallocPixelRef.h
M include/core/SkFlattenable.h
M include/core/SkShape.h
M include/core/SkPixelRef.h
M include/core/SkGraphics.h
M include/core/SkPathEffect.h
M include/core/SkPostConfig.h
M include/core/SkXfermode.h
M include/core/SkColorFilter.h
M include/images/SkFlipPixelRef.h
M include/images/SkImageRef_GlobalPool.h
M src/effects/SkDashPathEffect.cpp
M src/effects/SkColorMatrixFilter.cpp
M src/effects/SkBlurImageFilter.cpp
M src/effects/SkGroupShape.cpp
M src/effects/SkCornerPathEffect.cpp
M src/effects/SkGradientShader.cpp
M src/effects/SkBlurMaskFilter.cpp
M src/effects/SkAvoidXfermode.cpp
M src/effects/Sk2DPathEffect.cpp
M src/effects/SkBlurDrawLooper.cpp
M src/effects/SkPixelXorXfermode.cpp
M src/effects/SkColorFilters.cpp
M src/effects/SkLayerDrawLooper.cpp
M src/effects/SkRectShape.cpp
A src/effects/SkEffects.cpp
M src/effects/SkLayerRasterizer.cpp
M src/effects/SkDiscretePathEffect.cpp
M src/effects/Sk1DPathEffect.cpp
A src/effects/SkEffects_none.cpp
M src/core/SkPixelRef.cpp
M src/core/SkGraphics.cpp
M src/core/SkFlattenable.cpp
M src/core/SkBitmapProcShader.h
M src/core/SkPathEffect.cpp
M src/core/SkShape.cpp
M src/core/SkXfermode.cpp
M src/core/SkMallocPixelRef.cpp
M src/core/SkBitmapProcShader.cpp
M src/images/SkFlipPixelRef.cpp
M src/images/SkImageRef_GlobalPool.cpp
A src/ports/SkGlobalInitialization_chromium.cpp
M src/ports/SkImageRef_ashmem.h
M src/ports/SkImageRef_ashmem.cpp
A src/ports/SkGlobalInitialization_default.cpp
M gyp/effects.gyp
M gyp/tools.gyp
M gyp/ports.gyp
git-svn-id: http://skia.googlecode.com/svn/trunk@2876 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-15 14:16:43 +00:00
reed@google.com
7c2029367c
add canvas::isDrawingToLayer(), as a fast query for chrome; faster than
...
setting up a drawiter and counting the layers.
git-svn-id: http://skia.googlecode.com/svn/trunk@2875 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-14 18:48:05 +00:00
djsollen@google.com
59204b4813
Closing fd for mmap after mapping succeeds.
...
Review URL: http://codereview.appspot.com/5467058
git-svn-id: http://skia.googlecode.com/svn/trunk@2847 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-09 21:19:38 +00:00
junov@chromium.org
b6e161937b
Adding isOpaque method to skia shader classes
...
REVIEW=http://codereview.appspot.com/5451102/
TEST=unit test ShaderOpacity
git-svn-id: http://skia.googlecode.com/svn/trunk@2840 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-09 15:48:03 +00:00
reed@google.com
59ccef695c
add more SK_OVERRIDEs
...
update dox for SkEmptyShader
git-svn-id: http://skia.googlecode.com/svn/trunk@2817 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-07 14:59:50 +00:00
reed@google.com
5ae777dcad
rename sk_float_isNaN to sk_float_isnan to match related functions
...
add sk_float_isinf returning non-zero if the argument is +/- infinity
git-svn-id: http://skia.googlecode.com/svn/trunk@2813 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-06 20:18:05 +00:00
reed@google.com
1607863b60
rename hasValidCoordinates to isFinite (on SkRect) and reimplement for speed
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2811 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-06 18:56:37 +00:00
reed@google.com
c2f8e9a500
make _isnan windows specific
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2804 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-05 21:51:36 +00:00
reed@google.com
61873a59d7
add sk_float_isfinite to mask platform differences
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2803 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-05 21:47:25 +00:00
senorblanco@chromium.org
ef843cdcd1
When a bitmap is texture-backed, change SkBitmap::copyTo() to do a deep
...
copy of the texels in VRAM rather than a readback and re-upload. This
gives a 3-10X speedup on recursive canvas-to-canvas draws.
N.B.: This introduces a new GM test, which will need new baselines.
git-svn-id: http://skia.googlecode.com/svn/trunk@2790 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-02 19:11:17 +00:00
reed@google.com
a89c77b5ca
revert 2783 -- broke debug gm
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2784 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-01 21:47:26 +00:00
tomhudson@google.com
f974a5d782
New function SkBlitter::blitAntiRect(); specifically accelerated for
...
supersampled antialiased clips.
git-svn-id: http://skia.googlecode.com/svn/trunk@2783 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-01 21:09:00 +00:00
tomhudson@google.com
05fffdcc91
Doxygen configuration file, documentation and minor cleanup on blitters.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2782 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-01 20:41:24 +00:00
djsollen@google.com
b44cd65a53
Fix Paint == comparison on Android.
...
The == operator was incorrect because of Androids use of
fGenerationID. This change moves the ID to the end of the
paint struct and omits it from the == comparison.
Review URL: http://codereview.appspot.com/5437098
git-svn-id: http://skia.googlecode.com/svn/trunk@2780 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-12-01 17:09:21 +00:00
reed@google.com
ea6805d222
add 2nd _ to __OpenBSD_
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2775 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-30 20:44:25 +00:00
junov@chromium.org
d80a509eb7
replacing Gr* with Sk* in SkTArray.h
...
REVIEW=http://codereview.appspot.com/5447053/
git-svn-id: http://skia.googlecode.com/svn/trunk@2770 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-30 18:35:19 +00:00
reed@google.com
3138d36f98
Add more Unix platforms on which Skia for Chromium has been built,
...
this patch was tested on FreeBSD, Solaris, NetBSD, and DragonFly BSD.
http://codereview.chromium.org/8672011/
git-svn-id: http://skia.googlecode.com/svn/trunk@2764 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-30 15:27:30 +00:00
reed@google.com
1271d78e8f
add bytes() to SkTDArray, which returns the number of bytes in the array,
...
as opposed to count() which returns the number of elements.
git-svn-id: http://skia.googlecode.com/svn/trunk@2758 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-28 19:54:12 +00:00
tomhudson@google.com
01224d5d0a
Unroll loops in SkBlurMask for speedup on Windows (benchmarks should see
...
15% on interpolated blurs, 5-10% on simple blurs).
git-svn-id: http://skia.googlecode.com/svn/trunk@2755 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-28 18:22:01 +00:00
reed@google.com
c9d9337790
define SK_OVERRIDE based on windows compiler, not windows platform (for mingw)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2748 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-28 15:25:12 +00:00
bsalomon@google.com
b1277c96b0
Fix mac debug asserts
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2747 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-23 21:58:39 +00:00
bsalomon@google.com
0442380545
Add hints for static analysis about when we intend to crash
...
Review URL: http://codereview.appspot.com/5433062
git-svn-id: http://skia.googlecode.com/svn/trunk@2745 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-23 21:25:35 +00:00
reed@google.com
ffe49f5380
store 3 bits of luminance, but (for now) discretize that in fonthost::filterec
...
for backward compatibility
git-svn-id: http://skia.googlecode.com/svn/trunk@2732 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-22 19:42:41 +00:00
reed@google.com
1f6b4ae0f7
remove GetGammaFlag from SkFontHost
...
prep for retooling of gamma support
git-svn-id: http://skia.googlecode.com/svn/trunk@2730 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-22 14:20:55 +00:00
caryclark@google.com
54c782c968
add SetFlags for command line control
...
http://codereview.appspot.com/5416047/
M include/core/SkGraphics.h
M src/core/SkGraphics.cpp
git-svn-id: http://skia.googlecode.com/svn/trunk@2727 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-21 20:42:14 +00:00
reed@google.com
f788feb3f1
use a define for the shift amount for the hinting bits
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2726 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-21 19:46:00 +00:00
reed@google.com
b6bb5cb7c2
reorder bits and remove obsolete kForceAA experimental bit
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2725 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-21 19:32:29 +00:00
reed@google.com
9998c66930
remove all references to SkGlobals (obsolete)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2713 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-17 22:09:47 +00:00
mike@reedtribe.org
e303fcf68d
add SkXfermode::IsMode() and use that in SkDevice
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2703 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-17 02:16:43 +00:00
senorblanco@chromium.org
54e01b2ab9
This change makes SkImageFilter and SkBlurImageFilter flattenable/unflattenable.
...
The imageblur test also needed to stop calling getDeviceSize(), since it was
returning 99999x99999 for the SkPicture case.
git-svn-id: http://skia.googlecode.com/svn/trunk@2699 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-16 18:20:47 +00:00
bungeman@google.com
39698b1bd7
Add paging support for handle based typefaces.
...
http://codereview.appspot.com/5379043/
http://codereview.appspot.com/5364052/
git-svn-id: http://skia.googlecode.com/svn/trunk@2693 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-15 22:26:41 +00:00
bsalomon@google.com
ae0fb058dd
Add default param to SkDevice::writePixels b/c WK is relying on old signature. (Function will be made protected once WK calls the Canvas version)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2666 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-10 22:34:56 +00:00
bsalomon@google.com
d58a1cd00b
Add config8888 support to writePixels
...
Review URL: http://codereview.appspot.com/5374052/
git-svn-id: http://skia.googlecode.com/svn/trunk@2662 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-10 20:57:43 +00:00
reed@google.com
44da42e92f
have paint's measure calls respect vertical
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2660 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-10 20:04:47 +00:00
reed@google.com
830a23e39b
add vertical-text bit to paint (not supported yet)
...
check-point for using freetype on mac (not enabled yet)
git-svn-id: http://skia.googlecode.com/svn/trunk@2657 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-10 15:20:49 +00:00
reed@google.com
073c90769e
use new PurgeFontCache() api
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2633 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-08 20:03:48 +00:00
djsollen@google.com
56c69773ae
Update files to use SK_BUILD_FOR_ANDROID.
...
This CL also removes any unecessary references to
the ANDROID definition.
Review URL: http://codereview.appspot.com/5354049
git-svn-id: http://skia.googlecode.com/svn/trunk@2629 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-08 19:00:26 +00:00
reed@google.com
6245ab718d
fix prev. change for __OpenBSD__
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2628 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-08 18:21:20 +00:00
reed@google.com
77407ca019
add api to SkGraphics to get/set font cache limit
...
add SK_DEFAULT_FONT_CACHE_LIMIT to SkUserConfig, to override our default value
git-svn-id: http://skia.googlecode.com/svn/trunk@2621 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-08 13:48:32 +00:00
bsalomon@google.com
6850eab42b
Override 32BPP format in SkCanvas::readPixels
...
Review URL: http://codereview.appspot.com/5330073/
git-svn-id: http://skia.googlecode.com/svn/trunk@2600 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-03 20:29:47 +00:00
reed@google.com
15356a68b2
experimental -- add SkImageFilter to paint. Not called yet.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2599 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-03 19:29:08 +00:00
djsollen@google.com
58629291bc
Adding support to trunk for building Skia using the Android NDK.
...
This CL depends on a subsequent CL to add the appropriate NDK
toolchain and system sources to the skia repo.
Review URL: http://codereview.appspot.com/5306089/
Review URL: http://codereview.appspot.com/5306089
git-svn-id: http://skia.googlecode.com/svn/trunk@2592 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-03 13:08:29 +00:00
bsalomon@google.com
daba14b7d4
Line-endings only change (some windows line-endings snuck in)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2588 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-02 20:10:48 +00:00
bsalomon@google.com
910267dde2
Make SkDevice::onReadPixels take a const& rather than const*
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2587 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-02 20:06:25 +00:00
bsalomon@google.com
c69809745e
Recommit r2584 with gpu pass of the new ReadPixels test disabled in fixed pt (gpu code doesn't work in general in fixed pt).
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2586 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-02 19:57:21 +00:00
bsalomon@google.com
ace7bd5623
Revert r2584 (new test fails in fixed pt builds)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2585 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-02 19:39:51 +00:00
bsalomon@google.com
1a8ddf0a35
Changes the SkCanvas::readPixels API. Allows caller to read into prealloced bitmap pixels. Changes how clipping to device bounds is handled.
...
Review URL: http://codereview.appspot.com/5307077/
git-svn-id: http://skia.googlecode.com/svn/trunk@2584 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-02 19:34:16 +00:00
reed@google.com
cad8176281
remove unused copyPixelsFrom ... (copyPixelsTo is next on the chopping block)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2579 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-01 15:53:28 +00:00
reed@google.com
210ce003a5
add getDeviceSize() so callers won't need to call getDevice() so much
...
... we hope to make devices private in the future
git-svn-id: http://skia.googlecode.com/svn/trunk@2577 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-11-01 14:24:23 +00:00
reed@google.com
67ba5fa328
fix scalar=fixed by implementing SkRegion form of AntiFillRect
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2516 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-24 12:56:20 +00:00
reed@google.com
045e62d715
enable soft clipping (yikes)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2515 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-24 12:19:46 +00:00
reed@google.com
f0f617a502
add SkRect::intersect(a, b), matching what was already available in SkIRect
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2513 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-21 14:05:06 +00:00
reed@google.com
de916c8ac8
add SK_API to our malloc functions
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2497 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-19 19:50:48 +00:00
reed@google.com
7a17e3a34f
oops, init fSize to 0 before calling resize
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2493 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-18 18:58:06 +00:00
reed@google.com
1c401d8f42
add OnShrink options to SkAutoMalloc
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2492 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-18 18:52:03 +00:00
reed@google.com
3ab4195445
remove unused optional param to SkAutoMalloc
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2491 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-18 18:32:46 +00:00
reed@google.com
86b49d2ef3
move SkAutoMaskFreeImage from SkMaskFilter.h to SkMask.h
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2489 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-18 17:35:26 +00:00
reed@google.com
f52e55543e
(re)add SkMask::getAddr() which now checks its pixel-size at runtime.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2488 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-18 17:29:44 +00:00
reed@google.com
7989186dab
rename SkMask::getAddr to getAddr8, to match the specificity of the others
...
e.g. getAddr1, getAddrLCD16, etc.
This is to make way for a real getAddr that will compute its pixel-size at runtime
git-svn-id: http://skia.googlecode.com/svn/trunk@2487 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-18 15:44:57 +00:00
reed@google.com
edb606cb99
move LCD blits into opts, so they can have assembly versions
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2484 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-18 13:56:50 +00:00
reed@google.com
ec4400824c
commit http://codereview.chromium.org/8274009/
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2479 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-13 19:16:20 +00:00
reed@google.com
da96563e31
add FillIRect variant that takes a rasterclip
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2478 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-13 15:29:01 +00:00
reed@google.com
1ba7137fc0
add rasterclip entrypoints for scan converting paths
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2473 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-12 20:42:05 +00:00
reed@google.com
0017708a5b
use SkRasterClip inside canvas (check-point for soft clipping)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2462 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-12 14:34:30 +00:00
reed@google.com
58af9a6470
separate SkBlitMask decl into its own header
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2461 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-12 13:43:52 +00:00
reed@google.com
071eef918d
add bool argument to canvas' clipRect and clipPath for antialiasing
...
(currently ignored)
git-svn-id: http://skia.googlecode.com/svn/trunk@2459 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-12 11:52:53 +00:00
reed@google.com
294dd7b3d7
change getLastPt to return a bool
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2453 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-11 11:58:32 +00:00
reed@google.com
5e2457ef2e
add getTotalClipBounds() as a partial replacement for getTotalClip. This can be
...
faster than getTotalClip, since it doesn't need to compute the actual complex
region for the answer.
git-svn-id: http://skia.googlecode.com/svn/trunk@2452 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-10 21:24:37 +00:00
bungeman@google.com
07faed1102
Setting perspective in fixed point.
...
http://codereview.appspot.com/5088043/
git-svn-id: http://skia.googlecode.com/svn/trunk@2435 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-07 21:55:56 +00:00
bungeman@google.com
cf385232c4
Don't let templates live in shadows.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2434 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-07 21:10:39 +00:00
bungeman@google.com
a12cc7fda0
Separate code paths of SkTArray at compile time.
...
http://codereview.appspot.com/5243043/
git-svn-id: http://skia.googlecode.com/svn/trunk@2433 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-07 20:54:15 +00:00
reed@google.com
0abb499daf
add SkAlphaBlend255
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2426 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-06 20:04:36 +00:00
reed@google.com
632e1a281b
move call to nothingToDraw into our iterator, so it sees the results of filters and loopers
...
before making its decision.
git-svn-id: http://skia.googlecode.com/svn/trunk@2417 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-06 12:37:00 +00:00
bsalomon@google.com
fa6ac938e6
Fixup rendering of empty paths (including inverted fills)
...
Add GM and Sample that draw empty paths with various styles and fills
Review URL: http://codereview.appspot.com/5185047/
git-svn-id: http://skia.googlecode.com/svn/trunk@2414 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-05 19:57:55 +00:00
bungeman@google.com
02f5584185
Change SkAutoMaskImage so that we're less likely to write leaky code.
...
http://codereview.appspot.com/5180047/
git-svn-id: http://skia.googlecode.com/svn/trunk@2409 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-04 21:25:00 +00:00
bungeman@google.com
18ac1ba3d1
Make asBlur method const.
...
http://codereview.appspot.com/5190041/
This change makes asBlur const consistent with SkShader::asAGradient and asABitmap.
git-svn-id: http://skia.googlecode.com/svn/trunk@2404 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-04 15:11:38 +00:00
reed@google.com
dcd0f3a980
quick-rejects based on xfermode, using SkPaint::nothingToDraw()
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2402 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-04 01:17:15 +00:00
reed@google.com
2c508f2dc2
add force-rle parameter to help with aaclip testing
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2401 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-03 21:15:46 +00:00
reed@google.com
c74ab18130
add accessors to irect
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2399 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-03 20:27:14 +00:00
vandebo@chromium.org
5676b4a23a
Revert r2122, r2116, r2108 Now that Chrome's PlatformDevice doesn't inherit from SkDevice.
...
Review URL: http://codereview.appspot.com/5178045
git-svn-id: http://skia.googlecode.com/svn/trunk@2396 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-03 19:03:48 +00:00
tomhudson@google.com
1341304449
Use SK_OVERRIDE to add a little extra robustness against name changes.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2395 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-10-03 16:01:10 +00:00
reed@google.com
3253898f72
need these for the forceaa change
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2391 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-30 20:57:05 +00:00
bsalomon@google.com
92669014aa
Add SkSTArray, hide stack storage cons in SkTArray, unify SkTArray init logic
...
Review URL: http://codereview.appspot.com/5127044/
git-svn-id: http://skia.googlecode.com/svn/trunk@2342 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-27 19:10:05 +00:00
tomhudson@google.com
c12e1b138e
Replace SkMath.h includes as required for fixed point.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2341 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-27 18:03:23 +00:00
tomhudson@google.com
889bd8bd7f
Make SkMath.h less visible in public header files.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2340 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-27 17:38:17 +00:00
reed@google.com
894aa9a7af
experimental
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2320 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-23 14:49:49 +00:00
reed@google.com
10296ccb6a
add segment types query to SkPath (i.e. does it have any quads)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2292 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-21 12:29:05 +00:00
bsalomon@google.com
4fa6694c58
Resubmit 2289 with fix for glsl version
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2291 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-20 19:06:12 +00:00
bsalomon@google.com
1fac5ca505
Revert 2289. GLSL version detection not robust enough. May think we don't have GLSL 1.50 support based on OpenGL version. We have to look at the available extensions, not just GL version.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2290 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-20 17:57:44 +00:00
bsalomon@google.com
98874cdda0
[GPU] Use new Var type for inputs/outputs of FS and VS
...
Review URL: http://codereview.appspot.com/5056048/
git-svn-id: http://skia.googlecode.com/svn/trunk@2289 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-20 17:33:24 +00:00
reed@google.com
4bce115b31
make string's reference counting thread-safe
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2268 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-14 16:13:58 +00:00
bsalomon@google.com
5c6ae60a71
Fix compilation error related to using nonexistent sk_malloc instead of sk_malloc_throw. VC++ lazy template code compilation let this work on windows since the wrong function name was only in currently unused templated functions.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2266 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-14 14:01:31 +00:00
bsalomon@google.com
49313f6b43
GrTArray->SkTArray & docs
...
Review URL: http://codereview.appspot.com/5005045/
git-svn-id: http://skia.googlecode.com/svn/trunk@2265 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-14 13:54:05 +00:00
bsalomon@google.com
cff323ecd8
Shutup strict aliasing warnings in SkTLazy
...
Review URL: http://codereview.appspot.com/5020042/
git-svn-id: http://skia.googlecode.com/svn/trunk@2263 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-14 12:44:13 +00:00
bsalomon@google.com
8c2fe99ed2
Fix some issues in gpu device with perspective. Add a gm that would have caught them.
...
Review URL: http://codereview.appspot.com/4994048/
git-svn-id: http://skia.googlecode.com/svn/trunk@2256 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-13 15:27:18 +00:00
tomhudson@google.com
bcb671c82a
Add SkCanvas::getClipDescription() and getClipDeviceBounds() so clients don't
...
need to explicitly get the exact clip & compute those values themselves. (We
may be able to provide description/bounds more cheaply than the exact clip.)
git-svn-id: http://skia.googlecode.com/svn/trunk@2255 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-13 15:07:58 +00:00
tomhudson@google.com
8a0b0291ae
Revert r2250 - removal of setMatrixClip() - because Chrome makes heavy use
...
of those functions in a way we're not yet ready to clean up.
git-svn-id: http://skia.googlecode.com/svn/trunk@2254 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-13 14:41:06 +00:00
reed@google.com
4c888aae25
write 0 to our refcnt in the destructor, in the off-chance of it helping us
...
catch reuse-after-delete bugs (debug only)
git-svn-id: http://skia.googlecode.com/svn/trunk@2251 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-12 19:54:12 +00:00
tomhudson@google.com
66d57255ad
Replaces SkDevice::setMatrixClip() with markMatrixDirty() and markClipDirty(),
...
which require no arguments and so may be called without requiring the matrix
and clip to be completely evaluated.
De-inlines virtual functions in SkDevice interface.
git-svn-id: http://skia.googlecode.com/svn/trunk@2250 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-12 19:52:44 +00:00
bsalomon@google.com
dbeeac3332
Add perspective support to the gpu aa hairline renderer.
...
Review URL: http://codereview.appspot.com/4969071/
git-svn-id: http://skia.googlecode.com/svn/trunk@2249 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-12 14:59:34 +00:00
bsalomon@google.com
383963280d
[gpu] Remove getMaxStretch for perspective, use mapRadius for perspective path subdiv tol, add test
...
Review URL: http://codereview.appspot.com/4975063/
git-svn-id: http://skia.googlecode.com/svn/trunk@2246 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-09 19:32:04 +00:00
bsalomon@google.com
181e9bd948
Improve gpu path subdiv with perspective, remove tolerance scale, fix comment
...
Review URL: http://codereview.appspot.com/4993041/
git-svn-id: http://skia.googlecode.com/svn/trunk@2239 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-07 18:42:30 +00:00
reed@google.com
a5adf5385d
use templated skipT() for skipping structs within a reader
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2238 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-07 13:52:17 +00:00
reed@google.com
55b5f4bd6a
add SkPoint::CanNormalize to unify decisions about when a vector is degenerate
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2236 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-07 12:23:41 +00:00
reed@google.com
f0b5e1190a
add drawBitmapNine to canvas
...
will add to device soon I think
git-svn-id: http://skia.googlecode.com/svn/trunk@2233 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-07 11:57:34 +00:00
bsalomon@google.com
6dcd27cd5e
add detach back to SkAutoMalloc
...
Review URL: http://codereview.appspot.com/4956066/
git-svn-id: http://skia.googlecode.com/svn/trunk@2218 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-06 15:02:33 +00:00
reed@google.com
bdf736133b
add optional SK_OVERRIDE_GLOBAL_NEW for testing
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2217 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-06 14:56:20 +00:00
bsalomon@google.com
7d4679a2e1
Rename existing nonpreserving reallocs to reset, add reset to SkAutoMalloc, use reset in GrBufferAllocPool
...
Review URL: http://codereview.appspot.com/4951058/
git-svn-id: http://skia.googlecode.com/svn/trunk@2215 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-02 22:06:24 +00:00
bsalomon@google.com
e174ea4bb1
Fix some warnings when including some Skia headers in Chromium code under VS2008.
...
Review URL: http://codereview.appspot.com/4956058/
git-svn-id: http://skia.googlecode.com/svn/trunk@2209 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-09-01 15:34:14 +00:00
reed@google.com
d51bfa0583
rename getBounds to getGlobalBounds, since it now takes the device's origin
...
into account. Remove unused intersects().
git-svn-id: http://skia.googlecode.com/svn/trunk@2193 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-30 15:56:11 +00:00
tomhudson@google.com
dd5f7442f6
Add SkMatrix::getPerspectiveTypeMaskOnly() and SkMatrix::isTriviallyIdentity().
...
Reduces profile time in setConcat() and computeTypeMask() for demos that
do a lot of matrix concatenation.
git-svn-id: http://skia.googlecode.com/svn/trunk@2191 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-30 15:13:55 +00:00
reed@google.com
2e68478d86
move SkComputeAxisAlignmentForHText(const SkMatrix& matrix) out of inline,
...
since that isn't really necessary, and it is generating a warning/error for
some builds ('defined but not used')
git-svn-id: http://skia.googlecode.com/svn/trunk@2169 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-24 15:38:46 +00:00
reed@google.com
cb6ccdde51
respect subpixel positioning
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2165 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-23 21:30:47 +00:00
bsalomon@google.com
647a804c3d
Core skia changes to prepare for Gr AA Hairline renderer
...
Review URL: http://codereview.appspot.com/4940045/
git-svn-id: http://skia.googlecode.com/svn/trunk@2160 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-23 14:39:01 +00:00
bungeman@google.com
52c748b169
Gpu can draw underlined text.
...
http://codereview.appspot.com/4919047/
git-svn-id: http://skia.googlecode.com/svn/trunk@2154 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-22 21:30:43 +00:00
vandebo@chromium.org
37ad8fb72f
[PDF] Subset font advance data (W array).
...
Patch by arthurhsu@chromium.org . Original CL:
http://codereview.appspot.com/4830068
http://codereview.appspot.com/4905051/
Review URL: http://codereview.appspot.com/4911042
git-svn-id: http://skia.googlecode.com/svn/trunk@2134 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-18 02:38:50 +00:00
vandebo@chromium.org
7b13aca86f
Revert "Improve generation of glyph advance array." This reverts commit r2126
...
gm segfaults in font id retrieval.
TBR=arthurhsu@chromium.org
Review URL: http://codereview.appspot.com/4901049
git-svn-id: http://skia.googlecode.com/svn/trunk@2128 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-16 23:30:48 +00:00
vandebo@chromium.org
e7f3300f42
Improve generation of glyph advance array.
...
Review URL: http://codereview.appspot.com/4830068
git-svn-id: http://skia.googlecode.com/svn/trunk@2126 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-16 22:45:43 +00:00
reed@google.com
ff8a166e29
move setOrigin to protected, as a stop-gap fix for proxy devices. will revert
...
soon I expect.
git-svn-id: http://skia.googlecode.com/svn/trunk@2108 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-12 16:13:34 +00:00
reed@google.com
c34d7cfca1
re-get the function-ptr when we unflatten a ProcCoeffXfermode
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2093 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-09 22:42:10 +00:00
bsalomon@google.com
a44f7003e5
Fix some ref leaks
...
Review URL: http://codereview.appspot.com/4837068/
git-svn-id: http://skia.googlecode.com/svn/trunk@2082 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-09 15:30:41 +00:00
bungeman@google.com
88edf1e507
Protect much of SkDevice and clarify usage of drawDevice.
...
http://codereview.appspot.com/4798069/
git-svn-id: http://skia.googlecode.com/svn/trunk@2066 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-08 19:41:56 +00:00
reed@google.com
a767fa06ca
add api for scalers to force us to use skia to generate their bits from their
...
path. This may allow the windows scaler to do that if GDI is giving bad
results (i.e. not respecting the request for antialiasing).
git-svn-id: http://skia.googlecode.com/svn/trunk@2054 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-05 21:40:26 +00:00
reed@google.com
099d22dbce
add roundOut()
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2019 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-01 20:53:19 +00:00
reed@google.com
1b20280f9b
deprecate SkScalarFloor, SkScalarCeil, SkScalarRound
...
Should instead use the explicit version that returns either a scalar or int
e.g.
SkScalarRoundToInt
SkScalarROundToScalar
git-svn-id: http://skia.googlecode.com/svn/trunk@2018 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-01 20:49:45 +00:00
reed@google.com
84b437e6ce
update dox for LCD text
...
git-svn-id: http://skia.googlecode.com/svn/trunk@2001 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-08-01 12:45:35 +00:00
bungeman@google.com
b81be7a780
Include <new> required for placement new in SkTLazy.
...
Also, add SkTLazy to gyp and remove old includes.
git-svn-id: http://skia.googlecode.com/svn/trunk@1984 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-28 16:51:20 +00:00
epoger@google.com
ec3ed6a5eb
Automatic update of all copyright notices to reflect new license terms.
...
I have manually examined all of these diffs and restored a few files that
seem to require manual adjustment.
The following files still need to be modified manually, in a separate CL:
android_sample/SampleApp/AndroidManifest.xml
android_sample/SampleApp/res/layout/layout.xml
android_sample/SampleApp/res/menu/sample.xml
android_sample/SampleApp/res/values/strings.xml
android_sample/SampleApp/src/com/skia/sampleapp/SampleApp.java
android_sample/SampleApp/src/com/skia/sampleapp/SampleView.java
experimental/CiCarbonSampleMain.c
experimental/CocoaDebugger/main.m
experimental/FileReaderApp/main.m
experimental/SimpleCocoaApp/main.m
experimental/iOSSampleApp/Shared/SkAlertPrompt.h
experimental/iOSSampleApp/Shared/SkAlertPrompt.m
experimental/iOSSampleApp/SkiOSSampleApp-Base.xcconfig
experimental/iOSSampleApp/SkiOSSampleApp-Debug.xcconfig
experimental/iOSSampleApp/SkiOSSampleApp-Release.xcconfig
gpu/src/android/GrGLDefaultInterface_android.cpp
gyp/common.gypi
gyp_skia
include/ports/SkHarfBuzzFont.h
include/views/SkOSWindow_wxwidgets.h
make.bat
make.py
src/opts/memset.arm.S
src/opts/memset16_neon.S
src/opts/memset32_neon.S
src/opts/opts_check_arm.cpp
src/ports/SkDebug_brew.cpp
src/ports/SkMemory_brew.cpp
src/ports/SkOSFile_brew.cpp
src/ports/SkXMLParser_empty.cpp
src/utils/ios/SkImageDecoder_iOS.mm
src/utils/ios/SkOSFile_iOS.mm
src/utils/ios/SkStream_NSData.mm
tests/FillPathTest.cpp
Review URL: http://codereview.appspot.com/4816058
git-svn-id: http://skia.googlecode.com/svn/trunk@1982 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-28 14:26:00 +00:00
epoger@google.com
4f1151ab27
Documentation only: add warning to SkCanvas::writePixels() that this operation
...
will not be recorded by SkPicture.
Review URL: http://codereview.appspot.com/4815054
git-svn-id: http://skia.googlecode.com/svn/trunk@1947 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-25 15:47:33 +00:00
reed@google.com
6dc745506e
remove forward declaration and reference to extinct SkDeviceFactory
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1931 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-21 18:00:46 +00:00
reed@google.com
b530ef5869
have == always return bool, never int
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1915 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-20 19:55:42 +00:00
bsalomon@google.com
5c63865b52
Use texture cache for writePixels temp
...
Review URL: http://codereview.appspot.com/4757050/
git-svn-id: http://skia.googlecode.com/svn/trunk@1887 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-18 19:31:59 +00:00
bsalomon@google.com
d9f826c0db
flip Y in uploads to bottom-up textures (and add gm test)
...
Review URL: http://codereview.appspot.com/4756043/
git-svn-id: http://skia.googlecode.com/svn/trunk@1882 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-18 15:25:04 +00:00
reed@google.com
7f6d6d4571
add validate() and SkAutoRef
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1872 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-15 15:25:22 +00:00
tomhudson@google.com
7d04280a68
Extends skdiff to handle commands of the form
...
skdiff --chromium-release baseDir outputDir
skdiff --chromium-debug baseDir outputDir
where baseDir is typically ../chromium/src.
Handles Chromium/WebKit layout tests: recursively traverses the
layout-test-results directory and compares -expected and -actual PNGs,
building a webpage showing the two images, their difference image,
and statistics, sorted by % of pixels difference. Respects all the
standard skdiff flags.
Also changes command line options named with words from starting with
a single hyphen to starting with two, falling in line with standards:
--threshold, --sortbymismatch, etc.
git-svn-id: http://skia.googlecode.com/svn/trunk@1856 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-14 13:15:55 +00:00
bungeman@google.com
1ddd7c3928
Change pdfTransform to asAffine.
...
http://codereview.appspot.com/4704044/
git-svn-id: http://skia.googlecode.com/svn/trunk@1851 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-13 19:41:55 +00:00
bsalomon@google.com
b3b8dfa313
Fix path iter returned pt on close, test path close pt in unit test.
...
Review URL: http://codereview.appspot.com/4715044/
git-svn-id: http://skia.googlecode.com/svn/trunk@1849 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-13 17:44:36 +00:00
tomhudson@google.com
333d6cb244
Remove a few old uses of SK_RESTRICT on references.
...
Conditionally #defines SK_RESTRICT to be __restrict on Win32;
this successfully compiles in VS2008.
git-svn-id: http://skia.googlecode.com/svn/trunk@1841 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-12 19:19:03 +00:00
reed@google.com
2b75f4279a
add asABlur() to maskfilters, so devices like gpu and pdf can query them.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1816 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-07 13:43:38 +00:00
reed@google.com
9c49bc3e64
Allow texture-backed bitmaps to perform a read-back when lockPixels is called.
...
This means we have to be even more cautious about when we call lock, and we should
always check getTexture() first if we can handle a texture directly, rather than
forcing the read-back to get the bits.
git-svn-id: http://skia.googlecode.com/svn/trunk@1815 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-07 13:42:37 +00:00
reed@google.com
2be9e8b407
ColorShaders report no bitmaps, but only a color_gradient, which we now detect
...
on the gpu side.
git-svn-id: http://skia.googlecode.com/svn/trunk@1810 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-06 21:18:09 +00:00
reed@google.com
cde92111d5
remove SkDeviceFactory from the collective consciousness, now that devices know
...
how to create compatible siblings.
git-svn-id: http://skia.googlecode.com/svn/trunk@1808 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-06 20:00:52 +00:00
reed@google.com
37a201231b
add SkEmptyShader, and return it from CreateBitmapShader if the bitmap is empty
...
(i.e. has no pixels at all)
git-svn-id: http://skia.googlecode.com/svn/trunk@1792 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-05 18:54:12 +00:00
epoger@google.com
9ef2d8382f
Reverting r1775 at Mike and Brian's request
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1786 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-01 21:12:20 +00:00
bsalomon@google.com
8bcc6f47b0
export SkAutoSTMalloc (for multi-dll chrome build)
...
Review URL: http://codereview.appspot.com/4643063/
git-svn-id: http://skia.googlecode.com/svn/trunk@1784 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-01 20:45:29 +00:00
tomhudson@google.com
0c8d93a940
Reworks r1770 so that users who have replaced SkUserConfig don't have to
...
make any changes to continue compiling successfully.
git-svn-id: http://skia.googlecode.com/svn/trunk@1779 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-07-01 17:08:26 +00:00
junov@google.com
22c8bb8ebd
Fixing several issues with rendering blurred bitmaps with Ganesh
...
BUG=http://code.google.com/p/skia/issues/detail?id=305
REVIEW=http://codereview.appspot.com/4630073/
git-svn-id: http://skia.googlecode.com/svn/trunk@1775 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-30 22:16:06 +00:00
bsalomon@google.com
3582bf9e3d
Remove GrAuto*Malloc, replace with SkAuto*Malloc
...
Review URL: http://codereview.appspot.com/4629088
git-svn-id: http://skia.googlecode.com/svn/trunk@1774 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-30 21:32:31 +00:00
reed@google.com
5d2fef0d83
fix asserts in new premul inline function
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1773 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-30 21:17:22 +00:00
reed@google.com
0b8b3bb083
make inline version of premultiply, to speed up gradient creation.
...
We could speed-up again if we...
- respected kDither and only built 1/2 of the table for non-dither requests
- output simple params to the gpu rather than always a texture
- detected that we have no alpha, and then can skip premul per-entry
git-svn-id: http://skia.googlecode.com/svn/trunk@1772 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-30 21:06:22 +00:00
junov@google.com
4ee7ae5dcf
Adding the notion of a volatile bitmap to SkBitmap.
...
Volatility is a hint that indicates that the contents of a bitmap
are ephemeral. SkGpuDevice will not preserve volatile bitmaps
in its texture cache, and will use textures from a pool of
keyless (recyclable) textures to avoid the performance hit of
texture allocation and release.
A subsequent change is required in webkit in order to take advantage
of this optimization. putImageData, and other methods that create
temporary bitmaps will have to mark their bitmaps as volatile.
before rendering them through skia.
git-svn-id: http://skia.googlecode.com/svn/trunk@1769 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-30 17:30:49 +00:00
tomhudson@google.com
3a1f6a06cc
SkStringPrintf helper fucntion + a new unit test for it.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1766 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-30 14:39:52 +00:00
reed@google.com
33114e0e59
remove unused and untested SkPath::subdivide()
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1732 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-28 11:57:12 +00:00
reed@google.com
314e9b3ba0
add ptr/len and SkData versions of Deflate()
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1726 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-27 17:41:22 +00:00
reed@google.com
effc5016f0
remove obsolete text codepaths
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1725 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-27 16:44:46 +00:00
reed@google.com
5667afc5cb
remove drawShape from canvas api
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1723 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-27 14:42:15 +00:00
reed@google.com
7453d0e450
use general SkWStream for parameter
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1719 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-24 20:45:40 +00:00
reed@google.com
8a85d0c493
replace detach/getStream apis on dynamicwstream with SkData
...
http://codereview.appspot.com/4657046/
git-svn-id: http://skia.googlecode.com/svn/trunk@1714 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-24 19:12:12 +00:00
tomhudson@google.com
317d540409
New benchmark for SkMatrix::computeType().
...
Utility function in SkMatrix to make benchmarking more accurate.
git-svn-id: http://skia.googlecode.com/svn/trunk@1710 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-24 18:30:49 +00:00
reed@google.com
3a31ac1cf5
add (replacing SkDataRef)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1698 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-24 13:11:05 +00:00
reed@google.com
8d0b5770f8
rename public SkDataRef to SkData
...
rename animator's internal SkData to SkDataInput
git-svn-id: http://skia.googlecode.com/svn/trunk@1697 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-24 13:07:31 +00:00
reed@google.com
70442a6cf7
add copyToData() to dyanamicwstream
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1695 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-23 21:48:04 +00:00
caryclark@google.com
1eeaf0ba23
Add support for 8 bits/component glyphs, to
...
better match the fonts produced by CoreText on OS/X.
M include/config/SkUserConfig.h
M include/core/SkMask.h
M include/core/SkScalerContext.h
M src/core/SkBlitter_ARGB32.cpp
M src/core/SkScalerContext.cpp
M src/core/SkPaint.cpp
M src/gpu/SkGrFontScaler.cpp
M src/ports/SkFontHost_mac_coretext.cpp
M src/ports/SkFontHost_mac.cpp
M gpu/include/GrTypes.h
M gpu/src/GrAtlas.cpp
git-svn-id: http://skia.googlecode.com/svn/trunk@1672 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-22 13:19:43 +00:00
vandebo@chromium.org
e1bc274295
Fix a batch of coverity defects, uninitialized class fields.
...
In SkClipStack::B2FIter::Clip, SkWriter32, SkClipStack::Rec, SkDeque::F2BIter, SkPDFShader::State
CID 15427,15433,15533,15532,16274,16740
Review URL: http://codereview.appspot.com/4630055
git-svn-id: http://skia.googlecode.com/svn/trunk@1669 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-21 22:26:39 +00:00
reed@google.com
6bac947cd5
Add option in flattening to write factory names inline, as we are recording.
...
SkGPipe needs this, since it cannot (unlike SkPicture) see all of the factories
before it hands its data to the reader.
In this mode, the writer embedds the factory name the first time it sees it,
and then after that writes an index (referencing the fFactorySet). The reader
installs an empty array, and as it encounters names, appends them to that array
so that subsequent indices can be used to retrieve the previously named factory.
Some of the existing patheffects did not register their factory names, so those
changes are also part of this CL. Annoyingly, to register your factory using the
current scheme, it has to be in the public section of the class definition.
git-svn-id: http://skia.googlecode.com/svn/trunk@1663 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-21 19:24:00 +00:00
reed@google.com
fd0ffcf486
change string read/write to store length as full 32-bit value. This simplifies
...
the internal logic, and allows SkFlattenable to rely on this when distinguishing
between 0 and indices (which will soon be negative) and string-lengths.
git-svn-id: http://skia.googlecode.com/svn/trunk@1660 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-21 15:43:11 +00:00
reed@google.com
2d54d06adc
update dox
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1657 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-21 12:19:28 +00:00
bsalomon@google.com
e97f0856a8
Add createNewCompatibleDevice. Allow devices to have a NULL factory and saveLayer will fall back on createNewCompatibleDevice.
...
Review URL: http://codereview.appspot.com/4633044/
git-svn-id: http://skia.googlecode.com/svn/trunk@1625 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-17 13:10:25 +00:00
reed@google.com
af951c9bc4
make SkDevice constructors explicit between offscreen and on/direct
...
http://codereview.appspot.com/4632044/
git-svn-id: http://skia.googlecode.com/svn/trunk@1620 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-16 19:10:39 +00:00
epoger@google.com
1fd56dc6e1
Implement SkPoint::Normalize() for SK_SCALAR_IS_FIXED and add performance warning to its declaration
...
http://codereview.appspot.com/4582043/
git-svn-id: http://skia.googlecode.com/svn/trunk@1602 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-15 18:04:58 +00:00
tomhudson@google.com
a87cd2af4c
Increase compatibility with clang, mostly around SK_RESTRICT.
...
Attempting to fix up our use of __restrict__ so Chrome can enable it.
git-svn-id: http://skia.googlecode.com/svn/trunk@1597 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-15 16:50:27 +00:00
reed@google.com
ca1f5e2a5d
style and warnings
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1590 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-14 19:31:24 +00:00
reed@google.com
35ae8ea9be
add SkDataRef (for future use)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1588 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-14 19:18:26 +00:00
reed@google.com
7d26c590f6
add 2nd parameter to SkFontHost::NextLogicalFont()
...
needed by android to map different styles of fallback fonts
git-svn-id: http://skia.googlecode.com/svn/trunk@1562 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-13 13:01:10 +00:00
epoger@google.com
80afbf08eb
#include <math.h> if SK_SCALAR_IS_FIXED but SK_CAN_USE_FLOAT
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1561 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-09 22:16:28 +00:00
reed@google.com
a87e065870
add SkFixedFloorToFixed
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1524 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-07 13:38:39 +00:00
reed@google.com
542e035dcd
remove unneeded check for thumb. see http://codereview.appspot.com/4539048/
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1477 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-02 13:45:33 +00:00
reed@google.com
3fb5187647
speed-up SkMatrix::preScale by 3x, by special-casing it instead of just calling
...
concat. Inspired by the profile of the fishtank site
git-svn-id: http://skia.googlecode.com/svn/trunk@1462 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-01 15:11:22 +00:00
twiz@google.com
c0c4d22bac
Removal of obsolete interface, SkMatrixClipObserver.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1435 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-26 14:57:48 +00:00
vandebo@chromium.org
8887ede824
[PDF] Improve the SkClipStack skipping prefix code.
...
Because of intersecting done in SkClipStack, we may have to do more work in the last entry of the prefix.
Review URL: http://codereview.appspot.com/4530066
git-svn-id: http://skia.googlecode.com/svn/trunk@1418 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-25 01:27:52 +00:00
epoger@google.com
b28b5e4e26
Warn when an SkScalar is passed into SkIntToScalar() (converted twice)
...
http://codereview.appspot.com/4548051/
git-svn-id: http://skia.googlecode.com/svn/trunk@1405 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-24 14:51:57 +00:00
reed@google.com
dde0956375
add cross-process option to gpipe
...
add unittests for reader32 and writer32
git-svn-id: http://skia.googlecode.com/svn/trunk@1397 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-23 12:21:05 +00:00
ctguil@chromium.org
c7d9f9d8ae
Expose SkComposeShader as SK_API.
...
This is used by the ChromeOS build of Chrome.
Review URL: http://codereview.appspot.com/4548054
git-svn-id: http://skia.googlecode.com/svn/trunk@1396 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-20 22:16:08 +00:00
bsalomon@google.com
27661181d7
Fix windows color order
...
Review URL: http://codereview.appspot.com/4553048/
git-svn-id: http://skia.googlecode.com/svn/trunk@1379 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-19 15:57:44 +00:00
reed@google.com
05ea1810a2
move SHIFT default definitions from SkColorPriv.h to SkPostConfig.h, so that
...
clients don't accidentally see them defined on some platforms when they only
include SkTypes.h, and not others.
git-svn-id: http://skia.googlecode.com/svn/trunk@1373 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-18 21:24:16 +00:00
reed@google.com
02b5331078
encode current LCD orientation and order into font-cache-key
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1368 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-18 19:00:53 +00:00
bsalomon@google.com
f2d91557b2
separate coverage stages from color stages.
...
Review URL: http://codereview.appspot.com/4538064/
git-svn-id: http://skia.googlecode.com/svn/trunk@1339 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-16 20:56:06 +00:00
reed@google.com
4b4fb3a52c
fully expand the initialization for rect (android compiler didn't like {0})
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1336 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-16 18:24:19 +00:00
reed@google.com
b54455e440
Change getConvexity() to now compute it if the value is set to kUnkown.
...
Change behavior for degenerate paths: now those return kConvex instead of kUnknown
git-svn-id: http://skia.googlecode.com/svn/trunk@1330 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-16 14:16:04 +00:00
reed@google.com
04863fa14a
add Convexity enum to SkPath
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1324 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-15 04:08:24 +00:00
reed@google.com
af8edcc477
update dox
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1318 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-12 22:31:01 +00:00
twiz@google.com
246bd0f271
git-svn-id: http://skia.googlecode.com/svn/trunk@1292 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-10 23:10:26 +00:00
reed@google.com
f2eb5ab780
fix bug where we wrote uninitialized data to the flatten stream for shaders.
...
Both shader and gradient_shader write matrices to the flatten stream. However, they were
just calling write(&matrix, sizeof(SkMatrix)) and the matrix can contain lazily-computed
function ptrs as part of its internal cache. Thus two matrices that are logically the
same may write different bytes.
This is a problem because picture relies on flattening objects and then using the
flatten stream as a key into its cache. This matrix-write bug effectively kills the
effectiveness of the cache for shaders.
The fix is to write proper read/write functions for matrix (and region btw). These
call through to the existing low-level flatten routines (which just write into a
memory ptr).
git-svn-id: http://skia.googlecode.com/svn/trunk@1290 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-10 22:56:42 +00:00
bsalomon@google.com
cc4dac3dac
Make GrMatrix an alias of SkMatrix. Add new methods to SkMatrix.
...
Review URL: http://codereview.appspot.com/4538043/
Checked in on behalf of reed@ with some additional work (remove the do-nother sk->gr matrix converter).
git-svn-id: http://skia.googlecode.com/svn/trunk@1289 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-10 13:52:42 +00:00
bsalomon@google.com
ee9aa30457
Fixes from Sk/Gr rect unification.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1288 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-09 22:32:52 +00:00
vandebo@chromium.org
6744d498fc
[PDF] Add a ToUnicode mapping for fonts.
...
This makes text in PDFs searchable and copy&paste-able.
Code from arthurhsu@chromium.org . Original review: http://codereview.appspot.com/4428082/
Review URL: http://codereview.appspot.com/4525042
git-svn-id: http://skia.googlecode.com/svn/trunk@1280 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-09 18:13:47 +00:00
reed@google.com
20efde71b4
Share code with SkRect
...
http://codereview.appspot.com/4523046/
git-svn-id: http://skia.googlecode.com/svn/trunk@1277 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-09 17:00:02 +00:00
vandebo@chromium.org
9fbdf87518
[PDF] Refactor content stream creation in SkPDFDevice to support more xfermodes.
...
Instead of writing all drawing and state updates into the final content stream immediately, this change creates a new ContentEntry each time the transform, clip, or paint changes. Drawing is done into a stream in the ContentEntry. When the consumer asks for the content, we combine all the ContentEntries with appropriate updates to the state (clip, transform, paint) in between. This allows us to modify the clip even after a drawing has completed. It also lets us remove ContentEntries with no drawing. Further optimization can be done to better use the stack features of PDF, for now we follow the previous model of having a single clip followed by a single transform on the graphic state stack.
Push rectangle logic into SkPDFUtil::AppendRectangle.
Change private functions to adhere to coding standards.
Review URL: http://codereview.appspot.com/4459041
git-svn-id: http://skia.googlecode.com/svn/trunk@1269 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-09 07:55:58 +00:00
reed@google.com
7744c205f2
use SkPoint, creating an alias for GrPoint
...
http://codereview.appspot.com/4498041/
git-svn-id: http://skia.googlecode.com/svn/trunk@1268 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-06 19:26:26 +00:00
bsalomon@google.com
fc29629525
Replace GrStringBuilder with SkString. First step in cleaning up the shader generator. Slight performance hit when creating a new shader (<10% of total shader gen time on my Windows box is spent in building our string before handing it to GL). Much of this can be recovered by better usage pattern of SkString in coming revisions.
...
Review URL: http://codereview.appspot.com/4465053/
git-svn-id: http://skia.googlecode.com/svn/trunk@1266 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-06 13:53:47 +00:00
bsalomon@google.com
0aa6c3e212
Tab -> spaces
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1264 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-06 13:02:10 +00:00
reed@google.com
185d3d016d
add SkScalarIsInt()
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1262 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-06 12:18:08 +00:00
reed@google.com
a571c99228
don't require a ptr unless size > 0
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1259 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-05 20:04:44 +00:00
reed@google.com
8d90eeba09
add find()
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1243 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-04 18:03:00 +00:00
reed@google.com
3048d4fd4e
remove deprecated getViewport/setViewport
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1235 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-04 13:50:34 +00:00
reed@google.com
acd471f47c
updated pipe
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1231 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-03 21:26:46 +00:00
vandebo@chromium.org
1e1c36f4f8
Add comparison and assignment to SkClipStack (and fix an optimization bug).
...
Review URL: http://codereview.appspot.com/4423085
git-svn-id: http://skia.googlecode.com/svn/trunk@1230 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-03 16:26:09 +00:00
reed@google.com
7894b92b57
code style
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1229 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-03 15:41:49 +00:00
reed@google.com
2f3dc9dc4c
add typefacecache
...
speedup lcd blits
clean up some samples
git-svn-id: http://skia.googlecode.com/svn/trunk@1220 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-02 17:33:45 +00:00
reed@google.com
3b521d0533
update dox
...
code style
git-svn-id: http://skia.googlecode.com/svn/trunk@1215 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-29 11:53:41 +00:00
mike@reedtribe.org
e9e08cc7b2
rename SkPtrRecorder and related wrappers to SkPtrSet, since that is the pattern
...
is it providing. Also add a templated wrapper to handle typecasting of ptr types.
git-svn-id: http://skia.googlecode.com/svn/trunk@1214 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-29 01:44:52 +00:00
mike@reedtribe.org
e8f754a41c
update dox
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1213 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-29 01:02:43 +00:00
tomhudson@google.com
4b33d28eb3
New 'skdiff' tool to compare two directories full of files, write diff images
...
into a third directory, and create a summary web page with metrics for easy
inspection of the results.
git-svn-id: http://skia.googlecode.com/svn/trunk@1200 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-27 15:39:30 +00:00
tomhudson@google.com
1447c6f7f4
Add missing flattenable registrations and CreateProc() functions;
...
fixes gm --serialize xfermode test case.
git-svn-id: http://skia.googlecode.com/svn/trunk@1199 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-27 14:09:52 +00:00
reed@google.com
f31663403b
http://codereview.appspot.com/4436057/
...
Tag some more API headers with SK_API so they are exposed
when doing a DLL build.
git-svn-id: http://skia.googlecode.com/svn/trunk@1193 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-26 20:06:08 +00:00
reed@google.com
c009111446
http://codereview.appspot.com/4438070/
...
update SK_API for non-windows builds
git-svn-id: http://skia.googlecode.com/svn/trunk@1192 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-26 20:04:16 +00:00
reed@google.com
5b3d5349be
add helper available()
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1188 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-26 17:49:03 +00:00
mike@reedtribe.org
ea4ac97dec
make SkDeviceFactory reference counted
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1180 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-26 11:48:33 +00:00
reed@google.com
1a32d4aed2
add SK_API
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1178 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-25 20:02:38 +00:00
reed@google.com
739456585a
devolve flattening parameters to their base classes
...
e.g. FlattenableReadBufer -> Reader32
git-svn-id: http://skia.googlecode.com/svn/trunk@1174 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-25 19:04:27 +00:00
mike@reedtribe.org
4135f28932
code style
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1158 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-20 11:04:30 +00:00
reed@google.com
6b7aee387d
optimize when we have a colorfilter, but no shader or xfermode
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1152 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-19 18:36:09 +00:00
reed@google.com
13659f1f8d
handle overflow
...
note: gradient caller doesn't so we can still draw wrong when the caller
converts its initial fx from float->fixed. Perhaps SkClampRange should offer
a float interface as well.
git-svn-id: http://skia.googlecode.com/svn/trunk@1149 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-18 19:59:38 +00:00
reed@google.com
63c1ad82fc
add fFx1 field, returning where to start the iterator for fCount1 range
...
add unittest
git-svn-id: http://skia.googlecode.com/svn/trunk@1145 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-18 14:15:36 +00:00
bsalomon@google.com
8c3ff17e2c
Add DLL exports (Fixes Multi-DLL build in Chrome against TOT skia)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1137 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-15 15:42:24 +00:00
reed@google.com
73ccb980e9
move header
...
fix warning in release build
git-svn-id: http://skia.googlecode.com/svn/trunk@1136 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-15 15:31:03 +00:00
djsollen@google.com
f5dbe2f00f
Upstream android changes.
...
reviewed by: reed
git-svn-id: http://skia.googlecode.com/svn/trunk@1134 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-15 13:41:26 +00:00
reed@google.com
2a98181f04
add SkCanvas::clear(SkColor color) to call the new virtual clear on device.
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1131 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-14 18:59:28 +00:00
bsalomon@google.com
398109cc3e
rename SkDevice::eraseColor to clear and make virtual.
...
Properly flush in GrContext before calling GrGpu::clear()
Review URL: http://codereview.appspot.com/4419043/
git-svn-id: http://skia.googlecode.com/svn/trunk@1130 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-14 18:40:27 +00:00
reed@google.com
43c50c8c77
add reflection asColorMode to SkColorFilter (for gpu)
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1126 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-14 15:50:52 +00:00
bsalomon@google.com
586f48cfa8
Add genID for SkBitmaps with raw pixels
...
Review URL: http://codereview.appspot.com/4413047/
git-svn-id: http://skia.googlecode.com/svn/trunk@1125 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-14 15:07:22 +00:00
reed@google.com
c0d4aa2088
fix asMode() to always succeed if the xfermode was built from a Mode
...
update dox to reflect this
update test
git-svn-id: http://skia.googlecode.com/svn/trunk@1121 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-13 21:12:04 +00:00
wjmaclean@chromium.org
1fbf760a12
Fix SkFixed overflows in SkFixedSquare, SkGradientShader.
...
Return SK_FixedMax when overflow occurs.
git-svn-id: http://skia.googlecode.com/svn/trunk@1117 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-13 13:31:06 +00:00
reed@google.com
24fb8e2cce
mark viewport APIs as deprecated
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1108 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-11 19:42:50 +00:00
reed@google.com
ad91799832
code style
...
git-svn-id: http://skia.googlecode.com/svn/trunk@1106 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-04-11 19:01:12 +00:00