Commit Graph

247 Commits

Author SHA1 Message Date
tomhudson@google.com
278cbb452a Enable WebKit/Chromium style logging for Skia.
New macros called in Ganesh functions; by default are compiled away,
in example code resolve to printout, and are compatible with WebKit/Chromium
event logging and GPU profiler.



git-svn-id: http://skia.googlecode.com/svn/trunk@1770 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-30 19:37:01 +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
afec7ba759 Fix bug where equality was used instead of assignment.
git-svn-id: http://skia.googlecode.com/svn/trunk@1767 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-30 14:47:55 +00:00
bsalomon@google.com
cb0c5ab54d Fix valgrind reported issue, uninit mem in AutoReleaseGeometry::reset()
Review URL: http://codereview.appspot.com/4667048/




git-svn-id: http://skia.googlecode.com/svn/trunk@1761 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-29 17:48:17 +00:00
senorblanco@chromium.org
78b8253c0a Parse SampleApp command line for a test name. If an argument is passed to
SampleApp on the command line, interpret it as a test name.  If it's a valid
test, open that test at startup.

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



git-svn-id: http://skia.googlecode.com/svn/trunk@1742 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-28 19:44:03 +00:00
tomhudson@google.com
c10a88825d Guard against 0 tolerance in curve subdivision.
git-svn-id: http://skia.googlecode.com/svn/trunk@1735 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-28 15:19:32 +00:00
yangsu@google.com
6d2a6a400b Updated the references to iOS util files in the iOSSampleApp project file
renamed gpu/src/skia to gpu/ios



git-svn-id: http://skia.googlecode.com/svn/trunk@1707 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-24 17:26:53 +00:00
tomhudson@google.com
d22b6e4351 Remove global curve subdivision tolerance from GrPathUtils.
Put in framework for changing curve subdivision tolerance when rendering
offscreen AA tiles; however, comment out actual tolerance changes because
of possible quality issues with simple circles (q.v. Arcs slide of SampleApp).



git-svn-id: http://skia.googlecode.com/svn/trunk@1702 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-24 15:53:40 +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
bsalomon@google.com
d19aa27e03 Fix copy/paste error in GrDrawTarget::AutoStateRestore::set
Review URL: http://codereview.appspot.com/4639063/



git-svn-id: http://skia.googlecode.com/svn/trunk@1670 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-22 01:28:17 +00:00
bsalomon@google.com
7359eae7c6 fix to free a plot when purging gr font cache
Review URL: http://codereview.appspot.com/4645054/



git-svn-id: http://skia.googlecode.com/svn/trunk@1667 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-21 21:18:25 +00:00
bsalomon@google.com
6aab8e3df7 Initialize members to satisfy coverity.
Code review: http://codereview.appspot.com/4657043/



git-svn-id: http://skia.googlecode.com/svn/trunk@1665 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-21 20:32:12 +00:00
bsalomon@google.com
25fb21f5df Refactor GrDrawTarget vertex/index api
Review URL: http://codereview.appspot.com/4631056/



git-svn-id: http://skia.googlecode.com/svn/trunk@1662 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-21 18:17:25 +00:00
bsalomon@google.com
61f3bde1ba Fix handling of nan when clamping number of pts in quads/cubics
Review URL: http://codereview.appspot.com/4646044/



git-svn-id: http://skia.googlecode.com/svn/trunk@1642 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-17 20:06:49 +00:00
bsalomon@google.com
fe6765293f Remember last successful stencil format
Review URL: http://codereview.appspot.com/4625048/



git-svn-id: http://skia.googlecode.com/svn/trunk@1640 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-17 18:12:21 +00:00
bsalomon@google.com
90405934c5 Fix self-assignment
Review URL: http://codereview.appspot.com/4631047/



git-svn-id: http://skia.googlecode.com/svn/trunk@1637 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-17 15:56:55 +00:00
Scroggo
b092140c18 Remove redundant GrTouchGesture. Switch its only user to SkTouchGesture.
Review at http://codereview.appspot.com/4636045/


git-svn-id: http://skia.googlecode.com/svn/trunk@1636 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-17 15:17:07 +00:00
bsalomon@google.com
b5b3168a64 First pass at improving temporary tex/rt reuse
Review URL: http://codereview.appspot.com/4625043/




