Commit graph

9 commits

Author SHA1 Message Date
Daniel Vilar
6db4929e08 Rename ndilib to ndisys 2018-09-18 11:52:09 +02:00
Daniel Vilar
07a8b8a274 Refactor logic to use multiple streams in the same pipeline
Now it's possible to connect to N streams in the same pipeline. Each new connection will create a new NDI receiver except if it's a empty slot in the receiver.

Each receiver has two slots one to connect to audio and other to connect to video to the same stream.
2018-08-20 11:09:43 +02:00
Daniel Vilar
ba45931830 Add audio to the pipeline even if the stream source it's already in use for video
FIXME: Whith this commit it's possible to add more streams for the same source if the pipeline has an audio source for that source.
2018-08-14 16:47:58 +02:00
Daniel Vilar
570abeff49 Clean code 2018-06-27 11:56:11 +02:00
Daniel Vilar
e8ee6fd806 Close NDI stream when closing gstreamer 2018-06-04 13:44:27 +02:00
galicaster
db5493d110 Clean code 2018-04-24 19:41:27 +02:00
Daniel Vilar
ca4e498a0b Added NDI code 2018-04-23 13:42:38 +02:00
rubenrua
1377916b3b Add NdiInstance struct that implement Send
https://doc.rust-lang.org/book/second-edition/ch19-03-advanced-traits.html#the-newtype-pattern-to-implement-external-traits-on-external-types

error[E0277]: the trait bound `*mut std::os::raw::c_void: std::marker::Send` is not satisfied in `ndisrc::State`
   --> src/ndisrc.rs:276:6
       |
       276 | impl ObjectImpl<BaseSrc> for NdiSrc {
           |      ^^^^^^^^^^^^^^^^^^^ `*mut std::os::raw::c_void` cannot be sent between threads safely
               |
                   = help: within `ndisrc::State`, the trait `std::marker::Send` is not implemented for `*mut std::os::raw::c_void`
                       = note: required because it appears within the type `std::option::Option<*mut std::os::raw::c_void>`
                           = note: required because it appears within the type `ndisrc::State`
                               = note: required because of the requirements on the impl of `std::marker::Sync` for `std::sync::Mutex<ndisrc::State>`
                                   = note: required because it appears within the type `ndisrc::NdiSrc`

error[E0277]: the trait bound `*mut std::os::raw::c_void: std::marker::Send` is not satisfied in `ndisrc::State`
   --> src/ndisrc.rs:405:6
       |
       405 | impl ElementImpl<BaseSrc> for NdiSrc {
           |      ^^^^^^^^^^^^^^^^^^^^ `*mut std::os::raw::c_void` cannot be sent between threads safely
               |
                   = help: within `ndisrc::State`, the trait `std::marker::Send` is not implemented for `*mut std::os::raw::c_void`
                       = note: required because it appears within the type `std::option::Option<*mut std::os::raw::c_void>`
                           = note: required because it appears within the type `ndisrc::State`
                               = note: required because of the requirements on the impl of `std::marker::Sync` for `std::sync::Mutex<ndisrc::State>`
                                   = note: required because it appears within the type `ndisrc::NdiSrc`

error[E0277]: the trait bound `*mut std::os::raw::c_void: std::marker::Send` is not satisfied in `ndisrc::State`
   --> src/ndisrc.rs:424:6
       |
       424 | impl BaseSrcImpl<BaseSrc> for NdiSrc {
           |      ^^^^^^^^^^^^^^^^^^^^ `*mut std::os::raw::c_void` cannot be sent between threads safely
               |
                   = help: within `ndisrc::State`, the trait `std::marker::Send` is not implemented for `*mut std::os::raw::c_void`
                       = note: required because it appears within the type `std::option::Option<*mut std::os::raw::c_void>`
                           = note: required because it appears within the type `ndisrc::State`
                               = note: required because of the requirements on the impl of `std::marker::Sync` for `std::sync::Mutex<ndisrc::State>`
                                   = note: required because it appears within the type `ndisrc::NdiSrc`

error: aborting due to 3 previous errors
2018-04-16 16:53:22 +00:00
rubenrua
892eb29c3b Add ndilib.rs 2018-04-16 16:42:33 +00:00