playing mp3 in a windows service

This forum is about all development around libVLC.
kevintcore
Blank Cone
Blank Cone
Posts: 16
Joined: 28 Jul 2011 21:28

playing mp3 in a windows service

Postby kevintcore » 24 May 2012 20:58

I am using libvlc in an application that runs as a service. It plays mp3 files among other formats.
I am using waveout because it does not require a desktop (an active session / logon). That is a requirement.
However the sound quality playing an mp3 file is poor. It is often choppy and garbled in places.

I can reproduce this with the VLC UI player by selecting waveOut. The sound quality of the mp3 file is just as bad.
Using the default output or directX both sound fine. However, from my understanding, those require a desktop so I can't use them in my service.
Does anyone have any suggestions?

kevintcore
Blank Cone
Blank Cone
Posts: 16
Joined: 28 Jul 2011 21:28

Re: playing mp3 in a windows service

Postby kevintcore » 24 May 2012 21:10

Update:
I have tried using vlc to convert my file to muLaw then playing in through the UI and it sounds equally as bad in waveout.

muLaw conversion:
vlc C:\temp\audio.mp3 :sout=#transcode{vcodec=none,vb=0,scale=0,acodec=mlaw,ab=16,channels=1,samplerate=32000}:standard{access=file,dst=audio.wav} vlc://quit

Rémi Denis-Courmont
Developer
Developer
Posts: 15268
Joined: 07 Jun 2004 16:01
VLC version: master
Operating System: Linux
Contact:

Re: playing mp3 in a windows service

Postby Rémi Denis-Courmont » 24 May 2012 23:17

Your symptoms sound like unstable latency measurements from the waveOut API. How to fix it? That is a million dollar question (a.k.a. I wish I knew).
Rémi Denis-Courmont
https://www.remlab.net/
Private messages soliciting support will be systematically discarded


Return to “Development around libVLC”

Who is online

Users browsing this forum: No registered users and 28 guests