Project Home
Project Home
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - How to get the playlist?: (16 Items)
   
How to get the playlist?  
Hello all!
     I want to get the playlist,want do I need to do ?
can you give me the process? 
 Thanks very much!
Re: How to get the playlist?  
I'm not sure, but maybe mme_trksessionview_readx() is what you want? 
You can use this function to see what MME has in its tracksession view 
(what it is going to play, and in what order).

-- 
Ryan J. Allen
QNX Software Systems
Re: How to get the playlist?  
Hi Allen!
     I use the function as you said :

 int mme_trksessionview_readx( mme_hdl_t *hdl,
                              unsigned type,
                              int offset,
                              unsigned ntracks,
                              void *buf,
                              unsigned *buflen );


I get  a path from the buf,it dosen't a list of song file and songinfo,but I want to get the playlist inclued all mp3 
name and their artist.please give me some ideal.
thanks!
Re: How to get the playlist?  
Try:

qdbc -dmme "select * from trksessionview"

Is there a list of fids output? If so, then assuming your tracksessionid is 3, you could do the following to get a list 
of fid,titles:

qdbc -dmme "select fid, title from library where fid IN (select fid from trksessionview where trksessionid=3"

You can so the same qdbc does in your C code.

You can extend the state to join with library_artists for example and also retrieve the artist name.

Regards,
Gilles
Re: How to get the playlist?  
thanks for your reply!
    I have done as you said,but the title value is null,please give me some advice.
The resultt is as follow,thanks!


# mmecli resync_mediastore 1 2
(rc=0,errno=0) Starting a resync of msid=1, folderid=0, passmask=0x0002..  Execu
tion Time=0.007
# mmecli play 5
(rc=0,errno=0) Playing from tracksession fid/bid = 5.  Execution Time=0.559
# mmecli resync_mediastore 1 2
(rc=0,errno=0) Starting a resync of msid=1, folderid=0, passmask=0x0002..  Execu
tion Time=0.007
# qdbc -dmme "select * from nowplaying"
Rows: 1  Cols: 26
Names:  +ccid+playing+fid+msid+ftype+copyright+year+bitrate+samplerate+num_chann
els+size+discnum+tracknum+copied_fid+filename+artist+title+album+genre+composer+
conductor+soloist+ensemble+opus+category+description+
00000:  |1|0|5|1|1|0|0|0|0|0|3244728|0|0|0|Big Big World.mp3|Unknown Artist|[NUL
L]|Unknown Album|Unknown Genre|Unknown Composer|||||Unknown Category||
# qdbc -dmme "select * from trksessionview"
Rows: 14  Cols: 4
Names:  +sequentialid+fid+trksessionid+randomid+
00000:  |43|1|2|9|
00001:  |44|2|2|0|
00002:  |45|3|2|2|
00003:  |46|4|2|10|
00004:  |47|5|2|4|
00005:  |48|6|2|6|
00006:  |49|7|2|3|
00007:  |50|8|2|11|
00008:  |51|9|2|13|
00009:  |52|10|2|8|
00010:  |53|11|2|1|
00011:  |54|12|2|7|
00012:  |55|13|2|5|
00013:  |56|14|2|12|
# qdbc -dmme "select fid,title from library where fid IN(select fid from trksess
ionview where trksessionid=2)"
Rows: 14  Cols: 2
Names:  +fid+title+
00000:  |1|HardDrive|
00001:  |2|[NULL]|
00002:  |3|[NULL]|
00003:  |4|[NULL]|
00004:  |5|[NULL]|
00005:  |6|[NULL]|
00006:  |7|[NULL]|
00007:  |8|[NULL]|
00008:  |9|[NULL]|
00009:  |10|[NULL]|
00010:  |11|[NULL]|
00011:  |12|[NULL]|
00012:  |13|[NULL]|
00013:  |14|[NULL]|
#
Re: How to get the playlist?  
I suspect that you don't have a parser for the .mp3 file you are trying to play. I believe you need mpega_parser.so on 
the system, do you have it?

I don't know if it is freely available from the foundry, as there are patent and licensing issues.


Regards,
Gilles 
Re: How to get the playlist?  
It's also possible your file does not have ID3 tags for the metadata you are looking for.   It's a good idea to ensure 
that the file you are testing has tags inside it.
Re: How to get the playlist?  
Hi,roy!
      I have examin the lib/dll/media ,there are mpega_parser.so,aac_parser.so  and so on ,but xing_mpega_decoder.so is 
