summaryrefslogtreecommitdiff
path: root/lib/rbcodec/metadata
diff options
context:
space:
mode:
Diffstat (limited to 'lib/rbcodec/metadata')
-rw-r--r--lib/rbcodec/metadata/metadata.c8
-rw-r--r--lib/rbcodec/metadata/metadata.h1
2 files changed, 9 insertions, 0 deletions
diff --git a/lib/rbcodec/metadata/metadata.c b/lib/rbcodec/metadata/metadata.c
index 28cef46d92..670c37fcfd 100644
--- a/lib/rbcodec/metadata/metadata.c
+++ b/lib/rbcodec/metadata/metadata.c
@@ -304,6 +304,14 @@ int get_audio_base_codec_type(int type)
304 return base_type; 304 return base_type;
305} 305}
306 306
307const char * get_codec_string(int type)
308{
309 if (type < 0 || type >= AFMT_NUM_CODECS)
310 type = AFMT_UNKNOWN;
311
312 return audio_formats[type].label;
313}
314
307/* Get the basic audio type */ 315/* Get the basic audio type */
308bool rbcodec_format_is_atomic(int afmt) 316bool rbcodec_format_is_atomic(int afmt)
309{ 317{
diff --git a/lib/rbcodec/metadata/metadata.h b/lib/rbcodec/metadata/metadata.h
index a0ba0376c6..ce1b153833 100644
--- a/lib/rbcodec/metadata/metadata.h
+++ b/lib/rbcodec/metadata/metadata.h
@@ -333,6 +333,7 @@ void wipe_mp3entry(struct mp3entry *id3);
333 333
334void fill_metadata_from_path(struct mp3entry *id3, const char *trackname); 334void fill_metadata_from_path(struct mp3entry *id3, const char *trackname);
335int get_audio_base_codec_type(int type); 335int get_audio_base_codec_type(int type);
336const char * get_codec_string(int type);
336bool rbcodec_format_is_atomic(int afmt); 337bool rbcodec_format_is_atomic(int afmt);
337bool format_buffers_with_offset(int afmt); 338bool format_buffers_with_offset(int afmt);
338 339