Skip to content

Add bindings to enable WebRTC #117

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed

Conversation

a-morales
Copy link

Adding Promise, WebRTCSessionDescription and SDPMessage and supporting enum values to get WebRTC working. This is based off the work @vinicius-tona started in order to get WebRTC working.

This is the bare minimum required to get WebRTC working, but I can add more if required.

@vinicius-tona
Copy link

Thanks a lot for continuing this!
I ended up making my own c binding because I had no idea what was wrong

I will give it a shot as soon as it's merged and update what's necessary

@neilcsmith-net
Copy link
Member

Thanks for this. I'll look to review before merging ASAP.

A couple of quick things that show up immediately -

  • please check what version of GStreamer is needed for a method (or the whole class for some of these) and add to the Javadoc since GStreamer 1.14 or similar as necessary. This is for anything above GStreamer 1.8. There is work underway to better document and expose upstream versions, but at the moment everyone then has an easy way to find them!
  • please check copyright in headers - at least one is missing a correct attribution.

@neilcsmith-net
Copy link
Member

Sorry for the delay in following this up - had to take some time off post-conferences - 🤒

I've just pulled your changes into a local branch and it's making the tests crash. Think I know why, but need to consider best approach to handling it.

@neilcsmith-net neilcsmith-net added this to the 1.0 milestone Nov 15, 2018
@neilcsmith-net
Copy link
Member

OK, still not figured out why the tests are crashing for me. Will keep investigating, but this might need to wait until we can set up #125 otherwise.

@a-morales
Copy link
Author

Sounds good, if there is anything I can do to help move this along just let me know.

@neilcsmith-net
Copy link
Member

@a-morales actually, yes. Could you confirm all the tests run OK for you, and if so let me know what OS and GStreamer packages / versions you have installed? Thanks!

@a-morales
Copy link
Author

a-morales commented Nov 19, 2018

@neilcsmith-net I've ran the tests and they are running on me without crashing, though it looks like 4 tests are skipped. I'm on MacOS 10.14 and using gstreamer 1.14.4 along with Gst-plugins-{base-good-bad}

@neilcsmith-net
Copy link
Member

@a-morales Thanks! I've been tied up with travelling but will have another look at the test problems with this ASAP. Were these additional commits intended to be part of this PR? Is the PR now complete as far as you're concerned or is there more to come?

@a-morales
Copy link
Author

@neilcsmith-net

I added the additional comments just to make the integration a bit easier for WebRTCBin and make it similar to how it is for web browsers and mobile devices. I do have some additional changes to this, but don't want to commit it since it adds data channel support which is currently on master in Gst-plugins-bad and currently not available in an official release, so wanted to hold off on including that.

@neilcsmith-net
Copy link
Member

@a-morales Thanks! Just pulled your additional changes and the tests passed. Checked out what I had before ... and the tests still pass! So, I'm none the wiser why the tests were consistently crashing before, but assume something due to system updates. Will look to pull in ASAP and probably make available in 0.9.4.

@a-morales
Copy link
Author

Cool, while using this in a project I'm working on, I did discover some memory issues with some of the bindings. I think I got them all fixed and can push them up if you like. I can additionally do a rebase if you prefer.

@neilcsmith-net
Copy link
Member

@a-morales if by rebase you mean separate PR, then yes please! Be interested to see them. I got rid of quite a lot when I did the original forking, but I'm sure there are a few left. How are you measuring? Although maybe add that info in the new PR. Thanks!

@neilcsmith-net
Copy link
Member

Just realised the obvious missed question - memory issues in this code or the existing code?

@a-morales
Copy link
Author

It was a memory issue in this code, I was seeing Gstreamer throw warnings/errors after assertions failed when trying to free objects, in which the assertions were that the objects didn't have any other references pointing to them. I just did a build of Gstreamer to show the address of the objects if they failed assertions when freeing them up and enabled the logging for this library to figure out which objects were throwing the errors.

@neilcsmith-net
Copy link
Member

Great! And in which case, definitely this PR! 😄

@a-morales
Copy link
Author

goin to close this now as #129 is a rebase of this.

@a-morales a-morales closed this Dec 17, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants