Skip to content

Commit 6af3914

Browse files
committed
Add examples/ortc README
We had no documentation before Relates to #379
1 parent 9677e61 commit 6af3914

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

examples/ortc/README.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# ortc
2+
ortc demonstrates Pion WebRTC's [ORTC](https://ortc.org/) capabilities. Instead of using the Session Description Protocol
3+
to configure and communicate ORTC provides APIs. Users then can implement signaling with whatever protocol they wish.
4+
ORTC can then be used to implement WebRTC. A ORTC implementation can parse/emit Session Description and act as a WebRTC
5+
implementation.
6+
7+
In this example we have defined a simple JSON based signaling protocol.
8+
9+
## Instructions
10+
### Download ortc
11+
```
12+
export GO111MODULE=on
13+
go get github.com/pion/webrtc/v3/examples/ortc
14+
```
15+
16+
### Run first client as offerer
17+
`ortc -offer` this will emit a base64 message. Copy this message to your clipboard.
18+
19+
## Run the second client as answerer
20+
Run the second client. This should be launched with the message you copied in the previous step as stdin.
21+
22+
`echo BASE64_MESSAGE_YOU_COPIED | ortc`
23+
24+
### Enjoy
25+
If everything worked you will see `Data channel 'Foo'-'' open.` in each terminal.
26+
27+
Each client will send random messages every 5 seconds that will appear in the terminal
28+
29+
Congrats, you have used Pion WebRTC! Now start building something cool

0 commit comments

Comments
 (0)