git-svn-id: http://skia.googlecode.com/svn/trunk@1616 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-16 18:05:35 +00:00
tomhudson@google.com
e67bd3fbc9 Rename GrGLBug to GrGLCapability.
Default all architectures to kProbe_GrGLCapability.
Use new facilities better from GrGpuGL.cpp



git-svn-id: http://skia.googlecode.com/svn/trunk@1613 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-16 14:08:04 +00:00
Scroggo
c29d7cdf3e Always call notifyTextureDelete in onRelease.
Reviewed at http://codereview.appspot.com/4620050/


git-svn-id: http://skia.googlecode.com/svn/trunk@1611 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-16 13:14:21 +00:00
tomhudson@google.com
30e4bb6667 Avoid checking to see if a bool is less than zero.
Create a symbolic name for -1 when it means "don't know, probe at runtime".



git-svn-id: http://skia.googlecode.com/svn/trunk@1606 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-15 19:41:46 +00:00
senorblanco@chromium.org
129b8e3237 Implement edge AA for concave polys in the tesselated path renderer.
Review URL:  http://codereview.appspot.com/4571072/



git-svn-id: http://skia.googlecode.com/svn/trunk@1600 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-15 17:52:09 +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
bsalomon@google.com
cd19a5f194 Set texture dirty flag only when texture has really changed
Review URL: http://codereview.appspot.com/4571073/



git-svn-id: http://skia.googlecode.com/svn/trunk@1592 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-15 14:00:23 +00:00
bsalomon@google.com
7ac249bdc7 Enable SSAA on inverse filled paths
Review URL: http://codereview.appspot.com/4613044/



git-svn-id: http://skia.googlecode.com/svn/trunk@1584 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-14 18:46:24 +00:00
epoger@google.com
baa677b248 delete all old (non-Gyp) buildfiles
git-svn-id: http://skia.googlecode.com/svn/trunk@1583 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-14 18:35:08 +00:00
tomhudson@google.com
747bf293d4 FBO probing at Context startup is very expensive. This patch removes the
test of whether FBOs work at all, and adds parameters to the GrGLInterface
so that values can be passed into the Context creation routines instead
of executing the probes.

The GrGLInterface now defaults to run FBO tests on Android (since hardware
varies), but assumes success on desktop and software platforms.



git-svn-id: http://skia.googlecode.com/svn/trunk@1582 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-14 18:16:52 +00:00
bsalomon@google.com
3914958a49 Fix text-as-path with skshader on gpu
Review URL: http://codereview.appspot.com/4576057/



git-svn-id: http://skia.googlecode.com/svn/trunk@1575 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-13 21:55:32 +00:00
bsalomon@google.com
79d2dbed5a uint32_t -> int for texture extents
Review URL: http://codereview.appspot.com/4584053/



git-svn-id: http://skia.googlecode.com/svn/trunk@1574 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-13 19:28:02 +00:00
reed@google.com
b9255d523f drop extraneous GrPrintfs
git-svn-id: http://skia.googlecode.com/svn/trunk@1572 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-13 18:54:59 +00:00
bsalomon@google.com
919583674b Consider hw render target limit for offscreen supersample and tile
Review URL: http://codereview.appspot.com/4575041/



git-svn-id: http://skia.googlecode.com/svn/trunk@1568 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-13 17:58:13 +00:00
djsollen@google.com
e32b5837c3 Updates to the Android SampleApp
http://codereview.appspot.com/4602049/


git-svn-id: http://skia.googlecode.com/svn/trunk@1567 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-13 16:58:40 +00:00
junov@google.com
53a5584bb0 Adding functionality for purgin graphics resource handles
This will allow a fix to WebKit for preventing a crash when the graphics
context is destroyed before the GrContext

BUG=http://code.google.com/p/chromium/issues/detail?id=85309



git-svn-id: http://skia.googlecode.com/svn/trunk@1551 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-08 22:55:10 +00:00
thakis@chromium.org
7e12f82aa4 GCC 4.6 fix: intptr_t <-> NULL triggers an warning.
BUG=chromium:87001
TEST=none

Patch by Ryan Sleevi <rsleevi@chromium.org>
Review URL: http://codereview.appspot.com/4571048/

git-svn-id: http://skia.googlecode.com/svn/trunk@1538 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-07 22:18:07 +00:00
bsalomon@google.com
7ca72f3355 Apply translate param to path bounds when computing ssaa bounds
Review URL: http://codereview.appspot.com/4591044/



