GithubHelp home page GithubHelp logo

rikbrown / kinesis-video-gstreamer-java Goto Github PK

View Code? Open in Web Editor NEW
6.0 3.0 1.0 7 KB

Publish from GStreamer to Kinesis Video using Java (for now, just RTSP streams)

Java 100.00%
amazon amazon-web-services aws kinesis-video gstreamer gst rtsp

kinesis-video-gstreamer-java's Introduction

kinesis-video-gstreamer-java

Publish GStreamer streams to Kinesis Video, implemented in Java.

This code is more or less analogous to the kinesis-video-gst-demo provided in amazon-kinesis-video-streams-producer-cpp, except it's written in pure Java (well, it depends on GStreamer and the native Kinesis bindings, but the code is all Java).

This code depends on the amazon-kinesis-video-streams-producer-sdk-java, and simply implements a MediaSource which can read from GStreamer.

What you get

  • I've only implemented H264 RTSP streaming (because my use case was publishing streams from a security camera which uses H264 and emits a RTSP stream).
    • Coming soon I intend to genericify the GStreamer code so you can plug any GST Pipeline in. Or feel free to do that yourself.
  • There's a demo (GStreamerRtspPublisherDemo) which should work.

Caveats

  • This currently depends on some code which isn't actually available. Specifically:
    1. I forked amazon-kinesis-video-streams-producer-sdk-java because it didn't really support making custom implementations of MediaSource (hopefully this will be merged in soon).
    2. That library isn't actually published to Maven yet so to get this project to build you'll need to jump through some hoops described below.
Kotlin? ๐Ÿ˜ข

I actually wrote this in Kotlin first. I'll provide some Kotlin code soon. I wanted a Java-based demo so AWS could refer to it though. Hey, I used Java 10 and var at least?

Running the demo

Prerequisites

  • Gradle (brew install gradle)
  • Maven (brew install maven)
  • GStreamer (brew install gstreamer gst-plugins-base gst-libav gst-plugins-bad gst-plugins-good gst-plugins-ugly)

Steps

  1. Clone a local copy of my forked version of amazon-kinesis-video-streams-producer-sdk-java

  2. Install it into your local Maven repository (mvn install from its directory)

  3. Clone this repository

  4. Run the demo!

    gradle -Paws.accessKeyId=<accessKeyId>> -Paws.secretKey=<secretKey> -PstreamName=<KinesisStreamName> -PrtspUri=<rtsp://whateverYourRtspUriHappensToBe> runRtspDemo

kinesis-video-gstreamer-java's People

Contributors

rikbrown avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

zhangxin8105

kinesis-video-gstreamer-java's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.