aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/codec/SkJpegUtility.h
diff options
context:
space:
mode:
authorGravatar Matt Sarett <msarett@google.com>2017-06-06 17:58:33 +0000
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-06-06 18:20:40 +0000
commit15f4d02738895663daa484e4c8677cbad41bcab5 (patch)
tree3ee2e4f4f2b592fca2e82838fb84df80e66a617f /src/codec/SkJpegUtility.h
parent23f734cbf6688b120d9d6cc0a0c5beac4abbf51e (diff)
Revert "Handle different types of streams in different jpeg source managers"
This reverts commit 96cc36124d06e023005dd901b32c59b29f55a135. Reason for revert: I think this is break one of our test bots. I will reland once that is figured out. Original change's description: > Handle different types of streams in different jpeg source managers > > For streams that are memory backed (stream->getMemoryBase() returns > a non-null ptr and hasLength() returns true), handle the stream > with skjpeg_mem_source_mgr, which directly assigns memory base to > the source manager. For other non memory backed streams, handle the > stream with skjpeg_buffered_source_mgr, which is renamed from > the old skjpeg_source_mgr with no implementation change. > > Signed-off-by: cjbao <cathy.bao@intel.com> > Bug: skia: > Change-Id: I748de0bdba726bbb318922c08497135e73e37329 > Reviewed-on: https://skia-review.googlesource.com/17296 > Reviewed-by: Leon Scroggins <scroggo@google.com> > Reviewed-by: Matt Sarett <msarett@google.com> > Commit-Queue: Matt Sarett <msarett@google.com> > TBR=msarett@google.com,scroggo@google.com,cathy.bao@intel.com # Not skipping CQ checks because original CL landed > 1 day ago. Bug: skia: Change-Id: Idf6c426468cc959b3f4661c0b3e86cb4d5e93688 Reviewed-on: https://skia-review.googlesource.com/18850 Reviewed-by: Matt Sarett <msarett@google.com> Commit-Queue: Matt Sarett <msarett@google.com>
Diffstat (limited to 'src/codec/SkJpegUtility.h')
-rw-r--r--src/codec/SkJpegUtility.h11
1 files changed, 2 insertions, 9 deletions
diff --git a/src/codec/SkJpegUtility.h b/src/codec/SkJpegUtility.h
index e5dd848d99..33f4fbda8b 100644
--- a/src/codec/SkJpegUtility.h
+++ b/src/codec/SkJpegUtility.h
@@ -29,8 +29,8 @@ void skjpeg_err_exit(j_common_ptr cinfo);
/*
* Source handling struct for that allows libjpeg to use our stream object
*/
-struct skjpeg_buffered_source_mgr : jpeg_source_mgr {
- skjpeg_buffered_source_mgr(SkStream* stream);
+struct skjpeg_source_mgr : jpeg_source_mgr {
+ skjpeg_source_mgr(SkStream* stream);
SkStream* fStream; // unowned
enum {
@@ -41,11 +41,4 @@ struct skjpeg_buffered_source_mgr : jpeg_source_mgr {
uint8_t fBuffer[kBufferSize];
};
-/*
- * source for memory backed streams with a valid length
- */
-struct skjpeg_mem_source_mgr : jpeg_source_mgr {
- skjpeg_mem_source_mgr(SkStream* stream);
-};
-
#endif