git-svn-id: http://skia.googlecode.com/svn/trunk@1532 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-07 18:46:50 +00:00
thakis@chromium.org
441d7da536 Correct argument order for drawSimpleRect()
Patch by Ryan Sleevi <rsleevi@chromium.org>
Review URL: http://codereview.appspot.com/4568055/

git-svn-id: http://skia.googlecode.com/svn/trunk@1523 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-07 04:03:17 +00:00
kbr@chromium.org
120bdffcf0 Committing on behalf of gman@chromium.org:
Fix for putImageData

TEST=manually ran tests that were failing
BUG=84165
TBR=reed@google.com

Code review URL: http://codereview.appspot.com/4570042


git-svn-id: http://skia.googlecode.com/svn/trunk@1518 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-07 01:27:01 +00:00
reed@google.com
70c136e54e allow the build system to enable offscreen_aa to some max dimension
default is still 0 for the moment.



git-svn-id: http://skia.googlecode.com/svn/trunk@1498 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-03 19:51:26 +00:00
twiz@google.com
76b8274242 Correction of texture domain calculation. Review=http://codereview.appspot.com/4517126
git-svn-id: http://skia.googlecode.com/svn/trunk@1483 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-02 20:30:02 +00:00
tomhudson@google.com
0d831725f6 Reduce GrGLProgram::ProgramDesc from 88B to 24B.
http://codereview.appspot.com/4561058.



git-svn-id: http://skia.googlecode.com/svn/trunk@1480 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-02 15:37:14 +00:00
tomhudson@google.com
78e7d2c795 Fix to bug, partial fix to unit tests following on from
http://codereview.appspot.com/4536100/



git-svn-id: http://skia.googlecode.com/svn/trunk@1475 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-01 20:43:05 +00:00
reed@google.com
9b24d25c6b include SkTypes.h
git-svn-id: http://skia.googlecode.com/svn/trunk@1474 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-01 20:27:53 +00:00
tomhudson@google.com
0d3f1fbd6b Speed up GrBinHashKey computation by replacing Adler32 with One-at-a-Time hash
function, do 32b at a time instead of 8b at a time.



git-svn-id: http://skia.googlecode.com/svn/trunk@1472 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-06-01 19:27:31 +00:00
bsalomon@google.com
d7beab4252 Fix copy/paste bug that checks same stencil field twice in isDisabled().
git-svn-id: http://skia.googlecode.com/svn/trunk@1442 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-27 16:42:30 +00:00
junov@google.com
5d6e108624 This change eliminates a potential memory leak and it
fixes a mem check bug that was blocking the skia roll 
into Chromium.

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




git-svn-id: http://skia.googlecode.com/svn/trunk@1424 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-25 20:26:11 +00:00
senorblanco@chromium.org
1fa803d6b4 Rename glu libtess symbols. When enabled in WebKit, the internal_glu libtess
symbols in skia will collide with the same internal_ implementation in WebKit.
Rename the glu entry points with an Sk_ prefix instead.  Also, unfork the
changes to the libtess source as much as possible (the same as was done in
http://trac.webkit.org/changeset/87178).

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



git-svn-id: http://skia.googlecode.com/svn/trunk@1419 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-25 14:46:17 +00:00
junov@google.com
2f83940c4d Fixes performance for texture domain uniform upload
Code review: http://codereview.appspot.com/4536073/
bug: http://code.google.com/p/skia/issues/detail?id=275




git-svn-id: http://skia.googlecode.com/svn/trunk@1406 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-24 15:13:01 +00:00
bungeman@google.com
8c5753ea2e Fixed point no longer crashes when GL enabled in gm tests.
http://codereview.appspot.com/4532073/


git-svn-id: http://skia.googlecode.com/svn/trunk@1394 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-20 19:11:50 +00:00
bsalomon@google.com
0251b2fe99 Tag GrPrintf with GR_API so that it is exposed to users of a Skia DLL
Review URL: http://codereview.appspot.com/4530059/


git-svn-id: http://skia.googlecode.com/svn/trunk@1392 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-20 18:50:54 +00:00
bsalomon@google.com
271cffc77b Add dual source blending support for proper blending with coverage.
Review URL: http://codereview.appspot.com/4535088/



git-svn-id: http://skia.googlecode.com/svn/trunk@1390 2bbb7eff-a529-9590-31e7-b0007b416f81
2011-05-20 14:13:56 +00:00