From 61cc1aaea7c5cd2d14d4baade6b8cd251c69fbdd Mon Sep 17 00:00:00 2001 From: fengalin Date: Sun, 30 Jul 2017 20:26:30 +0200 Subject: [PATCH] Add more tags Album covers can be found in `image` as a `Sample` Some containers (e.g. mkv) may use `album-artist` instead of `artist` --- gstreamer/src/tags.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gstreamer/src/tags.rs b/gstreamer/src/tags.rs index 8809f178d..06cd3b5a4 100644 --- a/gstreamer/src/tags.rs +++ b/gstreamer/src/tags.rs @@ -19,6 +19,7 @@ use glib::translate::{from_glib, from_glib_none, from_glib_full, ToGlib, ToGlibP use miniobject::*; use TagMergeMode; +use Sample; pub trait Tag<'a> { type TagType: FromValueOptional<'a> + SetValue; @@ -40,6 +41,7 @@ macro_rules! impl_tag( impl_tag!(Title, &'a str, "title"); impl_tag!(Album, &'a str, "album"); impl_tag!(Artist, &'a str, "artist"); +impl_tag!(AlbumArtist, &'a str, "album-artist"); impl_tag!(Encoder, &'a str, "encoder"); impl_tag!(AudioCodec, &'a str, "audio-codec"); impl_tag!(VideoCodec, &'a str, "video-codec"); @@ -49,6 +51,7 @@ impl_tag!(ContainerFormat, &'a str, "container-format"); impl_tag!(LanguageCode, &'a str, "language-code"); impl_tag!(Duration, u64, "duration"); impl_tag!(NominalBitrate, u32, "nominal-bitrate"); +impl_tag!(Image, Sample, "image"); pub type TagList = GstRc; pub struct TagListRef(ffi::GstTagList);