We have two data channel. One is named “InputEvent”, and another is named “CustomMessage”. The “InputEvent” is for mouse and keyboard events. The “CustomMessage” is for project business usage.
When UE5.0.3:
Delegate OnDataChannelOpenNative in UPixelStreamingDelegates has two parameters:
- FPixelStreamingPlayerId PlayerId
- webrtc::DataChannelInterface* DataChannel
We can use DataChannel->label() to distinguish “CustomMessage” from “InputEvent”.
When UE5.1.0
Delegate OnDataChannelOpenNative in UPixelStreamingDelegates has three parameters:
- FString StreamerId
- FPixelStreamingPlayerId PlayerId
- FPixelStreamingDataChannel*
We cannot distinguish these two DataChannel.
Is there a way to distinguish them?