Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(444)

Unified Diff: third_party/WebKit/Source/platform/image-decoders/gif/GIFImageReader.h

Issue 1460523002: GIF decoding to Index8, unit tests and misusing unit test as benchmark (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/platform/image-decoders/gif/GIFImageReader.h
diff --git a/third_party/WebKit/Source/platform/image-decoders/gif/GIFImageReader.h b/third_party/WebKit/Source/platform/image-decoders/gif/GIFImageReader.h
index 18170f5ff537b9f497a02859ac11b30ca506c760..3e17c454a35f437146686e6a6f146bcf3f870eaf 100644
--- a/third_party/WebKit/Source/platform/image-decoders/gif/GIFImageReader.h
+++ b/third_party/WebKit/Source/platform/image-decoders/gif/GIFImageReader.h
@@ -168,6 +168,8 @@ public:
}
void setDefined() { m_isDefined = true; }
bool isDefined() const { return m_isDefined; }
+ size_t getPosition() const { return m_position; }
+ size_t getTableSize() const { return m_colors; }
// Build RGBA table using the data stream.
void buildTable(blink::FastSharedBufferReader*);
@@ -292,6 +294,7 @@ public:
, m_sentSizeToClient(false)
, m_loopCount(cLoopCountNotSeen)
, m_parseCompleted(false)
+ , m_backgroundIndex(-1)
{
}
@@ -329,6 +332,8 @@ public:
void clearDecodeState(size_t index) { m_frames[index]->clearDecodeState(); }
+ unsigned short backgroundIndex() const { return m_backgroundIndex; }
+
private:
bool parseData(size_t dataPosition, size_t len, blink::GIFImageDecoder::GIFParseQuery);
void setRemainingBytes(size_t);
@@ -358,6 +363,7 @@ private:
RefPtr<blink::SharedBuffer> m_data;
bool m_parseCompleted;
+ unsigned short m_backgroundIndex;
};
#endif

Powered by Google App Engine
This is Rietveld 408576698