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

Unified Diff: Source/platform/graphics/DeferredImageDecoder.h

Issue 985583002: Don't cache any SkBitmaps in DeferredImageDecoder (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: done now Created 5 years, 9 months 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
« no previous file with comments | « Source/platform/graphics/BitmapImageTest.cpp ('k') | Source/platform/graphics/DeferredImageDecoder.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/graphics/DeferredImageDecoder.h
diff --git a/Source/platform/graphics/DeferredImageDecoder.h b/Source/platform/graphics/DeferredImageDecoder.h
index d35bbc64bb13134ca9cb19fbcdf58a3ab4497741..67f2a15fa9a420b1a09f1331f4c12cb95d76c7f6 100644
--- a/Source/platform/graphics/DeferredImageDecoder.h
+++ b/Source/platform/graphics/DeferredImageDecoder.h
@@ -30,6 +30,7 @@
#include "SkPixelRef.h"
#include "platform/PlatformExport.h"
#include "platform/geometry/IntSize.h"
+#include "platform/graphics/FrameData.h"
#include "platform/graphics/ImageFrameGenerator.h"
#include "platform/graphics/ImageSource.h"
#include "platform/image-decoders/ImageDecoder.h"
@@ -57,7 +58,7 @@ public:
String filenameExtension() const;
- ImageFrame* frameBufferAtIndex(size_t index);
+ PassRefPtr<NativeImageSkia> createFrameAtIndex(size_t);
void setData(SharedBuffer& data, bool allDataReceived);
@@ -72,7 +73,7 @@ public:
bool frameIsCompleteAtIndex(size_t) const;
float frameDurationAtIndex(size_t) const;
unsigned frameBytesAtIndex(size_t index) const;
- ImageOrientation orientation() const;
+ ImageOrientation orientationAtIndex(size_t index) const;
bool hotSpot(IntPoint&) const;
// For testing.
@@ -87,7 +88,6 @@ private:
RefPtr<SharedBuffer> m_data;
bool m_allDataReceived;
unsigned m_lastDataSize;
- bool m_dataChanged;
OwnPtr<ImageDecoder> m_actualDecoder;
String m_filenameExtension;
@@ -96,7 +96,8 @@ private:
int m_repetitionCount;
bool m_hasColorProfile;
- Vector<OwnPtr<ImageFrame>> m_lazyDecodedFrames;
+ // Carries only frame state and other information. Does not carry bitmap.
+ Vector<FrameData> m_frameData;
RefPtr<ImageFrameGenerator> m_frameGenerator;
static bool s_enabled;
« no previous file with comments | « Source/platform/graphics/BitmapImageTest.cpp ('k') | Source/platform/graphics/DeferredImageDecoder.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698