Go bindings for GStreamer (retired: currently I don't use/develop this package)

Related tags

gst
Overview

Retired. I don't use/develop this package anymore.

Go bindings for GStreamer at a very early stage of maturity.

This package is based on GLib bindings. It should be goinstalable. Try

$ go get github.com/ziutek/gst

Documentation

See examples directory and http://gopkgdoc.appspot.com/pkg/github.com/ziutek/gst

To run examples use go run command:

$ cd examples
$ go run simple.go

To run live WebM example use go run live_webm.go and open http://127.0.0.1:8080 with your browser. You probably need to wait a long time for video because of small bitrate of this stream and big buffer in you browser.

Issues
  • 'g_type_init' is deprecated

    'g_type_init' is deprecated

    I get the following error when trying to go get this library:

    # github.com/ziutek/glib
    type.go:19:1: error: 'g_type_init' is deprecated (declared at /usr/include/glib-2.0/gobject/gtype.h:669) [-Werror=deprecated-declarations]
     )
     ^
    cc1: all warnings being treated as errors
    

    I also tried running the examples, they don't work either, giving the same error.

    I'm on Arch Linux x64, Go 1.1, GCC 4.8.1.

    opened by mahmoudhossam 2
  • Adding go binding for gst_version(...) - gst.GetVersion()

    Adding go binding for gst_version(...) - gst.GetVersion()

    Tested, works fine

    opened by revmischa 2
  • Fix error when compiling gst.

    Fix error when compiling gst.

    github.com/ziutek/gst/common.go:187: constant 18446744073709551615 overflows int64

    I changed to type to uint to fix the error message.

    opened by fin-ger 0
  • uint64

    uint64

    opened by xpopit 0
  • Error common.go:214:29: constant -1 overflows uint64

    Error common.go:214:29: constant -1 overflows uint64

    common.go:214:29: constant -1 overflows uint64

    opened by xpopit 0
  • Compilation error in examples/player.go

    Compilation error in examples/player.go

    https://github.com/ziutek/gst/blob/master/examples/player.go#L57

    XOverlayCast is missing in gst and I cannot figure out how to replace it.

    opened by EvAlex 2
  • issues running live_web.go example on go 1.4.1

    issues running live_web.go example on go 1.4.1

    GST_DEBUG=3 go run live_webm.go 0:00:00.023227292 4260 0xc67090 WARN structure gststructure.c:195:gst_structure_validate_name: Invalid character ',' at offset 11 in structure name: video/x-raw,format=yuv

    (live_webm:4260): GStreamer-CRITICAL **: gst_structure_new_empty: assertion 'gst_structure_validate_name (name)' failed

    (live_webm:4260): GStreamer-CRITICAL **: gst_structure_take_value: assertion 'structure != NULL' failed

    (live_webm:4260): GStreamer-CRITICAL **: gst_structure_take_value: assertion 'structure != NULL' failed

    (live_webm:4260): GStreamer-CRITICAL **: gst_structure_take_value: assertion 'structure != NULL' failed 0:00:00.025233199 4260 0xc720a0 FIXME default gstutils.c:3643:gst_pad_create_stream_id_internal: Creating random stream-id, consider implementing a deterministic way of creating a stream-id 0:00:00.029249741 4260 0xc720a0 WARN basesrc gstbasesrc.c:2933:gst_base_src_loop: error: Internal data flow error. 0:00:00.029347884 4260 0xc720a0 WARN basesrc gstbasesrc.c:2933:gst_base_src_loop: error: streaming task paused, reason not-linked (-1)

    go version go1.4.2 linux/amd64 gstreamer version 1.4.3.

    opened by dhoss 3
  • Added basic support for: GstAllocator, GstAppSrc, GstBuffer

    Added basic support for: GstAllocator, GstAppSrc, GstBuffer

    Due to lack of push-behaviour I added some basic GstAppSrc and GstBuffer support which allows to allocate buffer and push it to AppSrc element inside "need-data" handler.

    opened by sergey789 1
  • Windows 8.1 - go.exe get github.com/ziutek/gst fails

    Windows 8.1 - go.exe get github.com/ziutek/gst fails

    I have not found any documentation how to install it for windows 8.1? in windows 8.1 when i apply

    C:\Go\bin>go.exe get github.com/ziutek/gst
    # pkg-config --cflags glib-2.0 gobject-2.0 gthread-2.0
    pkg-config: exec: "pkg-config": executable file not found in %PATH%
    

    Can you please show me how to make it work? (i have Gstreamer SDK in C:\gstreamer\1.0..)

    opened by shamun 3
  • live_webm example broken in go 1.4.1

    live_webm example broken in go 1.4.1

    I've tested the gstreamer bindings in osx.

    gstreamer 1.4.5, go 1.4.1 (built with swig support) are installed, as well as all the dependencies

    The simple example works ok (replacing xvimagesink for autovideosink), but the live_webm fails building and launching it as shown. Any ideas on what's going on?

    fatal error: attempt to execute C code on Go stack

    runtime stack: runtime.throw(0x444a625) /usr/local/Cellar/go/1.4.1/libexec/src/runtime/panic.go:491 +0xad badc() /usr/local/Cellar/go/1.4.1/libexec/src/runtime/stack.c:891 +0x2a runtime.onM(0x4465370) /usr/local/Cellar/go/1.4.1/libexec/src/runtime/asm_amd64.s:257 +0x68 runtime.mstart() /usr/local/Cellar/go/1.4.1/libexec/src/runtime/proc.c:818

    goroutine 1 [running]: runtime.switchtoM() /usr/local/Cellar/go/1.4.1/libexec/src/runtime/asm_amd64.s:198 fp=0xc208009a90 sp=0xc208009a88 runtime.morestackc() /usr/local/Cellar/go/1.4.1/libexec/src/runtime/stack.c:885 +0x1e fp=0xc208009aa8 sp=0xc208009a90 runtime.sighandler(0x5082120, 0x0, 0x0, 0x0) /usr/local/Cellar/go/1.4.1/libexec/src/runtime/signal_amd64x.c:44 +0x14 fp=0xc208009ab0 sp=0xc208009aa8

    goroutine 5 [syscall, locked to thread]: github.com/ziutek/glib._Cfunc_mp_wait(0x0) /Users/bleedinge/src/go/src/github.com/ziutek/glib/:517 +0x4d github.com/ziutek/glib.callbackLoop() /Users/bleedinge/src/go/src/github.com/ziutek/glib/object.go:417 +0x1f created by github.com/ziutek/glib.init·1 /Users/bleedinge/src/go/src/github.com/ziutek/glib/object.go:423 +0x25

    goroutine 17 [syscall, locked to thread]: runtime.goexit() /usr/local/Cellar/go/1.4.1/libexec/src/runtime/asm_amd64.s:2232 +0x1

    opened by bleedinge 4
  • segfault in (*Message).ParseError

    segfault in (*Message).ParseError

    I get a segfault when trying to parse a error message from gstreamer.

    *** glibc detected *** /usr/local/bin/rtp-receiver: free(): invalid pointer: 0x00fd9040 ***
    SIGABRT: abort
    PC=0xb6c1acdc
    
    goroutine 43 [syscall]:
    runtime.cgocall(0xf7f8, 0x8246cb88)
        /usr/lib/go/src/pkg/runtime/cgocall.c:142 +0xdc fp=0x8246cb78 sp=0x8246cb4c
    github.com/ziutek/gst._Cfunc_free(0xfd9040)
        github.com/ziutek/gst/_obj/_cgo_defun.c:82 +0x34 fp=0x8246cb84 sp=0x8246cb78
    github.com/ziutek/gst.(*Message).ParseError(0x10b9c08, 0x96b92bc0, 0x96b2c680, 0x73)
        /home/pi/.go/src/github.com/ziutek/gst/message.go:157 +0x188 fp=0x8246cba8 sp=0x8246cb84
    main.(*Manager).onMessage(0x96b00540, 0x96b0b7a8, 0x10b9c08)
        /home/pi/go/streaming/common-client.go:49 +0xd0 fp=0x8246cc1c sp=0x8246c
    [..]
    

    I tried it with different go versions without any change in behavior.

    My current workaround is to comment out two lines in the library to not make it free the two pointers:

    func (m *Message) ParseError() (err *glib.Error, debug string) {
            var d *C.gchar
            var     e, ret_e *C.GError
    
            C.gst_message_parse_error(m.g(), &e, &d)
            // prevent segfaults by not freeing the pointer
            //defer C.free(unsafe.Pointer(e))
            //defer C.free(unsafe.Pointer(d))
    
            debug = C.GoString((*C.char)(d))
            ret_e = new(C.GError)
            *ret_e = *e
            err = (*glib.Error)(unsafe.Pointer(ret_e))
            return
    }
    

    I'm not sure, if this is the way to fix it. I guess it creates a memory leak.

    opened by felixb 0
  • support for 1.0

    support for 1.0

    How different and therefore how hard would it be to support gstreamer 1.0? Thanks for the awesome work!

    opened by JosePedroDias 0
  • Error when try go get with go 1.3

    Error when try go get with go 1.3

    When I try instal gst, I see this error: cannot use o.g() (type *C.struct__GstObject) as type *C.GstObject in argument to _Cfunc_gst_object_set_name

    Here is reason: http://golang.org/doc/go1.3#cgo

    opened by UndeRus 4
  • parse_launch implementation ?

    parse_launch implementation ?

    Hi, thanks for this module.

    Have you planned to integrate parse_launch function ?

    Thanks

    opened by metal3d 10
