Hello...<br><br><div class="gmail_quote">On 12 August 2012 13:33, Alexey Sokolov <span dir="ltr"><<a href="mailto:alexey@asokolov.org" target="_blank">alexey@asokolov.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
12.08.2012 19:29, Rémi Denis-Courmont пишет:<br>
<div class="im">> Le dimanche 12 août 2012 13:49:37 Alexey Sokolov, vous avez écrit :<br>
>> Hello.<br>
>><br>
>> 12.08.2012 15:30, Mark Lee пишет:<br>
>>> +/**<br>
>>> + * Create a new default equalizer, with all frequency values zeroed.<br>
>>> + *<br>
>>> + * The new equalizer can subsequently be associated with a media player<br>
>>> by using + * libvlc_media_player_set_equalizer().<br>
>>> + *<br>
>>> + * When the application is finished with a particular equalizer instance<br>
>>> it should + * disassociate it from the media player by invoking<br>
>>> libvlc_media_player_set_equalizer(NULL) + * and then free it by using<br>
>>> libvlc_audio_equalizer_release().<br>
>>> + *<br>
>> Why not to use reference count, as other libvlc objects do?<br>
> Why use a reference count? This is just plain (small) data.<br>
><br>
> Way overkill.<br>
><br>
</div>To not to need to maintain validness of the pointer ourself.<br>
If it's so small data, why not to store it inside the media_player<br>
completely instead?<br>
media_player would just memcpy the data to its field.<br></blockquote><div><br>I think one idea was that potentially an equalizer instance could be shared amongst multiple media players, so making a copy would not work if that were the case. That idea maybe strengthens the argument for a refcount.<br>
 <br>Anyway, I am happy to implement this whichever way. <br><br>I have a new patch that addresses all of the comments made so far except for this refcount issue, but I'll hold off submitting it to see where this discussion goes.<br>
<br></div></div>