1# swap-tracks 2 3swap-tracks demonstrates how to swap multiple incoming tracks on a single outgoing track. 4 5## Instructions 6 7### Build swap-tracks 8 9```shell 10cargo build --example swap-tracks 11``` 12 13### Open swap-tracks example page 14 15[jsfiddle.net](https://jsfiddle.net/dzc17fga/) you should see two text-areas and a 'Start Session' button. 16 17### Run swap-tracks, with your browsers SessionDescription as stdin 18 19In the jsfiddle the top textarea is your browser, copy that and: 20 21#### Linux/macOS 22 23Run `echo $BROWSER_SDP | ./target/debug/examples/swap-tracks` 24 25#### Windows 26 271. Paste the SessionDescription into a file. 281. Run `./target/debug/examples/swap-tracks < my_file` 29 30### Input swap-tracks's SessionDescription into your browser 31 32Copy the text that `swap-tracks` just emitted and copy into second text area 33 34### Hit 'Start Session' in jsfiddle, enjoy your video! 35 36Your browser should send streams to webrtc-rs, and then a stream will be relayed back, changing every 5 seconds. 37 38Congrats, you have used WebRTC.rs! 39