Initial KTX file decoder
R=bsalomon@google.com, robertphillips@google.com, halcanary@google.com, reed@google.com
Author: krajcevski@google.com
Review URL: https://codereview.chromium.org/302333002
diff --git a/src/images/SkStreamHelpers.h b/src/images/SkStreamHelpers.h
index 7e766b7..008dd8e 100644
--- a/src/images/SkStreamHelpers.h
+++ b/src/images/SkStreamHelpers.h
@@ -10,6 +10,7 @@
class SkAutoMalloc;
class SkStream;
+class SkData;
/**
* Copy the provided stream to memory allocated by storage.
@@ -24,4 +25,12 @@
*/
size_t CopyStreamToStorage(SkAutoMalloc* storage, SkStream* stream);
+/**
+ * Copy the provided stream to an SkData variable. Used by SkImageDecoder_libktx.
+ * @param stream SkStream to be copied into data.
+ * @return SkData* The resulting SkData after the copy. This data will have a
+ * ref count of one upon return and belongs to the caller. Returns NULL on failure.
+ */
+SkData *CopyStreamToData(SkStream* stream);
+
#endif // SkStreamHelpers_DEFINED