mirror of
https://github.com/m1k1o/neko.git
synced 2024-07-24 14:40:50 +12:00
gst remove main loop.
This commit is contained in:
parent
c793ff1ff6
commit
d35c237f48
@ -1,15 +1,5 @@
|
|||||||
#include "gst.h"
|
#include "gst.h"
|
||||||
|
|
||||||
void gstreamer_init(void) {
|
|
||||||
gst_init(NULL, NULL);
|
|
||||||
}
|
|
||||||
|
|
||||||
GMainLoop *gstreamer_main_loop = NULL;
|
|
||||||
void gstreamer_loop(void) {
|
|
||||||
gstreamer_main_loop = g_main_loop_new (NULL, FALSE);
|
|
||||||
g_main_loop_run(gstreamer_main_loop);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void gstreamer_pipeline_log(GstPipelineCtx *ctx, char* level, const char* format, ...) {
|
static void gstreamer_pipeline_log(GstPipelineCtx *ctx, char* level, const char* format, ...) {
|
||||||
va_list argptr;
|
va_list argptr;
|
||||||
va_start(argptr, format);
|
va_start(argptr, format);
|
||||||
|
@ -33,9 +33,7 @@ var pipelinesLock sync.Mutex
|
|||||||
var registry *C.GstRegistry
|
var registry *C.GstRegistry
|
||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
C.gstreamer_init()
|
C.gst_init(nil, nil)
|
||||||
go C.gstreamer_loop()
|
|
||||||
|
|
||||||
registry = C.gst_registry_get()
|
registry = C.gst_registry_get()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -25,6 +25,3 @@ void gstreamer_pipeline_push(GstPipelineCtx *ctx, void *buffer, int bufferLen);
|
|||||||
gboolean gstreamer_pipeline_set_prop_int(GstPipelineCtx *ctx, char *binName, char *prop, gint value);
|
gboolean gstreamer_pipeline_set_prop_int(GstPipelineCtx *ctx, char *binName, char *prop, gint value);
|
||||||
gboolean gstreamer_pipeline_set_caps_framerate(GstPipelineCtx *ctx, const gchar* binName, gint numerator, gint denominator);
|
gboolean gstreamer_pipeline_set_caps_framerate(GstPipelineCtx *ctx, const gchar* binName, gint numerator, gint denominator);
|
||||||
gboolean gstreamer_pipeline_set_caps_resolution(GstPipelineCtx *ctx, const gchar* binName, gint width, gint height);
|
gboolean gstreamer_pipeline_set_caps_resolution(GstPipelineCtx *ctx, const gchar* binName, gint width, gint height);
|
||||||
|
|
||||||
void gstreamer_init(void);
|
|
||||||
void gstreamer_loop(void);
|
|
||||||
|
Loading…
Reference in New Issue
Block a user