From e19b3701260d4a855736c623b8c8a270413f041e Mon Sep 17 00:00:00 2001 From: Fabio Alessandrelli Date: Wed, 22 Sep 2021 23:16:23 +0200 Subject: Use libdatachannel library, add Godot 4 support. --- misc/gdnlib.tres | 28 ---------------------------- misc/scripts/file_format.sh | 2 ++ misc/webrtc.gdextension | 18 ++++++++++++++++++ misc/webrtc.tres | 28 ++++++++++++++++++++++++++++ 4 files changed, 48 insertions(+), 28 deletions(-) delete mode 100644 misc/gdnlib.tres create mode 100644 misc/webrtc.gdextension create mode 100644 misc/webrtc.tres (limited to 'misc') diff --git a/misc/gdnlib.tres b/misc/gdnlib.tres deleted file mode 100644 index eb291a9..0000000 --- a/misc/gdnlib.tres +++ /dev/null @@ -1,28 +0,0 @@ -[gd_resource type="GDNativeLibrary" format=2] - -[resource] -singleton = true -reloadable = false -entry/OSX.64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.osx.{TARGET}.64.dylib" -entry/OSX.arm64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.osx.{TARGET}.arm64.dylib" -entry/Windows.64 = "res://{GDNATIVE_PATH}/lib/webrtc_native.windows.{TARGET}.64.dll" -entry/Windows.32 = "res://{GDNATIVE_PATH}/lib/webrtc_native.windows.{TARGET}.32.dll" -entry/X11.64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.linux.{TARGET}.64.so" -entry/X11.32 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.linux.{TARGET}.32.so" -entry/Server.64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.linux.{TARGET}.64.so" -entry/Server.32 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.linux.{TARGET}.32.so" -entry/Android.armeabi-v7a = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.android.{TARGET}.armv7.so" -entry/Android.arm64-v8a = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.android.{TARGET}.arm64v8.so" -entry/Android.x64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.android.{TARGET}.x86_64.so" -entry/Android.x86 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.android.{TARGET}.x86.so" -entry/iOS.armv7 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.ios.{TARGET}.armv7.dylib" -entry/iOS.arm64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.ios.{TARGET}.arm64.dylib" -entry/iOS.x86_64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.ios.{TARGET}.x86_64.dylib" -dependency/Windows.64 = [ ] -dependency/Windows.32 = [ ] -dependency/X11.64 = [ ] -dependency/X11.32 = [ ] -dependency/Server.64 = [ ] -dependency/Server.32 = [ ] -dependency/Android.armeabi-v7a = [ ] -dependency/Android.arm64-v8a = [ ] diff --git a/misc/scripts/file_format.sh b/misc/scripts/file_format.sh index e6e1fe2..3bb4d8d 100755 --- a/misc/scripts/file_format.sh +++ b/misc/scripts/file_format.sh @@ -20,6 +20,8 @@ while IFS= read -rd '' f; do continue elif [[ "$f" == "godot-cpp"* ]]; then continue + elif [[ "$f" == "misc/patches"* ]]; then + continue fi # Ensure that files are UTF-8 formatted. recode UTF-8 "$f" 2> /dev/null diff --git a/misc/webrtc.gdextension b/misc/webrtc.gdextension new file mode 100644 index 0000000..a00d370 --- /dev/null +++ b/misc/webrtc.gdextension @@ -0,0 +1,18 @@ +[configuration] + +entry_symbol = "webrtc_extension_init" + +[libraries] + +linux.x86_64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.linux.{TARGET}.x86_64.so" +linux.x86_32 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.linux.{TARGET}.x86_32.so" +osx.x86_64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.osx.{TARGET}.x86_64.dylib" +osx.arm64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.osx.{TARGET}.arm64.dylib" +windows.x86_64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.windows.{TARGET}.x86_64.dll" +windows.x86_32 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.windows.{TARGET}.x86_32.dll" +android.arm64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.android.{TARGET}.arm64.so" +android.arm32 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.android.{TARGET}.arm32.so" +android.x86_64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.android.{TARGET}.x86_64.so" +android.x86_32 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.android.{TARGET}.x86_32.so" +ios.arm64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.ios.{TARGET}.arm64.dylib" +ios.x86_64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.ios.{TARGET}.x86_64.simulator.dylib" diff --git a/misc/webrtc.tres b/misc/webrtc.tres new file mode 100644 index 0000000..9519d9f --- /dev/null +++ b/misc/webrtc.tres @@ -0,0 +1,28 @@ +[gd_resource type="GDNativeLibrary" format=2] + +[resource] +singleton = true +reloadable = false +entry/OSX.64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.osx.{TARGET}.x86_64.dylib" +entry/OSX.arm64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.osx.{TARGET}.arm64.dylib" +entry/Windows.64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.windows.{TARGET}.x86_64.dll" +entry/Windows.32 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.windows.{TARGET}.x86_32.dll" +entry/X11.64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.linux.{TARGET}.x86_64.so" +entry/X11.32 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.linux.{TARGET}.x86_32.so" +entry/Server.64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.linux.{TARGET}.x86_64.so" +entry/Server.32 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.linux.{TARGET}.x86_32.so" +entry/Android.armeabi-v7a = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.android.{TARGET}.arm32.so" +entry/Android.arm64-v8a = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.android.{TARGET}.arm64.so" +entry/Android.x64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.android.{TARGET}.x86_64.so" +entry/Android.x86 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.android.{TARGET}.x86_32.so" +entry/iOS.armv7 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.ios.{TARGET}.armv32.dylib" +entry/iOS.arm64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.ios.{TARGET}.arm64.dylib" +entry/iOS.x86_64 = "res://{GDNATIVE_PATH}/lib/libwebrtc_native.ios.{TARGET}.x86_64.simulator.dylib" +dependency/Windows.64 = [ ] +dependency/Windows.32 = [ ] +dependency/X11.64 = [ ] +dependency/X11.32 = [ ] +dependency/Server.64 = [ ] +dependency/Server.32 = [ ] +dependency/Android.armeabi-v7a = [ ] +dependency/Android.arm64-v8a = [ ] -- cgit v1.2.3