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

Side by Side Diff: Source/core/platform/image-decoders/gif/GIFImageDecoder.h

Issue 15466003: Remove image decoder down sampling (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Remove virtual setSize() from GIF decoder Created 7 years, 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006 Apple Computer, Inc. All rights reserved. 2 * Copyright (C) 2006 Apple Computer, Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 27 matching lines...) Expand all
38 public: 38 public:
39 GIFImageDecoder(ImageSource::AlphaOption, ImageSource::GammaAndColorProf ileOption); 39 GIFImageDecoder(ImageSource::AlphaOption, ImageSource::GammaAndColorProf ileOption);
40 virtual ~GIFImageDecoder(); 40 virtual ~GIFImageDecoder();
41 41
42 enum GIFQuery { GIFFullQuery, GIFSizeQuery, GIFFrameCountQuery }; 42 enum GIFQuery { GIFFullQuery, GIFSizeQuery, GIFFrameCountQuery };
43 43
44 // ImageDecoder 44 // ImageDecoder
45 virtual String filenameExtension() const { return "gif"; } 45 virtual String filenameExtension() const { return "gif"; }
46 virtual void setData(SharedBuffer* data, bool allDataReceived); 46 virtual void setData(SharedBuffer* data, bool allDataReceived);
47 virtual bool isSizeAvailable(); 47 virtual bool isSizeAvailable();
48 virtual bool setSize(unsigned width, unsigned height);
49 virtual size_t frameCount(); 48 virtual size_t frameCount();
50 virtual int repetitionCount() const; 49 virtual int repetitionCount() const;
51 virtual ImageFrame* frameBufferAtIndex(size_t index); 50 virtual ImageFrame* frameBufferAtIndex(size_t index);
52 virtual bool frameIsCompleteAtIndex(size_t) const; 51 virtual bool frameIsCompleteAtIndex(size_t) const;
53 virtual float frameDurationAtIndex(size_t) const; 52 virtual float frameDurationAtIndex(size_t) const;
54 // CAUTION: setFailed() deletes |m_reader|. Be careful to avoid 53 // CAUTION: setFailed() deletes |m_reader|. Be careful to avoid
55 // accessing deleted memory, especially when calling this from inside 54 // accessing deleted memory, especially when calling this from inside
56 // GIFImageReader! 55 // GIFImageReader!
57 virtual bool setFailed(); 56 virtual bool setFailed();
58 virtual void clearFrameBufferCache(size_t clearBeforeFrame); 57 virtual void clearFrameBufferCache(size_t clearBeforeFrame);
(...skipping 16 matching lines...) Expand all
75 bool initFrameBuffer(unsigned frameIndex); 74 bool initFrameBuffer(unsigned frameIndex);
76 75
77 bool m_currentBufferSawAlpha; 76 bool m_currentBufferSawAlpha;
78 mutable int m_repetitionCount; 77 mutable int m_repetitionCount;
79 OwnPtr<GIFImageReader> m_reader; 78 OwnPtr<GIFImageReader> m_reader;
80 }; 79 };
81 80
82 } // namespace WebCore 81 } // namespace WebCore
83 82
84 #endif 83 #endif
OLDNEW
« no previous file with comments | « Source/core/platform/image-decoders/ImageDecoder.cpp ('k') | Source/core/platform/image-decoders/gif/GIFImageDecoder.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698