using System.Collections;
|
using System.Collections.Generic;
|
using System.Runtime.InteropServices;
|
|
public static class OpusNative
|
{
|
#if UNITY_ANDROID || UNITY_EDITOR || UNITY_STANDALONE
|
[DllImport("opus")]
|
#elif UNITY_IOS
|
[DllImport("__Internal")]
|
#endif
|
public static extern int native_opus_encode(short[] pcm, int len, byte[] opus);
|
|
#if UNITY_ANDROID || UNITY_EDITOR || UNITY_STANDALONE
|
[DllImport("opus")]
|
#elif UNITY_IOS
|
[DllImport("__Internal")]
|
#endif
|
public static extern int native_opus_decode(byte[] opus, int len, short[] pcm);
|
}
|