Re: Need to information to implement a media player

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thanks for your answers!

>> - is it OK to open a stream as soon as the application starts, even if
>> no sound will be eventually played? Or should I open a stream only
>> when a song is requested to be played and close it once it has
>> finished?
>
>Can you enforce the same audio format throughout the application
>lifetime? It seems saner to keep the PA mainloop and the PA context for
>the whole application, but create a new stream only when you start
>playback. You can do either way though.

Yes, actually I use ffmpeg under the hood to decode the files to a user defined format (defaulting to s16le / 44.1khz / stereo)
Ok, I will try to open/close the stream when the user start/stop the player.


>> - is it OK to use a single stream for several songs or is it better to
>> use separate streams, one for each song?
>
>You can of course do that. If you implement cross-fading, it's even hard
>to avoid. Remember to update the stream meta-data though.


Ok! Keeping the same stream makes the usage of pa_stream_get_time more complicated (but it's already complicated since the user can scroll within the songs).
Could you please elaborate more on meta data? I don't find any reference of this in the doc.
_______________________________________________
pulseaudio-discuss mailing list
pulseaudio-discuss@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/pulseaudio-discuss




[Index of Archives]     [Linux Audio Users]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux