amazon-kinesis-video-streams-producer-sdk-cpp icon indicating copy to clipboard operation
amazon-kinesis-video-streams-producer-sdk-cpp copied to clipboard

[QUESTION]How can I perform kvssink in mac without installing dependencies?

Open testsys-varadhu opened this issue 1 year ago • 3 comments

We are able to:

  • Build the SDK (https://github.com/awslabs/amazon-kinesis-video-streams-producer-sdk-cpp)
  • Reference it in my macOS desktop app
  • Run my desktop app
  • Create an RTMP stream

With some desktop environment setup, we are also able to:

  • Publish the stream

Everything is working well as part of our POC. Now that we have approval to move to development, we are facing challenges with bundling kvssink as part of our macOS desktop app. This app needs to run in non-elevated mode. We see similar framework working with iOS, but we are unable to achieve the same with macOS.

Can you please help us? Let us know if you need more details.

Thanks.

testsys-varadhu avatar Aug 29 '24 08:08 testsys-varadhu

Hi Varadharajan, can you please specify what you are asking? How is having to install dependencies affecting your use of kvssink? Also have you tried using a static build for use case with BUILD_STATIC enabled?

stefankiesz avatar Sep 03 '24 18:09 stefankiesz

@stefankiesz -- In my POC, I was able to install the dependencies using home brew and I was able to set the 'GST_PLUGIN_PATH' environment variable so it works in my local machine, whereas in the end user machine we will not have the privilege to install anything or to set the environment variables. I want to bundle the GStreamer and necessary libraries within my app bundle and need to load it during the execution of my app. After I include GStreamer.framework when i do kvssink = gst_element_factory_make("kvssink", "sink"); the sink is not getting initialized, and the variable is NULL.

testsys-varadhu avatar Sep 09 '24 06:09 testsys-varadhu

Here are the two options I've come to for this case.

  1. Place the libgstkvssink.so plugin file into the default GStreamer plugin directory for your system.
  2. Programmatically set the plugin to GStreamer using gst_registry_add_plugin.

I tested out the first option on Mac with success. To recreate:

  1. Don't set GST_PLUGIN_PATH. Can run unset GST_PLUGIN_PATH to be sure.
  2. After building kvssink, copy the outputted library file into the appropriate GStreamer directory: cp libgstkvssink.so /opt/homebrew/lib/gstreamer-1.0.
  3. Run the kvssink sample app per usual.

stefankiesz avatar Sep 13 '24 21:09 stefankiesz

Closing assuming resolved.

stefankiesz avatar Oct 07 '24 05:10 stefankiesz