[alsa-devel] [PATCH] compress: add support for gapless playback

Takashi Iwai tiwai at suse.de
Thu Feb 14 10:45:54 CET 2013


At Thu, 14 Feb 2013 15:02:45 +0530,
Vinod Koul wrote:
> 
> On Thu, Feb 14, 2013 at 10:13:57AM +0100, Takashi Iwai wrote:
> > At Thu, 14 Feb 2013 14:12:51 +0530,
> > Vinod Koul wrote:
> > > 
> > > this add new API for sound compress to support gapless playback.
> > > As noted in Documentation change, we add API to send metadata of encoder and
> > > padding delay to DSP. Also add API for indicating EOF and switching to
> > > subsequent track
> > > 
> > > Also bump the compress API version
> > > 
> > > Signed-off-by: Jeeja KP <jeeja.kp at intel.com>
> > > Signed-off-by: Vinod Koul <vinod.koul at intel.com>
> > > ---
> > >  v5:
> > > - update metadata value with 8 words
> > 
> > What's the reason behind this change?  I can think of metadata like EQ
> > parameters, but the magic number 8 is in question :)
> Yes the concern was that there might be an issue with parameters which are not
> single dwords, so 8 dwords was what came to my mind. 8 why, i picked the number
> :). Seems decent enough and not too big. For even bigger pparameters I was
> thinking to split..
> 
> If you think we should have 16/32 dwrods, am okay with it.

OK, I don't mind this change, so I can take it as is.

> > I'm no enthusiastic over minimalism like Apple, so I don't mind this
> > change, but just out of curiosity...
> > 
> > Also, another spot:
> > 
> > > @@ -145,6 +160,10 @@ struct snd_compr_codec_caps {
> > >  						struct snd_compr_codec_caps)
> > >  #define SNDRV_COMPRESS_SET_PARAMS	_IOW('C', 0x12, struct snd_compr_params)
> > >  #define SNDRV_COMPRESS_GET_PARAMS	_IOR('C', 0x13, struct snd_codec)
> > > +#define SNDRV_COMPRESS_SET_METADATA	_IOW('C', 0x14,\
> > > +						 struct snd_compr_metadata)
> > > +#define SNDRV_COMPRESS_GET_METADATA	_IOW('C', 0x15,\
> > > +						 struct snd_compr_metadata)
> Yes!
> > 
> > Isn't it _IOWR()?
> If this is only thing, let me send the update or you want a beverage :)

Another favor would be to have a bit more comments about the existing
metadata parameter definitions, namely, what's exactly expected, in
which unit, and how many values are used (now we have an array).
This can be put in either compress API document or a short comment in
the enum item definition.


Takashi


More information about the Alsa-devel mailing list