Opened 8 years ago

Closed 8 years ago

#126 closed enhancement (fixed)

libroar's memory buffer API should fully use a reference counter

Reported by: ph3-der-loewe Owned by: ph3-der-loewe
Priority: major Milestone: RoarAudio major release 1.0
Component: libroar and friends Version: 1.0beta0
Keywords: soname_change Cc:
Architecture: Compiler:
Difficulty: normal Kernel:
Operating System: Parent Tickets:
Patch attached: no Protocol:
Sound driver: Topic: New feature

Description

libroar's memory buffer API ('struct roar_buffer*') should fully use a reference counter. Currently it is only used partly and not very functional.

This requires soname change.

Subtickets

Change History (8)

comment:1 Changed 8 years ago by ph3-der-loewe

  • Difficulty set to normal

comment:2 Changed 8 years ago by ph3-der-loewe

  • Priority changed from medium to major

comment:3 Changed 8 years ago by ph3-der-loewe

  • Owner set to ph3-der-loewe
  • Status changed from new to accepted

Relevant functions (functions changing behaver) are:
roar_buffer_delete, roar_buffer_add, roar_buffer_get_next.
In addition calls to roar_buffer_shift_out may be relevant to porters as well.

comment:4 Changed 8 years ago by ph3-der-loewe

  • A function which does what roar_buffer_add does currently should be added: append buffer and destroy local pointer
  • roar_buffer_get_next is often used for a foreach construct. There should be a macro doing this with the new roar_buffer_get_next.
  • roar_buffer_next should be converted into a function implementing the right ref/unref ops.

comment:5 Changed 8 years ago by ph3-der-loewe

  • roar_buffer_next() as been converted to a function.
  • roar_buffer_moveinto() as created which is currently an alias to roar_buffer_add() but will be independed as soon as roar_buffer_add()'s behaver will change.

comment:6 Changed 8 years ago by ph3-der-loewe

  • Status changed from accepted to assigned

comment:7 Changed 8 years ago by ph3-der-loewe

added a macro roar_buffer_foreach(){}.

comment:8 Changed 8 years ago by ph3-der-loewe

  • Resolution set to fixed
  • Status changed from assigned to closed
  • Version changed from current to 1.0beta0
Note: See TracTickets for help on using tickets.