stream
- Last UpdatedFeb 19, 2025
- 2 minute read
Streams are like shares but use User Data Protocol (UDP)-based communications to improve synchronization and reduce possible lag.
-
Stream is not a node. It is a script command. It cannot be referenced by other nodes.
-
Stream communications have a dedicated type (client, server, none) and port to be configured in the config.xml file.
-
You should limit Stream use to a few fields, such as camera or avatar positions and orientations, that need to be perfectly coupled on different machines.
Cybersecurity Note: Stream does not provide data confidentiality from potential cyber attacks. It is strongly advised not to share credentials or other sensitive data because communication could be intercepted.
Platform support
This element is fully supported on XR-Windows, XR-Portable Windows, XR-Portable iOS, and XR-Portable Androi. It is not supported on XR-Portable WASM platform.
|
XR-WIN |
XR-P-WIN |
XR-P-IOS |
XR-P-AND |
XR-P-WASM |
|---|---|---|---|---|
|
Full support |
Full support |
Full support |
Full support |
No support |
|
|
|
|
|
|
Code example
This is a code example for stream.
<stream field="V529023.value" direction="inout"/>
Fields
These are the fields for stream command.
|
Fields |
Type |
Use |
Default value |
Description |
|---|---|---|---|---|
|
direction |
senum |
Optional |
Inout |
Specifies the share direction. Valid values are: in, out, and inout. |
|
field |
sstring |
Mandatory |
Not set |
The unique name of the field to be shared. |