How to play audio CD tracks with LibVLC

This forum is about all development around libVLC.
rz3001
New Cone
New Cone
Posts: 1
Joined: 30 Mar 2014 22:18

How to play audio CD tracks with LibVLC

Postby rz3001 » 31 Mar 2014 17:28

Hello there,
I'm trying to integrate libVLC in my app but I'm not being able to play audio CDs. I'm using PassLibVLC as a wrapper.
According to the help with the syntax cdda://[device] the CD can be played in VLC, that is not true at least for Windows, where the proper syntax is cdda:///[device] (example vlc cdda:///d:\ or vlc cdda:///d: is the valid syntax)
When I use the VLC syntax for the url in LibVCL the following events are triggered and nothing is played:
Stopped
MediaChanged
Opening
Buffering
EncounteredError (and nothing is returned by invoking libvlc_errmsg)
Same happens when using a libvlc_media_list_t_ptr.

Trying to play dvds it works great using the syntax dvd:///device.

Can anyone tellme how to use libvlc to play a specific track in an audio cds? and
How can I get the error message generated? I read in another post the the log routines have been disabled, is that true?

Kind regards

sherington
Cone that earned his stripes
Cone that earned his stripes
Posts: 491
Joined: 10 Sep 2008 11:57
VLC version: master
Operating System: Linux

Re: How to play audio CD tracks with LibVLC

Postby sherington » 31 Mar 2014 23:37

Essentially, you first "play" the device to get a list of tracks created as sub-items (nothing actually gets played here). This creates for you a libvlc_media_t instance for each sub-item, which you can get from the media player instance and play.

Please see https://forum.videolan.org/viewtopic.ph ... 81#p293563 for some hints, especially the part about Encountered Error.


Return to “Development around libVLC”

Who is online

Users browsing this forum: No registered users and 5 guests