[LAD] tree sort

Lieven Moors lievenmoors at gmail.com
Sun Oct 17 01:20:59 UTC 2010


On Sat, Oct 16, 2010 at 12:41:50PM +0200, lieven moors wrote:
> On Sat, Oct 16, 2010 at 11:06:19AM +0200, Jens M Andreasen wrote:
> > What you can do is, take an existing implementation and preallocate a
> > fixed number of objects in a linked list, like a stack. Then you pop off
> > the first object whereever there is a malloc() and push it on again
> > whereever there is a free()
> > 
> > 



Hi again,

I would like to ask another question related to this...

I would like to use libavl for the binary search tree,
and use a custom allocater. I didn't like reading the c++
custom allocator code...

One problem I have now, is that I would like to make some
modification that would allow me to use equal keys.

The idea is to make a tree of midi events for an arpeggiator
I'm working on, and use a period and frame field as key.

Could anyone give me a hint on how I could do this?

Thanks,

Lieven



More information about the Linux-audio-dev mailing list