not good for mp3. Otherwise, the ID3 tag is  complete.
      Does xing_mpega_decoder.so affect the song Info(title,artist ,etc) parsing ,please give me idea,thanks!
     the log is as follow:
     fully found metadata for group 00000002 from "/media/drive/老人与海.mp3".
Jan 01 00:03:08    2    27     0 MME:mss_bfs_sync_pass2(1772): msid=1, sync file
 failed CONTINUE
Jan 01 00:03:08    6    20     1 io-media-generic/trackplayer: Created graph ins
tance 'mdp_session_39'
Jan 01 00:03:08    6    20     1 io-media-generic: open( 'graphs/trackplayer/mdp
_session_39' ): success
Jan 01 00:03:08    3    20     1 io-media-generic/trackplayer: received invalid
dcmd (C0580F12)
Jan 01 00:03:08    2    27   200 MDP:metadata_get(838): Failed iom_get_track_inf
o, errno = 22
Jan 01 00:03:08    3    27   200 MDP:mdp_mgr_metadata_get(980): Error getting me
tadata for group 00000002 from "/media/drive/再见.mp3": An external resource cal
l used by the MDP failed. (10).
Jan 01 00:03:08    6    20     1 io-media-generic/trackplayer: Destroyed graph i
nstance 'mdp_session_39'
Jan 01 00:03:08    2    27   200 MDP:mdp_mgr_metadata_get(1010): No MDPs success
fully found metadata for group 00000002 from "/media/drive/再见.mp3".
Jan 01 00:03:08    2    27     0 MME:mss_bfs_sync_pass2(1772): msid=1, sync file
 failed CONTINUE
Jan 01 00:03:08    6    20     1 io-media-generic/trackplayer: Created graph ins
tance 'mdp_session_40'
Jan 01 00:03:08    6    20     1 io-media-generic: open( 'graphs/trackplayer/mdp
_session_40' ): success
Jan 01 00:03:08    3    20     1 io-media-generic/trackplayer: received invalid
dcmd (C0580F12)
Jan 01 00:03:08    2    27   200 MDP:metadata_get(838): Failed iom_get_track_inf
o, errno = 22
Jan 01 00:03:08    3    27   200 MDP:mdp_mgr_metadata_get(980): Error getting me
tadata for group 00000002 from "/media/drive/叱咤红人.mp3": An external resource
 call used by the MDP failed. (10).
Jan 01 00:03:08    6    20     1 io-media-generic/trackplayer: Destroyed graph i
nstance 'mdp_session_40'
Jan 01 00:03:08    2    27   200 MDP:mdp_mgr_metadata_get(1010): No MDPs success
fully found metadata for group 00000002 from "/media/drive/叱咤红人.mp3".
Jan 01 00:03:08    2    27     0 MME:mss_bfs_sync_pass2(1772): msid=1, sync file
 failed CONTINUE
#
Re: How to get the playlist?  
This looks like you may have mismatched/corrupted binaries.  The invalid DCMD warning from io-media means it recieved 
garbage from the MME.  Did you mix build environments when building the components by any chance?
Re: How to get the playlist?  
Hi all!
     Thanks for your reply.I didin't mix build environments when building the components .I can't synchronize the 
metadata successfully.Please give me advices.
I am looking forward your reply,thanks!
RE: How to get the playlist?  
Try:
  1.  post the output of
          use -i mme-generic
          use -i io-media-generic
          ls -l /lib/dll/media

  2. using a different set of MP3-s that don't have chinese characters
in the filename
  3. a different set of files that were produced using another tool
  4. increasing the verbosity of mme-generic and io-media:

          io-media-generic -DDDDD -S
          mme-generic -D -vvvvvv -s

and post the logs. 


--
  Mate

-----Original Message-----
From: Xiaolong Zhang [mailto:community-noreply@qnx.com] 
Sent: April 6, 2010 7:14 PM
To: general-multimedia
Subject: How to get the playlist?

Hello all!
     I want to get the playlist,want do I need to do ?
can you give me the process? 
 Thanks very much!



_______________________________________________

General
http://community.qnx.com/sf/go/post51192
Re: RE: How to get the playlist?  
Hi Mate  !
    I hanve done as you said ,the log is as follow,please give me advices,thanks very much.


# use -i mme-generic
NAME=mme-generic
DESCRIPTION=MME Generic build
DATE=2008/10/16-01:41:43-EDT
STATE=experimental
HOST=ccbuild
USER=builder
VERSION=9999
TAGID=9999


# use -i io-media-generic
NAME=io-media-generic
DESCRIPTION=TEST io-media system
DATE=2008/10/17-12:31:41-EDT
STATE=Experimental
HOST=QNXWS7728
USER=aboak

# ls -l /lib/dll/media
aac_parser.so                          rawfile_writer.so
ade3_writer.so                         stream_reader.so
audio_streamer.so                      tmpfile_streamer.so
audio_writer.so                        wav_parser.so
cdda_parser.so                         wavfile_writer.so
cdda_streamer.so                       wma9_decoder.so
fildes_streamer.so                     wma9_parser.so
fraunhofer_mp3_decoder.so              wms_control.so
media_streamer.so                      wms_streamer.so
mp4_parser.so                          xing_mpega_decoder.so.notgoodformp3
mpega_parser.so
queue_filter.so
#
# io-media-generic -DDDDD -S
io-media-generic: Initializing module 'aoi'
io-media-generic: Initializing module 'registry'
io-media-generic/registry: Initializing ctrlpnt 'registry'
io-media-generic: Initializing module 'mmf'
io-media-generic/mmf: Could not load the "audio_writer" DLL
io-media-generic: Initialization of module mmf failed
# mme-generic -D -vvvvv -s
00:15:13 | INFO | conf_init                    |801 | No configuration found; us
ing internal defaults.
00:15:13 | WARN | mme_load_mds                 |114 | No dynamic MDS libraries c
onfigured
00:15:13 | WARN | mme_load_mmdev               |216 | No dynamic MMDEV libraries
 configured
00:15:13 | INFO | mdp_mgr_init                 |312 | Starting metadata plug-in
initialization.
00:15:13 | INFO | init                         |87  | Initializing MDP 'cdtext'.

00:15:13 | INFO | mmpl_connect                 |226 | Thread 1 connecting to dat
abase.
00:15:14 | INFO | mmpl_connect                 |237 | Thread 1 connected to data
base.
00:15:14 | INFO | mss_ipod_init                |346 | Initializing MSS 'ipod'.
00:15:14 | INFO | mss_nosync_init              |64  | Initializing MSS 'nosync'.

00:15:14 | WARN | mss_nosync_init              |72  | No configuration element f
ound for MSS 'nosync'.
00:15:14 | INFO | none_init                    |33  | Initializing MDS 'none'.
00:15:15 | WARN | conf_get_str_from_element    |1296| "Locale" set to "en" (defa
ult).
00:15:16 | INFO | mmpl_locale_set              |3608| Set locale to 'en'.
00:15:16 | INFO | mmpl_disconnect              |453 | Thread 1 disconnecting fro
m database.
00:15:16 | INFO | mmpl_connect                 |226 | Thread 1 connecting to dat
abase.
00:15:16 | INFO | mmpl_connect                 |237 | Thread 1 connected to data
base.
00:15:16 | INFO | cc_global_init               |331 | mme_iom_resource_max_len 1
0
00:15:16 | INFO | mmpl_connect                 |226 | Thread 1 connecting to dat
abase.
00:15:16 | INFO | mmpl_connect                 |237 | Thread 1 connected to data
base.
00:15:16 | INFO | db_cleanup_start             |340 | Database clean-up thread i
s being started.
00:15:16 | INFO | db_cleanup_start             |383 | Set clean-up thread priori
ty to 6.
00:15:16 | INFO | mmpl_connect                 |226 | Thread 1 connecting to dat
abase.
00:15:17 | INFO | mmpl_connect                 |237 | Thread 1 connected to data
base.
00:15:17 | CRIT | mdi_init                     |1597| Temporary data store '' is
 not writable
00:15:17 | INFO | mmpl_connect                 |226 | Thread 4 connecting to dat
abase.
00:15:17 | CRIT | mme_main                     |451 | Unable to initialize the m
etadata interface.
#
Re: RE: How to get the playlist?  
You will want to get an official release of the product.  If not sure how to do that then it's best to talk to your QNX 
sales rep.

----- Original Message -----
From: Xiaolong Zhang <community-noreply@qnx.com>
To: general-multimedia <post51517@community.qnx.com>
Sent: Tue Apr 13 05:05:13 2010
Subject: Re: RE: How to get the playlist?

Hi Mate  !
    I hanve done as you said ,the log is as follow,please give me advices,thanks very much.


# use -i mme-generic
NAME=mme-generic
DESCRIPTION=MME Generic build
DATE=2008/10/16-01:41:43-EDT
STATE=experimental
HOST=ccbuild
USER=builder
VERSION=9999
TAGID=9999


# use -i io-media-generic
NAME=io-media-generic
DESCRIPTION=TEST io-media system
DATE=2008/10/17-12:31:41-EDT
STATE=Experimental
HOST=QNXWS7728
USER=aboak

# ls -l /lib/dll/media
aac_parser.so                          rawfile_writer.so
ade3_writer.so                         stream_reader.so
audio_streamer.so                      tmpfile_streamer.so
audio_writer.so                        wav_parser.so
cdda_parser.so                         wavfile_writer.so
cdda_streamer.so                       wma9_decoder.so
fildes_streamer.so                     wma9_parser.so
fraunhofer_mp3_decoder.so              wms_control.so
media_streamer.so                      wms_streamer.so
mp4_parser.so                          xing_mpega_decoder.so.notgoodformp3
mpega_parser.so
queue_filter.so
#
# io-media-generic -DDDDD -S
io-media-generic: Initializing module 'aoi'
io-media-generic: Initializing module 'registry'
io-media-generic/registry: Initializing ctrlpnt 'registry'
io-media-generic: Initializing module 'mmf'
io-media-generic/mmf: Could not load the "audio_writer" DLL
io-media-generic: Initialization of module mmf failed
# mme-generic -D -vvvvv -s
00:15:13 | INFO | conf_init                    |801 | No configuration found; us
ing internal defaults.
00:15:13 | WARN | mme_load_mds                 |114 | No dynamic MDS libraries c
onfigured
00:15:13 | WARN | mme_load_mmdev               |216 | No dynamic MMDEV libraries
 configured
00:15:13 | INFO | mdp_mgr_init                 |312 | Starting metadata plug-in
initialization.
00:15:13 | INFO | init                         |87  | Initializing MDP 'cdtext'.

00:15:13 | INFO | mmpl_connect                 |226 | Thread 1 connecting to dat
abase.
00:15:14 | INFO | mmpl_connect                 |237 | Thread 1 connected to data
base.
00:15:14 | INFO | mss_ipod_init                |346 | Initializing MSS 'ipod'.
00:15:14 | INFO | mss_nosync_init              |64  | Initializing MSS 'nosync'.

00:15:14 | WARN | mss_nosync_init              |72  | No configuration element f
ound for MSS 'nosync'.
00:15:14 | INFO | none_init                    |33  | Initializing MDS 'none'.
00:15:15 | WARN | conf_get_str_from_element    |1296| "Locale" set to "en" (defa
ult).
00:15:16 | INFO | mmpl_locale_set              |3608| Set locale to 'en'.
00:15:16 | INFO | mmpl_disconnect              |453 | Thread 1 disconnecting fro
m database.
00:15:16 | INFO | mmpl_connect                 |226 | Thread 1 connecting to dat
abase.
00:15:16 | INFO | mmpl_connect                 |237 | Thread 1 connected to data
base.
00:15:16 | INFO | cc_global_init               |331 | mme_iom_resource_max_len 1
0
00:15:16 | INFO | mmpl_connect                 |226 | Thread 1 connecting to dat
abase.
00:15:16 | INFO | mmpl_connect                 |237 | Thread 1 connected to data
base.
00:15:16 | INFO | db_cleanup_start             |340 | Database clean-up thread i
s being started.
00:15:16 | INFO | db_cleanup_start             |383 | Set clean-up thread priori
ty to 6.
00:15:16 | INFO | mmpl_connect                 |226 | Thread 1 connecting to dat
abase.
00:15:17 | INFO | mmpl_connect                 |237 | Thread 1 connected to data
base.
00:15:17 | CRIT | mdi_init                     |1597| Temporary data store '' is
 not...
View Full Message
Re: RE: How to get the playlist?  
Thanks for your reply!Can you tell me the reason why the  sync of metadata is failed?
       thanks!
Re: RE: How to get the playlist?  
> # use -i mme-generic
> NAME=mme-generic
> DESCRIPTION=MME Generic build
> DATE=2008/10/16-01:41:43-EDT
> STATE=experimental
> HOST=ccbuild
> USER=builder
> VERSION=9999
> TAGID=9999

This MME version above is experimental, where did you get this?

> # use -i io-media-generic
> NAME=io-media-generic
> DESCRIPTION=TEST io-media system
> DATE=2008/10/17-12:31:41-EDT
> STATE=Experimental
> HOST=QNXWS7728
> USER=aboak

This is also experimental, it probably has a header file mismatch with the mme-generic, such that both are having 
communication problems.


Also, all of these are dated 2008, I wonder where they came from? Without knowing exactly where you got these from, all 
I can say is that you probably need to try to find a specific release (like Aviage 1.2) and take all of the binaries 
from there.

Regards,
Gilles
Re: RE: How to get the playlist?  
Hi roy!

       Thanks very much for your reply,I have changed the Binary files with the release version of mme-core-1.2 .As a 
result ,the sync is successful.