Skip to content

Commit

Permalink
Clarify access pattern from the plugin side
Browse files Browse the repository at this point in the history
  • Loading branch information
jatinchowdhury18 committed Oct 17, 2024
1 parent 1b1a68e commit f2a84b9
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions include/clap/ext/draft/scratch-memory.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,14 @@ typedef struct clap_host_scratch_memory {
// when scratch memory was requested then this method should return
// null.
//
// This method may only be called by the plugin from the audio thread,
// (i.e. during the process() or thread_pool.exec() callback), and
// the provided memory is only valid until the plugin returns from
// that callback. The plugin must not hold any references to data
// that lives in the scratch memory after returning from the callback,
// as that data will likely be over-written by another plugin using
// the same scratch memory.
//
// The provided memory is not initialized, and may have been used
// by other plugin instances, so the plugin must correctly initialize
// the memory when using it.
Expand Down

0 comments on commit f2a84b9

Please sign in to comment.