diff options
-rw-r--r-- | include/media/mediametadataretriever.h | 1 | ||||
-rw-r--r-- | include/media/stagefright/MetaData.h | 1 | ||||
-rw-r--r-- | media/java/android/media/MediaMetadataRetriever.java | 6 | ||||
-rw-r--r-- | media/libstagefright/MP3Extractor.cpp | 1 | ||||
-rw-r--r-- | media/libstagefright/MPEG4Extractor.cpp | 5 | ||||
-rw-r--r-- | media/libstagefright/StagefrightMediaScanner.cpp | 1 | ||||
-rw-r--r-- | media/libstagefright/StagefrightMetadataRetriever.cpp | 1 |
7 files changed, 14 insertions, 2 deletions
diff --git a/include/media/mediametadataretriever.h b/include/media/mediametadataretriever.h index 022b849..9b12410 100644 --- a/include/media/mediametadataretriever.h +++ b/include/media/mediametadataretriever.h @@ -55,6 +55,7 @@ enum { METADATA_KEY_WRITER = 21, METADATA_KEY_MIMETYPE = 22, METADATA_KEY_DISC_NUMBER = 23, + METADATA_KEY_ALBUMARTIST = 24, // Add more here... }; diff --git a/include/media/stagefright/MetaData.h b/include/media/stagefright/MetaData.h index 8f423f7..45cc4f6 100644 --- a/include/media/stagefright/MetaData.h +++ b/include/media/stagefright/MetaData.h @@ -51,6 +51,7 @@ enum { kKeyAlbum = 'albu', // cstring kKeyArtist = 'arti', // cstring + kKeyAlbumArtist = 'aart', // cstring kKeyComposer = 'comp', // cstring kKeyGenre = 'genr', // cstring kKeyTitle = 'titl', // cstring diff --git a/media/java/android/media/MediaMetadataRetriever.java b/media/java/android/media/MediaMetadataRetriever.java index 04f8b5d..681751b 100644 --- a/media/java/android/media/MediaMetadataRetriever.java +++ b/media/java/android/media/MediaMetadataRetriever.java @@ -21,10 +21,10 @@ import android.content.Context; import android.content.res.AssetFileDescriptor; import android.graphics.Bitmap; import android.net.Uri; -import android.os.ParcelFileDescriptor; + import java.io.FileDescriptor; -import java.io.IOException; import java.io.FileNotFoundException; +import java.io.IOException; /** * MediaMetadataRetriever class provides a unified interface for retrieving @@ -256,5 +256,7 @@ public class MediaMetadataRetriever public static final int METADATA_KEY_VIDEO_WIDTH = 20; public static final int METADATA_KEY_WRITER = 21; public static final int METADATA_KEY_MIMETYPE = 22; + public static final int METADATA_KEY_DISCNUMBER = 23; + public static final int METADATA_KEY_ALBUMARTIST = 24; // Add more here... } diff --git a/media/libstagefright/MP3Extractor.cpp b/media/libstagefright/MP3Extractor.cpp index 79b7674..ab38bca 100644 --- a/media/libstagefright/MP3Extractor.cpp +++ b/media/libstagefright/MP3Extractor.cpp @@ -731,6 +731,7 @@ sp<MetaData> MP3Extractor::getMetaData() { static const Map kMap[] = { { kKeyAlbum, "TALB", "TAL" }, { kKeyArtist, "TPE1", "TP1" }, + { kKeyAlbumArtist, "TPE2", "TP2" }, { kKeyComposer, "TCOM", "TCM" }, { kKeyGenre, "TCON", "TCO" }, { kKeyTitle, "TIT2", "TT2" }, diff --git a/media/libstagefright/MPEG4Extractor.cpp b/media/libstagefright/MPEG4Extractor.cpp index 1ff38ee..666ed08 100644 --- a/media/libstagefright/MPEG4Extractor.cpp +++ b/media/libstagefright/MPEG4Extractor.cpp @@ -1045,6 +1045,11 @@ status_t MPEG4Extractor::parseMetaData(off_t offset, size_t size) { metadataKey = kKeyArtist; break; } + case FOURCC('a', 'A', 'R', 'T'): + { + metadataKey = kKeyAlbumArtist; + break; + } case FOURCC(0xa9, 'd', 'a', 'y'): { metadataKey = kKeyYear; diff --git a/media/libstagefright/StagefrightMediaScanner.cpp b/media/libstagefright/StagefrightMediaScanner.cpp index 22f701c..b1eca2b 100644 --- a/media/libstagefright/StagefrightMediaScanner.cpp +++ b/media/libstagefright/StagefrightMediaScanner.cpp @@ -194,6 +194,7 @@ status_t StagefrightMediaScanner::processFile( { "discnumber", METADATA_KEY_DISC_NUMBER }, { "album", METADATA_KEY_ALBUM }, { "artist", METADATA_KEY_ARTIST }, + { "albumartist", METADATA_KEY_ALBUMARTIST }, { "composer", METADATA_KEY_COMPOSER }, { "genre", METADATA_KEY_GENRE }, { "title", METADATA_KEY_TITLE }, diff --git a/media/libstagefright/StagefrightMetadataRetriever.cpp b/media/libstagefright/StagefrightMetadataRetriever.cpp index f617fe8..df6235f 100644 --- a/media/libstagefright/StagefrightMetadataRetriever.cpp +++ b/media/libstagefright/StagefrightMetadataRetriever.cpp @@ -308,6 +308,7 @@ void StagefrightMetadataRetriever::parseMetaData() { { kKeyDiscNumber, METADATA_KEY_DISC_NUMBER }, { kKeyAlbum, METADATA_KEY_ALBUM }, { kKeyArtist, METADATA_KEY_ARTIST }, + { kKeyAlbumArtist, METADATA_KEY_ALBUMARTIST }, { kKeyAuthor, METADATA_KEY_AUTHOR }, { kKeyComposer, METADATA_KEY_COMPOSER }, { kKeyDate, METADATA_KEY_DATE }, |