Skip to content

Commit 1eddfbb

Browse files
committed
fix: wrong library name for non-windows platform
1 parent 19087f6 commit 1eddfbb

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Diff for: unity/Scripts/LibOpus.cs

+4-2
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,11 @@ namespace Libopus
88
{
99
public static class LibraryWrapper
1010
{
11+
#if UNITY_STANDALONE_WIN || UNITY_EDITOR_WIN
1112
const string dllName = "opus.dll";
12-
13+
#else
14+
const string dllName = "libopus";
15+
#endif
1316
public enum EncoderCtlID
1417
{
1518
SetApplicationRequest = 4000,
@@ -120,7 +123,6 @@ public enum EncoderCtlID
120123
[DllImport(dllName)]
121124
public static extern void opus_encoder_destroy(IntPtr encoder);
122125
#endregion
123-
124126
#region Decoder
125127
/// <summary>
126128
/// Allocates and initializes a decoder state.

0 commit comments

Comments
 (0)