IDataSource: add getFlags() to expose DataSource::flags().
This will let MPEG4Extractor cache stbl data. Therefore it can avoid data
flushing in data source (NuCachedSource2) due to reading stbl and access
unit data alternatively when the stream is larger than max cache size.
Bug: 26533748
Change-Id: Ia534755ab9130e4dcee94d53ca3c933d1b9eb566
diff --git a/include/media/IDataSource.h b/include/media/IDataSource.h
index 07e46f7..09009f0 100644
--- a/include/media/IDataSource.h
+++ b/include/media/IDataSource.h
@@ -41,6 +41,9 @@
// This should be called before deleting |this|. The other methods may
// return errors if they're called after calling close().
virtual void close() = 0;
+ // Get the flags of the source.
+ // Refer to DataSource:Flags for the definition of the flags.
+ virtual uint32_t getFlags() = 0;
private:
DISALLOW_EVIL_CONSTRUCTORS(IDataSource);