diff options
author | 2015-10-14 15:21:11 -0700 | |
---|---|---|
committer | 2015-10-14 15:21:11 -0700 | |
commit | 67e676087cb847d40709ef639b2e2ecc7c99bbb2 (patch) | |
tree | a5f2c8b7f863bb0996464096e8970c806eeb421e /src/images | |
parent | a912ddef05e6c2b7a2c4076772b6cead56a345bd (diff) |
Revert of Supply separate flags for onBuildTileIndex (patchset #1 id:1 of https://codereview.chromium.org/1402783008/ )
Reason for revert:
Missing an important line.
Original issue's description:
> Supply separate flags for onBuildTileIndex
>
> This is a follow up to:
> https://codereview.chromium.org/1401283003/
>
> Supply separate flags for onBuildTileIndex
>
> Since png and jpeg's implementations of onBuildTileIndex rely on
> modifications to their underlying libraries, rather than whether we are
> running on Android, use separate flags that can be disabled
> independently.
>
> This will allow us to easily turn off the feature. It also is a step
> towards building and running on other platforms for testing (e.g.
> valgrind/ASAN to find memory leaks etc).
>
> BUG=skia:
>
> Committed: https://skia.googlesource.com/skia/+/fc06e9c0e621744654e231ae6fa4460d88c0e27e
TBR=scroggo@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:
Review URL: https://codereview.chromium.org/1394433005
Diffstat (limited to 'src/images')
-rw-r--r-- | src/images/SkJpegUtility.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/images/SkJpegUtility.cpp b/src/images/SkJpegUtility.cpp index f1a32cae10..10249ea8bf 100644 --- a/src/images/SkJpegUtility.cpp +++ b/src/images/SkJpegUtility.cpp @@ -13,7 +13,7 @@ static void sk_init_source(j_decompress_ptr cinfo) { skjpeg_source_mgr* src = (skjpeg_source_mgr*)cinfo->src; src->next_input_byte = (const JOCTET*)src->fBuffer; src->bytes_in_buffer = 0; -#ifdef SK_JPEG_INDEX_SUPPORTED +#ifdef SK_BUILD_FOR_ANDROID src->current_offset = 0; #endif if (!src->fStream->rewind()) { @@ -22,7 +22,7 @@ static void sk_init_source(j_decompress_ptr cinfo) { } } -#ifdef SK_JPEG_INDEX_SUPPORTED +#ifdef SK_BUILD_FOR_ANDROID static boolean sk_seek_input_data(j_decompress_ptr cinfo, long byte_offset) { skjpeg_source_mgr* src = (skjpeg_source_mgr*)cinfo->src; size_t bo = (size_t) byte_offset; @@ -57,7 +57,7 @@ static boolean sk_fill_input_buffer(j_decompress_ptr cinfo) { return FALSE; } -#ifdef SK_JPEG_INDEX_SUPPORTED +#ifdef SK_BUILD_FOR_ANDROID src->current_offset += bytes; #endif src->next_input_byte = (const JOCTET*)src->fBuffer; @@ -77,7 +77,7 @@ static void sk_skip_input_data(j_decompress_ptr cinfo, long num_bytes) { cinfo->err->error_exit((j_common_ptr)cinfo); return; } -#ifdef SK_JPEG_INDEX_SUPPORTED +#ifdef SK_BUILD_FOR_ANDROID src->current_offset += bytes; #endif bytesToSkip -= bytes; @@ -104,7 +104,7 @@ skjpeg_source_mgr::skjpeg_source_mgr(SkStream* stream, SkImageDecoder* decoder) skip_input_data = sk_skip_input_data; resync_to_restart = jpeg_resync_to_restart; term_source = sk_term_source; -#ifdef SK_JPEG_INDEX_SUPPORTED +#ifdef SK_BUILD_FOR_ANDROID seek_input_data = sk_seek_input_data; #endif // SkDebugf("**************** use memorybase %p %d\n", fMemoryBase, fMemoryBaseSize); |