Owner
Michał Derkacz
Michał Derkacz
Go bindings for libVLC and high-level media player interface

Go bindings for libVLC 2.X/3.X/4.X and high-level media player interface. The package can be useful for adding multimedia capabilities to applications

Adrian-George Bostan 224 Jul 20, 2021
Go Media Framework

Go FFmpeg Bindings Installation Prerequisites Current master branch supports all major Go versions, starting from 1.6. Build/install FFmpeg build last

alex 695 Jul 23, 2021
Golang bindings for FFmpeg

goav Golang binding for FFmpeg A comprehensive binding to the ffmpeg video/audio manipulation library. Usage import "github.com/giorgisio/goav/avforma

H. Giorgis 1.7k Jul 24, 2021
Parse and generate m3u8 playlists for Apple HTTP Live Streaming (HLS) in Golang (ported from gem https://github.com/sethdeckard/m3u8)

go-m3u8 Golang package for m3u8 (ported m3u8 gem https://github.com/sethdeckard/m3u8) go-m3u8 provides easy generation and parsing of m3u8 playlists d

Tan Quang Ngo 75 Jun 2, 2021
Take control over your live stream video by running it yourself. Streaming + chat out of the box.

Take control over your content and stream it yourself. Explore the docs » View Demo · Use Our Server for Testing · FAQ · Report Bug Table of Contents

Owncast 4.9k Jul 20, 2021
Plays videos using Prometheus and Grafana, e.g. Bad Apple.

prometheus_video_renderer Plays videos using Prometheus and Grafana, e.g. Bad Apple. Modes Currently 3 different modes are supported. Bitmap The bitma

Jacob Colvin 44 Jul 11, 2021
falco is VCL parser and linter optimized for Fastly.

falco falco is VCL parser and linter optimized for Fastly. Disclaimer This is a VCL parser, but dedicated to Fastly's VCL (version 2.x), so we don't c

Yoshiaki Sugimoto 20 Jul 15, 2021
Personal video streaming server.

tube This is a Golang project to build a self hosted "tube"-style video player for watching your own video collection over HTTP or hosting your own ch

davy wybiral 199 Jul 15, 2021
👾 Annie is a fast, simple and clean video downloader built with Go.

?? Annie is a fast, simple and clean video downloader built with Go. Installation Prerequisites Install via go get Homebrew (macOS only) Arch Linux Vo

Xinzhao Xu 15.1k Jul 24, 2021
Parser and generator of M3U8-playlists for Apple HLS. Library for Go language. :cinema:

M3U8 This is the most complete opensource library for parsing and generating of M3U8 playlists used in HTTP Live Streaming (Apple HLS) for internet vi

Alexander I.Grafov 841 Jul 17, 2021
live video streaming server in golang

中文 Simple and efficient live broadcast server: Very simple to install and use; Pure Golang, high performance, and cross-platform; Supports commonly us

浩麟 6.8k Jul 19, 2021
Quik.do is a video conferencing tool.

Quik.do is a video conferencing tool.

Bora Tanrıkulu 93 Jul 19, 2021
LiveKit - Open source, distributed video/audio rooms over WebRTC

LiveKit is an open source project that provides scalable, multi-user conferencing over WebRTC. It's designed to give you everything you need to build real time video/audio capabilities in your applications.

LiveKit 1.5k Jul 27, 2021
A Go implementation of fluent-ffmpeg

A Go implementation of fluent-ffmpeg

Modfy 274 Jul 15, 2021