attach method

Pointer<NativeFunction<C>> attach()

Registers this callback and returns its native function pointer.

Adds this to registry if not already present, then returns nativeFunction. Pass the result directly to the native attach API:

rl.Audio.AttachAudioMixedProcessor(callback.attach());

Implementation

Pointer<NativeFunction<C>> attach() {
  if (!registry.contains(this)) registry.add(this);
  return nativeFunction;
}