Files
go-gst/gst/base/gst_push_src.go
2025-09-16 22:36:07 +02:00

35 lines
987 B
Go

package base
/*
#include "gst.go.h"
*/
import "C"
import (
"github.com/go-gst/go-glib/glib"
"github.com/go-gst/go-gst/gst"
)
// GstPushSrc represents a GstBaseSrc.
type GstPushSrc struct{ *GstBaseSrc }
// ToGstPushSrc returns a GstPushSrc object for the given object.
//
// Deprecated: This is handwritten and will be removed in a future version. Please use the autogenerated bindings instead.
func ToGstPushSrc(obj interface{}) *GstPushSrc {
switch obj := obj.(type) {
case *gst.Object:
return &GstPushSrc{&GstBaseSrc{&gst.Element{Object: obj}}}
case *glib.Object:
return &GstPushSrc{&GstBaseSrc{&gst.Element{Object: &gst.Object{InitiallyUnowned: &glib.InitiallyUnowned{Object: obj}}}}}
}
return nil
}
// Instance returns the underlying C GstBaseSrc instance
//
// Deprecated: This is handwritten and will be removed in a future version. Please use the autogenerated bindings instead.
func (g *GstPushSrc) Instance() *C.GstPushSrc {
return C.toGstPushSrc(g.Unsafe())
}