Skip to content
This repository has been archived by the owner on Apr 25, 2023. It is now read-only.

Rust sendrecv #20

Closed
wants to merge 25 commits into from
Closed
Show file tree
Hide file tree
Changes from 13 commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
ad8a9d5
Add docker-compose demo
maxmcd May 27, 2018
5f3d57b
Beginnings of gst-rust, plugin validation and basic WS event loop
maxmcd May 29, 2018
3f32c7f
Promise and event progress
maxmcd May 30, 2018
6ecf017
Add send ice, create offer, send sdp and others
maxmcd May 30, 2018
a6359d9
Json message parsing and Sdp message parse_buffer fix
maxmcd May 31, 2018
3d03d52
Video to browser working
maxmcd May 31, 2018
ab61ee6
Add appstate handling with Atomic and Arc
maxmcd May 31, 2018
656ec1b
Implement on_incoming_stream, on_incoming_decodebin_stream, handle_me…
maxmcd May 31, 2018
e03100a
Remove debugging statements and some cleanup
maxmcd May 31, 2018
59a5616
Added minor fixes and improvements related to PR
maxmcd May 31, 2018
e778ca1
Add some error handling, add more to Mutex, minor fixes
maxmcd Jun 5, 2018
d4165e4
Add peer-id and server flags, clean up some mutex use, general cleanup
maxmcd Jun 5, 2018
37d2714
Remove unsafe fetching of sdp as text
maxmcd Jun 5, 2018
c49d8e3
Add --disable-ssl option to simple-server.py
maxmcd Jun 6, 2018
8586f28
Add --disable-ssl flag to webrtc-sendrecv.c
maxmcd Jun 6, 2018
38499be
Add minor fixes, manually construct initial pipeline
maxmcd Jun 12, 2018
1a4cb92
Use structs for json handling
maxmcd Jun 12, 2018
36d0c24
Combine WsClient and AppControl
maxmcd Jun 12, 2018
76fb8a7
Minor refactoring and cleanup
maxmcd Jun 13, 2018
03bf984
Replace ws lib, use bus and better error handling, remove all panics
maxmcd Jun 15, 2018
b392f4b
Cleanup and more idiomatic error handling for missing elements
maxmcd Jun 15, 2018
23850c6
Use enum for json serialization as well
maxmcd Jun 15, 2018
7ed8ddf
Better handle signalling server going away
maxmcd Jun 15, 2018
e06c8d3
Move caught bus message types to catchall, lt => cmp, handle bus errors
maxmcd Jun 16, 2018
1f80d35
Consolidate app_control cloning
maxmcd Jun 16, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
version: '3'

services:
# uncomment the sendrecv you would like to use
#
# sendrecv-gst:
# build: ./sendrecv/gst
sendrecv-gst-rust:
build: ./sendrecv/gst-rust
sendrecv-js:
build: ./sendrecv/js
ports:
- 8080:80
depends_on:
- signalling
signalling:
build: ./signalling
ports:
- 8443:8443
1 change: 1 addition & 0 deletions sendrecv/gst-rust/.dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/target/
10 changes: 10 additions & 0 deletions sendrecv/gst-rust/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Generated by Cargo
# will have compiled files and executables
/target/

# Remove Cargo.lock from gitignore if creating an executable, leave it for libraries
# More information here https://doc.rust-lang.org/cargo/guide/cargo-toml-vs-cargo-lock.html
Cargo.lock

# These are backup files generated by rustfmt
**/*.rs.bk
16 changes: 16 additions & 0 deletions sendrecv/gst-rust/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
[package]
name = "gst-rust"
version = "0.1.0"
authors = ["maxmcd <[email protected]>"]

[dependencies]
clap = "2.31.2"
glib = { git = "https://github.com/gtk-rs/glib" }
gstreamer = { git = "https://github.com/sdroege/gstreamer-rs", features = ["v1_14"] }
gstreamer-rtsp-server = { git = "https://github.com/sdroege/gstreamer-rs" }
gstreamer-sdp = { git = "https://github.com/sdroege/gstreamer-rs" }
gstreamer-sdp-sys = { git = "https://github.com/sdroege/gstreamer-sys" }
gstreamer-webrtc = { git = "https://github.com/sdroege/gstreamer-rs" }
rand = "0.5"
serde_json = "1.0.19"
ws = "0.7.6"
13 changes: 13 additions & 0 deletions sendrecv/gst-rust/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
FROM maxmcd/gstreamer:1.14-buster

RUN apt-get install -y curl
RUN wget -O rustup.sh https://sh.rustup.rs && sh ./rustup.sh -y
ENV PATH=$PATH:/root/.cargo/bin/

WORKDIR /opt/
COPY . /opt/
RUN cargo build

CMD echo "Waiting a few seconds for you to open the browser at localhost:8080" \
&& sleep 10 \
&& /opt/target/debug/gst-rust --peer-id=1 --server=ws://signalling:8443
Loading