Commit Graph

52 Commits

Author SHA1 Message Date
robertphillips@google.com
15e9d3e66e Expanded distribution of instance counting
http://codereview.appspot.com/6300114/



git-svn-id: http://skia.googlecode.com/svn/trunk@4291 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-06-21 20:25:03 +00:00
tomhudson@google.com
1f90287df3 Punctuation cleanup to satisfy idiosyncracies of OpenBSD gcc 4.2.1.
Original patch by landry.breuil.

http://code.google.com/p/skia/issues/detail?id=626



git-svn-id: http://skia.googlecode.com/svn/trunk@4112 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-06-01 13:15:47 +00:00
robertphillips@google.com
49d9fd5fdb Plumbing to propagate save & restore from SkCanvas down to GrContext & lower
http://codereview.appspot.com/6203067/



git-svn-id: http://skia.googlecode.com/svn/trunk@4034 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-05-23 11:44:08 +00:00
reed@google.com
8926b169f6 apply imagefilter to all draw calls
Review URL: https://codereview.appspot.com/5856048

git-svn-id: http://skia.googlecode.com/svn/trunk@3476 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-03-23 15:36:36 +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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
a7d948523d replace SkRefDict with SkMetaData (much more general)
git-svn-id: http://skia.googlecode.com/svn/trunk@1025 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-03-30 21:23:07 +00:00
reed@google.com
7ff8d81290 add dox for drawPath, describing how to interpret the prePathMatrix.
git-svn-id: http://skia.googlecode.com/svn/trunk@1006 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-03-25 15:08:16 +00:00
vandebo@chromium.org
57463e1908 Make SkDeviceFactory part of the API.
Review URL: http://codereview.appspot.com/4273081

git-svn-id: http://skia.googlecode.com/svn/trunk@965 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-03-19 17:27:49 +00:00
ctguil@chromium.org
7ffb1b21ab Add code needed to build skia as a windows dll within the chromium project.
- Export/import skia APIs if SKIA_DLL is defined.
- This change has no effect on skia.

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

git-svn-id: http://skia.googlecode.com/svn/trunk@944 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-03-15 21:27:08 +00:00
reed@google.com
f67e4cf4c1 add filterTextFlags() to SkDevice (virtual) to allow device subclasses to
filter what text features we try to use. The filtering allows for implementation
limitations to dictate when we turn off certain text features.



git-svn-id: http://skia.googlecode.com/svn/trunk@943 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-03-15 20:56:58 +00:00
djsollen@google.com
cd9d69b9ce Upstreaming changes from android.
- fix compile warnings in the GPU code
- upstream android specific code (ifdef protected)
- fail gracefully when a custom allocator fails



git-svn-id: http://skia.googlecode.com/svn/trunk@936 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-03-14 20:30:14 +00:00
reed@google.com
6f8f292aa7 add origin to device
used for interpreting the clipstack when a device is a layer



git-svn-id: http://skia.googlecode.com/svn/trunk@894 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-03-04 22:27:10 +00:00
bsalomon@google.com
d302f1401b Add support for clipstack to Gr. GrClip is now a list of rects and paths with set operations to combine them. The stencil buffer is used to perform the set operations to put the clip into the stencil buffer. Building Gr's clip from Skia's clipStack is currently disabled due to the fact that Skia's clipStack is relative to the root layer not the current layer. This will be fixed in a subsequent CL.
git-svn-id: http://skia.googlecode.com/svn/trunk@878 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-03-03 13:54:13 +00:00
reed@google.com
46799cd9f0 change virtual setMatrixClip() to take a SkClipStack parameter.
git-svn-id: http://skia.googlecode.com/svn/trunk@831 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-02-22 20:56:26 +00:00
reed@google.com
3dd42b3c87 update dox for readPixels()
git-svn-id: http://skia.googlecode.com/svn/trunk@772 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-02-07 22:44:43 +00:00
reed@google.com
3636ed558f embed a refdict inside SkDevice
udate unittests to test refdict's destructor



git-svn-id: http://skia.googlecode.com/svn/trunk@731 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-01-25 23:50:57 +00:00
reed@android.com
f2b98d67dc merge with changes for GPU backend
git-svn-id: http://skia.googlecode.com/svn/trunk@637 2bbb7eff-a529-9590-31e7-b0007b416f81
2010-12-20 18:26:13 +00:00
vandebo@chromium.org
8c1d88dcfb Remove include of SkGLDevice.h from SkGLCanvas.h
The '#include "SkGLDevice.h"' from include/core/SkDevice.h requires internal
Skia code to be added to the include search paths when using the deprecated API.
This change adds back SkGLCanvas.cpp to avoid exposing SkGLDevice.h to the
public API.

The change also includes an explicit virtual destructor on SkDeviceFactory to
silence a -Wnon-virtual-dtor warning and allow for -Werror.

Original Issue: http://codereview.appspot.com/3009041/

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

git-svn-id: http://skia.googlecode.com/svn/trunk@623 2bbb7eff-a529-9590-31e7-b0007b416f81
2010-11-11 00:49:41 +00:00
vandebo@chromium.org
35fc62b960 Move the device capability method to SkDevice.
These are not the capabilities of the factory, but of the device.  Additionally, it is more often needed when you have a device then when you have a factory, which caused creating of a new factory.

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

git-svn-id: http://skia.googlecode.com/svn/trunk@618 2bbb7eff-a529-9590-31e7-b0007b416f81
2010-10-26 19:47:30 +00:00
vandebo@chromium.org
9b49dc0db8 First pieces of SkPDFDevice. Supports:
Matrix transforms.
Rendering bitmaps.
Basic paint parameters.
Rendering rectangles, points, lines, polygons.
Render a paint to the page.

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

git-svn-id: http://skia.googlecode.com/svn/trunk@614 2bbb7eff-a529-9590-31e7-b0007b416f81
2010-10-20 22:23:29 +00:00
vandebo@chromium.org
b70ae310bb Fix a memory leak in the new Canvas/Device workflow.
The previous change made it difficult to inherit from SkCanvas without leaking memory.  By making SkDeviceFactory not reference counted, the right thing happens more naturally, just NewCanvas : public SkCanvas(new NewDeviceFactory()) {...}

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

git-svn-id: http://skia.googlecode.com/svn/trunk@605 2bbb7eff-a529-9590-31e7-b0007b416f81
2010-10-15 18:58:19 +00:00