From f66cc7185e5124c0c12f547e3087230f79c46d74 Mon Sep 17 00:00:00 2001 From: Jacob Gelman <3182119+ladvoc@users.noreply.github.com> Date: Fri, 28 Mar 2025 15:58:16 +1100 Subject: [PATCH 1/5] Move .gitignore to Unity project directory --- .gitignore => LivekitUnitySampleApp/.gitignore | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .gitignore => LivekitUnitySampleApp/.gitignore (100%) diff --git a/.gitignore b/LivekitUnitySampleApp/.gitignore similarity index 100% rename from .gitignore rename to LivekitUnitySampleApp/.gitignore From 6b98bf16cebafe8da87d1a6174cb51f8a47d2df5 Mon Sep 17 00:00:00 2001 From: Jacob Gelman <3182119+ladvoc@users.noreply.github.com> Date: Fri, 28 Mar 2025 15:59:00 +1100 Subject: [PATCH 2/5] Add vscode configuration --- LivekitUnitySampleApp/.vscode/extensions.json | 5 ++ LivekitUnitySampleApp/.vscode/launch.json | 10 ++++ LivekitUnitySampleApp/.vscode/settings.json | 60 +++++++++++++++++++ 3 files changed, 75 insertions(+) create mode 100644 LivekitUnitySampleApp/.vscode/extensions.json create mode 100644 LivekitUnitySampleApp/.vscode/launch.json create mode 100644 LivekitUnitySampleApp/.vscode/settings.json diff --git a/LivekitUnitySampleApp/.vscode/extensions.json b/LivekitUnitySampleApp/.vscode/extensions.json new file mode 100644 index 0000000..ddb6ff8 --- /dev/null +++ b/LivekitUnitySampleApp/.vscode/extensions.json @@ -0,0 +1,5 @@ +{ + "recommendations": [ + "visualstudiotoolsforunity.vstuc" + ] +} diff --git a/LivekitUnitySampleApp/.vscode/launch.json b/LivekitUnitySampleApp/.vscode/launch.json new file mode 100644 index 0000000..da60e25 --- /dev/null +++ b/LivekitUnitySampleApp/.vscode/launch.json @@ -0,0 +1,10 @@ +{ + "version": "0.2.0", + "configurations": [ + { + "name": "Attach to Unity", + "type": "vstuc", + "request": "attach" + } + ] +} \ No newline at end of file diff --git a/LivekitUnitySampleApp/.vscode/settings.json b/LivekitUnitySampleApp/.vscode/settings.json new file mode 100644 index 0000000..d8cf83a --- /dev/null +++ b/LivekitUnitySampleApp/.vscode/settings.json @@ -0,0 +1,60 @@ +{ + "files.exclude": { + "**/.DS_Store": true, + "**/.git": true, + "**/.vs": true, + "**/.gitmodules": true, + "**/.vsconfig": true, + "**/*.booproj": true, + "**/*.pidb": true, + "**/*.suo": true, + "**/*.user": true, + "**/*.userprefs": true, + "**/*.unityproj": true, + "**/*.dll": true, + "**/*.exe": true, + "**/*.pdf": true, + "**/*.mid": true, + "**/*.midi": true, + "**/*.wav": true, + "**/*.gif": true, + "**/*.ico": true, + "**/*.jpg": true, + "**/*.jpeg": true, + "**/*.png": true, + "**/*.psd": true, + "**/*.tga": true, + "**/*.tif": true, + "**/*.tiff": true, + "**/*.3ds": true, + "**/*.3DS": true, + "**/*.fbx": true, + "**/*.FBX": true, + "**/*.lxo": true, + "**/*.LXO": true, + "**/*.ma": true, + "**/*.MA": true, + "**/*.obj": true, + "**/*.OBJ": true, + "**/*.asset": true, + "**/*.cubemap": true, + "**/*.flare": true, + "**/*.mat": true, + "**/*.meta": true, + "**/*.prefab": true, + "**/*.unity": true, + "build/": true, + "Build/": true, + "Library/": true, + "library/": true, + "obj/": true, + "Obj/": true, + "Logs/": true, + "logs/": true, + "ProjectSettings/": true, + "UserSettings/": true, + "temp/": true, + "Temp/": true + }, + "dotnet.defaultSolution": "LivekitUnitySampleApp.sln" +} \ No newline at end of file From 8881c301d9fb7d74e4e8684c23b0887a6cc1bebe Mon Sep 17 00:00:00 2001 From: Jacob Gelman <3182119+ladvoc@users.noreply.github.com> Date: Fri, 28 Mar 2025 15:59:14 +1100 Subject: [PATCH 3/5] Create SDK development workspace --- SDK.code-workspace | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 SDK.code-workspace diff --git a/SDK.code-workspace b/SDK.code-workspace new file mode 100644 index 0000000..8801212 --- /dev/null +++ b/SDK.code-workspace @@ -0,0 +1,10 @@ +{ + "folders": [ + { + "path": "../client-sdk-unity" + }, + { + "path": "./LivekitUnitySampleApp" + } + ] +} \ No newline at end of file From 8227af56ba6b5e7d5a28cefbd64c0caa5512ce3e Mon Sep 17 00:00:00 2001 From: Jacob Gelman <3182119+ladvoc@users.noreply.github.com> Date: Fri, 28 Mar 2025 16:21:11 +1100 Subject: [PATCH 4/5] Use standard case --- LivekitUnitySampleApp/Assets/LivekitSamples.cs | 16 ++++++++-------- .../Assets/Scenes/SampleScene.unity | 6 +++--- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/LivekitUnitySampleApp/Assets/LivekitSamples.cs b/LivekitUnitySampleApp/Assets/LivekitSamples.cs index ab934d6..7bd38f2 100644 --- a/LivekitUnitySampleApp/Assets/LivekitSamples.cs +++ b/LivekitUnitySampleApp/Assets/LivekitSamples.cs @@ -59,24 +59,24 @@ public void OnClickPublishVideo() Debug.Log("OnClickPublishVideo clicked!"); } - public void onClickPublishData() + public void OnClickPublishData() { publishData(); Debug.Log("onClickPublishData clicked!"); } - public void onClickMakeCall() + public void OnClickMakeCall() { Debug.Log("onClickMakeCall clicked!"); if(webCamTexture == null) { StartCoroutine(OpenCamera()); } - + StartCoroutine(MakeCall()); } - public void onClickHangup() + public void OnClickHangup() { Debug.Log("onClickHangup clicked!"); room.Disconnect(); @@ -102,7 +102,7 @@ IEnumerator MakeCall() UpdateStatusText("Connected"); } } - + } void CleanUp() @@ -115,7 +115,7 @@ void CleanUp() } _audioObjects.Clear(); - + foreach (var item in _rtcAudioSources) { item.Stop(); @@ -173,7 +173,7 @@ void AddVideoTrack(RemoteVideoTrack videoTrack) image.texture = tex; } }; - + _videoObjects[videoTrack.Sid] = imgObject; imgObject.transform.SetParent(layoutGroup.gameObject.transform, false); @@ -254,7 +254,7 @@ public IEnumerator publishMicrophone() { Debug.Log("Track published!"); } - + _rtcAudioSources.Add(rtcSource); yield return rtcSource.PrepareAndStart(); } diff --git a/LivekitUnitySampleApp/Assets/Scenes/SampleScene.unity b/LivekitUnitySampleApp/Assets/Scenes/SampleScene.unity index 79472fe..1959e12 100644 --- a/LivekitUnitySampleApp/Assets/Scenes/SampleScene.unity +++ b/LivekitUnitySampleApp/Assets/Scenes/SampleScene.unity @@ -207,7 +207,7 @@ MonoBehaviour: m_Calls: - m_Target: {fileID: 1478206704} m_TargetAssemblyTypeName: LivekitSamples, Assembly-CSharp - m_MethodName: onClickPublishData + m_MethodName: OnClickPublishData m_Mode: 1 m_Arguments: m_ObjectArgument: {fileID: 0} @@ -1737,7 +1737,7 @@ MonoBehaviour: m_Calls: - m_Target: {fileID: 1478206704} m_TargetAssemblyTypeName: LivekitSamples, Assembly-CSharp - m_MethodName: onClickHangup + m_MethodName: OnClickHangup m_Mode: 1 m_Arguments: m_ObjectArgument: {fileID: 0} @@ -1870,7 +1870,7 @@ MonoBehaviour: m_Calls: - m_Target: {fileID: 1478206704} m_TargetAssemblyTypeName: LivekitSamples, Assembly-CSharp - m_MethodName: onClickMakeCall + m_MethodName: OnClickMakeCall m_Mode: 1 m_Arguments: m_ObjectArgument: {fileID: 0} From 8717d2ebef006a7cf15b65d50756f8e349d4b5ff Mon Sep 17 00:00:00 2001 From: Jacob Gelman <3182119+ladvoc@users.noreply.github.com> Date: Fri, 28 Mar 2025 16:31:23 +1100 Subject: [PATCH 5/5] Move vscode settings to repo root --- {LivekitUnitySampleApp/.vscode => .vscode}/extensions.json | 0 {LivekitUnitySampleApp/.vscode => .vscode}/launch.json | 0 {LivekitUnitySampleApp/.vscode => .vscode}/settings.json | 6 ++++-- 3 files changed, 4 insertions(+), 2 deletions(-) rename {LivekitUnitySampleApp/.vscode => .vscode}/extensions.json (100%) rename {LivekitUnitySampleApp/.vscode => .vscode}/launch.json (100%) rename {LivekitUnitySampleApp/.vscode => .vscode}/settings.json (94%) diff --git a/LivekitUnitySampleApp/.vscode/extensions.json b/.vscode/extensions.json similarity index 100% rename from LivekitUnitySampleApp/.vscode/extensions.json rename to .vscode/extensions.json diff --git a/LivekitUnitySampleApp/.vscode/launch.json b/.vscode/launch.json similarity index 100% rename from LivekitUnitySampleApp/.vscode/launch.json rename to .vscode/launch.json diff --git a/LivekitUnitySampleApp/.vscode/settings.json b/.vscode/settings.json similarity index 94% rename from LivekitUnitySampleApp/.vscode/settings.json rename to .vscode/settings.json index d8cf83a..f5979e9 100644 --- a/LivekitUnitySampleApp/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,4 +1,7 @@ { + "settings": { + "dotnet.defaultSolution": "LivekitUnitySampleApp.sln" + }, "files.exclude": { "**/.DS_Store": true, "**/.git": true, @@ -55,6 +58,5 @@ "UserSettings/": true, "temp/": true, "Temp/": true - }, - "dotnet.defaultSolution": "LivekitUnitySampleApp.sln" + } } \ No newline at end of file