* [PATCH ] AVRCP: Handle Total Number Of Tracks metadata @ 2015-06-05 15:13 Bharat Panda 2015-06-11 5:44 ` Bharat Bhusan Panda 2015-06-19 9:45 ` Bharat Bhusan Panda 0 siblings, 2 replies; 6+ messages in thread From: Bharat Panda @ 2015-06-05 15:13 UTC (permalink / raw) To: linux-bluetooth; +Cc: cpgs, Bharat Panda Total Number of Tracks was not displayed, coz "Number of Tracks" was not handled in metadata parser. --- profiles/audio/media.c | 3 +++ tools/mpris-proxy.c | 3 +++ 2 files changed, 6 insertions(+) diff --git a/profiles/audio/media.c b/profiles/audio/media.c index f12569e..8e7e1a3 100644 --- a/profiles/audio/media.c +++ b/profiles/audio/media.c @@ -1510,6 +1510,9 @@ static gboolean parse_player_metadata(struct media_player *mp, } else if (strcasecmp(key, "xesam:trackNumber") == 0) { if (!parse_int32_metadata(mp, "TrackNumber", &var)) return FALSE; + } else if (strcasecmp(key, "xesam:totalTracks") == 0) { + if (!parse_int32_metadata(mp, "NumberOfTracks", &var)) + return FALSE; } else DBG("%s not supported, ignoring", key); diff --git a/tools/mpris-proxy.c b/tools/mpris-proxy.c index 693055e..5749427 100644 --- a/tools/mpris-proxy.c +++ b/tools/mpris-proxy.c @@ -1261,6 +1261,9 @@ static int parse_track_entry(DBusMessageIter *entry, const char *key, } else if (strcasecmp(key, "TrackNumber") == 0) { if (!parse_int32_metadata(&var, "xesam:trackNumber", metadata)) return -EINVAL; + } else if (strcasecmp(key, "NumberOfTracks") == 0) { + if (!parse_int32_metadata(&var, "xesam:totalTracks", metadata)) + return -EINVAL; } else if (strcasecmp(key, "Item") == 0) { if (!parse_path_metadata(&var, "mpris:trackid", metadata)) return -EINVAL; -- 1.9.1 ^ permalink raw reply related [flat|nested] 6+ messages in thread
* RE: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata 2015-06-05 15:13 [PATCH ] AVRCP: Handle Total Number Of Tracks metadata Bharat Panda @ 2015-06-11 5:44 ` Bharat Bhusan Panda 2015-06-19 9:45 ` Bharat Bhusan Panda 1 sibling, 0 replies; 6+ messages in thread From: Bharat Bhusan Panda @ 2015-06-11 5:44 UTC (permalink / raw) To: linux-bluetooth; +Cc: cpgs ping > -----Original Message----- > From: linux-bluetooth-owner@vger.kernel.org [mailto:linux-bluetooth- > owner@vger.kernel.org] On Behalf Of Bharat Panda > Sent: Friday, June 05, 2015 8:44 PM > To: linux-bluetooth@vger.kernel.org > Cc: cpgs@samsung.com; Bharat Panda > Subject: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata > > Total Number of Tracks was not displayed, coz "Number of Tracks" > was not handled in metadata parser. > --- > profiles/audio/media.c | 3 +++ > tools/mpris-proxy.c | 3 +++ > 2 files changed, 6 insertions(+) > > diff --git a/profiles/audio/media.c b/profiles/audio/media.c index > f12569e..8e7e1a3 100644 > --- a/profiles/audio/media.c > +++ b/profiles/audio/media.c > @@ -1510,6 +1510,9 @@ static gboolean parse_player_metadata(struct > media_player *mp, > } else if (strcasecmp(key, "xesam:trackNumber") == 0) { > if (!parse_int32_metadata(mp, "TrackNumber", > &var)) > return FALSE; > + } else if (strcasecmp(key, "xesam:totalTracks") == 0) { > + if (!parse_int32_metadata(mp, "NumberOfTracks", > &var)) > + return FALSE; > } else > DBG("%s not supported, ignoring", key); > > diff --git a/tools/mpris-proxy.c b/tools/mpris-proxy.c index 693055e..5749427 > 100644 > --- a/tools/mpris-proxy.c > +++ b/tools/mpris-proxy.c > @@ -1261,6 +1261,9 @@ static int parse_track_entry(DBusMessageIter > *entry, const char *key, > } else if (strcasecmp(key, "TrackNumber") == 0) { > if (!parse_int32_metadata(&var, "xesam:trackNumber", > metadata)) > return -EINVAL; > + } else if (strcasecmp(key, "NumberOfTracks") == 0) { > + if (!parse_int32_metadata(&var, "xesam:totalTracks", > metadata)) > + return -EINVAL; > } else if (strcasecmp(key, "Item") == 0) { > if (!parse_path_metadata(&var, "mpris:trackid", metadata)) > return -EINVAL; > -- > 1.9.1 > > -- > To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in > the body of a message to majordomo@vger.kernel.org More majordomo > info at http://vger.kernel.org/majordomo-info.html ^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata 2015-06-05 15:13 [PATCH ] AVRCP: Handle Total Number Of Tracks metadata Bharat Panda 2015-06-11 5:44 ` Bharat Bhusan Panda @ 2015-06-19 9:45 ` Bharat Bhusan Panda 2015-06-23 8:39 ` Luiz Augusto von Dentz 1 sibling, 1 reply; 6+ messages in thread From: Bharat Bhusan Panda @ 2015-06-19 9:45 UTC (permalink / raw) To: linux-bluetooth; +Cc: cpgs ping > -----Original Message----- > From: Bharat Bhusan Panda [mailto:bharat.panda@samsung.com] > Sent: Thursday, June 11, 2015 11:14 AM > To: 'linux-bluetooth@vger.kernel.org' > Cc: 'cpgs@samsung.com' > Subject: RE: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata > > ping > > > -----Original Message----- > > From: linux-bluetooth-owner@vger.kernel.org [mailto:linux-bluetooth- > > owner@vger.kernel.org] On Behalf Of Bharat Panda > > Sent: Friday, June 05, 2015 8:44 PM > > To: linux-bluetooth@vger.kernel.org > > Cc: cpgs@samsung.com; Bharat Panda > > Subject: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata > > > > Total Number of Tracks was not displayed, coz "Number of Tracks" > > was not handled in metadata parser. > > --- > > profiles/audio/media.c | 3 +++ > > tools/mpris-proxy.c | 3 +++ > > 2 files changed, 6 insertions(+) > > > > diff --git a/profiles/audio/media.c b/profiles/audio/media.c index > > f12569e..8e7e1a3 100644 > > --- a/profiles/audio/media.c > > +++ b/profiles/audio/media.c > > @@ -1510,6 +1510,9 @@ static gboolean parse_player_metadata(struct > > media_player *mp, > > } else if (strcasecmp(key, "xesam:trackNumber") == 0) { > > if (!parse_int32_metadata(mp, "TrackNumber", > > &var)) > > return FALSE; > > + } else if (strcasecmp(key, "xesam:totalTracks") == 0) { > > + if (!parse_int32_metadata(mp, "NumberOfTracks", > > &var)) > > + return FALSE; > > } else > > DBG("%s not supported, ignoring", key); > > > > diff --git a/tools/mpris-proxy.c b/tools/mpris-proxy.c index > > 693055e..5749427 > > 100644 > > --- a/tools/mpris-proxy.c > > +++ b/tools/mpris-proxy.c > > @@ -1261,6 +1261,9 @@ static int parse_track_entry(DBusMessageIter > > *entry, const char *key, > > } else if (strcasecmp(key, "TrackNumber") == 0) { > > if (!parse_int32_metadata(&var, "xesam:trackNumber", > > metadata)) > > return -EINVAL; > > + } else if (strcasecmp(key, "NumberOfTracks") == 0) { > > + if (!parse_int32_metadata(&var, "xesam:totalTracks", > > metadata)) > > + return -EINVAL; > > } else if (strcasecmp(key, "Item") == 0) { > > if (!parse_path_metadata(&var, "mpris:trackid", metadata)) > > return -EINVAL; > > -- > > 1.9.1 > > > > -- > > To unsubscribe from this list: send the line "unsubscribe > > linux-bluetooth" in the body of a message to majordomo@vger.kernel.org > > More majordomo info at http://vger.kernel.org/majordomo-info.html ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata 2015-06-19 9:45 ` Bharat Bhusan Panda @ 2015-06-23 8:39 ` Luiz Augusto von Dentz 2015-06-23 11:34 ` Bharat Bhusan Panda 0 siblings, 1 reply; 6+ messages in thread From: Luiz Augusto von Dentz @ 2015-06-23 8:39 UTC (permalink / raw) To: Bharat Bhusan Panda; +Cc: linux-bluetooth@vger.kernel.org, cpgs Hi Bharat, On Fri, Jun 19, 2015 at 12:45 PM, Bharat Bhusan Panda <bharat.panda@samsung.com> wrote: > ping > >> -----Original Message----- >> From: Bharat Bhusan Panda [mailto:bharat.panda@samsung.com] >> Sent: Thursday, June 11, 2015 11:14 AM >> To: 'linux-bluetooth@vger.kernel.org' >> Cc: 'cpgs@samsung.com' >> Subject: RE: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata >> >> ping >> >> > -----Original Message----- >> > From: linux-bluetooth-owner@vger.kernel.org [mailto:linux-bluetooth- >> > owner@vger.kernel.org] On Behalf Of Bharat Panda >> > Sent: Friday, June 05, 2015 8:44 PM >> > To: linux-bluetooth@vger.kernel.org >> > Cc: cpgs@samsung.com; Bharat Panda >> > Subject: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata >> > >> > Total Number of Tracks was not displayed, coz "Number of Tracks" >> > was not handled in metadata parser. >> > --- >> > profiles/audio/media.c | 3 +++ >> > tools/mpris-proxy.c | 3 +++ >> > 2 files changed, 6 insertions(+) >> > >> > diff --git a/profiles/audio/media.c b/profiles/audio/media.c index >> > f12569e..8e7e1a3 100644 >> > --- a/profiles/audio/media.c >> > +++ b/profiles/audio/media.c >> > @@ -1510,6 +1510,9 @@ static gboolean parse_player_metadata(struct >> > media_player *mp, >> > } else if (strcasecmp(key, "xesam:trackNumber") == 0) { >> > if (!parse_int32_metadata(mp, "TrackNumber", >> > &var)) >> > return FALSE; >> > + } else if (strcasecmp(key, "xesam:totalTracks") == 0) { >> > + if (!parse_int32_metadata(mp, "NumberOfTracks", >> > &var)) >> > + return FALSE; >> > } else >> > DBG("%s not supported, ignoring", key); >> > >> > diff --git a/tools/mpris-proxy.c b/tools/mpris-proxy.c index >> > 693055e..5749427 >> > 100644 >> > --- a/tools/mpris-proxy.c >> > +++ b/tools/mpris-proxy.c >> > @@ -1261,6 +1261,9 @@ static int parse_track_entry(DBusMessageIter >> > *entry, const char *key, >> > } else if (strcasecmp(key, "TrackNumber") == 0) { >> > if (!parse_int32_metadata(&var, "xesam:trackNumber", >> > metadata)) >> > return -EINVAL; >> > + } else if (strcasecmp(key, "NumberOfTracks") == 0) { >> > + if (!parse_int32_metadata(&var, "xesam:totalTracks", >> > metadata)) >> > + return -EINVAL; I remember not finding any documentation for xesam:totalTracks do you have a link for it? If you could you please add to the description. >> > } else if (strcasecmp(key, "Item") == 0) { >> > if (!parse_path_metadata(&var, "mpris:trackid", metadata)) >> > return -EINVAL; >> > -- >> > 1.9.1 >> > >> > -- >> > To unsubscribe from this list: send the line "unsubscribe >> > linux-bluetooth" in the body of a message to majordomo@vger.kernel.org >> > More majordomo info at http://vger.kernel.org/majordomo-info.html > > -- > To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html -- Luiz Augusto von Dentz ^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata 2015-06-23 8:39 ` Luiz Augusto von Dentz @ 2015-06-23 11:34 ` Bharat Bhusan Panda 2015-06-23 12:53 ` Luiz Augusto von Dentz 0 siblings, 1 reply; 6+ messages in thread From: Bharat Bhusan Panda @ 2015-06-23 11:34 UTC (permalink / raw) To: 'Luiz Augusto von Dentz'; +Cc: linux-bluetooth, cpgs Hi Luiz, > -----Original Message----- > From: linux-bluetooth-owner@vger.kernel.org [mailto:linux-bluetooth- > owner@vger.kernel.org] On Behalf Of Luiz Augusto von Dentz > Sent: Tuesday, June 23, 2015 2:09 PM > To: Bharat Bhusan Panda > Cc: linux-bluetooth@vger.kernel.org; cpgs@samsung.com > Subject: Re: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata > > Hi Bharat, > > On Fri, Jun 19, 2015 at 12:45 PM, Bharat Bhusan Panda > <bharat.panda@samsung.com> wrote: > > ping > > > >> -----Original Message----- > >> From: Bharat Bhusan Panda [mailto:bharat.panda@samsung.com] > >> Sent: Thursday, June 11, 2015 11:14 AM > >> To: 'linux-bluetooth@vger.kernel.org' > >> Cc: 'cpgs@samsung.com' > >> Subject: RE: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata > >> > >> ping > >> > >> > -----Original Message----- > >> > From: linux-bluetooth-owner@vger.kernel.org > >> > [mailto:linux-bluetooth- owner@vger.kernel.org] On Behalf Of Bharat > >> > Panda > >> > Sent: Friday, June 05, 2015 8:44 PM > >> > To: linux-bluetooth@vger.kernel.org > >> > Cc: cpgs@samsung.com; Bharat Panda > >> > Subject: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata > >> > > >> > Total Number of Tracks was not displayed, coz "Number of Tracks" > >> > was not handled in metadata parser. > >> > --- > >> > profiles/audio/media.c | 3 +++ > >> > tools/mpris-proxy.c | 3 +++ > >> > 2 files changed, 6 insertions(+) > >> > > >> > diff --git a/profiles/audio/media.c b/profiles/audio/media.c index > >> > f12569e..8e7e1a3 100644 > >> > --- a/profiles/audio/media.c > >> > +++ b/profiles/audio/media.c > >> > @@ -1510,6 +1510,9 @@ static gboolean parse_player_metadata(struct > >> > media_player *mp, > >> > } else if (strcasecmp(key, "xesam:trackNumber") == 0) { > >> > if (!parse_int32_metadata(mp, "TrackNumber", > >> > &var)) > >> > return FALSE; > >> > + } else if (strcasecmp(key, "xesam:totalTracks") == 0) { > >> > + if (!parse_int32_metadata(mp, "NumberOfTracks", > >> > &var)) > >> > + return FALSE; > >> > } else > >> > DBG("%s not supported, ignoring", key); > >> > > >> > diff --git a/tools/mpris-proxy.c b/tools/mpris-proxy.c index > >> > 693055e..5749427 > >> > 100644 > >> > --- a/tools/mpris-proxy.c > >> > +++ b/tools/mpris-proxy.c > >> > @@ -1261,6 +1261,9 @@ static int parse_track_entry(DBusMessageIter > >> > *entry, const char *key, > >> > } else if (strcasecmp(key, "TrackNumber") == 0) { > >> > if (!parse_int32_metadata(&var, "xesam:trackNumber", > >> > metadata)) > >> > return -EINVAL; > >> > + } else if (strcasecmp(key, "NumberOfTracks") == 0) { > >> > + if (!parse_int32_metadata(&var, "xesam:totalTracks", > >> > metadata)) > >> > + return -EINVAL; > > I remember not finding any documentation for xesam:totalTracks do you > have a link for it? If you could you please add to the description. I don’t have any xesam or freedesktop reference for "xesam:totalTracks ", but I tried with "xesam:totalTracks" to get NumberOfTracks parsed and it works well to get it displayed. > > >> > } else if (strcasecmp(key, "Item") == 0) { > >> > if (!parse_path_metadata(&var, "mpris:trackid", metadata)) > >> > return -EINVAL; > >> > -- > >> > 1.9.1 > >> > > >> > -- > >> > To unsubscribe from this list: send the line "unsubscribe > >> > linux-bluetooth" in the body of a message to > >> > majordomo@vger.kernel.org More majordomo info at > >> > http://vger.kernel.org/majordomo-info.html > > > > -- > > To unsubscribe from this list: send the line "unsubscribe > > linux-bluetooth" in the body of a message to majordomo@vger.kernel.org > > More majordomo info at http://vger.kernel.org/majordomo-info.html > > > > -- > Luiz Augusto von Dentz > -- > To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in > the body of a message to majordomo@vger.kernel.org More majordomo > info at http://vger.kernel.org/majordomo-info.html -- Regards Bharat ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata 2015-06-23 11:34 ` Bharat Bhusan Panda @ 2015-06-23 12:53 ` Luiz Augusto von Dentz 0 siblings, 0 replies; 6+ messages in thread From: Luiz Augusto von Dentz @ 2015-06-23 12:53 UTC (permalink / raw) To: Bharat Bhusan Panda; +Cc: linux-bluetooth@vger.kernel.org, cpgs Hi Bharat, On Tue, Jun 23, 2015 at 2:34 PM, Bharat Bhusan Panda <bharat.panda@samsung.com> wrote: > Hi Luiz, > >> -----Original Message----- >> From: linux-bluetooth-owner@vger.kernel.org [mailto:linux-bluetooth- >> owner@vger.kernel.org] On Behalf Of Luiz Augusto von Dentz >> Sent: Tuesday, June 23, 2015 2:09 PM >> To: Bharat Bhusan Panda >> Cc: linux-bluetooth@vger.kernel.org; cpgs@samsung.com >> Subject: Re: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata >> >> Hi Bharat, >> >> On Fri, Jun 19, 2015 at 12:45 PM, Bharat Bhusan Panda >> <bharat.panda@samsung.com> wrote: >> > ping >> > >> >> -----Original Message----- >> >> From: Bharat Bhusan Panda [mailto:bharat.panda@samsung.com] >> >> Sent: Thursday, June 11, 2015 11:14 AM >> >> To: 'linux-bluetooth@vger.kernel.org' >> >> Cc: 'cpgs@samsung.com' >> >> Subject: RE: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata >> >> >> >> ping >> >> >> >> > -----Original Message----- >> >> > From: linux-bluetooth-owner@vger.kernel.org >> >> > [mailto:linux-bluetooth- owner@vger.kernel.org] On Behalf Of Bharat >> >> > Panda >> >> > Sent: Friday, June 05, 2015 8:44 PM >> >> > To: linux-bluetooth@vger.kernel.org >> >> > Cc: cpgs@samsung.com; Bharat Panda >> >> > Subject: [PATCH ] AVRCP: Handle Total Number Of Tracks metadata >> >> > >> >> > Total Number of Tracks was not displayed, coz "Number of Tracks" >> >> > was not handled in metadata parser. >> >> > --- >> >> > profiles/audio/media.c | 3 +++ >> >> > tools/mpris-proxy.c | 3 +++ >> >> > 2 files changed, 6 insertions(+) >> >> > >> >> > diff --git a/profiles/audio/media.c b/profiles/audio/media.c index >> >> > f12569e..8e7e1a3 100644 >> >> > --- a/profiles/audio/media.c >> >> > +++ b/profiles/audio/media.c >> >> > @@ -1510,6 +1510,9 @@ static gboolean parse_player_metadata(struct >> >> > media_player *mp, >> >> > } else if (strcasecmp(key, "xesam:trackNumber") == 0) { >> >> > if (!parse_int32_metadata(mp, "TrackNumber", >> >> > &var)) >> >> > return FALSE; >> >> > + } else if (strcasecmp(key, "xesam:totalTracks") == 0) { >> >> > + if (!parse_int32_metadata(mp, "NumberOfTracks", >> >> > &var)) >> >> > + return FALSE; >> >> > } else >> >> > DBG("%s not supported, ignoring", key); >> >> > >> >> > diff --git a/tools/mpris-proxy.c b/tools/mpris-proxy.c index >> >> > 693055e..5749427 >> >> > 100644 >> >> > --- a/tools/mpris-proxy.c >> >> > +++ b/tools/mpris-proxy.c >> >> > @@ -1261,6 +1261,9 @@ static int parse_track_entry(DBusMessageIter >> >> > *entry, const char *key, >> >> > } else if (strcasecmp(key, "TrackNumber") == 0) { >> >> > if (!parse_int32_metadata(&var, "xesam:trackNumber", >> >> > metadata)) >> >> > return -EINVAL; >> >> > + } else if (strcasecmp(key, "NumberOfTracks") == 0) { >> >> > + if (!parse_int32_metadata(&var, "xesam:totalTracks", >> >> > metadata)) >> >> > + return -EINVAL; >> >> I remember not finding any documentation for xesam:totalTracks do you >> have a link for it? If you could you please add to the description. > I don’t have any xesam or freedesktop reference for "xesam:totalTracks ", but I tried with "xesam:totalTracks" to get NumberOfTracks parsed and it works well to get it displayed. That is not my argument, my concern is that we should not make it xesam: if that doesn't exist, instead it should be bluetooth:/avrcp: if we are to create a new one that does not exist already. >> >> >> > } else if (strcasecmp(key, "Item") == 0) { >> >> > if (!parse_path_metadata(&var, "mpris:trackid", metadata)) >> >> > return -EINVAL; >> >> > -- >> >> > 1.9.1 >> >> > >> >> > -- >> >> > To unsubscribe from this list: send the line "unsubscribe >> >> > linux-bluetooth" in the body of a message to >> >> > majordomo@vger.kernel.org More majordomo info at >> >> > http://vger.kernel.org/majordomo-info.html >> > >> > -- >> > To unsubscribe from this list: send the line "unsubscribe >> > linux-bluetooth" in the body of a message to majordomo@vger.kernel.org >> > More majordomo info at http://vger.kernel.org/majordomo-info.html >> >> >> >> -- >> Luiz Augusto von Dentz >> -- >> To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in >> the body of a message to majordomo@vger.kernel.org More majordomo >> info at http://vger.kernel.org/majordomo-info.html > > -- > Regards > Bharat > -- Luiz Augusto von Dentz ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2015-06-23 12:53 UTC | newest] Thread overview: 6+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2015-06-05 15:13 [PATCH ] AVRCP: Handle Total Number Of Tracks metadata Bharat Panda 2015-06-11 5:44 ` Bharat Bhusan Panda 2015-06-19 9:45 ` Bharat Bhusan Panda 2015-06-23 8:39 ` Luiz Augusto von Dentz 2015-06-23 11:34 ` Bharat Bhusan Panda 2015-06-23 12:53 ` Luiz Augusto von Dentz
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).