Re: [PATCH] sscape: drop redundant fields from soundscape struct

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

 



At 02 Feb 2009 09:20:11 +0100,
krzysztof.h1@xxxxxxxxx wrote:
> 
> Takashi Iwai napisał(a):
> > At Sun, 1 Feb 2009 21:12:31 +0100,
> > Krzysztof Helt wrote:
> > > 
> > > The midi_vol is set only to 0 so it does not work
> > > as detection of change in midi volume. It is removed.
> > 
> > It's used to cache the value.  You should better to keep it, but fix
> > sscape_midi_put() function to remember the last
> > uctl->value.integer.value[0] value in this field.
> 
> I know that it was supposed to cache the volume value, but is it really needed?

Yes, if it's possible, it's always better.  get/put callbacks are
called relatively often.  It's no time-critical path, but the
frequency isn't negligible.

> It is not something time critical and the less code the better.

The code will be shorter since it simplifies the get callback, too.


Takashi

> > (And also better to change sscape_midi_get() to return midi_vol
> >  value.)
> > 
> Ok.
> 
> Regards,
> Krzysztof
> 
> ----------------------------------------------------------------------
> Doladuj telefon!
> Sprawdz >> http://link.interia.pl/f2047
> 
_______________________________________________
Alsa-devel mailing list
Alsa-devel@xxxxxxxxxxxxxxxx
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel


[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux