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

Unified Diff: src/codec/SkRawAdapterCodec.h

Issue 1520403003: Prototype of RAW decoding in Skia. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Set big endian explicitly for arm Created 4 years, 11 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 | « src/codec/SkCodec.cpp ('k') | src/codec/SkRawAdapterCodec.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/codec/SkRawAdapterCodec.h
diff --git a/src/codec/SkRawAdapterCodec.h b/src/codec/SkRawAdapterCodec.h
new file mode 100644
index 0000000000000000000000000000000000000000..b552f2aaeada2c6c9f2341ee3a654d61d9c7bc01
--- /dev/null
+++ b/src/codec/SkRawAdapterCodec.h
@@ -0,0 +1,42 @@
+/*
+ * Copyright 2016 Google Inc.
+ *
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+
+#ifndef SkRawAdapterCodec_DEFINED
+#define SkRawAdapterCodec_DEFINED
+
+#include "SkAndroidCodec.h"
+#include "SkCodec.h"
+#include "SkEncodedFormat.h"
+#include "SkRawCodec.h"
+#include "SkStream.h"
+#include "SkTypes.h"
+
+/**
+ * This class implements the functionality of SkAndroidCodec. It uses an
+ * SkRawCodec.
+ */
+class SkRawAdapterCodec : public SkAndroidCodec {
+public:
+
+ explicit SkRawAdapterCodec(SkRawCodec*);
+
+ virtual ~SkRawAdapterCodec() {}
+
+protected:
+
+ SkISize onGetSampledDimensions(int sampleSize) const override;
+
+ bool onGetSupportedSubset(SkIRect* /*desiredSubset*/) const override { return false; }
+
+ SkCodec::Result onGetAndroidPixels(const SkImageInfo& info, void* pixels, size_t rowBytes,
+ const AndroidOptions& options) override;
+
+private:
+
+ typedef SkAndroidCodec INHERITED;
+};
+#endif // SkRawAdapterCodec_DEFINED
« no previous file with comments | « src/codec/SkCodec.cpp ('k') | src/codec/SkRawAdapterCodec.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698