eyyyy thanks for making these videos. You have been a complete lifesaver!!!! im still not completely familiar with how it all works but i know ill get there eventually. Im just glad its working XD
Hello, how are you? I would like to ask the following question: I have a Janus server providing a WebRTC video, and I need to play it in Unity using WebRTC, but I’m not sure about the procedure. Could you explain how to do it?
Well, you'll have to watch the whole video to find out 😂 I simply messed up the Audio settings when exporting and was too lazy to export again. Wasn't aware that YT doesn't provide a possibility to increase the audio after uploading, sry about that 😅
Thank you so much for your tutorial. Using Unity-WebRTC with the official sample is really hard. I have followed your tutorial but I have obtained a different behavior in the messages exchange and, finally an error. The message "SERVER SimpleDataChannelService started!" appears twice and the next message is "Sender oppened channel!" before any ICEcandidate or Offer exchange. Do you know where could be the problem? I know it is a difficult question without any other data but any idea could help me. Thank you.
Hey there! Thanks for this. I'm having an issue: it takes a while to enter play mode in the Unity editor, and then there's no 'SERVER SimpleDataChannelService started!' message. Can you shed some light on this? Using unity 2022.3.20f1
Both scripts are added, when debugging I can see the wssv Ip at the SimpleDataChannelServer is not what we define on the InitClient. Could be that? @@firedragongamestudio
I'm at around minute 23. I get this error that says webRTC doesn't have context. I look online and it seems like I need WebRTC.Initialize(); to set up peer connections? but I currently don't see it in the code. is it something new? am I missing something? You don't plan on putting source online right? I'm trying to follow but sometimes double checking code is hard because I have to scroll through the video to see where you wrote something.
I'm actually going to open-source the code with January 2025. So if you're still struggeling, you should be able to test the code directly in about 3 weeks :)
Hi, thank you so much for the video! I'm having an Error SocketException: Could not resolve host 'MacBook-Pro-Alex.loc' Couldn't find any solution for that yet, would you happen to know what might cause this? it's the same Error with all the WebRTC tutorials.
Hi there! Thanks for the video. It's a great one! I wonder what I should do If I want to utilize WebRTC on the Server, not LAN. Can you suggest to me where to look?
It doesn't work for Hololens2 as the Unity package doesn't support Windows UWP (docs.unity3d.com/Packages/com.unity.webrtc@3.0/manual/requirements.html). It does work for Quest3, already uploaded a follow up video, for media streams incl. Quest3. Feel free to check it out :)
Thanks for this amazing video. I'm trying to send a mesh over webSockets, if I send a cube, send and receive it works, but if I try to send a mesh (from azure kinect) I've received a message 'InvalidOperationException: DataChannel is not open' . There is a maximum buffer message size ? How I can increase the socket buffer ? Thanks a lot !! great job.
Absolutely! I already created and uploaded a video media stream tutorial. I'm planning to release a tutorial with multiple streams too, pls look forward to it :)
@@firedragongamestudio thanks for the answer mate, but i did not want to depend on a paid service, and rather do port forwarding on the host side, he creates a server and we do the handshake to enable webRTC p2p, webrtc doc is very vague :(
@@gonzalolo There are currently several options for TURN servers available online, both as self-hosted applications (like the open-source COTURN project) and as cloud provided services.
Hello, Thank you for the video! I followed along and built and ran the application on Android. However, whenever I toggle "Send Message Via Channel" in the editor, I receive the message: 'InvalidOperationException: DataChannel is not open - Unity.WebRTC.RTCDataChannel.Send.' Additionally, the messages that appear in the editor do not show up on Android. I'm not sure why this is happening.
My laptop and Android phone are connected to the same Wi-Fi network, and the WebSocket server's IP has been changed to my local IP address. I have also disabled the firewall on my laptop. However, I am still encountering the same error
This project is open source and the repo can be found here: github.com/FireDragonGameStudio/YT-Unity-WebRTC
eyyyy thanks for making these videos. You have been a complete lifesaver!!!! im still not completely familiar with how it all works but i know ill get there eventually. Im just glad its working XD
Hello, how are you? I would like to ask the following question: I have a Janus server providing a WebRTC video, and I need to play it in Unity using WebRTC, but I’m not sure about the procedure. Could you explain how to do it?
Yo bro Is this a secret? 😂whispering like someone hiding in a closet with a serial killer looking for them
Well, you'll have to watch the whole video to find out 😂 I simply messed up the Audio settings when exporting and was too lazy to export again. Wasn't aware that YT doesn't provide a possibility to increase the audio after uploading, sry about that 😅
Yeah, thought I stumbled onto an ASMR video :)
Thank you so much for your tutorial. Using Unity-WebRTC with the official sample is really hard.
I have followed your tutorial but I have obtained a different behavior in the messages exchange and, finally an error. The message "SERVER SimpleDataChannelService started!" appears twice and the next message is "Sender oppened channel!" before any ICEcandidate or Offer exchange. Do you know where could be the problem? I know it is a difficult question without any other data but any idea could help me. Thank you.
There may be a possibility that you added the Server script two times in your scene. Pls make sure that there is only one running websocket server.
Hey there! Thanks for this. I'm having an issue: it takes a while to enter play mode in the Unity editor, and then there's no 'SERVER SimpleDataChannelService started!' message. Can you shed some light on this? Using unity 2022.3.20f1
Maybe you haven't added the server script to the hierarchy?
Both scripts are added@@firedragongamestudio
Both scripts are added, when debugging I can see the wssv Ip at the SimpleDataChannelServer is not what we define on the InitClient. Could be that? @@firedragongamestudio
It was that!
I'm at around minute 23. I get this error that says webRTC doesn't have context. I look online and it seems like I need WebRTC.Initialize(); to set up peer connections? but I currently don't see it in the code. is it something new? am I missing something?
You don't plan on putting source online right? I'm trying to follow but sometimes double checking code is hard because I have to scroll through the video to see where you wrote something.
I'm actually going to open-source the code with January 2025. So if you're still struggeling, you should be able to test the code directly in about 3 weeks :)
Hi, thank you so much for the video! I'm having an Error SocketException: Could not resolve host 'MacBook-Pro-Alex.loc'
Couldn't find any solution for that yet, would you happen to know what might cause this? it's the same Error with all the WebRTC tutorials.
Sounds like the string for the host is escaped somehow and cropped.
Hi there! Thanks for the video. It's a great one!
I wonder what I should do If I want to utilize WebRTC on the Server, not LAN. Can you suggest to me where to look?
Depending on the server (LAN or online) you'll have to look intp TURN and/or STUN servers for WebRTC.
You guess this would work for the HoLoLens 2 or Quest 3 to get a communication between device and PC as well?
It doesn't work for Hololens2 as the Unity package doesn't support Windows UWP (docs.unity3d.com/Packages/com.unity.webrtc@3.0/manual/requirements.html). It does work for Quest3, already uploaded a follow up video, for media streams incl. Quest3. Feel free to check it out :)
Thanks for this amazing video. I'm trying to send a mesh over webSockets, if I send a cube, send and receive it works, but if I try to send a mesh (from azure kinect) I've received a message 'InvalidOperationException: DataChannel is not open' . There is a maximum buffer message size ? How I can increase the socket buffer ? Thanks a lot !! great job.
Is it really the buffer size? If the data channel is closed, there must be a reason why...
Can we create a video call app using unity-webrtc?
Absolutely! I already created and uploaded a video media stream tutorial. I'm planning to release a tutorial with multiple streams too, pls look forward to it :)
Awsome tutorial
Webrtc is not easy to understand but your tutorial made it very easy
Hello, thanks for your great tutorial can this work between 2 terminal over the internet ?.
Yes, but you'll have to use TURN or STUN servers for this. It's on my list for future tutorials.
@@firedragongamestudio i
will keep whatching ^^
hi mate, thanks for the video.
can i use this approach to connect over the web? with forwarding?
Yes, you'll have to look for STUN and TURN servers. The WebRTC docs are pretty good explaining that :)
@@firedragongamestudio thanks for the answer mate, but i did not want to depend on a paid service, and rather do port forwarding on the host side, he creates a server and we do the handshake to enable webRTC p2p, webrtc doc is very vague :(
@@gonzalolo There are currently several options for TURN servers available online, both as self-hosted applications (like the open-source COTURN project) and as cloud provided services.
@@firedragongamestudio really appreciate your time mate :) thanks
Hello,
Thank you for the video!
I followed along and built and ran the application on Android.
However, whenever I toggle "Send Message Via Channel" in the editor, I receive the message: 'InvalidOperationException: DataChannel is not open - Unity.WebRTC.RTCDataChannel.Send.'
Additionally, the messages that appear in the editor do not show up on Android. I'm not sure why this is happening.
Are your devices in the same network/wifi? Have you changed the ip address of your websocket server to your local ip addess?
And try to turn of your firewall, maybe that's interfering too.
My laptop and Android phone are connected to the same Wi-Fi network, and the WebSocket server's IP has been changed to my local IP address.
I have also disabled the firewall on my laptop.
However, I am still encountering the same error
Can i send and receive data between two android devices connected to the same local network ?
Yes, if the websocket server itself runs on a PC in the same LAN. You can't start a websocket server on an Android device, afaik.
Please stop randomly pasting in code snippets. Its really annoying and makes it hard to follow along
lol, learn it yourself? i did just fine. why should he have to handwrite all of the code a second time just for your convenience?