Skip to content

iOS build instructions #16

@cheesymoo

Description

@cheesymoo

The provided documentation is lacking detail on how to load a Spatializer Plugin on a Unity app that target iOS.

The only working solution has been provided by the community: (via: https://discussions.unity.com/t/native-audio-plugin-bundle-does-not-work-on-ios/767945/3)

extern "C" {
// We have to manually register the Unity Audio Effect plugin.
struct UnityAudioEffectDefinition;
typedef int (*UnityPluginGetAudioEffectDefinitionsFunc)(
struct UnityAudioEffectDefinition*** descptr);
extern void UnityRegisterAudioPlugin(
UnityPluginGetAudioEffectDefinitionsFunc getAudioEffectDefinitions);
extern int UnityGetAudioEffectDefinitions(UnityAudioEffectDefinition*** definitionptr);

} // extern "C"

- (void)shouldAttachRenderDelegate {}
- (void)preStartUnity {
UnityRegisterAudioPlugin(UnityGetAudioEffectDefinitions);
}

Is this the recommended approach by Unity?

Earlier documentation suggests that the prefix audioplugin is sufficient for the plugins to be loaded, but this does not seem to the the case on embedded platforms.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions