Go to file
scroggo d61c384342 Allow SkStream::peek() to partially succeed
If the stream can peek less than requested, peek that amount. Return
the number of bytes peeked.

This simplifies crrev.com/1472123002. For a stream that is smaller than
14 bytes, it can successfully peek, meaning the client will not need to
fall back to read() + rewind(), which may fail if the stream can peek
but not rewind.

This CL revives code from patch set 3 of crrev.com/1044953002, where I
initially introduced peek() (including tests).

Add a test for SkFrontBufferedStream that verifies that peeking does
not make rewind() fail (i.e. by reading past the internal buffer).

BUG=skia:3257

Review URL: https://codereview.chromium.org/1490923005
2015-12-07 11:37:13 -08:00
animations first cut at a checkbox 2009-10-21 19:41:10 +00:00
bench simplify nanobench --quiet / -q output 2015-12-04 06:35:30 -08:00
bin bin/sync-and-gyp: sh->py (make more cross-platform) 2015-11-09 08:28:13 -08:00
cmake Update CMakeLists.txt to exclude SkFontConfigInterface_direct_*. 2015-12-01 14:26:28 -05:00
debugger Update debugger UI to auto-refresh the directory listing 2015-11-18 13:00:21 -08:00
dm Make SkAndroidCodec support ico 2015-12-04 08:00:50 -08:00
example Create a standalone example for using Skia with SDL 2015-11-13 11:22:19 -08:00
experimental Create GLSLUniformHandler class for gpu backend 2015-12-03 09:20:44 -08:00
forth Sanitizing source files in Skia_Periodic_House_Keeping 2013-01-26 07:06:02 +00:00
gm Add SkTileImageFilter sample to filterfastbounds GM. 2015-12-07 10:36:30 -08:00
gyp Match libjpeg-turbo name change in Android 2015-12-03 09:48:54 -08:00
include Allow SkStream::peek() to partially succeed 2015-12-07 11:37:13 -08:00
infra Add iOS compile bot to the CQ 2015-12-04 10:19:21 -08:00
platform_tools Add android_skp_capture.py, JSON file for geniewidget 2015-12-04 06:59:31 -08:00
resources demo tweaks, scale up perlin, add call to flush for fps 2015-11-09 13:10:30 -08:00
samplecode Fix skia_gpu=0 build (samplecode/SampleAnimatedText.cpp) 2015-11-17 09:38:05 -08:00
site Make building with clang documentation a bit easier to find 2015-12-03 09:20:55 -08:00
src Allow SkStream::peek() to partially succeed 2015-12-07 11:37:13 -08:00
tests Allow SkStream::peek() to partially succeed 2015-12-07 11:37:13 -08:00
third_party bring up SDL on windows 2015-11-11 13:17:06 -08:00
tools report back colorfilters in lua 2015-12-04 20:45:59 -08:00
.gitignore android/apps: Add CanvasProof App; 2015-09-23 12:40:34 -07:00
AUTHORS use malloc/calloc/free instead of moz_malloc/moz_calloc/moz_free in ports/SkMemory_mozalloc.cpp 2015-11-23 10:30:14 -08:00
BUILD.public Fix ODR violation. 2015-12-03 05:04:03 -08:00
codereview.settings Automatically add a docs preview link and NOTRY=true when there are only docs changes. 2015-02-26 10:16:13 -08:00
CONTRIBUTING Fix references to https://sites.google.com/site/skiadocs/. 2015-02-03 13:12:54 -02:00
CQ_COMMITTERS Moved committer list to chrome-infra-auth and deleted it from the repo 2015-09-02 13:37:54 -07:00
DEPS Cherry pick one more commit into libjpeg-turbo 2015-11-24 07:14:35 -08:00
Doxyfile Documentation: SkCanvas API 2015-05-19 10:21:29 -07:00
gyp_skia Support SKIA_OUT on Mac and ChromeOS 2015-05-04 08:04:28 -07:00
gyp_skia.py Roll gyp deps from 1765 to 1796. 2013-11-21 18:11:14 +00:00
LICENSE Include resources directory in google3 sync. 2015-10-20 13:00:48 -07:00
make.bat Fix references to https://sites.google.com/site/skiadocs/. 2015-02-03 13:12:54 -02:00
make.py GYP: remove stale skia_scalar gyp variable 2015-11-10 13:25:12 -05:00
Makefile Remove experimental/PdfViewer 2015-08-04 14:08:44 -07:00
OWNERS add root files from chrome 2013-08-13 19:11:15 +00:00
PRESUBMIT.py Comments Style: s/skbug.com/bug.skia.org/ 2015-11-07 05:29:00 -08:00
README Fix references to https://sites.google.com/site/skiadocs/. 2015-02-03 13:12:54 -02:00
README.chromium Update README.chromium. 2015-06-11 13:19:24 -07:00
skia.gyp Fix references to https://sites.google.com/site/skiadocs/. 2015-02-03 13:12:54 -02:00
SKP_VERSION Update SKP version 2015-12-06 00:27:08 -08:00
whitespace.txt Whitespace change to trigger bots after gsutil change 2015-11-24 11:36:09 -08:00

Skia is a complete 2D graphic library for drawing Text, Geometries, and Images.

See full details, and build instructions, at https://skia.org.