mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-02 21:48:55 +00:00
csharp: update c# bindings
Update to C# bindings to use a more recent version of GtkSharp and regenerate the bindings with that version Fix #1718
This commit is contained in:
parent
265a5c0df0
commit
4be602a137
219 changed files with 17554 additions and 3298 deletions
|
@ -301,6 +301,66 @@ namespace GES {
|
|||
unmanaged (this.Handle, proxy == null ? IntPtr.Zero : proxy.Handle);
|
||||
}
|
||||
|
||||
static RequestIdUpdateNativeDelegate RequestIdUpdate_cb_delegate;
|
||||
static RequestIdUpdateNativeDelegate RequestIdUpdateVMCallback {
|
||||
get {
|
||||
if (RequestIdUpdate_cb_delegate == null)
|
||||
RequestIdUpdate_cb_delegate = new RequestIdUpdateNativeDelegate (RequestIdUpdate_cb);
|
||||
return RequestIdUpdate_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideRequestIdUpdate (GLib.GType gtype)
|
||||
{
|
||||
OverrideRequestIdUpdate (gtype, RequestIdUpdateVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideRequestIdUpdate (GLib.GType gtype, RequestIdUpdateNativeDelegate callback)
|
||||
{
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) gtype.GetClassPtr()) + (long) class_abi.GetFieldOffset("request_id_update"));
|
||||
*raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate) callback);
|
||||
}
|
||||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate bool RequestIdUpdateNativeDelegate (IntPtr inst, IntPtr proposed_new_id, IntPtr error);
|
||||
|
||||
static bool RequestIdUpdate_cb (IntPtr inst, IntPtr proposed_new_id, IntPtr error)
|
||||
{
|
||||
try {
|
||||
Asset __obj = GLib.Object.GetObject (inst, false) as Asset;
|
||||
bool __result;
|
||||
__result = __obj.OnRequestIdUpdate (GLib.Marshaller.Utf8PtrToString (proposed_new_id), error);
|
||||
return __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
// NOTREACHED: above call does not return.
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(GES.Asset), ConnectionMethod="OverrideRequestIdUpdate")]
|
||||
protected virtual bool OnRequestIdUpdate (string proposed_new_id, IntPtr error)
|
||||
{
|
||||
return InternalRequestIdUpdate (proposed_new_id, error);
|
||||
}
|
||||
|
||||
private bool InternalRequestIdUpdate (string proposed_new_id, IntPtr error)
|
||||
{
|
||||
RequestIdUpdateNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("request_id_update"));
|
||||
unmanaged = (RequestIdUpdateNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(RequestIdUpdateNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return false;
|
||||
|
||||
IntPtr native_proposed_new_id = GLib.Marshaller.StringToPtrGStrdup (proposed_new_id);
|
||||
bool __result = unmanaged (this.Handle, native_proposed_new_id, error);
|
||||
GLib.Marshaller.Free (native_proposed_new_id);
|
||||
return __result;
|
||||
}
|
||||
|
||||
|
||||
// Internal representation of the wrapped structure ABI.
|
||||
static GLib.AbiStruct _class_abi = null;
|
||||
|
@ -445,6 +505,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr ges_asset_get_error(IntPtr raw);
|
||||
|
||||
public IntPtr Error {
|
||||
get {
|
||||
IntPtr raw_ret = ges_asset_get_error(Handle);
|
||||
IntPtr ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr ges_asset_list_proxies(IntPtr raw);
|
||||
|
||||
|
@ -521,6 +592,19 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_get_date(IntPtr raw, IntPtr meta_item, out IntPtr dest);
|
||||
|
||||
public bool GetDate(string meta_item, out GLib.Date dest) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
IntPtr native_dest;
|
||||
bool raw_ret = ges_meta_container_get_date(Handle, native_meta_item, out native_dest);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
dest = new GLib.Date(native_dest);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_get_date_time(IntPtr raw, IntPtr meta_item, out IntPtr dest);
|
||||
|
||||
|
@ -666,6 +750,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_register_meta_date(IntPtr raw, int flags, IntPtr meta_item, IntPtr value);
|
||||
|
||||
public bool RegisterMetaDate(GES.MetaFlag flags, string meta_item, GLib.Date value) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
bool raw_ret = ges_meta_container_register_meta_date(Handle, (int) flags, native_meta_item, value == null ? IntPtr.Zero : value.Handle);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_register_meta_date_time(IntPtr raw, int flags, IntPtr meta_item, IntPtr value);
|
||||
|
||||
|
@ -778,6 +873,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_set_date(IntPtr raw, IntPtr meta_item, IntPtr value);
|
||||
|
||||
public bool SetDate(string meta_item, GLib.Date value) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
bool raw_ret = ges_meta_container_set_date(Handle, native_meta_item, value == null ? IntPtr.Zero : value.Handle);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_set_date_time(IntPtr raw, IntPtr meta_item, IntPtr value);
|
||||
|
||||
|
|
|
@ -59,14 +59,14 @@ namespace GES {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate bool GetNaturalFramerateNativeDelegate (IntPtr inst, int framerate_n, int framerate_d);
|
||||
delegate bool GetNaturalFramerateNativeDelegate (IntPtr inst, out int framerate_n, out int framerate_d);
|
||||
|
||||
static bool GetNaturalFramerate_cb (IntPtr inst, int framerate_n, int framerate_d)
|
||||
static bool GetNaturalFramerate_cb (IntPtr inst, out int framerate_n, out int framerate_d)
|
||||
{
|
||||
try {
|
||||
ClipAsset __obj = GLib.Object.GetObject (inst, false) as ClipAsset;
|
||||
bool __result;
|
||||
__result = __obj.OnGetNaturalFramerate (framerate_n, framerate_d);
|
||||
__result = __obj.OnGetNaturalFramerate (out framerate_n, out framerate_d);
|
||||
return __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -76,21 +76,21 @@ namespace GES {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(GES.ClipAsset), ConnectionMethod="OverrideGetNaturalFramerate")]
|
||||
protected virtual bool OnGetNaturalFramerate (int framerate_n, int framerate_d)
|
||||
protected virtual bool OnGetNaturalFramerate (out int framerate_n, out int framerate_d)
|
||||
{
|
||||
return InternalGetNaturalFramerate (framerate_n, framerate_d);
|
||||
return InternalGetNaturalFramerate (out framerate_n, out framerate_d);
|
||||
}
|
||||
|
||||
private bool InternalGetNaturalFramerate (int framerate_n, int framerate_d)
|
||||
private bool InternalGetNaturalFramerate (out int framerate_n, out int framerate_d)
|
||||
{
|
||||
GetNaturalFramerateNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("get_natural_framerate"));
|
||||
unmanaged = (GetNaturalFramerateNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(GetNaturalFramerateNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return false;
|
||||
if (unmanaged == null) throw new InvalidOperationException ("No base method to invoke");
|
||||
|
||||
bool __result = unmanaged (this.Handle, framerate_n, framerate_d);
|
||||
bool __result = unmanaged (this.Handle, out framerate_n, out framerate_d);
|
||||
return __result;
|
||||
}
|
||||
|
||||
|
@ -147,10 +147,10 @@ namespace GES {
|
|||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_clip_asset_get_natural_framerate(IntPtr raw, int framerate_n, int framerate_d);
|
||||
static extern bool ges_clip_asset_get_natural_framerate(IntPtr raw, out int framerate_n, out int framerate_d);
|
||||
|
||||
public bool GetNaturalFramerate(int framerate_n, int framerate_d) {
|
||||
bool raw_ret = ges_clip_asset_get_natural_framerate(Handle, framerate_n, framerate_d);
|
||||
public bool GetNaturalFramerate(out int framerate_n, out int framerate_d) {
|
||||
bool raw_ret = ges_clip_asset_get_natural_framerate(Handle, out framerate_n, out framerate_d);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
|
|
@ -47,11 +47,21 @@ namespace GES {
|
|||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr ges_command_line_formatter_get_help(int nargs, IntPtr commands);
|
||||
|
||||
public static string GetHelp(int nargs, string commands) {
|
||||
IntPtr native_commands = GLib.Marshaller.StringToPtrGStrdup (commands);
|
||||
public static string GetHelp(string[] commands) {
|
||||
int nargs = (commands == null ? 0 : commands.Length);
|
||||
IntPtr native_commands = GLib.Marshaller.StringArrayToStrvPtr(commands, false);
|
||||
IntPtr raw_ret = ges_command_line_formatter_get_help(nargs, native_commands);
|
||||
string ret = GLib.Marshaller.PtrToStringGFree(raw_ret);
|
||||
GLib.Marshaller.Free (native_commands);
|
||||
GLib.Marshaller.StringArrayPtrFree (native_commands, nargs);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr ges_command_line_formatter_get_timeline_uri(IntPtr timeline);
|
||||
|
||||
public static string GetTimelineUri(GES.Timeline timeline) {
|
||||
IntPtr raw_ret = ges_command_line_formatter_get_timeline_uri(timeline == null ? IntPtr.Zero : timeline.Handle);
|
||||
string ret = GLib.Marshaller.PtrToStringGFree(raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
|
@ -28,7 +28,7 @@ namespace GES {
|
|||
public const uint TIMELINE_ELEMENT_NO_LAYER_PRIORITY = 4294967295;
|
||||
public const int VERSION_MAJOR = 1;
|
||||
public const int VERSION_MICRO = 0;
|
||||
public const int VERSION_MINOR = 19;
|
||||
public const int VERSION_MINOR = 23;
|
||||
public const int VERSION_NANO = 1;
|
||||
#endregion
|
||||
}
|
||||
|
|
|
@ -0,0 +1,24 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace GES {
|
||||
|
||||
using System;
|
||||
|
||||
public delegate void DiscoveredHandler(object o, DiscoveredArgs args);
|
||||
|
||||
public class DiscoveredArgs : GLib.SignalArgs {
|
||||
public Gst.PbUtils.DiscovererInfo Info{
|
||||
get {
|
||||
return (Gst.PbUtils.DiscovererInfo) Args [0];
|
||||
}
|
||||
}
|
||||
|
||||
public IntPtr Error{
|
||||
get {
|
||||
return (IntPtr) Args [1];
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -0,0 +1,247 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace GES {
|
||||
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
#region Autogenerated code
|
||||
public partial class DiscovererManager : GLib.Object {
|
||||
|
||||
public DiscovererManager (IntPtr raw) : base(raw) {}
|
||||
|
||||
protected DiscovererManager() : base(IntPtr.Zero)
|
||||
{
|
||||
CreateNativeObject (new string [0], new GLib.Value [0]);
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern ulong ges_discoverer_manager_get_timeout(IntPtr raw);
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void ges_discoverer_manager_set_timeout(IntPtr raw, ulong timeout);
|
||||
|
||||
[GLib.Property ("timeout")]
|
||||
public ulong Timeout {
|
||||
get {
|
||||
ulong raw_ret = ges_discoverer_manager_get_timeout(Handle);
|
||||
ulong ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
set {
|
||||
ges_discoverer_manager_set_timeout(Handle, value);
|
||||
}
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_discoverer_manager_get_use_cache(IntPtr raw);
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void ges_discoverer_manager_set_use_cache(IntPtr raw, bool use_cache);
|
||||
|
||||
[GLib.Property ("use-cache")]
|
||||
public bool UseCache {
|
||||
get {
|
||||
bool raw_ret = ges_discoverer_manager_get_use_cache(Handle);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
set {
|
||||
ges_discoverer_manager_set_use_cache(Handle, value);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("load-serialized-info")]
|
||||
public event GES.LoadSerializedInfoHandler LoadSerializedInfo {
|
||||
add {
|
||||
this.AddSignalHandler ("load-serialized-info", value, typeof (GES.LoadSerializedInfoArgs));
|
||||
}
|
||||
remove {
|
||||
this.RemoveSignalHandler ("load-serialized-info", value);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("discovered")]
|
||||
public event GES.DiscoveredHandler Discovered {
|
||||
add {
|
||||
this.AddSignalHandler ("discovered", value, typeof (GES.DiscoveredArgs));
|
||||
}
|
||||
remove {
|
||||
this.RemoveSignalHandler ("discovered", value);
|
||||
}
|
||||
}
|
||||
|
||||
static DiscoveredNativeDelegate Discovered_cb_delegate;
|
||||
static DiscoveredNativeDelegate DiscoveredVMCallback {
|
||||
get {
|
||||
if (Discovered_cb_delegate == null)
|
||||
Discovered_cb_delegate = new DiscoveredNativeDelegate (Discovered_cb);
|
||||
return Discovered_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideDiscovered (GLib.GType gtype)
|
||||
{
|
||||
OverrideDiscovered (gtype, DiscoveredVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideDiscovered (GLib.GType gtype, DiscoveredNativeDelegate callback)
|
||||
{
|
||||
OverrideVirtualMethod (gtype, "discovered", callback);
|
||||
}
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate void DiscoveredNativeDelegate (IntPtr inst, IntPtr info, IntPtr error);
|
||||
|
||||
static void Discovered_cb (IntPtr inst, IntPtr info, IntPtr error)
|
||||
{
|
||||
try {
|
||||
DiscovererManager __obj = GLib.Object.GetObject (inst, false) as DiscovererManager;
|
||||
__obj.OnDiscovered (GLib.Object.GetObject(info) as Gst.PbUtils.DiscovererInfo, error);
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, false);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(GES.DiscovererManager), ConnectionMethod="OverrideDiscovered")]
|
||||
protected virtual void OnDiscovered (Gst.PbUtils.DiscovererInfo info, IntPtr error)
|
||||
{
|
||||
InternalDiscovered (info, error);
|
||||
}
|
||||
|
||||
private void InternalDiscovered (Gst.PbUtils.DiscovererInfo info, IntPtr error)
|
||||
{
|
||||
GLib.Value ret = GLib.Value.Empty;
|
||||
GLib.ValueArray inst_and_params = new GLib.ValueArray (3);
|
||||
GLib.Value[] vals = new GLib.Value [3];
|
||||
vals [0] = new GLib.Value (this);
|
||||
inst_and_params.Append (vals [0]);
|
||||
vals [1] = new GLib.Value (info);
|
||||
inst_and_params.Append (vals [1]);
|
||||
vals [2] = new GLib.Value (error);
|
||||
inst_and_params.Append (vals [2]);
|
||||
g_signal_chain_from_overridden (inst_and_params.ArrayPtr, ref ret);
|
||||
foreach (GLib.Value v in vals)
|
||||
v.Dispose ();
|
||||
}
|
||||
|
||||
static LoadSerializedInfoNativeDelegate LoadSerializedInfo_cb_delegate;
|
||||
static LoadSerializedInfoNativeDelegate LoadSerializedInfoVMCallback {
|
||||
get {
|
||||
if (LoadSerializedInfo_cb_delegate == null)
|
||||
LoadSerializedInfo_cb_delegate = new LoadSerializedInfoNativeDelegate (LoadSerializedInfo_cb);
|
||||
return LoadSerializedInfo_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideLoadSerializedInfo (GLib.GType gtype)
|
||||
{
|
||||
OverrideLoadSerializedInfo (gtype, LoadSerializedInfoVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideLoadSerializedInfo (GLib.GType gtype, LoadSerializedInfoNativeDelegate callback)
|
||||
{
|
||||
OverrideVirtualMethod (gtype, "load-serialized-info", callback);
|
||||
}
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate IntPtr LoadSerializedInfoNativeDelegate (IntPtr inst, IntPtr uri);
|
||||
|
||||
static IntPtr LoadSerializedInfo_cb (IntPtr inst, IntPtr uri)
|
||||
{
|
||||
try {
|
||||
DiscovererManager __obj = GLib.Object.GetObject (inst, false) as DiscovererManager;
|
||||
Gst.PbUtils.DiscovererInfo __result;
|
||||
__result = __obj.OnLoadSerializedInfo (GLib.Marshaller.Utf8PtrToString (uri));
|
||||
return __result == null ? IntPtr.Zero : __result.OwnedHandle;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
// NOTREACHED: above call does not return.
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(GES.DiscovererManager), ConnectionMethod="OverrideLoadSerializedInfo")]
|
||||
protected virtual Gst.PbUtils.DiscovererInfo OnLoadSerializedInfo (string uri)
|
||||
{
|
||||
return InternalLoadSerializedInfo (uri);
|
||||
}
|
||||
|
||||
private Gst.PbUtils.DiscovererInfo InternalLoadSerializedInfo (string uri)
|
||||
{
|
||||
GLib.Value ret = new GLib.Value (GLib.GType.Object);
|
||||
GLib.ValueArray inst_and_params = new GLib.ValueArray (2);
|
||||
GLib.Value[] vals = new GLib.Value [2];
|
||||
vals [0] = new GLib.Value (this);
|
||||
inst_and_params.Append (vals [0]);
|
||||
vals [1] = new GLib.Value (uri);
|
||||
inst_and_params.Append (vals [1]);
|
||||
g_signal_chain_from_overridden (inst_and_params.ArrayPtr, ref ret);
|
||||
foreach (GLib.Value v in vals)
|
||||
v.Dispose ();
|
||||
Gst.PbUtils.DiscovererInfo result = (Gst.PbUtils.DiscovererInfo) ret;
|
||||
ret.Dispose ();
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
// Internal representation of the wrapped structure ABI.
|
||||
static GLib.AbiStruct _class_abi = null;
|
||||
static public new GLib.AbiStruct class_abi {
|
||||
get {
|
||||
if (_class_abi == null)
|
||||
_class_abi = new GLib.AbiStruct (GLib.Object.class_abi.Fields);
|
||||
|
||||
return _class_abi;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// End of the ABI representation.
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr ges_discoverer_manager_get_type();
|
||||
|
||||
public static new GLib.GType GType {
|
||||
get {
|
||||
IntPtr raw_ret = ges_discoverer_manager_get_type();
|
||||
GLib.GType ret = new GLib.GType(raw_ret);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr ges_discoverer_manager_get_default();
|
||||
|
||||
public static GES.DiscovererManager Default {
|
||||
get {
|
||||
IntPtr raw_ret = ges_discoverer_manager_get_default();
|
||||
GES.DiscovererManager ret = GLib.Object.GetObject(raw_ret, true) as GES.DiscovererManager;
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static DiscovererManager ()
|
||||
{
|
||||
GtkSharp.GstEditingServices.ObjectManager.Initialize ();
|
||||
}
|
||||
|
||||
// Internal representation of the wrapped structure ABI.
|
||||
static GLib.AbiStruct _abi_info = null;
|
||||
static public new GLib.AbiStruct abi_info {
|
||||
get {
|
||||
if (_abi_info == null)
|
||||
_abi_info = new GLib.AbiStruct (GLib.Object.abi_info.Fields);
|
||||
|
||||
return _abi_info;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// End of the ABI representation.
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
|
@ -0,0 +1,30 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace GES {
|
||||
|
||||
using System;
|
||||
|
||||
public delegate void ErrorLoadingAssetHandler(object o, ErrorLoadingAssetArgs args);
|
||||
|
||||
public class ErrorLoadingAssetArgs : GLib.SignalArgs {
|
||||
public IntPtr Error{
|
||||
get {
|
||||
return (IntPtr) Args [0];
|
||||
}
|
||||
}
|
||||
|
||||
public string Id{
|
||||
get {
|
||||
return (string) Args [1];
|
||||
}
|
||||
}
|
||||
|
||||
public GLib.GType ExtractableType{
|
||||
get {
|
||||
return (GLib.GType) Args [2];
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -0,0 +1,24 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace GES {
|
||||
|
||||
using System;
|
||||
|
||||
public delegate void ErrorLoadingHandler(object o, ErrorLoadingArgs args);
|
||||
|
||||
public class ErrorLoadingArgs : GLib.SignalArgs {
|
||||
public GES.Timeline Timeline{
|
||||
get {
|
||||
return (GES.Timeline) Args [0];
|
||||
}
|
||||
}
|
||||
|
||||
public IntPtr Error{
|
||||
get {
|
||||
return (IntPtr) Args [1];
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -13,6 +13,7 @@ namespace GES {
|
|||
bool CheckMetaRegistered(string meta_item, out GES.MetaFlag flags, out GLib.GType type);
|
||||
void Foreach(GES.MetaForeachFunc func);
|
||||
bool GetBoolean(string meta_item, out bool dest);
|
||||
bool GetDate(string meta_item, out GLib.Date dest);
|
||||
bool GetDateTime(string meta_item, out Gst.DateTime dest);
|
||||
bool GetDouble(string meta_item, out double dest);
|
||||
bool GetFloat(string meta_item, out float dest);
|
||||
|
@ -26,6 +27,7 @@ namespace GES {
|
|||
string MetasToString();
|
||||
bool RegisterMeta(GES.MetaFlag flags, string meta_item, GLib.Value value);
|
||||
bool RegisterMetaBoolean(GES.MetaFlag flags, string meta_item, bool value);
|
||||
bool RegisterMetaDate(GES.MetaFlag flags, string meta_item, GLib.Date value);
|
||||
bool RegisterMetaDateTime(GES.MetaFlag flags, string meta_item, Gst.DateTime value);
|
||||
bool RegisterMetaDouble(GES.MetaFlag flags, string meta_item, double value);
|
||||
bool RegisterMetaFloat(GES.MetaFlag flags, string meta_item, float value);
|
||||
|
@ -36,6 +38,7 @@ namespace GES {
|
|||
bool RegisterMetaUint64(GES.MetaFlag flags, string meta_item, ulong value);
|
||||
bool RegisterStaticMeta(GES.MetaFlag flags, string meta_item, GLib.GType type);
|
||||
bool SetBoolean(string meta_item, bool value);
|
||||
bool SetDate(string meta_item, GLib.Date value);
|
||||
bool SetDateTime(string meta_item, Gst.DateTime value);
|
||||
bool SetDouble(string meta_item, double value);
|
||||
bool SetFloat(string meta_item, float value);
|
||||
|
|
|
@ -573,6 +573,19 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_get_date(IntPtr raw, IntPtr meta_item, out IntPtr dest);
|
||||
|
||||
public bool GetDate(string meta_item, out GLib.Date dest) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
IntPtr native_dest;
|
||||
bool raw_ret = ges_meta_container_get_date(Handle, native_meta_item, out native_dest);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
dest = new GLib.Date(native_dest);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_get_date_time(IntPtr raw, IntPtr meta_item, out IntPtr dest);
|
||||
|
||||
|
@ -718,6 +731,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_register_meta_date(IntPtr raw, int flags, IntPtr meta_item, IntPtr value);
|
||||
|
||||
public bool RegisterMetaDate(GES.MetaFlag flags, string meta_item, GLib.Date value) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
bool raw_ret = ges_meta_container_register_meta_date(Handle, (int) flags, native_meta_item, value == null ? IntPtr.Zero : value.Handle);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_register_meta_date_time(IntPtr raw, int flags, IntPtr meta_item, IntPtr value);
|
||||
|
||||
|
@ -830,6 +854,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_set_date(IntPtr raw, IntPtr meta_item, IntPtr value);
|
||||
|
||||
public bool SetDate(string meta_item, GLib.Date value) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
bool raw_ret = ges_meta_container_set_date(Handle, native_meta_item, value == null ? IntPtr.Zero : value.Handle);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_set_date_time(IntPtr raw, IntPtr meta_item, IntPtr value);
|
||||
|
||||
|
|
|
@ -0,0 +1,18 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace GES {
|
||||
|
||||
using System;
|
||||
|
||||
public delegate void LoadSerializedInfoHandler(object o, LoadSerializedInfoArgs args);
|
||||
|
||||
public class LoadSerializedInfoArgs : GLib.SignalArgs {
|
||||
public string Uri{
|
||||
get {
|
||||
return (string) Args [0];
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -99,6 +99,19 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_get_date(IntPtr raw, IntPtr meta_item, out IntPtr dest);
|
||||
|
||||
public bool GetDate(string meta_item, out GLib.Date dest) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
IntPtr native_dest;
|
||||
bool raw_ret = ges_meta_container_get_date(Handle, native_meta_item, out native_dest);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
dest = new GLib.Date(native_dest);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_get_date_time(IntPtr raw, IntPtr meta_item, out IntPtr dest);
|
||||
|
||||
|
@ -244,6 +257,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_register_meta_date(IntPtr raw, int flags, IntPtr meta_item, IntPtr value);
|
||||
|
||||
public bool RegisterMetaDate(GES.MetaFlag flags, string meta_item, GLib.Date value) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
bool raw_ret = ges_meta_container_register_meta_date(Handle, (int) flags, native_meta_item, value == null ? IntPtr.Zero : value.Handle);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_register_meta_date_time(IntPtr raw, int flags, IntPtr meta_item, IntPtr value);
|
||||
|
||||
|
@ -356,6 +380,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_set_date(IntPtr raw, IntPtr meta_item, IntPtr value);
|
||||
|
||||
public bool SetDate(string meta_item, GLib.Date value) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
bool raw_ret = ges_meta_container_set_date(Handle, native_meta_item, value == null ? IntPtr.Zero : value.Handle);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_set_date_time(IntPtr raw, IntPtr meta_item, IntPtr value);
|
||||
|
||||
|
|
29
subprojects/gstreamer-sharp/ges/generated/GES/MarkerFlags.cs
Normal file
29
subprojects/gstreamer-sharp/ges/generated/GES/MarkerFlags.cs
Normal file
|
@ -0,0 +1,29 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace GES {
|
||||
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
#region Autogenerated code
|
||||
[Flags]
|
||||
[GLib.GType (typeof (GES.MarkerFlagsGType))]
|
||||
public enum MarkerFlags : uint {
|
||||
|
||||
None = 0,
|
||||
Snappable = 1,
|
||||
}
|
||||
|
||||
internal class MarkerFlagsGType {
|
||||
[DllImport ("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr ges_marker_flags_get_type ();
|
||||
|
||||
public static GLib.GType GType {
|
||||
get {
|
||||
return new GLib.GType (ges_marker_flags_get_type ());
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
}
|
|
@ -25,6 +25,21 @@ namespace GES {
|
|||
Raw = ges_marker_list_new();
|
||||
}
|
||||
|
||||
[GLib.Property ("flags")]
|
||||
public GES.MarkerFlags Flags {
|
||||
get {
|
||||
GLib.Value val = GetProperty ("flags");
|
||||
GES.MarkerFlags ret = (GES.MarkerFlags) (Enum) val;
|
||||
val.Dispose ();
|
||||
return ret;
|
||||
}
|
||||
set {
|
||||
GLib.Value val = new GLib.Value((Enum) value);
|
||||
SetProperty("flags", val);
|
||||
val.Dispose ();
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("marker-added")]
|
||||
public event GES.MarkerAddedHandler MarkerAdded {
|
||||
add {
|
||||
|
|
|
@ -157,6 +157,19 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_get_date(IntPtr raw, IntPtr meta_item, out IntPtr dest);
|
||||
|
||||
public bool GetDate(string meta_item, out GLib.Date dest) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
IntPtr native_dest;
|
||||
bool raw_ret = ges_meta_container_get_date(Handle, native_meta_item, out native_dest);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
dest = new GLib.Date(native_dest);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_get_date_time(IntPtr raw, IntPtr meta_item, out IntPtr dest);
|
||||
|
||||
|
@ -302,6 +315,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_register_meta_date(IntPtr raw, int flags, IntPtr meta_item, IntPtr value);
|
||||
|
||||
public bool RegisterMetaDate(GES.MetaFlag flags, string meta_item, GLib.Date value) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
bool raw_ret = ges_meta_container_register_meta_date(Handle, (int) flags, native_meta_item, value == null ? IntPtr.Zero : value.Handle);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_register_meta_date_time(IntPtr raw, int flags, IntPtr meta_item, IntPtr value);
|
||||
|
||||
|
@ -414,6 +438,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_set_date(IntPtr raw, IntPtr meta_item, IntPtr value);
|
||||
|
||||
public bool SetDate(string meta_item, GLib.Date value) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
bool raw_ret = ges_meta_container_set_date(Handle, native_meta_item, value == null ? IntPtr.Zero : value.Handle);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_set_date_time(IntPtr raw, IntPtr meta_item, IntPtr value);
|
||||
|
||||
|
|
|
@ -0,0 +1,24 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace GES {
|
||||
|
||||
using System;
|
||||
|
||||
public delegate void MissingUriHandler(object o, MissingUriArgs args);
|
||||
|
||||
public class MissingUriArgs : GLib.SignalArgs {
|
||||
public IntPtr Error{
|
||||
get {
|
||||
return (IntPtr) Args [0];
|
||||
}
|
||||
}
|
||||
|
||||
public GES.Asset WrongAsset{
|
||||
get {
|
||||
return (GES.Asset) Args [1];
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -195,6 +195,10 @@ namespace GES {
|
|||
ges_pipeline_preview_set_audio_sink(Handle, sink == null ? IntPtr.Zero : sink.Handle);
|
||||
}
|
||||
|
||||
public void PreviewSetAudioSink() {
|
||||
PreviewSetAudioSink (null);
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void ges_pipeline_preview_set_video_sink(IntPtr raw, IntPtr sink);
|
||||
|
||||
|
@ -202,6 +206,10 @@ namespace GES {
|
|||
ges_pipeline_preview_set_video_sink(Handle, sink == null ? IntPtr.Zero : sink.Handle);
|
||||
}
|
||||
|
||||
public void PreviewSetVideoSink() {
|
||||
PreviewSetVideoSink (null);
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern unsafe bool ges_pipeline_save_thumbnail(IntPtr raw, int width, int height, IntPtr format, IntPtr location, out IntPtr error);
|
||||
|
||||
|
@ -241,7 +249,7 @@ namespace GES {
|
|||
static extern bool ges_pipeline_set_timeline(IntPtr raw, IntPtr timeline);
|
||||
|
||||
public bool SetTimeline(GES.Timeline timeline) {
|
||||
bool raw_ret = ges_pipeline_set_timeline(Handle, timeline == null ? IntPtr.Zero : timeline.OwnedHandle);
|
||||
bool raw_ret = ges_pipeline_set_timeline(Handle, timeline == null ? IntPtr.Zero : timeline.Handle);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
|
|
@ -53,6 +53,16 @@ namespace GES {
|
|||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("error-loading")]
|
||||
public event GES.ErrorLoadingHandler ErrorLoading {
|
||||
add {
|
||||
this.AddSignalHandler ("error-loading", value, typeof (GES.ErrorLoadingArgs));
|
||||
}
|
||||
remove {
|
||||
this.RemoveSignalHandler ("error-loading", value);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("asset-added")]
|
||||
public event GES.AssetAddedHandler AssetAdded {
|
||||
add {
|
||||
|
@ -63,6 +73,16 @@ namespace GES {
|
|||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("error-loading-asset")]
|
||||
public event GES.ErrorLoadingAssetHandler ErrorLoadingAsset {
|
||||
add {
|
||||
this.AddSignalHandler ("error-loading-asset", value, typeof (GES.ErrorLoadingAssetArgs));
|
||||
}
|
||||
remove {
|
||||
this.RemoveSignalHandler ("error-loading-asset", value);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("asset-removed")]
|
||||
public event GES.AssetRemovedHandler AssetRemoved {
|
||||
add {
|
||||
|
@ -83,6 +103,16 @@ namespace GES {
|
|||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("missing-uri")]
|
||||
public event GES.MissingUriHandler MissingUri {
|
||||
add {
|
||||
this.AddSignalHandler ("missing-uri", value, typeof (GES.MissingUriArgs));
|
||||
}
|
||||
remove {
|
||||
this.RemoveSignalHandler ("missing-uri", value);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("asset-loading")]
|
||||
public event GES.AssetLoadingHandler AssetLoading {
|
||||
add {
|
||||
|
@ -93,6 +123,114 @@ namespace GES {
|
|||
}
|
||||
}
|
||||
|
||||
static ErrorLoadingNativeDelegate ErrorLoading_cb_delegate;
|
||||
static ErrorLoadingNativeDelegate ErrorLoadingVMCallback {
|
||||
get {
|
||||
if (ErrorLoading_cb_delegate == null)
|
||||
ErrorLoading_cb_delegate = new ErrorLoadingNativeDelegate (ErrorLoading_cb);
|
||||
return ErrorLoading_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideErrorLoading (GLib.GType gtype)
|
||||
{
|
||||
OverrideErrorLoading (gtype, ErrorLoadingVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideErrorLoading (GLib.GType gtype, ErrorLoadingNativeDelegate callback)
|
||||
{
|
||||
OverrideVirtualMethod (gtype, "error-loading", callback);
|
||||
}
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate void ErrorLoadingNativeDelegate (IntPtr inst, IntPtr timeline, IntPtr error);
|
||||
|
||||
static void ErrorLoading_cb (IntPtr inst, IntPtr timeline, IntPtr error)
|
||||
{
|
||||
try {
|
||||
Project __obj = GLib.Object.GetObject (inst, false) as Project;
|
||||
__obj.OnErrorLoading (GLib.Object.GetObject(timeline) as GES.Timeline, error);
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, false);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(GES.Project), ConnectionMethod="OverrideErrorLoading")]
|
||||
protected virtual void OnErrorLoading (GES.Timeline timeline, IntPtr error)
|
||||
{
|
||||
InternalErrorLoading (timeline, error);
|
||||
}
|
||||
|
||||
private void InternalErrorLoading (GES.Timeline timeline, IntPtr error)
|
||||
{
|
||||
GLib.Value ret = GLib.Value.Empty;
|
||||
GLib.ValueArray inst_and_params = new GLib.ValueArray (3);
|
||||
GLib.Value[] vals = new GLib.Value [3];
|
||||
vals [0] = new GLib.Value (this);
|
||||
inst_and_params.Append (vals [0]);
|
||||
vals [1] = new GLib.Value (timeline);
|
||||
inst_and_params.Append (vals [1]);
|
||||
vals [2] = new GLib.Value (error);
|
||||
inst_and_params.Append (vals [2]);
|
||||
g_signal_chain_from_overridden (inst_and_params.ArrayPtr, ref ret);
|
||||
foreach (GLib.Value v in vals)
|
||||
v.Dispose ();
|
||||
}
|
||||
|
||||
static ErrorLoadingAssetNativeDelegate ErrorLoadingAsset_cb_delegate;
|
||||
static ErrorLoadingAssetNativeDelegate ErrorLoadingAssetVMCallback {
|
||||
get {
|
||||
if (ErrorLoadingAsset_cb_delegate == null)
|
||||
ErrorLoadingAsset_cb_delegate = new ErrorLoadingAssetNativeDelegate (ErrorLoadingAsset_cb);
|
||||
return ErrorLoadingAsset_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideErrorLoadingAsset (GLib.GType gtype)
|
||||
{
|
||||
OverrideErrorLoadingAsset (gtype, ErrorLoadingAssetVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideErrorLoadingAsset (GLib.GType gtype, ErrorLoadingAssetNativeDelegate callback)
|
||||
{
|
||||
OverrideVirtualMethod (gtype, "error-loading-asset", callback);
|
||||
}
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate void ErrorLoadingAssetNativeDelegate (IntPtr inst, IntPtr error, IntPtr id, IntPtr extractable_type);
|
||||
|
||||
static void ErrorLoadingAsset_cb (IntPtr inst, IntPtr error, IntPtr id, IntPtr extractable_type)
|
||||
{
|
||||
try {
|
||||
Project __obj = GLib.Object.GetObject (inst, false) as Project;
|
||||
__obj.OnErrorLoadingAsset (error, GLib.Marshaller.Utf8PtrToString (id), new GLib.GType(extractable_type));
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, false);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(GES.Project), ConnectionMethod="OverrideErrorLoadingAsset")]
|
||||
protected virtual void OnErrorLoadingAsset (IntPtr error, string id, GLib.GType extractable_type)
|
||||
{
|
||||
InternalErrorLoadingAsset (error, id, extractable_type);
|
||||
}
|
||||
|
||||
private void InternalErrorLoadingAsset (IntPtr error, string id, GLib.GType extractable_type)
|
||||
{
|
||||
GLib.Value ret = GLib.Value.Empty;
|
||||
GLib.ValueArray inst_and_params = new GLib.ValueArray (4);
|
||||
GLib.Value[] vals = new GLib.Value [4];
|
||||
vals [0] = new GLib.Value (this);
|
||||
inst_and_params.Append (vals [0]);
|
||||
vals [1] = new GLib.Value (error);
|
||||
inst_and_params.Append (vals [1]);
|
||||
vals [2] = new GLib.Value (id);
|
||||
inst_and_params.Append (vals [2]);
|
||||
vals [3] = new GLib.Value (extractable_type);
|
||||
inst_and_params.Append (vals [3]);
|
||||
g_signal_chain_from_overridden (inst_and_params.ArrayPtr, ref ret);
|
||||
foreach (GLib.Value v in vals)
|
||||
v.Dispose ();
|
||||
}
|
||||
|
||||
static AssetAddedNativeDelegate AssetAdded_cb_delegate;
|
||||
static AssetAddedNativeDelegate AssetAddedVMCallback {
|
||||
get {
|
||||
|
@ -252,6 +390,124 @@ namespace GES {
|
|||
unmanaged (this.Handle, asset == null ? IntPtr.Zero : asset.Handle);
|
||||
}
|
||||
|
||||
static MissingUriNativeDelegate MissingUri_cb_delegate;
|
||||
static MissingUriNativeDelegate MissingUriVMCallback {
|
||||
get {
|
||||
if (MissingUri_cb_delegate == null)
|
||||
MissingUri_cb_delegate = new MissingUriNativeDelegate (MissingUri_cb);
|
||||
return MissingUri_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideMissingUri (GLib.GType gtype)
|
||||
{
|
||||
OverrideMissingUri (gtype, MissingUriVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideMissingUri (GLib.GType gtype, MissingUriNativeDelegate callback)
|
||||
{
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) gtype.GetClassPtr()) + (long) class_abi.GetFieldOffset("missing_uri"));
|
||||
*raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate) callback);
|
||||
}
|
||||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate IntPtr MissingUriNativeDelegate (IntPtr inst, IntPtr error, IntPtr wrong_asset);
|
||||
|
||||
static IntPtr MissingUri_cb (IntPtr inst, IntPtr error, IntPtr wrong_asset)
|
||||
{
|
||||
try {
|
||||
Project __obj = GLib.Object.GetObject (inst, false) as Project;
|
||||
string __result;
|
||||
__result = __obj.OnMissingUri (error, GLib.Object.GetObject(wrong_asset) as GES.Asset);
|
||||
return GLib.Marshaller.StringToPtrGStrdup(__result);
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
// NOTREACHED: above call does not return.
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(GES.Project), ConnectionMethod="OverrideMissingUri")]
|
||||
protected virtual string OnMissingUri (IntPtr error, GES.Asset wrong_asset)
|
||||
{
|
||||
return InternalMissingUri (error, wrong_asset);
|
||||
}
|
||||
|
||||
private string InternalMissingUri (IntPtr error, GES.Asset wrong_asset)
|
||||
{
|
||||
MissingUriNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("missing_uri"));
|
||||
unmanaged = (MissingUriNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(MissingUriNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return null;
|
||||
|
||||
IntPtr __result = unmanaged (this.Handle, error, wrong_asset == null ? IntPtr.Zero : wrong_asset.Handle);
|
||||
return GLib.Marshaller.PtrToStringGFree(__result);
|
||||
}
|
||||
|
||||
static LoadingErrorNativeDelegate LoadingError_cb_delegate;
|
||||
static LoadingErrorNativeDelegate LoadingErrorVMCallback {
|
||||
get {
|
||||
if (LoadingError_cb_delegate == null)
|
||||
LoadingError_cb_delegate = new LoadingErrorNativeDelegate (LoadingError_cb);
|
||||
return LoadingError_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideLoadingError (GLib.GType gtype)
|
||||
{
|
||||
OverrideLoadingError (gtype, LoadingErrorVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideLoadingError (GLib.GType gtype, LoadingErrorNativeDelegate callback)
|
||||
{
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) gtype.GetClassPtr()) + (long) class_abi.GetFieldOffset("loading_error"));
|
||||
*raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate) callback);
|
||||
}
|
||||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate bool LoadingErrorNativeDelegate (IntPtr inst, IntPtr error, IntPtr id, IntPtr extractable_type);
|
||||
|
||||
static bool LoadingError_cb (IntPtr inst, IntPtr error, IntPtr id, IntPtr extractable_type)
|
||||
{
|
||||
try {
|
||||
Project __obj = GLib.Object.GetObject (inst, false) as Project;
|
||||
bool __result;
|
||||
__result = __obj.OnLoadingError (error, GLib.Marshaller.Utf8PtrToString (id), new GLib.GType(extractable_type));
|
||||
return __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
// NOTREACHED: above call does not return.
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(GES.Project), ConnectionMethod="OverrideLoadingError")]
|
||||
protected virtual bool OnLoadingError (IntPtr error, string id, GLib.GType extractable_type)
|
||||
{
|
||||
return InternalLoadingError (error, id, extractable_type);
|
||||
}
|
||||
|
||||
private bool InternalLoadingError (IntPtr error, string id, GLib.GType extractable_type)
|
||||
{
|
||||
LoadingErrorNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("loading_error"));
|
||||
unmanaged = (LoadingErrorNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(LoadingErrorNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return false;
|
||||
|
||||
IntPtr native_id = GLib.Marshaller.StringToPtrGStrdup (id);
|
||||
bool __result = unmanaged (this.Handle, error, native_id, extractable_type.Val);
|
||||
GLib.Marshaller.Free (native_id);
|
||||
return __result;
|
||||
}
|
||||
|
||||
static LoadedNativeDelegate Loaded_cb_delegate;
|
||||
static LoadedNativeDelegate LoadedVMCallback {
|
||||
get {
|
||||
|
|
|
@ -18,6 +18,122 @@ namespace GES {
|
|||
CreateNativeObject (new string [0], new GLib.Value [0]);
|
||||
}
|
||||
|
||||
static SelectPadNativeDelegate SelectPad_cb_delegate;
|
||||
static SelectPadNativeDelegate SelectPadVMCallback {
|
||||
get {
|
||||
if (SelectPad_cb_delegate == null)
|
||||
SelectPad_cb_delegate = new SelectPadNativeDelegate (SelectPad_cb);
|
||||
return SelectPad_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideSelectPad (GLib.GType gtype)
|
||||
{
|
||||
OverrideSelectPad (gtype, SelectPadVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideSelectPad (GLib.GType gtype, SelectPadNativeDelegate callback)
|
||||
{
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) gtype.GetClassPtr()) + (long) class_abi.GetFieldOffset("select_pad"));
|
||||
*raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate) callback);
|
||||
}
|
||||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate bool SelectPadNativeDelegate (IntPtr inst, IntPtr pad);
|
||||
|
||||
static bool SelectPad_cb (IntPtr inst, IntPtr pad)
|
||||
{
|
||||
try {
|
||||
Source __obj = GLib.Object.GetObject (inst, false) as Source;
|
||||
bool __result;
|
||||
__result = __obj.OnSelectPad (GLib.Object.GetObject(pad) as Gst.Pad);
|
||||
return __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
// NOTREACHED: above call does not return.
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(GES.Source), ConnectionMethod="OverrideSelectPad")]
|
||||
protected virtual bool OnSelectPad (Gst.Pad pad)
|
||||
{
|
||||
return InternalSelectPad (pad);
|
||||
}
|
||||
|
||||
private bool InternalSelectPad (Gst.Pad pad)
|
||||
{
|
||||
SelectPadNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("select_pad"));
|
||||
unmanaged = (SelectPadNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(SelectPadNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return false;
|
||||
|
||||
bool __result = unmanaged (this.Handle, pad == null ? IntPtr.Zero : pad.Handle);
|
||||
return __result;
|
||||
}
|
||||
|
||||
static CreateSourceNativeDelegate CreateSource_cb_delegate;
|
||||
static CreateSourceNativeDelegate CreateSourceVMCallback {
|
||||
get {
|
||||
if (CreateSource_cb_delegate == null)
|
||||
CreateSource_cb_delegate = new CreateSourceNativeDelegate (CreateSource_cb);
|
||||
return CreateSource_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideCreateSource (GLib.GType gtype)
|
||||
{
|
||||
OverrideCreateSource (gtype, CreateSourceVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideCreateSource (GLib.GType gtype, CreateSourceNativeDelegate callback)
|
||||
{
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) gtype.GetClassPtr()) + (long) class_abi.GetFieldOffset("create_source"));
|
||||
*raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate) callback);
|
||||
}
|
||||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate IntPtr CreateSourceNativeDelegate (IntPtr inst);
|
||||
|
||||
static IntPtr CreateSource_cb (IntPtr inst)
|
||||
{
|
||||
try {
|
||||
Source __obj = GLib.Object.GetObject (inst, false) as Source;
|
||||
Gst.Element __result;
|
||||
__result = __obj.OnCreateSource ();
|
||||
return __result == null ? IntPtr.Zero : __result.Handle;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
// NOTREACHED: above call does not return.
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(GES.Source), ConnectionMethod="OverrideCreateSource")]
|
||||
protected virtual Gst.Element OnCreateSource ()
|
||||
{
|
||||
return InternalCreateSource ();
|
||||
}
|
||||
|
||||
private Gst.Element InternalCreateSource ()
|
||||
{
|
||||
CreateSourceNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("create_source"));
|
||||
unmanaged = (CreateSourceNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(CreateSourceNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return null;
|
||||
|
||||
IntPtr __result = unmanaged (this.Handle);
|
||||
return GLib.Object.GetObject(__result) as Gst.Element;
|
||||
}
|
||||
|
||||
|
||||
// Internal representation of the wrapped structure ABI.
|
||||
static GLib.AbiStruct _class_abi = null;
|
||||
|
@ -25,10 +141,26 @@ namespace GES {
|
|||
get {
|
||||
if (_class_abi == null)
|
||||
_class_abi = new GLib.AbiStruct (new List<GLib.AbiField>{
|
||||
new GLib.AbiField("_ges_reserved"
|
||||
new GLib.AbiField("select_pad"
|
||||
, GES.TrackElement.class_abi.Fields
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr)) * 4 // _ges_reserved
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr)) // select_pad
|
||||
, null
|
||||
, "create_source"
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr))
|
||||
, 0
|
||||
),
|
||||
new GLib.AbiField("create_source"
|
||||
, -1
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr)) // create_source
|
||||
, "select_pad"
|
||||
, "_ges_reserved"
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr))
|
||||
, 0
|
||||
),
|
||||
new GLib.AbiField("_ges_reserved"
|
||||
, -1
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr)) * 2 // _ges_reserved
|
||||
, "create_source"
|
||||
, null
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr))
|
||||
, 0
|
||||
|
|
|
@ -791,7 +791,7 @@ namespace GES {
|
|||
static extern bool ges_timeline_add_track(IntPtr raw, IntPtr track);
|
||||
|
||||
public bool AddTrack(GES.Track track) {
|
||||
bool raw_ret = ges_timeline_add_track(Handle, track == null ? IntPtr.Zero : track.OwnedHandle);
|
||||
bool raw_ret = ges_timeline_add_track(Handle, track == null ? IntPtr.Zero : track.Handle);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
@ -823,6 +823,31 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void ges_timeline_disable_edit_apis(IntPtr raw, bool disable_edit_apis);
|
||||
|
||||
public void DisableEditApis(bool disable_edit_apis) {
|
||||
ges_timeline_disable_edit_apis(Handle, disable_edit_apis);
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void ges_timeline_freeze_commit(IntPtr raw);
|
||||
|
||||
public void FreezeCommit() {
|
||||
ges_timeline_freeze_commit(Handle);
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_timeline_get_edit_apis_disabled(IntPtr raw);
|
||||
|
||||
public bool EditApisDisabled {
|
||||
get {
|
||||
bool raw_ret = ges_timeline_get_edit_apis_disabled(Handle);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr ges_timeline_get_element(IntPtr raw, IntPtr name);
|
||||
|
||||
|
@ -967,6 +992,13 @@ namespace GES {
|
|||
return SaveToUri (uri, null, overwrite);
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void ges_timeline_thaw_commit(IntPtr raw);
|
||||
|
||||
public void ThawCommit() {
|
||||
ges_timeline_thaw_commit(Handle);
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr ges_extractable_get_asset(IntPtr raw);
|
||||
|
||||
|
@ -1043,6 +1075,19 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_get_date(IntPtr raw, IntPtr meta_item, out IntPtr dest);
|
||||
|
||||
public bool GetDate(string meta_item, out GLib.Date dest) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
IntPtr native_dest;
|
||||
bool raw_ret = ges_meta_container_get_date(Handle, native_meta_item, out native_dest);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
dest = new GLib.Date(native_dest);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_get_date_time(IntPtr raw, IntPtr meta_item, out IntPtr dest);
|
||||
|
||||
|
@ -1188,6 +1233,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_register_meta_date(IntPtr raw, int flags, IntPtr meta_item, IntPtr value);
|
||||
|
||||
public bool RegisterMetaDate(GES.MetaFlag flags, string meta_item, GLib.Date value) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
bool raw_ret = ges_meta_container_register_meta_date(Handle, (int) flags, native_meta_item, value == null ? IntPtr.Zero : value.Handle);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_register_meta_date_time(IntPtr raw, int flags, IntPtr meta_item, IntPtr value);
|
||||
|
||||
|
@ -1300,6 +1356,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_set_date(IntPtr raw, IntPtr meta_item, IntPtr value);
|
||||
|
||||
public bool SetDate(string meta_item, GLib.Date value) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
bool raw_ret = ges_meta_container_set_date(Handle, native_meta_item, value == null ? IntPtr.Zero : value.Handle);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_set_date_time(IntPtr raw, IntPtr meta_item, IntPtr value);
|
||||
|
||||
|
|
|
@ -2042,6 +2042,19 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_get_date(IntPtr raw, IntPtr meta_item, out IntPtr dest);
|
||||
|
||||
public bool GetDate(string meta_item, out GLib.Date dest) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
IntPtr native_dest;
|
||||
bool raw_ret = ges_meta_container_get_date(Handle, native_meta_item, out native_dest);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
dest = new GLib.Date(native_dest);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_get_date_time(IntPtr raw, IntPtr meta_item, out IntPtr dest);
|
||||
|
||||
|
@ -2187,6 +2200,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_register_meta_date(IntPtr raw, int flags, IntPtr meta_item, IntPtr value);
|
||||
|
||||
public bool RegisterMetaDate(GES.MetaFlag flags, string meta_item, GLib.Date value) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
bool raw_ret = ges_meta_container_register_meta_date(Handle, (int) flags, native_meta_item, value == null ? IntPtr.Zero : value.Handle);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_register_meta_date_time(IntPtr raw, int flags, IntPtr meta_item, IntPtr value);
|
||||
|
||||
|
@ -2299,6 +2323,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_set_date(IntPtr raw, IntPtr meta_item, IntPtr value);
|
||||
|
||||
public bool SetDate(string meta_item, GLib.Date value) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
bool raw_ret = ges_meta_container_set_date(Handle, native_meta_item, value == null ? IntPtr.Zero : value.Handle);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_set_date_time(IntPtr raw, IntPtr meta_item, IntPtr value);
|
||||
|
||||
|
|
|
@ -70,7 +70,7 @@ namespace GES {
|
|||
public string FontDesc {
|
||||
get {
|
||||
IntPtr raw_ret = ges_title_clip_get_font_desc(Handle);
|
||||
string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
|
||||
string ret = GLib.Marshaller.PtrToStringGFree(raw_ret);
|
||||
return ret;
|
||||
}
|
||||
set {
|
||||
|
@ -110,7 +110,7 @@ namespace GES {
|
|||
public string Text {
|
||||
get {
|
||||
IntPtr raw_ret = ges_title_clip_get_text(Handle);
|
||||
string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
|
||||
string ret = GLib.Marshaller.PtrToStringGFree(raw_ret);
|
||||
return ret;
|
||||
}
|
||||
set {
|
||||
|
|
|
@ -475,6 +475,19 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_get_date(IntPtr raw, IntPtr meta_item, out IntPtr dest);
|
||||
|
||||
public bool GetDate(string meta_item, out GLib.Date dest) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
IntPtr native_dest;
|
||||
bool raw_ret = ges_meta_container_get_date(Handle, native_meta_item, out native_dest);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
dest = new GLib.Date(native_dest);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_get_date_time(IntPtr raw, IntPtr meta_item, out IntPtr dest);
|
||||
|
||||
|
@ -620,6 +633,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_register_meta_date(IntPtr raw, int flags, IntPtr meta_item, IntPtr value);
|
||||
|
||||
public bool RegisterMetaDate(GES.MetaFlag flags, string meta_item, GLib.Date value) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
bool raw_ret = ges_meta_container_register_meta_date(Handle, (int) flags, native_meta_item, value == null ? IntPtr.Zero : value.Handle);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_register_meta_date_time(IntPtr raw, int flags, IntPtr meta_item, IntPtr value);
|
||||
|
||||
|
@ -732,6 +756,17 @@ namespace GES {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_set_date(IntPtr raw, IntPtr meta_item, IntPtr value);
|
||||
|
||||
public bool SetDate(string meta_item, GLib.Date value) {
|
||||
IntPtr native_meta_item = GLib.Marshaller.StringToPtrGStrdup (meta_item);
|
||||
bool raw_ret = ges_meta_container_set_date(Handle, native_meta_item, value == null ? IntPtr.Zero : value.Handle);
|
||||
bool ret = raw_ret;
|
||||
GLib.Marshaller.Free (native_meta_item);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_meta_container_set_date_time(IntPtr raw, IntPtr meta_item, IntPtr value);
|
||||
|
||||
|
|
|
@ -219,6 +219,122 @@ namespace GES {
|
|||
v.Dispose ();
|
||||
}
|
||||
|
||||
static CreateGnlObjectNativeDelegate CreateGnlObject_cb_delegate;
|
||||
static CreateGnlObjectNativeDelegate CreateGnlObjectVMCallback {
|
||||
get {
|
||||
if (CreateGnlObject_cb_delegate == null)
|
||||
CreateGnlObject_cb_delegate = new CreateGnlObjectNativeDelegate (CreateGnlObject_cb);
|
||||
return CreateGnlObject_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideCreateGnlObject (GLib.GType gtype)
|
||||
{
|
||||
OverrideCreateGnlObject (gtype, CreateGnlObjectVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideCreateGnlObject (GLib.GType gtype, CreateGnlObjectNativeDelegate callback)
|
||||
{
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) gtype.GetClassPtr()) + (long) class_abi.GetFieldOffset("create_gnl_object"));
|
||||
*raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate) callback);
|
||||
}
|
||||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate IntPtr CreateGnlObjectNativeDelegate (IntPtr inst);
|
||||
|
||||
static IntPtr CreateGnlObject_cb (IntPtr inst)
|
||||
{
|
||||
try {
|
||||
TrackElement __obj = GLib.Object.GetObject (inst, false) as TrackElement;
|
||||
Gst.Element __result;
|
||||
__result = __obj.OnCreateGnlObject ();
|
||||
return __result == null ? IntPtr.Zero : __result.Handle;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
// NOTREACHED: above call does not return.
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(GES.TrackElement), ConnectionMethod="OverrideCreateGnlObject")]
|
||||
protected virtual Gst.Element OnCreateGnlObject ()
|
||||
{
|
||||
return InternalCreateGnlObject ();
|
||||
}
|
||||
|
||||
private Gst.Element InternalCreateGnlObject ()
|
||||
{
|
||||
CreateGnlObjectNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("create_gnl_object"));
|
||||
unmanaged = (CreateGnlObjectNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(CreateGnlObjectNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return null;
|
||||
|
||||
IntPtr __result = unmanaged (this.Handle);
|
||||
return GLib.Object.GetObject(__result) as Gst.Element;
|
||||
}
|
||||
|
||||
static CreateElementNativeDelegate CreateElement_cb_delegate;
|
||||
static CreateElementNativeDelegate CreateElementVMCallback {
|
||||
get {
|
||||
if (CreateElement_cb_delegate == null)
|
||||
CreateElement_cb_delegate = new CreateElementNativeDelegate (CreateElement_cb);
|
||||
return CreateElement_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideCreateElement (GLib.GType gtype)
|
||||
{
|
||||
OverrideCreateElement (gtype, CreateElementVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideCreateElement (GLib.GType gtype, CreateElementNativeDelegate callback)
|
||||
{
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) gtype.GetClassPtr()) + (long) class_abi.GetFieldOffset("create_element"));
|
||||
*raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate) callback);
|
||||
}
|
||||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate IntPtr CreateElementNativeDelegate (IntPtr inst);
|
||||
|
||||
static IntPtr CreateElement_cb (IntPtr inst)
|
||||
{
|
||||
try {
|
||||
TrackElement __obj = GLib.Object.GetObject (inst, false) as TrackElement;
|
||||
Gst.Element __result;
|
||||
__result = __obj.OnCreateElement ();
|
||||
return __result == null ? IntPtr.Zero : __result.Handle;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
// NOTREACHED: above call does not return.
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(GES.TrackElement), ConnectionMethod="OverrideCreateElement")]
|
||||
protected virtual Gst.Element OnCreateElement ()
|
||||
{
|
||||
return InternalCreateElement ();
|
||||
}
|
||||
|
||||
private Gst.Element InternalCreateElement ()
|
||||
{
|
||||
CreateElementNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("create_element"));
|
||||
unmanaged = (CreateElementNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(CreateElementNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return null;
|
||||
|
||||
IntPtr __result = unmanaged (this.Handle);
|
||||
return GLib.Object.GetObject(__result) as Gst.Element;
|
||||
}
|
||||
|
||||
static ActiveChangedNativeDelegate ActiveChanged_cb_delegate;
|
||||
static ActiveChangedNativeDelegate ActiveChangedVMCallback {
|
||||
get {
|
||||
|
@ -497,25 +613,16 @@ namespace GES {
|
|||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void ges_track_element_add_children_props(IntPtr raw, IntPtr element, IntPtr[] wanted_categories, IntPtr[] blacklist, IntPtr[] whitelist);
|
||||
static extern void ges_track_element_add_children_props(IntPtr raw, IntPtr element, IntPtr wanted_categories, IntPtr blacklist, IntPtr whitelist);
|
||||
|
||||
public void AddChildrenProps(Gst.Element element, string[] wanted_categories, string[] blacklist, string[] whitelist) {
|
||||
int cnt_wanted_categories = wanted_categories == null ? 0 : wanted_categories.Length;
|
||||
IntPtr[] native_wanted_categories = new IntPtr [cnt_wanted_categories + 1];
|
||||
for (int i = 0; i < cnt_wanted_categories; i++)
|
||||
native_wanted_categories [i] = GLib.Marshaller.StringToPtrGStrdup(wanted_categories[i]);
|
||||
native_wanted_categories [cnt_wanted_categories] = IntPtr.Zero;
|
||||
int cnt_blacklist = blacklist == null ? 0 : blacklist.Length;
|
||||
IntPtr[] native_blacklist = new IntPtr [cnt_blacklist + 1];
|
||||
for (int i = 0; i < cnt_blacklist; i++)
|
||||
native_blacklist [i] = GLib.Marshaller.StringToPtrGStrdup(blacklist[i]);
|
||||
native_blacklist [cnt_blacklist] = IntPtr.Zero;
|
||||
int cnt_whitelist = whitelist == null ? 0 : whitelist.Length;
|
||||
IntPtr[] native_whitelist = new IntPtr [cnt_whitelist + 1];
|
||||
for (int i = 0; i < cnt_whitelist; i++)
|
||||
native_whitelist [i] = GLib.Marshaller.StringToPtrGStrdup(whitelist[i]);
|
||||
native_whitelist [cnt_whitelist] = IntPtr.Zero;
|
||||
IntPtr native_wanted_categories = GLib.Marshaller.StringArrayToStrvPtr(wanted_categories, true);
|
||||
IntPtr native_blacklist = GLib.Marshaller.StringArrayToStrvPtr(blacklist, true);
|
||||
IntPtr native_whitelist = GLib.Marshaller.StringArrayToStrvPtr(whitelist, true);
|
||||
ges_track_element_add_children_props(Handle, element == null ? IntPtr.Zero : element.Handle, native_wanted_categories, native_blacklist, native_whitelist);
|
||||
GLib.Marshaller.StrFreeV (native_wanted_categories);
|
||||
GLib.Marshaller.StrFreeV (native_blacklist);
|
||||
GLib.Marshaller.StrFreeV (native_whitelist);
|
||||
}
|
||||
|
||||
public void AddChildrenProps(Gst.Element element) {
|
||||
|
|
|
@ -59,14 +59,14 @@ namespace GES {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate bool GetNaturalFramerateNativeDelegate (IntPtr inst, int framerate_n, int framerate_d);
|
||||
delegate bool GetNaturalFramerateNativeDelegate (IntPtr inst, out int framerate_n, out int framerate_d);
|
||||
|
||||
static bool GetNaturalFramerate_cb (IntPtr inst, int framerate_n, int framerate_d)
|
||||
static bool GetNaturalFramerate_cb (IntPtr inst, out int framerate_n, out int framerate_d)
|
||||
{
|
||||
try {
|
||||
TrackElementAsset __obj = GLib.Object.GetObject (inst, false) as TrackElementAsset;
|
||||
bool __result;
|
||||
__result = __obj.OnGetNaturalFramerate (framerate_n, framerate_d);
|
||||
__result = __obj.OnGetNaturalFramerate (out framerate_n, out framerate_d);
|
||||
return __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -76,21 +76,21 @@ namespace GES {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(GES.TrackElementAsset), ConnectionMethod="OverrideGetNaturalFramerate")]
|
||||
protected virtual bool OnGetNaturalFramerate (int framerate_n, int framerate_d)
|
||||
protected virtual bool OnGetNaturalFramerate (out int framerate_n, out int framerate_d)
|
||||
{
|
||||
return InternalGetNaturalFramerate (framerate_n, framerate_d);
|
||||
return InternalGetNaturalFramerate (out framerate_n, out framerate_d);
|
||||
}
|
||||
|
||||
private bool InternalGetNaturalFramerate (int framerate_n, int framerate_d)
|
||||
private bool InternalGetNaturalFramerate (out int framerate_n, out int framerate_d)
|
||||
{
|
||||
GetNaturalFramerateNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("get_natural_framerate"));
|
||||
unmanaged = (GetNaturalFramerateNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(GetNaturalFramerateNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return false;
|
||||
if (unmanaged == null) throw new InvalidOperationException ("No base method to invoke");
|
||||
|
||||
bool __result = unmanaged (this.Handle, framerate_n, framerate_d);
|
||||
bool __result = unmanaged (this.Handle, out framerate_n, out framerate_d);
|
||||
return __result;
|
||||
}
|
||||
|
||||
|
@ -138,10 +138,10 @@ namespace GES {
|
|||
}
|
||||
|
||||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool ges_track_element_asset_get_natural_framerate(IntPtr raw, int framerate_n, int framerate_d);
|
||||
static extern bool ges_track_element_asset_get_natural_framerate(IntPtr raw, out int framerate_n, out int framerate_d);
|
||||
|
||||
public bool GetNaturalFramerate(int framerate_n, int framerate_d) {
|
||||
bool raw_ret = ges_track_element_asset_get_natural_framerate(Handle, framerate_n, framerate_d);
|
||||
public bool GetNaturalFramerate(out int framerate_n, out int framerate_d) {
|
||||
bool raw_ret = ges_track_element_asset_get_natural_framerate(Handle, out framerate_n, out framerate_d);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
|
|
@ -96,6 +96,7 @@ namespace GES {
|
|||
[DllImport("ges-1.0", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void ges_uri_clip_asset_class_set_timeout(ulong timeout);
|
||||
|
||||
[Obsolete]
|
||||
public static ulong Timeout {
|
||||
set {
|
||||
ges_uri_clip_asset_class_set_timeout(value);
|
||||
|
|
|
@ -82,6 +82,7 @@ namespace GES {
|
|||
WindshieldV = 263,
|
||||
WindshieldH = 264,
|
||||
Crossfade = 512,
|
||||
FadeIn = 513,
|
||||
}
|
||||
|
||||
internal class VideoStandardTransitionTypeGType {
|
||||
|
|
|
@ -27,6 +27,7 @@ namespace GtkSharp.GstEditingServices {
|
|||
GLib.GType.Register (GES.ClipAsset.GType, typeof (GES.ClipAsset));
|
||||
GLib.GType.Register (GES.CommandLineFormatter.GType, typeof (GES.CommandLineFormatter));
|
||||
GLib.GType.Register (GES.Container.GType, typeof (GES.Container));
|
||||
GLib.GType.Register (GES.DiscovererManager.GType, typeof (GES.DiscovererManager));
|
||||
GLib.GType.Register (GES.Effect.GType, typeof (GES.Effect));
|
||||
GLib.GType.Register (GES.EffectAsset.GType, typeof (GES.EffectAsset));
|
||||
GLib.GType.Register (GES.EffectClip.GType, typeof (GES.EffectClip));
|
||||
|
|
|
@ -134,6 +134,8 @@ int main (int argc, char *argv[]) {
|
|||
g_print("\"sizeof(GESProject)\": \"%" G_GUINT64_FORMAT "\"\n", (guint64) sizeof(GESProject));
|
||||
g_print("\"GESProject.priv\": \"%" G_GUINT64_FORMAT "\"\n", (guint64) G_STRUCT_OFFSET(GESProject, priv));
|
||||
g_print("\"sizeof(GESSourceClass)\": \"%" G_GUINT64_FORMAT "\"\n", (guint64) sizeof(GESSourceClass));
|
||||
g_print("\"GESSourceClass.select_pad\": \"%" G_GUINT64_FORMAT "\"\n", (guint64) G_STRUCT_OFFSET(GESSourceClass, select_pad));
|
||||
g_print("\"GESSourceClass.create_source\": \"%" G_GUINT64_FORMAT "\"\n", (guint64) G_STRUCT_OFFSET(GESSourceClass, create_source));
|
||||
g_print("\"sizeof(GESSource)\": \"%" G_GUINT64_FORMAT "\"\n", (guint64) sizeof(GESSource));
|
||||
g_print("\"GESSource.priv\": \"%" G_GUINT64_FORMAT "\"\n", (guint64) G_STRUCT_OFFSET(GESSource, priv));
|
||||
g_print("\"sizeof(GESSourceClipClass)\": \"%" G_GUINT64_FORMAT "\"\n", (guint64) sizeof(GESSourceClipClass));
|
||||
|
|
|
@ -149,6 +149,8 @@ namespace AbiTester {
|
|||
Console.WriteLine("\"sizeof(GESProject)\": \"" + GES.Project.abi_info.Size + "\"");
|
||||
Console.WriteLine("\"GESProject.priv\": \"" + GES.Project.abi_info.GetFieldOffset("priv") + "\"");
|
||||
Console.WriteLine("\"sizeof(GESSourceClass)\": \"" + GES.Source.class_abi.Size + "\"");
|
||||
Console.WriteLine("\"GESSourceClass.select_pad\": \"" + GES.Source.class_abi.GetFieldOffset("select_pad") + "\"");
|
||||
Console.WriteLine("\"GESSourceClass.create_source\": \"" + GES.Source.class_abi.GetFieldOffset("create_source") + "\"");
|
||||
Console.WriteLine("\"sizeof(GESSource)\": \"" + GES.Source.abi_info.Size + "\"");
|
||||
Console.WriteLine("\"GESSource.priv\": \"" + GES.Source.abi_info.GetFieldOffset("priv") + "\"");
|
||||
Console.WriteLine("\"sizeof(GESSourceClipClass)\": \"" + GES.SourceClip.class_abi.Size + "\"");
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -32,12 +32,16 @@ generated_sources = [
|
|||
'GES/CreateTrackElementFunc.cs',
|
||||
'GES/CreateTrackElementsFunc.cs',
|
||||
'GES/DeepNotifyHandler.cs',
|
||||
'GES/DiscoveredHandler.cs',
|
||||
'GES/DiscovererManager.cs',
|
||||
'GES/Edge.cs',
|
||||
'GES/EditMode.cs',
|
||||
'GES/Effect.cs',
|
||||
'GES/EffectAsset.cs',
|
||||
'GES/EffectClip.cs',
|
||||
'GES/Error.cs',
|
||||
'GES/ErrorLoadingAssetHandler.cs',
|
||||
'GES/ErrorLoadingHandler.cs',
|
||||
'GES/ExtractableAdapter.cs',
|
||||
'GES/ExtractableCheckId.cs',
|
||||
'GES/FillTrackElementFunc.cs',
|
||||
|
@ -64,16 +68,19 @@ generated_sources = [
|
|||
'GES/Layer.cs',
|
||||
'GES/LayerAddedHandler.cs',
|
||||
'GES/LayerRemovedHandler.cs',
|
||||
'GES/LoadSerializedInfoHandler.cs',
|
||||
'GES/LoadedHandler.cs',
|
||||
'GES/LoadingHandler.cs',
|
||||
'GES/Marker.cs',
|
||||
'GES/MarkerAddedHandler.cs',
|
||||
'GES/MarkerFlags.cs',
|
||||
'GES/MarkerList.cs',
|
||||
'GES/MarkerMovedHandler.cs',
|
||||
'GES/MarkerRemovedHandler.cs',
|
||||
'GES/MetaContainerAdapter.cs',
|
||||
'GES/MetaFlag.cs',
|
||||
'GES/MetaForeachFunc.cs',
|
||||
'GES/MissingUriHandler.cs',
|
||||
'GES/MultiFileSource.cs',
|
||||
'GES/NotifyMetaHandler.cs',
|
||||
'GES/Operation.cs',
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -34,6 +34,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
|||
<attr path="/api/namespace/object[@name='Layer']/field[@cname='parent']" name="access">private</attr>
|
||||
<attr path="/api/namespace/object[@name='Formatter']/field[@cname='parent']" name="access">private</attr>
|
||||
<attr path="/api/namespace/object/class_struct[@cname='GESBaseXmlFormatterClass']/field[@cname='content_parser']" name="type">GMarkupParser</attr>
|
||||
<attr path="/api/namespace/object[@name='BaseEffect']/method[@cname='ges_base_effect_set_time_translation_funcs']" name="hidden">true</attr>
|
||||
|
||||
<attr path="/api/namespace/object/class_struct[@cname='GESEffectAssetClass']" name="private">true</attr>
|
||||
<add-node path="/api/namespace/object/class_struct[@cname='GESVideoSourceClass']">
|
||||
|
|
|
@ -50,7 +50,7 @@ namespace Gst {
|
|||
[DllImport("gstreamer-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_buffer_new_wrapped(IntPtr data, UIntPtr n_length);
|
||||
|
||||
public Buffer(byte[] data) {
|
||||
public Buffer(byte[] data) : base(IntPtr.Zero) {
|
||||
IntPtr ptr = GLib.Marshaller.Malloc((ulong)data.Length);
|
||||
Marshal.Copy(data, 0, ptr, data.Length);
|
||||
Raw = gst_buffer_new_wrapped(ptr, new UIntPtr((ulong)data.Length));
|
||||
|
|
|
@ -21,7 +21,6 @@ namespace Gst {
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
partial class MiniObject {
|
||||
protected MiniObject() { }
|
||||
|
||||
[DllImport("gstreamer-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_mini_object_replace(IntPtr olddata, IntPtr newdata);
|
||||
|
|
|
@ -0,0 +1,29 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace Gst.App {
|
||||
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
#region Autogenerated code
|
||||
[GLib.GType (typeof (Gst.App.AppLeakyTypeGType))]
|
||||
public enum AppLeakyType {
|
||||
|
||||
None = 0,
|
||||
Upstream = 1,
|
||||
Downstream = 2,
|
||||
}
|
||||
|
||||
internal class AppLeakyTypeGType {
|
||||
[DllImport ("gstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_app_leaky_type_get_type ();
|
||||
|
||||
public static GLib.GType GType {
|
||||
get {
|
||||
return new GLib.GType (gst_app_leaky_type_get_type ());
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
}
|
|
@ -134,13 +134,33 @@ namespace Gst.App {
|
|||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("try-pull-sample")]
|
||||
public event Gst.App.TryPullSampleEventHandler TryPullSampleEvent {
|
||||
[GLib.Signal("try-pull-object")]
|
||||
public event Gst.App.TryPullObjectEventHandler TryPullObjectEvent {
|
||||
add {
|
||||
this.AddSignalHandler ("try-pull-sample", value, typeof (Gst.App.TryPullSampleEventArgs));
|
||||
this.AddSignalHandler ("try-pull-object", value, typeof (Gst.App.TryPullObjectEventArgs));
|
||||
}
|
||||
remove {
|
||||
this.RemoveSignalHandler ("try-pull-sample", value);
|
||||
this.RemoveSignalHandler ("try-pull-object", value);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("propose-allocation")]
|
||||
public event Gst.App.ProposeAllocationHandler ProposeAllocation {
|
||||
add {
|
||||
this.AddSignalHandler ("propose-allocation", value, typeof (Gst.App.ProposeAllocationArgs));
|
||||
}
|
||||
remove {
|
||||
this.RemoveSignalHandler ("propose-allocation", value);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("new-sample")]
|
||||
public event Gst.App.NewSampleHandler NewSample {
|
||||
add {
|
||||
this.AddSignalHandler ("new-sample", value, typeof (Gst.App.NewSampleArgs));
|
||||
}
|
||||
remove {
|
||||
this.RemoveSignalHandler ("new-sample", value);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -154,13 +174,13 @@ namespace Gst.App {
|
|||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("try-pull-preroll")]
|
||||
public event Gst.App.TryPullPrerollEventHandler TryPullPrerollEvent {
|
||||
[GLib.Signal("try-pull-sample")]
|
||||
public event Gst.App.TryPullSampleEventHandler TryPullSampleEvent {
|
||||
add {
|
||||
this.AddSignalHandler ("try-pull-preroll", value, typeof (Gst.App.TryPullPrerollEventArgs));
|
||||
this.AddSignalHandler ("try-pull-sample", value, typeof (Gst.App.TryPullSampleEventArgs));
|
||||
}
|
||||
remove {
|
||||
this.RemoveSignalHandler ("try-pull-preroll", value);
|
||||
this.RemoveSignalHandler ("try-pull-sample", value);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -174,16 +194,140 @@ namespace Gst.App {
|
|||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("new-sample")]
|
||||
public event Gst.App.NewSampleHandler NewSample {
|
||||
[GLib.Signal("try-pull-preroll")]
|
||||
public event Gst.App.TryPullPrerollEventHandler TryPullPrerollEvent {
|
||||
add {
|
||||
this.AddSignalHandler ("new-sample", value, typeof (Gst.App.NewSampleArgs));
|
||||
this.AddSignalHandler ("try-pull-preroll", value, typeof (Gst.App.TryPullPrerollEventArgs));
|
||||
}
|
||||
remove {
|
||||
this.RemoveSignalHandler ("new-sample", value);
|
||||
this.RemoveSignalHandler ("try-pull-preroll", value);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("new-serialized-event")]
|
||||
public event Gst.App.NewSerializedEventHandler NewSerializedEvent {
|
||||
add {
|
||||
this.AddSignalHandler ("new-serialized-event", value, typeof (Gst.App.NewSerializedEventArgs));
|
||||
}
|
||||
remove {
|
||||
this.RemoveSignalHandler ("new-serialized-event", value);
|
||||
}
|
||||
}
|
||||
|
||||
static NewSerializedEventNativeDelegate NewSerializedEvent_cb_delegate;
|
||||
static NewSerializedEventNativeDelegate NewSerializedEventVMCallback {
|
||||
get {
|
||||
if (NewSerializedEvent_cb_delegate == null)
|
||||
NewSerializedEvent_cb_delegate = new NewSerializedEventNativeDelegate (NewSerializedEvent_cb);
|
||||
return NewSerializedEvent_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideNewSerializedEvent (GLib.GType gtype)
|
||||
{
|
||||
OverrideNewSerializedEvent (gtype, NewSerializedEventVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideNewSerializedEvent (GLib.GType gtype, NewSerializedEventNativeDelegate callback)
|
||||
{
|
||||
OverrideVirtualMethod (gtype, "new-serialized-event", callback);
|
||||
}
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate bool NewSerializedEventNativeDelegate (IntPtr inst);
|
||||
|
||||
static bool NewSerializedEvent_cb (IntPtr inst)
|
||||
{
|
||||
try {
|
||||
AppSink __obj = GLib.Object.GetObject (inst, false) as AppSink;
|
||||
bool __result;
|
||||
__result = __obj.OnNewSerializedEvent ();
|
||||
return __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
// NOTREACHED: above call does not return.
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.App.AppSink), ConnectionMethod="OverrideNewSerializedEvent")]
|
||||
protected virtual bool OnNewSerializedEvent ()
|
||||
{
|
||||
return InternalNewSerializedEvent ();
|
||||
}
|
||||
|
||||
private bool InternalNewSerializedEvent ()
|
||||
{
|
||||
GLib.Value ret = new GLib.Value (GLib.GType.Boolean);
|
||||
GLib.ValueArray inst_and_params = new GLib.ValueArray (1);
|
||||
GLib.Value[] vals = new GLib.Value [1];
|
||||
vals [0] = new GLib.Value (this);
|
||||
inst_and_params.Append (vals [0]);
|
||||
g_signal_chain_from_overridden (inst_and_params.ArrayPtr, ref ret);
|
||||
foreach (GLib.Value v in vals)
|
||||
v.Dispose ();
|
||||
bool result = (bool) ret;
|
||||
ret.Dispose ();
|
||||
return result;
|
||||
}
|
||||
|
||||
static ProposeAllocationNativeDelegate ProposeAllocation_cb_delegate;
|
||||
static ProposeAllocationNativeDelegate ProposeAllocationVMCallback {
|
||||
get {
|
||||
if (ProposeAllocation_cb_delegate == null)
|
||||
ProposeAllocation_cb_delegate = new ProposeAllocationNativeDelegate (ProposeAllocation_cb);
|
||||
return ProposeAllocation_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideProposeAllocation (GLib.GType gtype)
|
||||
{
|
||||
OverrideProposeAllocation (gtype, ProposeAllocationVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideProposeAllocation (GLib.GType gtype, ProposeAllocationNativeDelegate callback)
|
||||
{
|
||||
OverrideVirtualMethod (gtype, "propose-allocation", callback);
|
||||
}
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate bool ProposeAllocationNativeDelegate (IntPtr inst, IntPtr query);
|
||||
|
||||
static bool ProposeAllocation_cb (IntPtr inst, IntPtr query)
|
||||
{
|
||||
try {
|
||||
AppSink __obj = GLib.Object.GetObject (inst, false) as AppSink;
|
||||
bool __result;
|
||||
__result = __obj.OnProposeAllocation (query == IntPtr.Zero ? null : (Gst.Query) GLib.Opaque.GetOpaque (query, typeof (Gst.Query), false));
|
||||
return __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
// NOTREACHED: above call does not return.
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.App.AppSink), ConnectionMethod="OverrideProposeAllocation")]
|
||||
protected virtual bool OnProposeAllocation (Gst.Query query)
|
||||
{
|
||||
return InternalProposeAllocation (query);
|
||||
}
|
||||
|
||||
private bool InternalProposeAllocation (Gst.Query query)
|
||||
{
|
||||
GLib.Value ret = new GLib.Value (GLib.GType.Boolean);
|
||||
GLib.ValueArray inst_and_params = new GLib.ValueArray (2);
|
||||
GLib.Value[] vals = new GLib.Value [2];
|
||||
vals [0] = new GLib.Value (this);
|
||||
inst_and_params.Append (vals [0]);
|
||||
vals [1] = new GLib.Value (query);
|
||||
inst_and_params.Append (vals [1]);
|
||||
g_signal_chain_from_overridden (inst_and_params.ArrayPtr, ref ret);
|
||||
foreach (GLib.Value v in vals)
|
||||
v.Dispose ();
|
||||
bool result = (bool) ret;
|
||||
ret.Dispose ();
|
||||
return result;
|
||||
}
|
||||
|
||||
static EosNativeDelegate Eos_cb_delegate;
|
||||
static EosNativeDelegate EosVMCallback {
|
||||
get {
|
||||
|
@ -469,6 +613,64 @@ namespace Gst.App {
|
|||
return __result == IntPtr.Zero ? null : (Gst.Sample) GLib.Opaque.GetOpaque (__result, typeof (Gst.Sample), true);
|
||||
}
|
||||
|
||||
static TryPullObjectEventNativeDelegate TryPullObjectEvent_cb_delegate;
|
||||
static TryPullObjectEventNativeDelegate TryPullObjectEventVMCallback {
|
||||
get {
|
||||
if (TryPullObjectEvent_cb_delegate == null)
|
||||
TryPullObjectEvent_cb_delegate = new TryPullObjectEventNativeDelegate (TryPullObjectEvent_cb);
|
||||
return TryPullObjectEvent_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideTryPullObjectEvent (GLib.GType gtype)
|
||||
{
|
||||
OverrideTryPullObjectEvent (gtype, TryPullObjectEventVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideTryPullObjectEvent (GLib.GType gtype, TryPullObjectEventNativeDelegate callback)
|
||||
{
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) gtype.GetClassPtr()) + (long) class_abi.GetFieldOffset("try_pull_object"));
|
||||
*raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate) callback);
|
||||
}
|
||||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate IntPtr TryPullObjectEventNativeDelegate (IntPtr inst, ulong timeout);
|
||||
|
||||
static IntPtr TryPullObjectEvent_cb (IntPtr inst, ulong timeout)
|
||||
{
|
||||
try {
|
||||
AppSink __obj = GLib.Object.GetObject (inst, false) as AppSink;
|
||||
Gst.MiniObject __result;
|
||||
__result = __obj.OnTryPullObjectEvent (timeout);
|
||||
return __result == null ? IntPtr.Zero : __result.OwnedCopy;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
// NOTREACHED: above call does not return.
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.App.AppSink), ConnectionMethod="OverrideTryPullObjectEvent")]
|
||||
protected virtual Gst.MiniObject OnTryPullObjectEvent (ulong timeout)
|
||||
{
|
||||
return InternalTryPullObjectEvent (timeout);
|
||||
}
|
||||
|
||||
private Gst.MiniObject InternalTryPullObjectEvent (ulong timeout)
|
||||
{
|
||||
TryPullObjectEventNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("try_pull_object"));
|
||||
unmanaged = (TryPullObjectEventNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(TryPullObjectEventNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return null;
|
||||
|
||||
IntPtr __result = unmanaged (this.Handle, timeout);
|
||||
return __result == IntPtr.Zero ? null : (Gst.MiniObject) GLib.Opaque.GetOpaque (__result, typeof (Gst.MiniObject), true);
|
||||
}
|
||||
|
||||
|
||||
// Internal representation of the wrapped structure ABI.
|
||||
static GLib.AbiStruct _class_abi = null;
|
||||
|
@ -528,14 +730,22 @@ namespace Gst.App {
|
|||
, -1
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr)) // try_pull_sample
|
||||
, "try_pull_preroll"
|
||||
, "try_pull_object"
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr))
|
||||
, 0
|
||||
),
|
||||
new GLib.AbiField("try_pull_object"
|
||||
, -1
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr)) // try_pull_object
|
||||
, "try_pull_sample"
|
||||
, "_gst_reserved"
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr))
|
||||
, 0
|
||||
),
|
||||
new GLib.AbiField("_gst_reserved"
|
||||
, -1
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr)) * 2 // _gst_reserved
|
||||
, "try_pull_sample"
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr)) * 1 // _gst_reserved
|
||||
, "try_pull_object"
|
||||
, null
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr))
|
||||
, 0
|
||||
|
|
|
@ -15,7 +15,9 @@ namespace Gst.App {
|
|||
private IntPtr _eos;
|
||||
private IntPtr _new_preroll;
|
||||
private IntPtr _new_sample;
|
||||
[MarshalAs (UnmanagedType.ByValArray, SizeConst=4)]
|
||||
private IntPtr _new_event;
|
||||
private IntPtr _propose_allocation;
|
||||
[MarshalAs (UnmanagedType.ByValArray, SizeConst=2)]
|
||||
private IntPtr[] _gstGstReserved;
|
||||
|
||||
public static Gst.App.AppSinkCallbacks Zero = new Gst.App.AppSinkCallbacks ();
|
||||
|
@ -28,7 +30,7 @@ namespace Gst.App {
|
|||
|
||||
public bool Equals (AppSinkCallbacks other)
|
||||
{
|
||||
return true && _eos.Equals (other._eos) && _new_preroll.Equals (other._new_preroll) && _new_sample.Equals (other._new_sample);
|
||||
return true && _eos.Equals (other._eos) && _new_preroll.Equals (other._new_preroll) && _new_sample.Equals (other._new_sample) && _new_event.Equals (other._new_event) && _propose_allocation.Equals (other._propose_allocation);
|
||||
}
|
||||
|
||||
public override bool Equals (object other)
|
||||
|
@ -38,7 +40,7 @@ namespace Gst.App {
|
|||
|
||||
public override int GetHashCode ()
|
||||
{
|
||||
return this.GetType ().FullName.GetHashCode () ^ _eos.GetHashCode () ^ _new_preroll.GetHashCode () ^ _new_sample.GetHashCode ();
|
||||
return this.GetType ().FullName.GetHashCode () ^ _eos.GetHashCode () ^ _new_preroll.GetHashCode () ^ _new_sample.GetHashCode () ^ _new_event.GetHashCode () ^ _propose_allocation.GetHashCode ();
|
||||
}
|
||||
|
||||
private static GLib.GType GType {
|
||||
|
|
|
@ -51,6 +51,18 @@ namespace Gst.App {
|
|||
}
|
||||
}
|
||||
|
||||
[DllImport("gstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern ulong gst_app_src_get_current_level_buffers(IntPtr raw);
|
||||
|
||||
[GLib.Property ("current-level-buffers")]
|
||||
public ulong CurrentLevelBuffers {
|
||||
get {
|
||||
ulong raw_ret = gst_app_src_get_current_level_buffers(Handle);
|
||||
ulong ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
[DllImport("gstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern ulong gst_app_src_get_current_level_bytes(IntPtr raw);
|
||||
|
||||
|
@ -63,6 +75,18 @@ namespace Gst.App {
|
|||
}
|
||||
}
|
||||
|
||||
[DllImport("gstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern ulong gst_app_src_get_current_level_time(IntPtr raw);
|
||||
|
||||
[GLib.Property ("current-level-time")]
|
||||
public ulong CurrentLevelTime {
|
||||
get {
|
||||
ulong raw_ret = gst_app_src_get_current_level_time(Handle);
|
||||
ulong ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
[DllImport("gstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern ulong gst_app_src_get_duration(IntPtr raw);
|
||||
|
||||
|
@ -144,6 +168,42 @@ namespace Gst.App {
|
|||
}
|
||||
}
|
||||
|
||||
[DllImport("gstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern int gst_app_src_get_leaky_type(IntPtr raw);
|
||||
|
||||
[DllImport("gstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_app_src_set_leaky_type(IntPtr raw, int leaky);
|
||||
|
||||
[GLib.Property ("leaky-type")]
|
||||
public Gst.App.AppLeakyType LeakyType {
|
||||
get {
|
||||
int raw_ret = gst_app_src_get_leaky_type(Handle);
|
||||
Gst.App.AppLeakyType ret = (Gst.App.AppLeakyType) raw_ret;
|
||||
return ret;
|
||||
}
|
||||
set {
|
||||
gst_app_src_set_leaky_type(Handle, (int) value);
|
||||
}
|
||||
}
|
||||
|
||||
[DllImport("gstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern ulong gst_app_src_get_max_buffers(IntPtr raw);
|
||||
|
||||
[DllImport("gstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_app_src_set_max_buffers(IntPtr raw, ulong max);
|
||||
|
||||
[GLib.Property ("max-buffers")]
|
||||
public ulong MaxBuffers {
|
||||
get {
|
||||
ulong raw_ret = gst_app_src_get_max_buffers(Handle);
|
||||
ulong ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
set {
|
||||
gst_app_src_set_max_buffers(Handle, value);
|
||||
}
|
||||
}
|
||||
|
||||
[DllImport("gstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern ulong gst_app_src_get_max_bytes(IntPtr raw);
|
||||
|
||||
|
@ -177,6 +237,24 @@ namespace Gst.App {
|
|||
}
|
||||
}
|
||||
|
||||
[DllImport("gstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern ulong gst_app_src_get_max_time(IntPtr raw);
|
||||
|
||||
[DllImport("gstapp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_app_src_set_max_time(IntPtr raw, ulong max);
|
||||
|
||||
[GLib.Property ("max-time")]
|
||||
public ulong MaxTime {
|
||||
get {
|
||||
ulong raw_ret = gst_app_src_get_max_time(Handle);
|
||||
ulong ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
set {
|
||||
gst_app_src_set_max_time(Handle, value);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.Property ("min-latency")]
|
||||
public long MinLatency {
|
||||
get {
|
||||
|
@ -336,25 +414,25 @@ namespace Gst.App {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate void NeedDataNativeDelegate (IntPtr inst, uint _object);
|
||||
delegate void NeedDataNativeDelegate (IntPtr inst, uint length);
|
||||
|
||||
static void NeedData_cb (IntPtr inst, uint _object)
|
||||
static void NeedData_cb (IntPtr inst, uint length)
|
||||
{
|
||||
try {
|
||||
AppSrc __obj = GLib.Object.GetObject (inst, false) as AppSrc;
|
||||
__obj.OnNeedData (_object);
|
||||
__obj.OnNeedData (length);
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, false);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.App.AppSrc), ConnectionMethod="OverrideNeedData")]
|
||||
protected virtual void OnNeedData (uint _object)
|
||||
protected virtual void OnNeedData (uint length)
|
||||
{
|
||||
InternalNeedData (_object);
|
||||
InternalNeedData (length);
|
||||
}
|
||||
|
||||
private void InternalNeedData (uint _object)
|
||||
private void InternalNeedData (uint length)
|
||||
{
|
||||
NeedDataNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
|
@ -363,7 +441,7 @@ namespace Gst.App {
|
|||
}
|
||||
if (unmanaged == null) return;
|
||||
|
||||
unmanaged (this.Handle, _object);
|
||||
unmanaged (this.Handle, length);
|
||||
}
|
||||
|
||||
static EnoughDataNativeDelegate EnoughData_cb_delegate;
|
||||
|
@ -442,14 +520,14 @@ namespace Gst.App {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate bool SeekDataNativeDelegate (IntPtr inst, ulong _object);
|
||||
delegate bool SeekDataNativeDelegate (IntPtr inst, ulong offset);
|
||||
|
||||
static bool SeekData_cb (IntPtr inst, ulong _object)
|
||||
static bool SeekData_cb (IntPtr inst, ulong offset)
|
||||
{
|
||||
try {
|
||||
AppSrc __obj = GLib.Object.GetObject (inst, false) as AppSrc;
|
||||
bool __result;
|
||||
__result = __obj.OnSeekData (_object);
|
||||
__result = __obj.OnSeekData (offset);
|
||||
return __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -459,12 +537,12 @@ namespace Gst.App {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.App.AppSrc), ConnectionMethod="OverrideSeekData")]
|
||||
protected virtual bool OnSeekData (ulong _object)
|
||||
protected virtual bool OnSeekData (ulong offset)
|
||||
{
|
||||
return InternalSeekData (_object);
|
||||
return InternalSeekData (offset);
|
||||
}
|
||||
|
||||
private bool InternalSeekData (ulong _object)
|
||||
private bool InternalSeekData (ulong offset)
|
||||
{
|
||||
SeekDataNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
|
@ -473,7 +551,7 @@ namespace Gst.App {
|
|||
}
|
||||
if (unmanaged == null) return false;
|
||||
|
||||
bool __result = unmanaged (this.Handle, _object);
|
||||
bool __result = unmanaged (this.Handle, offset);
|
||||
return __result;
|
||||
}
|
||||
|
||||
|
@ -500,14 +578,14 @@ namespace Gst.App {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate int PushBufferEventNativeDelegate (IntPtr inst, IntPtr _object);
|
||||
delegate int PushBufferEventNativeDelegate (IntPtr inst, IntPtr buffer);
|
||||
|
||||
static int PushBufferEvent_cb (IntPtr inst, IntPtr _object)
|
||||
static int PushBufferEvent_cb (IntPtr inst, IntPtr buffer)
|
||||
{
|
||||
try {
|
||||
AppSrc __obj = GLib.Object.GetObject (inst, false) as AppSrc;
|
||||
Gst.FlowReturn __result;
|
||||
__result = __obj.OnPushBufferEvent (_object == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (_object, typeof (Gst.Buffer), false));
|
||||
__result = __obj.OnPushBufferEvent (buffer == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (buffer, typeof (Gst.Buffer), false));
|
||||
return (int) __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -517,12 +595,12 @@ namespace Gst.App {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.App.AppSrc), ConnectionMethod="OverridePushBufferEvent")]
|
||||
protected virtual Gst.FlowReturn OnPushBufferEvent (Gst.Buffer _object)
|
||||
protected virtual Gst.FlowReturn OnPushBufferEvent (Gst.Buffer buffer)
|
||||
{
|
||||
return InternalPushBufferEvent (_object);
|
||||
return InternalPushBufferEvent (buffer);
|
||||
}
|
||||
|
||||
private Gst.FlowReturn InternalPushBufferEvent (Gst.Buffer _object)
|
||||
private Gst.FlowReturn InternalPushBufferEvent (Gst.Buffer buffer)
|
||||
{
|
||||
PushBufferEventNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
|
@ -531,7 +609,7 @@ namespace Gst.App {
|
|||
}
|
||||
if (unmanaged == null) return (Gst.FlowReturn) 0;
|
||||
|
||||
int __result = unmanaged (this.Handle, _object == null ? IntPtr.Zero : _object.Handle);
|
||||
int __result = unmanaged (this.Handle, buffer == null ? IntPtr.Zero : buffer.Handle);
|
||||
return (Gst.FlowReturn) __result;
|
||||
}
|
||||
|
||||
|
@ -616,14 +694,14 @@ namespace Gst.App {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate int PushSampleEventNativeDelegate (IntPtr inst, IntPtr _object);
|
||||
delegate int PushSampleEventNativeDelegate (IntPtr inst, IntPtr sample);
|
||||
|
||||
static int PushSampleEvent_cb (IntPtr inst, IntPtr _object)
|
||||
static int PushSampleEvent_cb (IntPtr inst, IntPtr sample)
|
||||
{
|
||||
try {
|
||||
AppSrc __obj = GLib.Object.GetObject (inst, false) as AppSrc;
|
||||
Gst.FlowReturn __result;
|
||||
__result = __obj.OnPushSampleEvent (_object == IntPtr.Zero ? null : (Gst.Sample) GLib.Opaque.GetOpaque (_object, typeof (Gst.Sample), false));
|
||||
__result = __obj.OnPushSampleEvent (sample == IntPtr.Zero ? null : (Gst.Sample) GLib.Opaque.GetOpaque (sample, typeof (Gst.Sample), false));
|
||||
return (int) __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -633,12 +711,12 @@ namespace Gst.App {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.App.AppSrc), ConnectionMethod="OverridePushSampleEvent")]
|
||||
protected virtual Gst.FlowReturn OnPushSampleEvent (Gst.Sample _object)
|
||||
protected virtual Gst.FlowReturn OnPushSampleEvent (Gst.Sample sample)
|
||||
{
|
||||
return InternalPushSampleEvent (_object);
|
||||
return InternalPushSampleEvent (sample);
|
||||
}
|
||||
|
||||
private Gst.FlowReturn InternalPushSampleEvent (Gst.Sample _object)
|
||||
private Gst.FlowReturn InternalPushSampleEvent (Gst.Sample sample)
|
||||
{
|
||||
PushSampleEventNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
|
@ -647,7 +725,7 @@ namespace Gst.App {
|
|||
}
|
||||
if (unmanaged == null) return (Gst.FlowReturn) 0;
|
||||
|
||||
int __result = unmanaged (this.Handle, _object == null ? IntPtr.Zero : _object.Handle);
|
||||
int __result = unmanaged (this.Handle, sample == null ? IntPtr.Zero : sample.Handle);
|
||||
return (Gst.FlowReturn) __result;
|
||||
}
|
||||
|
||||
|
@ -674,14 +752,14 @@ namespace Gst.App {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate int PushBufferListEventNativeDelegate (IntPtr inst, IntPtr _object);
|
||||
delegate int PushBufferListEventNativeDelegate (IntPtr inst, IntPtr buffer_list);
|
||||
|
||||
static int PushBufferListEvent_cb (IntPtr inst, IntPtr _object)
|
||||
static int PushBufferListEvent_cb (IntPtr inst, IntPtr buffer_list)
|
||||
{
|
||||
try {
|
||||
AppSrc __obj = GLib.Object.GetObject (inst, false) as AppSrc;
|
||||
Gst.FlowReturn __result;
|
||||
__result = __obj.OnPushBufferListEvent (_object == IntPtr.Zero ? null : (Gst.BufferList) GLib.Opaque.GetOpaque (_object, typeof (Gst.BufferList), false));
|
||||
__result = __obj.OnPushBufferListEvent (buffer_list == IntPtr.Zero ? null : (Gst.BufferList) GLib.Opaque.GetOpaque (buffer_list, typeof (Gst.BufferList), false));
|
||||
return (int) __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -691,12 +769,12 @@ namespace Gst.App {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.App.AppSrc), ConnectionMethod="OverridePushBufferListEvent")]
|
||||
protected virtual Gst.FlowReturn OnPushBufferListEvent (Gst.BufferList _object)
|
||||
protected virtual Gst.FlowReturn OnPushBufferListEvent (Gst.BufferList buffer_list)
|
||||
{
|
||||
return InternalPushBufferListEvent (_object);
|
||||
return InternalPushBufferListEvent (buffer_list);
|
||||
}
|
||||
|
||||
private Gst.FlowReturn InternalPushBufferListEvent (Gst.BufferList _object)
|
||||
private Gst.FlowReturn InternalPushBufferListEvent (Gst.BufferList buffer_list)
|
||||
{
|
||||
PushBufferListEventNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
|
@ -705,7 +783,7 @@ namespace Gst.App {
|
|||
}
|
||||
if (unmanaged == null) return (Gst.FlowReturn) 0;
|
||||
|
||||
int __result = unmanaged (this.Handle, _object == null ? IntPtr.Zero : _object.Handle);
|
||||
int __result = unmanaged (this.Handle, buffer_list == null ? IntPtr.Zero : buffer_list.Handle);
|
||||
return (Gst.FlowReturn) __result;
|
||||
}
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@ namespace Gst.App {
|
|||
public delegate void NeedDataHandler(object o, NeedDataArgs args);
|
||||
|
||||
public class NeedDataArgs : GLib.SignalArgs {
|
||||
public uint Object{
|
||||
public uint Length{
|
||||
get {
|
||||
return (uint) Args [0];
|
||||
}
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace Gst.App {
|
||||
|
||||
using System;
|
||||
|
||||
public delegate void NewSerializedEventHandler(object o, NewSerializedEventArgs args);
|
||||
|
||||
public class NewSerializedEventArgs : GLib.SignalArgs {
|
||||
}
|
||||
}
|
|
@ -0,0 +1,18 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace Gst.App {
|
||||
|
||||
using System;
|
||||
|
||||
public delegate void ProposeAllocationHandler(object o, ProposeAllocationArgs args);
|
||||
|
||||
public class ProposeAllocationArgs : GLib.SignalArgs {
|
||||
public Gst.Query Query{
|
||||
get {
|
||||
return (Gst.Query) Args [0];
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -8,7 +8,7 @@ namespace Gst.App {
|
|||
public delegate void PushBufferEventHandler(object o, PushBufferEventArgs args);
|
||||
|
||||
public class PushBufferEventArgs : GLib.SignalArgs {
|
||||
public Gst.Buffer Object{
|
||||
public Gst.Buffer Buffer{
|
||||
get {
|
||||
return (Gst.Buffer) Args [0];
|
||||
}
|
||||
|
|
|
@ -8,7 +8,7 @@ namespace Gst.App {
|
|||
public delegate void PushBufferListEventHandler(object o, PushBufferListEventArgs args);
|
||||
|
||||
public class PushBufferListEventArgs : GLib.SignalArgs {
|
||||
public Gst.BufferList Object{
|
||||
public Gst.BufferList BufferList{
|
||||
get {
|
||||
return (Gst.BufferList) Args [0];
|
||||
}
|
||||
|
|
|
@ -8,7 +8,7 @@ namespace Gst.App {
|
|||
public delegate void PushSampleEventHandler(object o, PushSampleEventArgs args);
|
||||
|
||||
public class PushSampleEventArgs : GLib.SignalArgs {
|
||||
public Gst.Sample Object{
|
||||
public Gst.Sample Sample{
|
||||
get {
|
||||
return (Gst.Sample) Args [0];
|
||||
}
|
||||
|
|
|
@ -8,7 +8,7 @@ namespace Gst.App {
|
|||
public delegate void SeekDataHandler(object o, SeekDataArgs args);
|
||||
|
||||
public class SeekDataArgs : GLib.SignalArgs {
|
||||
public ulong Object{
|
||||
public ulong Offset{
|
||||
get {
|
||||
return (ulong) Args [0];
|
||||
}
|
||||
|
|
|
@ -0,0 +1,18 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace Gst.App {
|
||||
|
||||
using System;
|
||||
|
||||
public delegate void TryPullObjectEventHandler(object o, TryPullObjectEventArgs args);
|
||||
|
||||
public class TryPullObjectEventArgs : GLib.SignalArgs {
|
||||
public ulong Timeout{
|
||||
get {
|
||||
return (ulong) Args [0];
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -54,19 +54,6 @@ namespace Gst.Audio {
|
|||
return (Gst.Audio.AudioBuffer) Marshal.PtrToStructure (raw, typeof (Gst.Audio.AudioBuffer));
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_buffer_map(IntPtr raw, IntPtr info, IntPtr gstbuffer, int flags);
|
||||
|
||||
public bool Map(Gst.Audio.AudioInfo info, Gst.Buffer gstbuffer, Gst.MapFlags flags) {
|
||||
IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf (this));
|
||||
System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false);
|
||||
bool raw_ret = gst_audio_buffer_map(this_as_native, info == null ? IntPtr.Zero : info.Handle, gstbuffer == null ? IntPtr.Zero : gstbuffer.Handle, (int) flags);
|
||||
bool ret = raw_ret;
|
||||
ReadNative (this_as_native, ref this);
|
||||
System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_audio_buffer_unmap(IntPtr raw);
|
||||
|
||||
|
@ -91,16 +78,27 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_buffer_reorder_channels(IntPtr buffer, int format, int channels, int[] from, int[] to);
|
||||
static extern bool gst_audio_buffer_map(IntPtr buffer, IntPtr info, IntPtr gstbuffer, int flags);
|
||||
|
||||
public static bool ReorderChannels(Gst.Buffer buffer, Gst.Audio.AudioFormat format, int channels, Gst.Audio.AudioChannelPosition[] from, Gst.Audio.AudioChannelPosition[] to) {
|
||||
int cnt_from = from == null ? 0 : from.Length;
|
||||
int[] native_from = new int [cnt_from];
|
||||
for (int i = 0; i < cnt_from; i++)
|
||||
public static bool Map(out Gst.Audio.AudioBuffer buffer, Gst.Audio.AudioInfo info, Gst.Buffer gstbuffer, Gst.MapFlags flags) {
|
||||
IntPtr native_buffer = Marshal.AllocHGlobal (Marshal.SizeOf (typeof (Gst.Audio.AudioBuffer)));
|
||||
bool raw_ret = gst_audio_buffer_map(native_buffer, info == null ? IntPtr.Zero : info.Handle, gstbuffer == null ? IntPtr.Zero : gstbuffer.Handle, (int) flags);
|
||||
bool ret = raw_ret;
|
||||
buffer = Gst.Audio.AudioBuffer.New (native_buffer);
|
||||
Marshal.FreeHGlobal (native_buffer);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_buffer_reorder_channels(IntPtr buffer, int format, int channels, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]int[] from, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]int[] to);
|
||||
|
||||
public static bool ReorderChannels(Gst.Buffer buffer, Gst.Audio.AudioFormat format, Gst.Audio.AudioChannelPosition[] from, Gst.Audio.AudioChannelPosition[] to) {
|
||||
int channels = (from == null ? 0 : from.Length);
|
||||
int[] native_from = new int [channels];
|
||||
for (int i = 0; i < channels; i++)
|
||||
native_from [i] = (int) from[i];
|
||||
int cnt_to = to == null ? 0 : to.Length;
|
||||
int[] native_to = new int [cnt_to];
|
||||
for (int i = 0; i < cnt_to; i++)
|
||||
int[] native_to = new int [channels];
|
||||
for (int i = 0; i < channels; i++)
|
||||
native_to [i] = (int) to[i];
|
||||
bool raw_ret = gst_audio_buffer_reorder_channels(buffer == null ? IntPtr.Zero : buffer.Handle, (int) format, channels, native_from, native_to);
|
||||
bool ret = raw_ret;
|
||||
|
|
|
@ -332,14 +332,14 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate int ParseNativeDelegate (IntPtr inst, IntPtr adapter, int offset, int length);
|
||||
delegate int ParseNativeDelegate (IntPtr inst, IntPtr adapter, out int offset, out int length);
|
||||
|
||||
static int Parse_cb (IntPtr inst, IntPtr adapter, int offset, int length)
|
||||
static int Parse_cb (IntPtr inst, IntPtr adapter, out int offset, out int length)
|
||||
{
|
||||
try {
|
||||
AudioDecoder __obj = GLib.Object.GetObject (inst, false) as AudioDecoder;
|
||||
Gst.FlowReturn __result;
|
||||
__result = __obj.OnParse (GLib.Object.GetObject(adapter) as Gst.Base.Adapter, offset, length);
|
||||
__result = __obj.OnParse (GLib.Object.GetObject(adapter) as Gst.Base.Adapter, out offset, out length);
|
||||
return (int) __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -349,21 +349,21 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.Audio.AudioDecoder), ConnectionMethod="OverrideParse")]
|
||||
protected virtual Gst.FlowReturn OnParse (Gst.Base.Adapter adapter, int offset, int length)
|
||||
protected virtual Gst.FlowReturn OnParse (Gst.Base.Adapter adapter, out int offset, out int length)
|
||||
{
|
||||
return InternalParse (adapter, offset, length);
|
||||
return InternalParse (adapter, out offset, out length);
|
||||
}
|
||||
|
||||
private Gst.FlowReturn InternalParse (Gst.Base.Adapter adapter, int offset, int length)
|
||||
private Gst.FlowReturn InternalParse (Gst.Base.Adapter adapter, out int offset, out int length)
|
||||
{
|
||||
ParseNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("parse"));
|
||||
unmanaged = (ParseNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(ParseNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return (Gst.FlowReturn) 0;
|
||||
if (unmanaged == null) throw new InvalidOperationException ("No base method to invoke");
|
||||
|
||||
int __result = unmanaged (this.Handle, adapter == null ? IntPtr.Zero : adapter.Handle, offset, length);
|
||||
int __result = unmanaged (this.Handle, adapter == null ? IntPtr.Zero : adapter.Handle, out offset, out length);
|
||||
return (Gst.FlowReturn) __result;
|
||||
}
|
||||
|
||||
|
@ -1410,7 +1410,7 @@ namespace Gst.Audio {
|
|||
public Gst.Audio.AudioInfo AudioInfo {
|
||||
get {
|
||||
IntPtr raw_ret = gst_audio_decoder_get_audio_info(Handle);
|
||||
Gst.Audio.AudioInfo ret = raw_ret == IntPtr.Zero ? null : (Gst.Audio.AudioInfo) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Audio.AudioInfo), true);
|
||||
Gst.Audio.AudioInfo ret = raw_ret == IntPtr.Zero ? null : (Gst.Audio.AudioInfo) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Audio.AudioInfo), false);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1330,7 +1330,7 @@ namespace Gst.Audio {
|
|||
public Gst.Audio.AudioInfo AudioInfo {
|
||||
get {
|
||||
IntPtr raw_ret = gst_audio_encoder_get_audio_info(Handle);
|
||||
Gst.Audio.AudioInfo ret = raw_ret == IntPtr.Zero ? null : (Gst.Audio.AudioInfo) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Audio.AudioInfo), true);
|
||||
Gst.Audio.AudioInfo ret = raw_ret == IntPtr.Zero ? null : (Gst.Audio.AudioInfo) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Audio.AudioInfo), false);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -45,6 +45,23 @@ namespace Gst.Audio {
|
|||
return (Gst.Audio.AudioFormatInfo) Marshal.PtrToStructure (raw, typeof (Gst.Audio.AudioFormatInfo));
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_audio_format_info_fill_silence(IntPtr raw, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]IntPtr[] dest, UIntPtr length);
|
||||
|
||||
public void FillSilence(IntPtr[] dest) {
|
||||
IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf (this));
|
||||
System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false);
|
||||
ulong length = (ulong)(dest == null ? 0 : dest.Length);
|
||||
gst_audio_format_info_fill_silence(this_as_native, dest, new UIntPtr ((uint)length));
|
||||
ReadNative (this_as_native, ref this);
|
||||
System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native);
|
||||
}
|
||||
|
||||
static void ReadNative (IntPtr native, ref Gst.Audio.AudioFormatInfo target)
|
||||
{
|
||||
target = New (native);
|
||||
}
|
||||
|
||||
public bool Equals (AudioFormatInfo other)
|
||||
{
|
||||
return true && Format.Equals (other.Format) && Name.Equals (other.Name) && Description.Equals (other.Description) && Flags.Equals (other.Flags) && Endianness.Equals (other.Endianness) && Width.Equals (other.Width) && Depth.Equals (other.Depth) && Silence.Equals (other.Silence) && UnpackFormat.Equals (other.UnpackFormat) && UnpackFunc.Equals (other.UnpackFunc) && PackFunc.Equals (other.PackFunc);
|
||||
|
|
|
@ -5,6 +5,6 @@ namespace Gst.Audio {
|
|||
|
||||
using System;
|
||||
|
||||
public delegate void AudioFormatPack(Gst.Audio.AudioFormatInfo info, Gst.Audio.AudioPackFlags flags, byte[] src, byte[] data);
|
||||
public delegate void AudioFormatPack(Gst.Audio.AudioFormatInfo info, Gst.Audio.AudioPackFlags flags, byte[] src, byte[] data, int n_length);
|
||||
|
||||
}
|
||||
|
|
|
@ -5,6 +5,6 @@ namespace Gst.Audio {
|
|||
|
||||
using System;
|
||||
|
||||
public delegate void AudioFormatUnpack(Gst.Audio.AudioFormatInfo info, Gst.Audio.AudioPackFlags flags, byte[] dest, byte[] data);
|
||||
public delegate void AudioFormatUnpack(Gst.Audio.AudioFormatInfo info, Gst.Audio.AudioPackFlags flags, byte[] dest, byte[] data, int n_length);
|
||||
|
||||
}
|
||||
|
|
|
@ -130,22 +130,6 @@ namespace Gst.Audio {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_info_from_caps(IntPtr raw, IntPtr caps);
|
||||
|
||||
public bool FromCaps(Gst.Caps caps) {
|
||||
bool raw_ret = gst_audio_info_from_caps(Handle, caps == null ? IntPtr.Zero : caps.Handle);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_audio_info_init(IntPtr raw);
|
||||
|
||||
public void Init() {
|
||||
gst_audio_info_init(Handle);
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_info_is_equal(IntPtr raw, IntPtr other);
|
||||
|
||||
|
@ -179,6 +163,28 @@ namespace Gst.Audio {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_info_from_caps(out IntPtr info, IntPtr caps);
|
||||
|
||||
public static bool FromCaps(out Gst.Audio.AudioInfo info, Gst.Caps caps) {
|
||||
IntPtr native_info;
|
||||
bool raw_ret = gst_audio_info_from_caps(out native_info, caps == null ? IntPtr.Zero : caps.Handle);
|
||||
bool ret = raw_ret;
|
||||
info = native_info == IntPtr.Zero ? null : (Gst.Audio.AudioInfo) GLib.Opaque.GetOpaque (native_info, typeof (Gst.Audio.AudioInfo), false);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_audio_info_init(out IntPtr info);
|
||||
|
||||
public static Gst.Audio.AudioInfo Init() {
|
||||
Gst.Audio.AudioInfo info;
|
||||
IntPtr native_info;
|
||||
gst_audio_info_init(out native_info);
|
||||
info = native_info == IntPtr.Zero ? null : (Gst.Audio.AudioInfo) GLib.Opaque.GetOpaque (native_info, typeof (Gst.Audio.AudioInfo), false);
|
||||
return info;
|
||||
}
|
||||
|
||||
public AudioInfo(IntPtr raw) : base(raw) {}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
|
@ -189,6 +195,14 @@ namespace Gst.Audio {
|
|||
Raw = gst_audio_info_new();
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_audio_info_new_from_caps(IntPtr caps);
|
||||
|
||||
public AudioInfo (Gst.Caps caps)
|
||||
{
|
||||
Raw = gst_audio_info_new_from_caps(caps == null ? IntPtr.Zero : caps.Handle);
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_audio_info_free(IntPtr raw);
|
||||
|
||||
|
|
|
@ -0,0 +1,58 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace Gst.Audio {
|
||||
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
#region Autogenerated code
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
public partial struct AudioLevelMeta : IEquatable<AudioLevelMeta> {
|
||||
|
||||
public Gst.Meta Meta;
|
||||
public byte Level;
|
||||
public bool VoiceActivity;
|
||||
|
||||
public static Gst.Audio.AudioLevelMeta Zero = new Gst.Audio.AudioLevelMeta ();
|
||||
|
||||
public static Gst.Audio.AudioLevelMeta New(IntPtr raw) {
|
||||
if (raw == IntPtr.Zero)
|
||||
return Gst.Audio.AudioLevelMeta.Zero;
|
||||
return (Gst.Audio.AudioLevelMeta) Marshal.PtrToStructure (raw, typeof (Gst.Audio.AudioLevelMeta));
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_audio_level_meta_get_info();
|
||||
|
||||
public static Gst.MetaInfo Info {
|
||||
get {
|
||||
IntPtr raw_ret = gst_audio_level_meta_get_info();
|
||||
Gst.MetaInfo ret = Gst.MetaInfo.New (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
public bool Equals (AudioLevelMeta other)
|
||||
{
|
||||
return true && Meta.Equals (other.Meta) && Level.Equals (other.Level) && VoiceActivity.Equals (other.VoiceActivity);
|
||||
}
|
||||
|
||||
public override bool Equals (object other)
|
||||
{
|
||||
return other is AudioLevelMeta && Equals ((AudioLevelMeta) other);
|
||||
}
|
||||
|
||||
public override int GetHashCode ()
|
||||
{
|
||||
return this.GetType ().FullName.GetHashCode () ^ Meta.GetHashCode () ^ Level.GetHashCode () ^ VoiceActivity.GetHashCode ();
|
||||
}
|
||||
|
||||
private static GLib.GType GType {
|
||||
get { return GLib.GType.Pointer; }
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
|
@ -738,14 +738,14 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate uint CommitNativeDelegate (IntPtr inst, ulong sample, byte[] data, int in_samples, int out_samples, ref int accum);
|
||||
delegate uint CommitNativeDelegate (IntPtr inst, ref ulong sample, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=3)]byte[] data, int in_samples, int out_samples, ref int accum);
|
||||
|
||||
static uint Commit_cb (IntPtr inst, ulong sample, byte[] data, int in_samples, int out_samples, ref int accum)
|
||||
static uint Commit_cb (IntPtr inst, ref ulong sample, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=3)]byte[] data, int in_samples, int out_samples, ref int accum)
|
||||
{
|
||||
try {
|
||||
AudioRingBuffer __obj = GLib.Object.GetObject (inst, false) as AudioRingBuffer;
|
||||
uint __result;
|
||||
__result = __obj.OnCommit (sample, data, in_samples, out_samples, ref accum);
|
||||
__result = __obj.OnCommit (ref sample, data, out_samples, ref accum);
|
||||
return __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -755,12 +755,12 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.Audio.AudioRingBuffer), ConnectionMethod="OverrideCommit")]
|
||||
protected virtual uint OnCommit (ulong sample, byte[] data, int in_samples, int out_samples, ref int accum)
|
||||
protected virtual uint OnCommit (ref ulong sample, byte[] data, int out_samples, ref int accum)
|
||||
{
|
||||
return InternalCommit (sample, data, in_samples, out_samples, ref accum);
|
||||
return InternalCommit (ref sample, data, out_samples, ref accum);
|
||||
}
|
||||
|
||||
private uint InternalCommit (ulong sample, byte[] data, int in_samples, int out_samples, ref int accum)
|
||||
private uint InternalCommit (ref ulong sample, byte[] data, int out_samples, ref int accum)
|
||||
{
|
||||
CommitNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
|
@ -769,7 +769,8 @@ namespace Gst.Audio {
|
|||
}
|
||||
if (unmanaged == null) return 0;
|
||||
|
||||
uint __result = unmanaged (this.Handle, sample, data, in_samples, out_samples, ref accum);
|
||||
int in_samples = (data == null ? 0 : data.Length);
|
||||
uint __result = unmanaged (this.Handle, ref sample, data, in_samples, out_samples, ref accum);
|
||||
return __result;
|
||||
}
|
||||
|
||||
|
@ -1029,10 +1030,11 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern uint gst_audio_ring_buffer_commit(IntPtr raw, ulong sample, byte[] data, int in_samples, int out_samples, ref int accum);
|
||||
static extern uint gst_audio_ring_buffer_commit(IntPtr raw, ref ulong sample, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=3)]byte[] data, int in_samples, int out_samples, ref int accum);
|
||||
|
||||
public uint Commit(ulong sample, byte[] data, int in_samples, int out_samples, ref int accum) {
|
||||
uint raw_ret = gst_audio_ring_buffer_commit(Handle, sample, data, in_samples, out_samples, ref accum);
|
||||
public uint Commit(ref ulong sample, byte[] data, int out_samples, ref int accum) {
|
||||
int in_samples = (data == null ? 0 : data.Length);
|
||||
uint raw_ret = gst_audio_ring_buffer_commit(Handle, ref sample, data, in_samples, out_samples, ref accum);
|
||||
uint ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
@ -1123,9 +1125,10 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern uint gst_audio_ring_buffer_read(IntPtr raw, ulong sample, byte[] data, uint len, out ulong timestamp);
|
||||
static extern uint gst_audio_ring_buffer_read(IntPtr raw, ulong sample, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=3)]byte[] data, uint len, out ulong timestamp);
|
||||
|
||||
public uint Read(ulong sample, byte[] data, uint len, out ulong timestamp) {
|
||||
public uint Read(ulong sample, byte[] data, out ulong timestamp) {
|
||||
uint len = (uint)(data == null ? 0 : data.Length);
|
||||
uint raw_ret = gst_audio_ring_buffer_read(Handle, sample, data, len, out timestamp);
|
||||
uint ret = raw_ret;
|
||||
return ret;
|
||||
|
|
|
@ -5,6 +5,6 @@ namespace Gst.Audio {
|
|||
|
||||
using System;
|
||||
|
||||
public delegate void AudioRingBufferCallback(Gst.Audio.AudioRingBuffer rbuf, byte[] data, uint len);
|
||||
public delegate void AudioRingBufferCallback(Gst.Audio.AudioRingBuffer rbuf, byte[] data, IntPtr user_data);
|
||||
|
||||
}
|
||||
|
|
|
@ -25,6 +25,7 @@ namespace Gst.Audio {
|
|||
Mpeg2AacRaw = 12,
|
||||
Mpeg4AacRaw = 13,
|
||||
Flac = 14,
|
||||
Dsd = 15,
|
||||
}
|
||||
|
||||
internal class AudioRingBufferFormatTypeGType {
|
||||
|
|
|
@ -200,18 +200,42 @@ namespace Gst.Audio {
|
|||
, -1
|
||||
, (uint) Marshal.SizeOf(typeof(int)) // seglatency
|
||||
, "segtotal"
|
||||
, "_gst_reserved"
|
||||
, "ABI"
|
||||
, (long) Marshal.OffsetOf(typeof(GstAudioRingBufferSpec_seglatencyAlign), "seglatency")
|
||||
, 0
|
||||
),
|
||||
new GLib.AbiField("_gst_reserved"
|
||||
// union struct ABI.abi
|
||||
new GLib.AbiField("ABI.abi.dsd_format"
|
||||
, -1
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr)) * 4 // _gst_reserved
|
||||
, (uint) Marshal.SizeOf(System.Enum.GetUnderlyingType(typeof(Gst.Audio.DsdFormat))) // ABI.abi.dsd_format
|
||||
, "seglatency"
|
||||
, null
|
||||
, (long) Marshal.OffsetOf(typeof(GstAudioRingBufferSpec_ABI_abi_dsd_formatAlign), "ABI_abi_dsd_format")
|
||||
, 0
|
||||
),
|
||||
// End ABI.abi
|
||||
|
||||
// union struct ABI
|
||||
new GLib.AbiField("ABI._gst_reserved"
|
||||
, -1
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr)) * 4 // ABI._gst_reserved
|
||||
, "seglatency"
|
||||
, null
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr))
|
||||
, 0
|
||||
),
|
||||
// End ABI
|
||||
|
||||
new GLib.AbiField("ABI"
|
||||
, -1
|
||||
, new List<List<string>>() { // union ABI
|
||||
new List<string>() {"ABI.abi.dsd_format"},
|
||||
new List<string>() {"ABI._gst_reserved"}
|
||||
}
|
||||
, "seglatency"
|
||||
, null
|
||||
, 0
|
||||
),
|
||||
});
|
||||
|
||||
return _abi_info;
|
||||
|
@ -260,6 +284,13 @@ namespace Gst.Audio {
|
|||
private int seglatency;
|
||||
}
|
||||
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
public struct GstAudioRingBufferSpec_ABI_abi_dsd_formatAlign
|
||||
{
|
||||
sbyte f1;
|
||||
private Gst.Audio.DsdFormat ABI_abi_dsd_format;
|
||||
}
|
||||
|
||||
|
||||
// End of the ABI representation.
|
||||
|
||||
|
|
|
@ -273,14 +273,14 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate int WriteNativeDelegate (IntPtr inst, IntPtr data, uint length);
|
||||
delegate int WriteNativeDelegate (IntPtr inst, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]IntPtr[] data, uint length);
|
||||
|
||||
static int Write_cb (IntPtr inst, IntPtr data, uint length)
|
||||
static int Write_cb (IntPtr inst, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]IntPtr[] data, uint length)
|
||||
{
|
||||
try {
|
||||
AudioSink __obj = GLib.Object.GetObject (inst, false) as AudioSink;
|
||||
int __result;
|
||||
__result = __obj.OnWrite (data, length);
|
||||
__result = __obj.OnWrite (data);
|
||||
return __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -290,12 +290,12 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.Audio.AudioSink), ConnectionMethod="OverrideWrite")]
|
||||
protected virtual int OnWrite (IntPtr data, uint length)
|
||||
protected virtual int OnWrite (IntPtr[] data)
|
||||
{
|
||||
return InternalWrite (data, length);
|
||||
return InternalWrite (data);
|
||||
}
|
||||
|
||||
private int InternalWrite (IntPtr data, uint length)
|
||||
private int InternalWrite (IntPtr[] data)
|
||||
{
|
||||
WriteNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
|
@ -304,6 +304,7 @@ namespace Gst.Audio {
|
|||
}
|
||||
if (unmanaged == null) return 0;
|
||||
|
||||
uint length = (uint)(data == null ? 0 : data.Length);
|
||||
int __result = unmanaged (this.Handle, data, length);
|
||||
return __result;
|
||||
}
|
||||
|
|
|
@ -273,14 +273,14 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate uint ReadNativeDelegate (IntPtr inst, IntPtr data, uint length, ulong timestamp);
|
||||
delegate uint ReadNativeDelegate (IntPtr inst, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]IntPtr[] data, uint length, out ulong timestamp);
|
||||
|
||||
static uint Read_cb (IntPtr inst, IntPtr data, uint length, ulong timestamp)
|
||||
static uint Read_cb (IntPtr inst, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]IntPtr[] data, uint length, out ulong timestamp)
|
||||
{
|
||||
try {
|
||||
AudioSrc __obj = GLib.Object.GetObject (inst, false) as AudioSrc;
|
||||
uint __result;
|
||||
__result = __obj.OnRead (data, length, timestamp);
|
||||
__result = __obj.OnRead (data, out timestamp);
|
||||
return __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -290,21 +290,22 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.Audio.AudioSrc), ConnectionMethod="OverrideRead")]
|
||||
protected virtual uint OnRead (IntPtr data, uint length, ulong timestamp)
|
||||
protected virtual uint OnRead (IntPtr[] data, out ulong timestamp)
|
||||
{
|
||||
return InternalRead (data, length, timestamp);
|
||||
return InternalRead (data, out timestamp);
|
||||
}
|
||||
|
||||
private uint InternalRead (IntPtr data, uint length, ulong timestamp)
|
||||
private uint InternalRead (IntPtr[] data, out ulong timestamp)
|
||||
{
|
||||
ReadNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("read"));
|
||||
unmanaged = (ReadNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(ReadNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return 0;
|
||||
if (unmanaged == null) throw new InvalidOperationException ("No base method to invoke");
|
||||
|
||||
uint __result = unmanaged (this.Handle, data, length, timestamp);
|
||||
uint length = (uint)(data == null ? 0 : data.Length);
|
||||
uint __result = unmanaged (this.Handle, data, length, out timestamp);
|
||||
return __result;
|
||||
}
|
||||
|
||||
|
|
|
@ -13,11 +13,12 @@ namespace Gst.Audio {
|
|||
|
||||
public const string AUDIO_CHANNELS_RANGE = @"(int) [ 1, max ]";
|
||||
public const string AUDIO_CONVERTER_OPT_DITHER_METHOD = @"GstAudioConverter.dither-method";
|
||||
public const string AUDIO_CONVERTER_OPT_DITHER_THRESHOLD = @"GstAudioConverter.dither-threshold";
|
||||
public const string AUDIO_CONVERTER_OPT_MIX_MATRIX = @"GstAudioConverter.mix-matrix";
|
||||
public const string AUDIO_CONVERTER_OPT_NOISE_SHAPING_METHOD = @"GstAudioConverter.noise-shaping-method";
|
||||
public const string AUDIO_CONVERTER_OPT_QUANTIZATION = @"GstAudioConverter.quantization";
|
||||
public const string AUDIO_CONVERTER_OPT_RESAMPLER_METHOD = @"GstAudioConverter.resampler-method";
|
||||
public const int AUDIO_DECODER_MAX_ERRORS = 10;
|
||||
public const int AUDIO_DECODER_MAX_ERRORS = -1;
|
||||
public const string AUDIO_DECODER_SINK_NAME = @"sink";
|
||||
public const string AUDIO_DECODER_SRC_NAME = @"src";
|
||||
public const int AUDIO_DEF_CHANNELS = 2;
|
||||
|
@ -41,9 +42,13 @@ namespace Gst.Audio {
|
|||
public const int AUDIO_RESAMPLER_QUALITY_DEFAULT = 4;
|
||||
public const int AUDIO_RESAMPLER_QUALITY_MAX = 10;
|
||||
public const int AUDIO_RESAMPLER_QUALITY_MIN = 0;
|
||||
public const string DSD_FORMATS_ALL = @"{ DSDU32BE, DSDU16BE, DSDU8, DSDU32LE, DSDU16LE }";
|
||||
public const string DSD_MEDIA_TYPE = @"audio/x-dsd";
|
||||
public const int DSD_SILENCE_PATTERN_BYTE = 105;
|
||||
public const string META_TAG_AUDIO_CHANNELS_STR = @"channels";
|
||||
public const string META_TAG_AUDIO_RATE_STR = @"rate";
|
||||
public const string META_TAG_AUDIO_STR = @"audio";
|
||||
public const string META_TAG_DSD_PLANE_OFFSETS_STR = @"dsdplaneoffsets";
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,35 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace Gst.Audio {
|
||||
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
#region Autogenerated code
|
||||
[GLib.GType (typeof (Gst.Audio.DsdFormatGType))]
|
||||
public enum DsdFormat {
|
||||
|
||||
DsdFormatUnknown = 0,
|
||||
DsdFormatU8 = 1,
|
||||
DsdFormatU16le = 2,
|
||||
DsdFormatU16 = 2,
|
||||
DsdFormatU16be = 3,
|
||||
DsdFormatU32le = 4,
|
||||
DsdFormatU32 = 4,
|
||||
DsdFormatU32be = 5,
|
||||
NumDsdFormats = 6,
|
||||
}
|
||||
|
||||
internal class DsdFormatGType {
|
||||
[DllImport ("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_dsd_format_get_type ();
|
||||
|
||||
public static GLib.GType GType {
|
||||
get {
|
||||
return new GLib.GType (gst_dsd_format_get_type ());
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
}
|
|
@ -0,0 +1,149 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace Gst.Audio {
|
||||
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
#region Autogenerated code
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
public partial struct DsdInfo : IEquatable<DsdInfo> {
|
||||
|
||||
public Gst.Audio.DsdFormat Format;
|
||||
public int Rate;
|
||||
public int Channels;
|
||||
public Gst.Audio.AudioLayout Layout;
|
||||
public bool ReversedBytes;
|
||||
[MarshalAs (UnmanagedType.ByValArray, SizeConst=64)]
|
||||
public Gst.Audio.AudioChannelPosition[] Positions;
|
||||
public Gst.Audio.AudioFlags Flags;
|
||||
[MarshalAs (UnmanagedType.ByValArray, SizeConst=4)]
|
||||
private IntPtr[] _gstGstReserved;
|
||||
|
||||
public static Gst.Audio.DsdInfo Zero = new Gst.Audio.DsdInfo ();
|
||||
|
||||
public static Gst.Audio.DsdInfo New(IntPtr raw) {
|
||||
if (raw == IntPtr.Zero)
|
||||
return Gst.Audio.DsdInfo.Zero;
|
||||
return (Gst.Audio.DsdInfo) Marshal.PtrToStructure (raw, typeof (Gst.Audio.DsdInfo));
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_dsd_info_new();
|
||||
|
||||
public static DsdInfo New()
|
||||
{
|
||||
DsdInfo result = DsdInfo.New (gst_dsd_info_new());
|
||||
return result;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_dsd_info_new_from_caps(IntPtr caps);
|
||||
|
||||
public static DsdInfo NewFromCaps(Gst.Caps caps)
|
||||
{
|
||||
DsdInfo result = DsdInfo.New (gst_dsd_info_new_from_caps(caps == null ? IntPtr.Zero : caps.Handle));
|
||||
return result;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_dsd_info_get_type();
|
||||
|
||||
public static GLib.GType GType {
|
||||
get {
|
||||
IntPtr raw_ret = gst_dsd_info_get_type();
|
||||
GLib.GType ret = new GLib.GType(raw_ret);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_dsd_info_is_equal(IntPtr raw, IntPtr other);
|
||||
|
||||
public bool IsEqual(Gst.Audio.DsdInfo other) {
|
||||
IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf (this));
|
||||
System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false);
|
||||
IntPtr native_other = GLib.Marshaller.StructureToPtrAlloc (other);
|
||||
bool raw_ret = gst_dsd_info_is_equal(this_as_native, native_other);
|
||||
bool ret = raw_ret;
|
||||
ReadNative (this_as_native, ref this);
|
||||
System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native);
|
||||
Marshal.FreeHGlobal (native_other);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_dsd_info_to_caps(IntPtr raw);
|
||||
|
||||
public Gst.Caps ToCaps() {
|
||||
IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf (this));
|
||||
System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false);
|
||||
IntPtr raw_ret = gst_dsd_info_to_caps(this_as_native);
|
||||
Gst.Caps ret = raw_ret == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Caps), true);
|
||||
ReadNative (this_as_native, ref this);
|
||||
System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_dsd_info_from_caps(IntPtr info, IntPtr caps);
|
||||
|
||||
public static bool FromCaps(out Gst.Audio.DsdInfo info, Gst.Caps caps) {
|
||||
IntPtr native_info = Marshal.AllocHGlobal (Marshal.SizeOf (typeof (Gst.Audio.DsdInfo)));
|
||||
bool raw_ret = gst_dsd_info_from_caps(native_info, caps == null ? IntPtr.Zero : caps.Handle);
|
||||
bool ret = raw_ret;
|
||||
info = Gst.Audio.DsdInfo.New (native_info);
|
||||
Marshal.FreeHGlobal (native_info);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_dsd_info_init(IntPtr info);
|
||||
|
||||
public static Gst.Audio.DsdInfo Init() {
|
||||
Gst.Audio.DsdInfo info;
|
||||
IntPtr native_info = Marshal.AllocHGlobal (Marshal.SizeOf (typeof (Gst.Audio.DsdInfo)));
|
||||
gst_dsd_info_init(native_info);
|
||||
info = Gst.Audio.DsdInfo.New (native_info);
|
||||
Marshal.FreeHGlobal (native_info);
|
||||
return info;
|
||||
}
|
||||
|
||||
static void ReadNative (IntPtr native, ref Gst.Audio.DsdInfo target)
|
||||
{
|
||||
target = New (native);
|
||||
}
|
||||
|
||||
public bool Equals (DsdInfo other)
|
||||
{
|
||||
return true && Format.Equals (other.Format) && Rate.Equals (other.Rate) && Channels.Equals (other.Channels) && Layout.Equals (other.Layout) && ReversedBytes.Equals (other.ReversedBytes) && Positions.Equals (other.Positions) && Flags.Equals (other.Flags);
|
||||
}
|
||||
|
||||
public override bool Equals (object other)
|
||||
{
|
||||
return other is DsdInfo && Equals ((DsdInfo) other);
|
||||
}
|
||||
|
||||
public override int GetHashCode ()
|
||||
{
|
||||
return this.GetType ().FullName.GetHashCode () ^ Format.GetHashCode () ^ Rate.GetHashCode () ^ Channels.GetHashCode () ^ Layout.GetHashCode () ^ ReversedBytes.GetHashCode () ^ Positions.GetHashCode () ^ Flags.GetHashCode ();
|
||||
}
|
||||
|
||||
public static explicit operator GLib.Value (Gst.Audio.DsdInfo boxed)
|
||||
{
|
||||
GLib.Value val = GLib.Value.Empty;
|
||||
val.Init (Gst.Audio.DsdInfo.GType);
|
||||
val.Val = boxed;
|
||||
return val;
|
||||
}
|
||||
|
||||
public static explicit operator Gst.Audio.DsdInfo (GLib.Value val)
|
||||
{
|
||||
return (Gst.Audio.DsdInfo) val.Val;
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
|
@ -0,0 +1,77 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace Gst.Audio {
|
||||
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
#region Autogenerated code
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
public partial struct DsdPlaneOffsetMeta : IEquatable<DsdPlaneOffsetMeta> {
|
||||
|
||||
public Gst.Meta Meta;
|
||||
public int NumChannels;
|
||||
private UIntPtr num_bytes_per_channel;
|
||||
public ulong NumBytesPerChannel {
|
||||
get {
|
||||
return (ulong) num_bytes_per_channel;
|
||||
}
|
||||
set {
|
||||
num_bytes_per_channel = new UIntPtr (value);
|
||||
}
|
||||
}
|
||||
private UIntPtr offsets;
|
||||
public ulong Offsets {
|
||||
get {
|
||||
return (ulong) offsets;
|
||||
}
|
||||
set {
|
||||
offsets = new UIntPtr (value);
|
||||
}
|
||||
}
|
||||
[MarshalAs (UnmanagedType.ByValArray, SizeConst=4)]
|
||||
private IntPtr[] _gstGstReserved;
|
||||
|
||||
public static Gst.Audio.DsdPlaneOffsetMeta Zero = new Gst.Audio.DsdPlaneOffsetMeta ();
|
||||
|
||||
public static Gst.Audio.DsdPlaneOffsetMeta New(IntPtr raw) {
|
||||
if (raw == IntPtr.Zero)
|
||||
return Gst.Audio.DsdPlaneOffsetMeta.Zero;
|
||||
return (Gst.Audio.DsdPlaneOffsetMeta) Marshal.PtrToStructure (raw, typeof (Gst.Audio.DsdPlaneOffsetMeta));
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_dsd_plane_offset_meta_get_info();
|
||||
|
||||
public static Gst.MetaInfo Info {
|
||||
get {
|
||||
IntPtr raw_ret = gst_dsd_plane_offset_meta_get_info();
|
||||
Gst.MetaInfo ret = Gst.MetaInfo.New (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
public bool Equals (DsdPlaneOffsetMeta other)
|
||||
{
|
||||
return true && Meta.Equals (other.Meta) && NumChannels.Equals (other.NumChannels) && NumBytesPerChannel.Equals (other.NumBytesPerChannel) && Offsets.Equals (other.Offsets);
|
||||
}
|
||||
|
||||
public override bool Equals (object other)
|
||||
{
|
||||
return other is DsdPlaneOffsetMeta && Equals ((DsdPlaneOffsetMeta) other);
|
||||
}
|
||||
|
||||
public override int GetHashCode ()
|
||||
{
|
||||
return this.GetType ().FullName.GetHashCode () ^ Meta.GetHashCode () ^ NumChannels.GetHashCode () ^ NumBytesPerChannel.GetHashCode () ^ Offsets.GetHashCode ();
|
||||
}
|
||||
|
||||
private static GLib.GType GType {
|
||||
get { return GLib.GType.Pointer; }
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
|
@ -24,16 +24,27 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_buffer_reorder_channels(IntPtr buffer, int format, int channels, int[] from, int[] to);
|
||||
static extern bool gst_audio_buffer_map(IntPtr buffer, IntPtr info, IntPtr gstbuffer, int flags);
|
||||
|
||||
public static bool AudioBufferReorderChannels(Gst.Buffer buffer, Gst.Audio.AudioFormat format, int channels, Gst.Audio.AudioChannelPosition[] from, Gst.Audio.AudioChannelPosition[] to) {
|
||||
int cnt_from = from == null ? 0 : from.Length;
|
||||
int[] native_from = new int [cnt_from];
|
||||
for (int i = 0; i < cnt_from; i++)
|
||||
public static bool AudioBufferMap(out Gst.Audio.AudioBuffer buffer, Gst.Audio.AudioInfo info, Gst.Buffer gstbuffer, Gst.MapFlags flags) {
|
||||
IntPtr native_buffer = Marshal.AllocHGlobal (Marshal.SizeOf (typeof (Gst.Audio.AudioBuffer)));
|
||||
bool raw_ret = gst_audio_buffer_map(native_buffer, info == null ? IntPtr.Zero : info.Handle, gstbuffer == null ? IntPtr.Zero : gstbuffer.Handle, (int) flags);
|
||||
bool ret = raw_ret;
|
||||
buffer = Gst.Audio.AudioBuffer.New (native_buffer);
|
||||
Marshal.FreeHGlobal (native_buffer);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_buffer_reorder_channels(IntPtr buffer, int format, int channels, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]int[] from, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]int[] to);
|
||||
|
||||
public static bool AudioBufferReorderChannels(Gst.Buffer buffer, Gst.Audio.AudioFormat format, Gst.Audio.AudioChannelPosition[] from, Gst.Audio.AudioChannelPosition[] to) {
|
||||
int channels = (from == null ? 0 : from.Length);
|
||||
int[] native_from = new int [channels];
|
||||
for (int i = 0; i < channels; i++)
|
||||
native_from [i] = (int) from[i];
|
||||
int cnt_to = to == null ? 0 : to.Length;
|
||||
int[] native_to = new int [cnt_to];
|
||||
for (int i = 0; i < cnt_to; i++)
|
||||
int[] native_to = new int [channels];
|
||||
for (int i = 0; i < channels; i++)
|
||||
native_to [i] = (int) to[i];
|
||||
bool raw_ret = gst_audio_buffer_reorder_channels(buffer == null ? IntPtr.Zero : buffer.Handle, (int) format, channels, native_from, native_to);
|
||||
bool ret = raw_ret;
|
||||
|
@ -60,25 +71,25 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_channel_positions_from_mask(int channels, ulong channel_mask, int[] position);
|
||||
static extern bool gst_audio_channel_positions_from_mask(ulong channel_mask, int channels, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)]int[] position);
|
||||
|
||||
public static bool AudioChannelPositionsFromMask(int channels, ulong channel_mask, Gst.Audio.AudioChannelPosition[] position) {
|
||||
int cnt_position = position == null ? 0 : position.Length;
|
||||
int[] native_position = new int [cnt_position];
|
||||
for (int i = 0; i < cnt_position; i++)
|
||||
public static bool AudioChannelPositionsFromMask(ulong channel_mask, Gst.Audio.AudioChannelPosition[] position) {
|
||||
int channels = (position == null ? 0 : position.Length);
|
||||
int[] native_position = new int [channels];
|
||||
for (int i = 0; i < channels; i++)
|
||||
native_position [i] = (int) position[i];
|
||||
bool raw_ret = gst_audio_channel_positions_from_mask(channels, channel_mask, native_position);
|
||||
bool raw_ret = gst_audio_channel_positions_from_mask(channel_mask, channels, native_position);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_channel_positions_to_mask(int[] position, int channels, bool force_order, out ulong channel_mask);
|
||||
static extern bool gst_audio_channel_positions_to_mask([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]int[] position, int channels, bool force_order, out ulong channel_mask);
|
||||
|
||||
public static bool AudioChannelPositionsToMask(Gst.Audio.AudioChannelPosition[] position, int channels, bool force_order, out ulong channel_mask) {
|
||||
int cnt_position = position == null ? 0 : position.Length;
|
||||
int[] native_position = new int [cnt_position];
|
||||
for (int i = 0; i < cnt_position; i++)
|
||||
public static bool AudioChannelPositionsToMask(Gst.Audio.AudioChannelPosition[] position, bool force_order, out ulong channel_mask) {
|
||||
int channels = (position == null ? 0 : position.Length);
|
||||
int[] native_position = new int [channels];
|
||||
for (int i = 0; i < channels; i++)
|
||||
native_position [i] = (int) position[i];
|
||||
bool raw_ret = gst_audio_channel_positions_to_mask(native_position, channels, force_order, out channel_mask);
|
||||
bool ret = raw_ret;
|
||||
|
@ -86,12 +97,12 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_audio_channel_positions_to_string(int[] position, int channels);
|
||||
static extern IntPtr gst_audio_channel_positions_to_string([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]int[] position, int channels);
|
||||
|
||||
public static string AudioChannelPositionsToString(Gst.Audio.AudioChannelPosition[] position, int channels) {
|
||||
int cnt_position = position == null ? 0 : position.Length;
|
||||
int[] native_position = new int [cnt_position];
|
||||
for (int i = 0; i < cnt_position; i++)
|
||||
public static string AudioChannelPositionsToString(Gst.Audio.AudioChannelPosition[] position) {
|
||||
int channels = (position == null ? 0 : position.Length);
|
||||
int[] native_position = new int [channels];
|
||||
for (int i = 0; i < channels; i++)
|
||||
native_position [i] = (int) position[i];
|
||||
IntPtr raw_ret = gst_audio_channel_positions_to_string(native_position, channels);
|
||||
string ret = GLib.Marshaller.PtrToStringGFree(raw_ret);
|
||||
|
@ -99,12 +110,12 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_channel_positions_to_valid_order(int[] position, int channels);
|
||||
static extern bool gst_audio_channel_positions_to_valid_order([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]int[] position, int channels);
|
||||
|
||||
public static bool AudioChannelPositionsToValidOrder(Gst.Audio.AudioChannelPosition[] position, int channels) {
|
||||
int cnt_position = position == null ? 0 : position.Length;
|
||||
int[] native_position = new int [cnt_position];
|
||||
for (int i = 0; i < cnt_position; i++)
|
||||
public static bool AudioChannelPositionsToValidOrder(Gst.Audio.AudioChannelPosition[] position) {
|
||||
int channels = (position == null ? 0 : position.Length);
|
||||
int[] native_position = new int [channels];
|
||||
for (int i = 0; i < channels; i++)
|
||||
native_position [i] = (int) position[i];
|
||||
bool raw_ret = gst_audio_channel_positions_to_valid_order(native_position, channels);
|
||||
bool ret = raw_ret;
|
||||
|
@ -112,12 +123,12 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_check_valid_channel_positions(int[] position, int channels, bool force_order);
|
||||
static extern bool gst_audio_check_valid_channel_positions([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]int[] position, int channels, bool force_order);
|
||||
|
||||
public static bool AudioCheckValidChannelPositions(Gst.Audio.AudioChannelPosition[] position, int channels, bool force_order) {
|
||||
int cnt_position = position == null ? 0 : position.Length;
|
||||
int[] native_position = new int [cnt_position];
|
||||
for (int i = 0; i < cnt_position; i++)
|
||||
public static bool AudioCheckValidChannelPositions(Gst.Audio.AudioChannelPosition[] position, bool force_order) {
|
||||
int channels = (position == null ? 0 : position.Length);
|
||||
int[] native_position = new int [channels];
|
||||
for (int i = 0; i < channels; i++)
|
||||
native_position [i] = (int) position[i];
|
||||
bool raw_ret = gst_audio_check_valid_channel_positions(native_position, channels, force_order);
|
||||
bool ret = raw_ret;
|
||||
|
@ -170,11 +181,13 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_audio_format_fill_silence(IntPtr info, byte[] dest, UIntPtr n_length);
|
||||
static extern void gst_audio_format_fill_silence(IntPtr info, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] dest, UIntPtr n_length);
|
||||
|
||||
[Obsolete]
|
||||
public static void AudioFormatFillSilence(Gst.Audio.AudioFormatInfo info, byte[] dest) {
|
||||
IntPtr native_info = GLib.Marshaller.StructureToPtrAlloc (info);
|
||||
gst_audio_format_fill_silence(native_info, dest, new UIntPtr ((ulong) (dest == null ? 0 : dest.Length)));
|
||||
ulong n_length = (ulong)(dest == null ? 0 : dest.Length);
|
||||
gst_audio_format_fill_silence(native_info, dest, new UIntPtr ((uint)n_length));
|
||||
Marshal.FreeHGlobal (native_info);
|
||||
}
|
||||
|
||||
|
@ -217,16 +230,15 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_get_channel_reorder_map(int channels, int[] from, int[] to, int[] reorder_map);
|
||||
static extern bool gst_audio_get_channel_reorder_map(int channels, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)]int[] from, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)]int[] to, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)]int[] reorder_map);
|
||||
|
||||
public static bool AudioGetChannelReorderMap(int channels, Gst.Audio.AudioChannelPosition[] from, Gst.Audio.AudioChannelPosition[] to, int[] reorder_map) {
|
||||
int cnt_from = from == null ? 0 : from.Length;
|
||||
int[] native_from = new int [cnt_from];
|
||||
for (int i = 0; i < cnt_from; i++)
|
||||
public static bool AudioGetChannelReorderMap(Gst.Audio.AudioChannelPosition[] from, Gst.Audio.AudioChannelPosition[] to, int[] reorder_map) {
|
||||
int channels = (from == null ? 0 : from.Length);
|
||||
int[] native_from = new int [channels];
|
||||
for (int i = 0; i < channels; i++)
|
||||
native_from [i] = (int) from[i];
|
||||
int cnt_to = to == null ? 0 : to.Length;
|
||||
int[] native_to = new int [cnt_to];
|
||||
for (int i = 0; i < cnt_to; i++)
|
||||
int[] native_to = new int [channels];
|
||||
for (int i = 0; i < channels; i++)
|
||||
native_to [i] = (int) to[i];
|
||||
bool raw_ret = gst_audio_get_channel_reorder_map(channels, native_from, native_to, reorder_map);
|
||||
bool ret = raw_ret;
|
||||
|
@ -243,29 +255,71 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_iec61937_payload(byte[] src, uint src_n, byte[] dst, uint dst_n, IntPtr spec, int endianness);
|
||||
static extern bool gst_audio_iec61937_payload([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] src, uint src_n, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=3)]byte[] dst, uint dst_n, IntPtr spec, int endianness);
|
||||
|
||||
public static bool AudioIec61937Payload(byte[] src, uint src_n, byte[] dst, uint dst_n, Gst.Audio.AudioRingBufferSpec spec, int endianness) {
|
||||
public static bool AudioIec61937Payload(byte[] src, byte[] dst, Gst.Audio.AudioRingBufferSpec spec, int endianness) {
|
||||
uint src_n = (uint)(src == null ? 0 : src.Length);
|
||||
uint dst_n = (uint)(dst == null ? 0 : dst.Length);
|
||||
bool raw_ret = gst_audio_iec61937_payload(src, src_n, dst, dst_n, spec == null ? IntPtr.Zero : spec.Handle, endianness);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_audio_make_raw_caps(int[] formats, uint len, int layout);
|
||||
static extern bool gst_audio_info_from_caps(out IntPtr info, IntPtr caps);
|
||||
|
||||
public static Gst.Caps AudioMakeRawCaps(Gst.Audio.AudioFormat[] formats, uint len, Gst.Audio.AudioLayout layout) {
|
||||
int cnt_formats = formats == null ? 0 : formats.Length;
|
||||
int[] native_formats = new int [cnt_formats];
|
||||
for (int i = 0; i < cnt_formats; i++)
|
||||
public static bool AudioInfoFromCaps(out Gst.Audio.AudioInfo info, Gst.Caps caps) {
|
||||
IntPtr native_info;
|
||||
bool raw_ret = gst_audio_info_from_caps(out native_info, caps == null ? IntPtr.Zero : caps.Handle);
|
||||
bool ret = raw_ret;
|
||||
info = native_info == IntPtr.Zero ? null : (Gst.Audio.AudioInfo) GLib.Opaque.GetOpaque (native_info, typeof (Gst.Audio.AudioInfo), false);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_audio_info_init(out IntPtr info);
|
||||
|
||||
public static Gst.Audio.AudioInfo AudioInfoInit() {
|
||||
Gst.Audio.AudioInfo info;
|
||||
IntPtr native_info;
|
||||
gst_audio_info_init(out native_info);
|
||||
info = native_info == IntPtr.Zero ? null : (Gst.Audio.AudioInfo) GLib.Opaque.GetOpaque (native_info, typeof (Gst.Audio.AudioInfo), false);
|
||||
return info;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_audio_level_meta_api_get_type();
|
||||
|
||||
public static GLib.GType AudioLevelMetaApiGetType() {
|
||||
IntPtr raw_ret = gst_audio_level_meta_api_get_type();
|
||||
GLib.GType ret = new GLib.GType(raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_audio_level_meta_get_info();
|
||||
|
||||
public static Gst.MetaInfo AudioLevelMetaGetInfo() {
|
||||
IntPtr raw_ret = gst_audio_level_meta_get_info();
|
||||
Gst.MetaInfo ret = Gst.MetaInfo.New (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_audio_make_raw_caps([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]int[] formats, uint len, int layout);
|
||||
|
||||
public static Gst.Caps AudioMakeRawCaps(Gst.Audio.AudioFormat[] formats, Gst.Audio.AudioLayout layout) {
|
||||
uint len = (uint)(formats == null ? 0 : formats.Length);
|
||||
int[] native_formats = new int [len];
|
||||
for (int i = 0; i < len; i++)
|
||||
native_formats [i] = (int) formats[i];
|
||||
IntPtr raw_ret = gst_audio_make_raw_caps(native_formats, len, (int) layout);
|
||||
Gst.Caps ret = raw_ret == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Caps), true);
|
||||
return ret;
|
||||
}
|
||||
|
||||
public static Gst.Caps AudioMakeRawCaps(uint len, Gst.Audio.AudioLayout layout) {
|
||||
return AudioMakeRawCaps (null, len, layout);
|
||||
public static Gst.Caps AudioMakeRawCaps(Gst.Audio.AudioLayout layout) {
|
||||
return AudioMakeRawCaps (null, layout);
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
|
@ -287,18 +341,18 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_audio_reorder_channels(byte[] data, UIntPtr n_length, int format, int channels, int[] from, int[] to);
|
||||
static extern bool gst_audio_reorder_channels([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] data, UIntPtr n_length, int format, int channels, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=3)]int[] from, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=3)]int[] to);
|
||||
|
||||
public static bool AudioReorderChannels(byte[] data, Gst.Audio.AudioFormat format, int channels, Gst.Audio.AudioChannelPosition[] from, Gst.Audio.AudioChannelPosition[] to) {
|
||||
int cnt_from = from == null ? 0 : from.Length;
|
||||
int[] native_from = new int [cnt_from];
|
||||
for (int i = 0; i < cnt_from; i++)
|
||||
public static bool AudioReorderChannels(byte[] data, Gst.Audio.AudioFormat format, Gst.Audio.AudioChannelPosition[] from, Gst.Audio.AudioChannelPosition[] to) {
|
||||
ulong n_length = (ulong)(data == null ? 0 : data.Length);
|
||||
int channels = (from == null ? 0 : from.Length);
|
||||
int[] native_from = new int [channels];
|
||||
for (int i = 0; i < channels; i++)
|
||||
native_from [i] = (int) from[i];
|
||||
int cnt_to = to == null ? 0 : to.Length;
|
||||
int[] native_to = new int [cnt_to];
|
||||
for (int i = 0; i < cnt_to; i++)
|
||||
int[] native_to = new int [channels];
|
||||
for (int i = 0; i < channels; i++)
|
||||
native_to [i] = (int) to[i];
|
||||
bool raw_ret = gst_audio_reorder_channels(data, new UIntPtr ((ulong) (data == null ? 0 : data.Length)), (int) format, channels, native_from, native_to);
|
||||
bool raw_ret = gst_audio_reorder_channels(data, new UIntPtr ((uint)n_length), (int) format, channels, native_from, native_to);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
@ -329,22 +383,31 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_buffer_add_audio_downmix_meta(IntPtr buffer, int[] from_position, int from_channels, int[] to_position, int to_channels, float matrix);
|
||||
static extern IntPtr gst_buffer_add_audio_downmix_meta(IntPtr buffer, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]int[] from_position, int from_channels, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=4)]int[] to_position, int to_channels, float matrix);
|
||||
|
||||
public static Gst.Audio.AudioDownmixMeta BufferAddAudioDownmixMeta(Gst.Buffer buffer, Gst.Audio.AudioChannelPosition[] from_position, int from_channels, Gst.Audio.AudioChannelPosition[] to_position, int to_channels, float matrix) {
|
||||
int cnt_from_position = from_position == null ? 0 : from_position.Length;
|
||||
int[] native_from_position = new int [cnt_from_position];
|
||||
for (int i = 0; i < cnt_from_position; i++)
|
||||
public static Gst.Audio.AudioDownmixMeta BufferAddAudioDownmixMeta(Gst.Buffer buffer, Gst.Audio.AudioChannelPosition[] from_position, Gst.Audio.AudioChannelPosition[] to_position, float matrix) {
|
||||
int from_channels = (from_position == null ? 0 : from_position.Length);
|
||||
int[] native_from_position = new int [from_channels];
|
||||
for (int i = 0; i < from_channels; i++)
|
||||
native_from_position [i] = (int) from_position[i];
|
||||
int cnt_to_position = to_position == null ? 0 : to_position.Length;
|
||||
int[] native_to_position = new int [cnt_to_position];
|
||||
for (int i = 0; i < cnt_to_position; i++)
|
||||
int to_channels = (to_position == null ? 0 : to_position.Length);
|
||||
int[] native_to_position = new int [to_channels];
|
||||
for (int i = 0; i < to_channels; i++)
|
||||
native_to_position [i] = (int) to_position[i];
|
||||
IntPtr raw_ret = gst_buffer_add_audio_downmix_meta(buffer == null ? IntPtr.Zero : buffer.Handle, native_from_position, from_channels, native_to_position, to_channels, matrix);
|
||||
Gst.Audio.AudioDownmixMeta ret = Gst.Audio.AudioDownmixMeta.New (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_buffer_add_audio_level_meta(IntPtr buffer, byte level, bool voice_activity);
|
||||
|
||||
public static Gst.Audio.AudioLevelMeta BufferAddAudioLevelMeta(Gst.Buffer buffer, byte level, bool voice_activity) {
|
||||
IntPtr raw_ret = gst_buffer_add_audio_level_meta(buffer == null ? IntPtr.Zero : buffer.Handle, level, voice_activity);
|
||||
Gst.Audio.AudioLevelMeta ret = Gst.Audio.AudioLevelMeta.New (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_buffer_add_audio_meta(IntPtr buffer, IntPtr info, UIntPtr samples, UIntPtr offsets);
|
||||
|
||||
|
@ -359,18 +422,118 @@ namespace Gst.Audio {
|
|||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_buffer_get_audio_downmix_meta_for_channels(IntPtr buffer, int[] to_position, int to_channels);
|
||||
static extern IntPtr gst_buffer_add_dsd_plane_offset_meta(IntPtr buffer, int num_channels, UIntPtr num_bytes_per_channel, UIntPtr offsets);
|
||||
|
||||
public static Gst.Audio.AudioDownmixMeta BufferGetAudioDownmixMetaForChannels(Gst.Buffer buffer, Gst.Audio.AudioChannelPosition[] to_position, int to_channels) {
|
||||
int cnt_to_position = to_position == null ? 0 : to_position.Length;
|
||||
int[] native_to_position = new int [cnt_to_position];
|
||||
for (int i = 0; i < cnt_to_position; i++)
|
||||
public static Gst.Audio.DsdPlaneOffsetMeta BufferAddDsdPlaneOffsetMeta(Gst.Buffer buffer, int num_channels, ulong num_bytes_per_channel, ulong offsets) {
|
||||
IntPtr raw_ret = gst_buffer_add_dsd_plane_offset_meta(buffer == null ? IntPtr.Zero : buffer.Handle, num_channels, new UIntPtr (num_bytes_per_channel), new UIntPtr (offsets));
|
||||
Gst.Audio.DsdPlaneOffsetMeta ret = Gst.Audio.DsdPlaneOffsetMeta.New (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
public static Gst.Audio.DsdPlaneOffsetMeta BufferAddDsdPlaneOffsetMeta(Gst.Buffer buffer, int num_channels, ulong num_bytes_per_channel) {
|
||||
return BufferAddDsdPlaneOffsetMeta (buffer, num_channels, num_bytes_per_channel, 0);
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_buffer_get_audio_downmix_meta_for_channels(IntPtr buffer, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]int[] to_position, int to_channels);
|
||||
|
||||
public static Gst.Audio.AudioDownmixMeta BufferGetAudioDownmixMetaForChannels(Gst.Buffer buffer, Gst.Audio.AudioChannelPosition[] to_position) {
|
||||
int to_channels = (to_position == null ? 0 : to_position.Length);
|
||||
int[] native_to_position = new int [to_channels];
|
||||
for (int i = 0; i < to_channels; i++)
|
||||
native_to_position [i] = (int) to_position[i];
|
||||
IntPtr raw_ret = gst_buffer_get_audio_downmix_meta_for_channels(buffer == null ? IntPtr.Zero : buffer.Handle, native_to_position, to_channels);
|
||||
Gst.Audio.AudioDownmixMeta ret = Gst.Audio.AudioDownmixMeta.New (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_buffer_get_audio_level_meta(IntPtr buffer);
|
||||
|
||||
public static Gst.Audio.AudioLevelMeta BufferGetAudioLevelMeta(Gst.Buffer buffer) {
|
||||
IntPtr raw_ret = gst_buffer_get_audio_level_meta(buffer == null ? IntPtr.Zero : buffer.Handle);
|
||||
Gst.Audio.AudioLevelMeta ret = Gst.Audio.AudioLevelMeta.New (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_dsd_convert(byte input_data, byte output_data, int input_format, int output_format, int input_layout, int output_layout, UIntPtr input_plane_offsets, UIntPtr output_plane_offsets, UIntPtr num_dsd_bytes, int num_channels, bool reverse_byte_bits);
|
||||
|
||||
public static void DsdConvert(byte input_data, byte output_data, Gst.Audio.DsdFormat input_format, Gst.Audio.DsdFormat output_format, Gst.Audio.AudioLayout input_layout, Gst.Audio.AudioLayout output_layout, ulong input_plane_offsets, ulong output_plane_offsets, ulong num_dsd_bytes, int num_channels, bool reverse_byte_bits) {
|
||||
gst_dsd_convert(input_data, output_data, (int) input_format, (int) output_format, (int) input_layout, (int) output_layout, new UIntPtr (input_plane_offsets), new UIntPtr (output_plane_offsets), new UIntPtr (num_dsd_bytes), num_channels, reverse_byte_bits);
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern int gst_dsd_format_from_string(IntPtr str);
|
||||
|
||||
public static Gst.Audio.DsdFormat DsdFormatFromString(string str) {
|
||||
IntPtr native_str = GLib.Marshaller.StringToPtrGStrdup (str);
|
||||
int raw_ret = gst_dsd_format_from_string(native_str);
|
||||
Gst.Audio.DsdFormat ret = (Gst.Audio.DsdFormat) raw_ret;
|
||||
GLib.Marshaller.Free (native_str);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern uint gst_dsd_format_get_width(int format);
|
||||
|
||||
public static uint DsdFormatGetWidth(Gst.Audio.DsdFormat format) {
|
||||
uint raw_ret = gst_dsd_format_get_width((int) format);
|
||||
uint ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_dsd_format_to_string(int format);
|
||||
|
||||
public static string DsdFormatToString(Gst.Audio.DsdFormat format) {
|
||||
IntPtr raw_ret = gst_dsd_format_to_string((int) format);
|
||||
string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_dsd_info_from_caps(IntPtr info, IntPtr caps);
|
||||
|
||||
public static bool DsdInfoFromCaps(out Gst.Audio.DsdInfo info, Gst.Caps caps) {
|
||||
IntPtr native_info = Marshal.AllocHGlobal (Marshal.SizeOf (typeof (Gst.Audio.DsdInfo)));
|
||||
bool raw_ret = gst_dsd_info_from_caps(native_info, caps == null ? IntPtr.Zero : caps.Handle);
|
||||
bool ret = raw_ret;
|
||||
info = Gst.Audio.DsdInfo.New (native_info);
|
||||
Marshal.FreeHGlobal (native_info);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_dsd_info_init(IntPtr info);
|
||||
|
||||
public static Gst.Audio.DsdInfo DsdInfoInit() {
|
||||
Gst.Audio.DsdInfo info;
|
||||
IntPtr native_info = Marshal.AllocHGlobal (Marshal.SizeOf (typeof (Gst.Audio.DsdInfo)));
|
||||
gst_dsd_info_init(native_info);
|
||||
info = Gst.Audio.DsdInfo.New (native_info);
|
||||
Marshal.FreeHGlobal (native_info);
|
||||
return info;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_dsd_plane_offset_meta_api_get_type();
|
||||
|
||||
public static GLib.GType DsdPlaneOffsetMetaApiGetType() {
|
||||
IntPtr raw_ret = gst_dsd_plane_offset_meta_api_get_type();
|
||||
GLib.GType ret = new GLib.GType(raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_dsd_plane_offset_meta_get_info();
|
||||
|
||||
public static Gst.MetaInfo DsdPlaneOffsetMetaGetInfo() {
|
||||
IntPtr raw_ret = gst_dsd_plane_offset_meta_get_info();
|
||||
Gst.MetaInfo ret = Gst.MetaInfo.New (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstaudio-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern double gst_stream_volume_convert_volume(int from, int to, double val);
|
||||
|
||||
|
|
|
@ -40,10 +40,10 @@ namespace Gst.AudioSharp {
|
|||
}
|
||||
}
|
||||
|
||||
void InvokeNative (Gst.Audio.AudioFormatInfo info, Gst.Audio.AudioPackFlags flags, byte[] src, byte[] data)
|
||||
void InvokeNative (Gst.Audio.AudioFormatInfo info, Gst.Audio.AudioPackFlags flags, byte[] src, byte[] data, int n_length)
|
||||
{
|
||||
IntPtr native_info = GLib.Marshaller.StructureToPtrAlloc (info);
|
||||
native_cb (native_info, (int) flags, src, data, (data == null ? 0 : data.Length));
|
||||
native_cb (native_info, (int) flags, src, data, n_length);
|
||||
Marshal.FreeHGlobal (native_info);
|
||||
}
|
||||
}
|
||||
|
@ -53,7 +53,7 @@ namespace Gst.AudioSharp {
|
|||
public void NativeCallback (IntPtr info, int flags, byte[] src, byte[] data, int n_length)
|
||||
{
|
||||
try {
|
||||
managed (Gst.Audio.AudioFormatInfo.New (info), (Gst.Audio.AudioPackFlags) flags, src, data);
|
||||
managed (Gst.Audio.AudioFormatInfo.New (info), (Gst.Audio.AudioPackFlags) flags, src, data, n_length);
|
||||
if (release_on_call)
|
||||
gch.Free ();
|
||||
} catch (Exception e) {
|
||||
|
|
|
@ -40,10 +40,10 @@ namespace Gst.AudioSharp {
|
|||
}
|
||||
}
|
||||
|
||||
void InvokeNative (Gst.Audio.AudioFormatInfo info, Gst.Audio.AudioPackFlags flags, byte[] dest, byte[] data)
|
||||
void InvokeNative (Gst.Audio.AudioFormatInfo info, Gst.Audio.AudioPackFlags flags, byte[] dest, byte[] data, int n_length)
|
||||
{
|
||||
IntPtr native_info = GLib.Marshaller.StructureToPtrAlloc (info);
|
||||
native_cb (native_info, (int) flags, dest, data, (data == null ? 0 : data.Length));
|
||||
native_cb (native_info, (int) flags, dest, data, n_length);
|
||||
Marshal.FreeHGlobal (native_info);
|
||||
}
|
||||
}
|
||||
|
@ -53,7 +53,7 @@ namespace Gst.AudioSharp {
|
|||
public void NativeCallback (IntPtr info, int flags, byte[] dest, byte[] data, int n_length)
|
||||
{
|
||||
try {
|
||||
managed (Gst.Audio.AudioFormatInfo.New (info), (Gst.Audio.AudioPackFlags) flags, dest, data);
|
||||
managed (Gst.Audio.AudioFormatInfo.New (info), (Gst.Audio.AudioPackFlags) flags, dest, data, n_length);
|
||||
if (release_on_call)
|
||||
gch.Free ();
|
||||
} catch (Exception e) {
|
||||
|
|
|
@ -8,7 +8,7 @@ namespace Gst.AudioSharp {
|
|||
|
||||
#region Autogenerated code
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
internal delegate void AudioRingBufferCallbackNative(IntPtr rbuf, byte[] data, uint len, IntPtr user_data);
|
||||
internal delegate void AudioRingBufferCallbackNative(IntPtr rbuf, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] data, uint len, IntPtr user_data);
|
||||
|
||||
internal class AudioRingBufferCallbackInvoker {
|
||||
|
||||
|
@ -40,18 +40,19 @@ namespace Gst.AudioSharp {
|
|||
}
|
||||
}
|
||||
|
||||
void InvokeNative (Gst.Audio.AudioRingBuffer rbuf, byte[] data, uint len)
|
||||
void InvokeNative (Gst.Audio.AudioRingBuffer rbuf, byte[] data, IntPtr user_data)
|
||||
{
|
||||
uint len = (uint)(data == null ? 0 : data.Length);
|
||||
native_cb (rbuf == null ? IntPtr.Zero : rbuf.Handle, data, len, __data);
|
||||
}
|
||||
}
|
||||
|
||||
internal class AudioRingBufferCallbackWrapper {
|
||||
|
||||
public void NativeCallback (IntPtr rbuf, byte[] data, uint len, IntPtr user_data)
|
||||
public void NativeCallback (IntPtr rbuf, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] data, uint len, IntPtr user_data)
|
||||
{
|
||||
try {
|
||||
managed (GLib.Object.GetObject(rbuf) as Gst.Audio.AudioRingBuffer, data, len);
|
||||
managed (GLib.Object.GetObject(rbuf) as Gst.Audio.AudioRingBuffer, data, user_data);
|
||||
if (release_on_call)
|
||||
gch.Free ();
|
||||
} catch (Exception e) {
|
||||
|
|
|
@ -1717,6 +1717,40 @@ namespace Gst.Base {
|
|||
}
|
||||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_aggregator_get_force_live(IntPtr raw);
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_aggregator_set_force_live(IntPtr raw, bool force_live);
|
||||
|
||||
public bool ForceLive {
|
||||
get {
|
||||
bool raw_ret = gst_aggregator_get_force_live(Handle);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
set {
|
||||
gst_aggregator_set_force_live(Handle, value);
|
||||
}
|
||||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_aggregator_get_ignore_inactive_pads(IntPtr raw);
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_aggregator_set_ignore_inactive_pads(IntPtr raw, bool ignore);
|
||||
|
||||
public bool IgnoreInactivePads {
|
||||
get {
|
||||
bool raw_ret = gst_aggregator_get_ignore_inactive_pads(Handle);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
set {
|
||||
gst_aggregator_set_ignore_inactive_pads(Handle, value);
|
||||
}
|
||||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_aggregator_negotiate(IntPtr raw);
|
||||
|
||||
|
|
|
@ -301,6 +301,17 @@ namespace Gst.Base {
|
|||
}
|
||||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_aggregator_pad_is_inactive(IntPtr raw);
|
||||
|
||||
public bool IsInactive {
|
||||
get {
|
||||
bool raw_ret = gst_aggregator_pad_is_inactive(Handle);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_aggregator_pad_peek_buffer(IntPtr raw);
|
||||
|
||||
|
|
|
@ -266,14 +266,14 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate int HandleFrameNativeDelegate (IntPtr inst, IntPtr frame, int skipsize);
|
||||
delegate int HandleFrameNativeDelegate (IntPtr inst, IntPtr frame, out int skipsize);
|
||||
|
||||
static int HandleFrame_cb (IntPtr inst, IntPtr frame, int skipsize)
|
||||
static int HandleFrame_cb (IntPtr inst, IntPtr frame, out int skipsize)
|
||||
{
|
||||
try {
|
||||
BaseParse __obj = GLib.Object.GetObject (inst, false) as BaseParse;
|
||||
Gst.FlowReturn __result;
|
||||
__result = __obj.OnHandleFrame (Gst.Base.BaseParseFrame.New (frame), skipsize);
|
||||
__result = __obj.OnHandleFrame (Gst.Base.BaseParseFrame.New (frame), out skipsize);
|
||||
return (int) __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -283,22 +283,22 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.Base.BaseParse), ConnectionMethod="OverrideHandleFrame")]
|
||||
protected virtual Gst.FlowReturn OnHandleFrame (Gst.Base.BaseParseFrame frame, int skipsize)
|
||||
protected virtual Gst.FlowReturn OnHandleFrame (Gst.Base.BaseParseFrame frame, out int skipsize)
|
||||
{
|
||||
return InternalHandleFrame (frame, skipsize);
|
||||
return InternalHandleFrame (frame, out skipsize);
|
||||
}
|
||||
|
||||
private Gst.FlowReturn InternalHandleFrame (Gst.Base.BaseParseFrame frame, int skipsize)
|
||||
private Gst.FlowReturn InternalHandleFrame (Gst.Base.BaseParseFrame frame, out int skipsize)
|
||||
{
|
||||
HandleFrameNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("handle_frame"));
|
||||
unmanaged = (HandleFrameNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(HandleFrameNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return (Gst.FlowReturn) 0;
|
||||
if (unmanaged == null) throw new InvalidOperationException ("No base method to invoke");
|
||||
|
||||
IntPtr native_frame = GLib.Marshaller.StructureToPtrAlloc (frame);
|
||||
int __result = unmanaged (this.Handle, native_frame, skipsize);
|
||||
int __result = unmanaged (this.Handle, native_frame, out skipsize);
|
||||
Marshal.FreeHGlobal (native_frame);
|
||||
return (Gst.FlowReturn) __result;
|
||||
}
|
||||
|
|
|
@ -603,34 +603,36 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate void GetTimesNativeDelegate (IntPtr inst, IntPtr buffer, ulong start, ulong end);
|
||||
delegate void GetTimesNativeDelegate (IntPtr inst, IntPtr buffer, out ulong start, out ulong end);
|
||||
|
||||
static void GetTimes_cb (IntPtr inst, IntPtr buffer, ulong start, ulong end)
|
||||
static void GetTimes_cb (IntPtr inst, IntPtr buffer, out ulong start, out ulong end)
|
||||
{
|
||||
try {
|
||||
BaseSink __obj = GLib.Object.GetObject (inst, false) as BaseSink;
|
||||
__obj.OnGetTimes (buffer == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (buffer, typeof (Gst.Buffer), false), start, end);
|
||||
__obj.OnGetTimes (buffer == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (buffer, typeof (Gst.Buffer), false), out start, out end);
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, false);
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
// NOTREACHED: above call does not return.
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.Base.BaseSink), ConnectionMethod="OverrideGetTimes")]
|
||||
protected virtual void OnGetTimes (Gst.Buffer buffer, ulong start, ulong end)
|
||||
protected virtual void OnGetTimes (Gst.Buffer buffer, out ulong start, out ulong end)
|
||||
{
|
||||
InternalGetTimes (buffer, start, end);
|
||||
InternalGetTimes (buffer, out start, out end);
|
||||
}
|
||||
|
||||
private void InternalGetTimes (Gst.Buffer buffer, ulong start, ulong end)
|
||||
private void InternalGetTimes (Gst.Buffer buffer, out ulong start, out ulong end)
|
||||
{
|
||||
GetTimesNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("get_times"));
|
||||
unmanaged = (GetTimesNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(GetTimesNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return;
|
||||
if (unmanaged == null) throw new InvalidOperationException ("No base method to invoke");
|
||||
|
||||
unmanaged (this.Handle, buffer == null ? IntPtr.Zero : buffer.Handle, start, end);
|
||||
unmanaged (this.Handle, buffer == null ? IntPtr.Zero : buffer.Handle, out start, out end);
|
||||
}
|
||||
|
||||
static ProposeAllocationNativeDelegate ProposeAllocation_cb_delegate;
|
||||
|
|
|
@ -374,7 +374,7 @@ namespace Gst.Base {
|
|||
try {
|
||||
BaseSrc __obj = GLib.Object.GetObject (inst, false) as BaseSrc;
|
||||
Gst.Caps __result;
|
||||
__result = __obj.OnFixate (caps == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (caps, typeof (Gst.Caps), false));
|
||||
__result = __obj.OnFixate (caps == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (caps, typeof (Gst.Caps), true));
|
||||
return __result == null ? IntPtr.Zero : __result.OwnedCopy;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -398,6 +398,7 @@ namespace Gst.Base {
|
|||
}
|
||||
if (unmanaged == null) return null;
|
||||
|
||||
caps.Owned = false;
|
||||
IntPtr __result = unmanaged (this.Handle, caps == null ? IntPtr.Zero : caps.Handle);
|
||||
return __result == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (__result, typeof (Gst.Caps), true);
|
||||
}
|
||||
|
@ -712,14 +713,14 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate bool GetSizeNativeDelegate (IntPtr inst, ulong size);
|
||||
delegate bool GetSizeNativeDelegate (IntPtr inst, out ulong size);
|
||||
|
||||
static bool GetSize_cb (IntPtr inst, ulong size)
|
||||
static bool GetSize_cb (IntPtr inst, out ulong size)
|
||||
{
|
||||
try {
|
||||
BaseSrc __obj = GLib.Object.GetObject (inst, false) as BaseSrc;
|
||||
bool __result;
|
||||
__result = __obj.OnGetSize (size);
|
||||
__result = __obj.OnGetSize (out size);
|
||||
return __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -729,21 +730,21 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.Base.BaseSrc), ConnectionMethod="OverrideGetSize")]
|
||||
protected virtual bool OnGetSize (ulong size)
|
||||
protected virtual bool OnGetSize (out ulong size)
|
||||
{
|
||||
return InternalGetSize (size);
|
||||
return InternalGetSize (out size);
|
||||
}
|
||||
|
||||
private bool InternalGetSize (ulong size)
|
||||
private bool InternalGetSize (out ulong size)
|
||||
{
|
||||
GetSizeNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("get_size"));
|
||||
unmanaged = (GetSizeNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(GetSizeNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return false;
|
||||
if (unmanaged == null) throw new InvalidOperationException ("No base method to invoke");
|
||||
|
||||
bool __result = unmanaged (this.Handle, size);
|
||||
bool __result = unmanaged (this.Handle, out size);
|
||||
return __result;
|
||||
}
|
||||
|
||||
|
@ -1180,15 +1181,15 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate int CreateNativeDelegate (IntPtr inst, ulong offset, uint size, out IntPtr buf);
|
||||
delegate int CreateNativeDelegate (IntPtr inst, ulong offset, uint size, ref IntPtr buf);
|
||||
|
||||
static int Create_cb (IntPtr inst, ulong offset, uint size, out IntPtr buf)
|
||||
static int Create_cb (IntPtr inst, ulong offset, uint size, ref IntPtr buf)
|
||||
{
|
||||
try {
|
||||
BaseSrc __obj = GLib.Object.GetObject (inst, false) as BaseSrc;
|
||||
Gst.FlowReturn __result;
|
||||
Gst.Buffer mybuf;
|
||||
__result = __obj.OnCreate (offset, size, out mybuf);
|
||||
Gst.Buffer mybuf = buf == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (buf, typeof (Gst.Buffer), true);
|
||||
__result = __obj.OnCreate (offset, size, ref mybuf);
|
||||
buf = mybuf == null ? IntPtr.Zero : mybuf.Handle;
|
||||
return (int) __result;
|
||||
} catch (Exception e) {
|
||||
|
@ -1199,22 +1200,22 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.Base.BaseSrc), ConnectionMethod="OverrideCreate")]
|
||||
protected virtual Gst.FlowReturn OnCreate (ulong offset, uint size, out Gst.Buffer buf)
|
||||
protected virtual Gst.FlowReturn OnCreate (ulong offset, uint size, ref Gst.Buffer buf)
|
||||
{
|
||||
return InternalCreate (offset, size, out buf);
|
||||
return InternalCreate (offset, size, ref buf);
|
||||
}
|
||||
|
||||
private Gst.FlowReturn InternalCreate (ulong offset, uint size, out Gst.Buffer buf)
|
||||
private Gst.FlowReturn InternalCreate (ulong offset, uint size, ref Gst.Buffer buf)
|
||||
{
|
||||
CreateNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("create"));
|
||||
unmanaged = (CreateNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(CreateNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) throw new InvalidOperationException ("No base method to invoke");
|
||||
if (unmanaged == null) return (Gst.FlowReturn) 0;
|
||||
|
||||
IntPtr native_buf;
|
||||
int __result = unmanaged (this.Handle, offset, size, out native_buf);
|
||||
IntPtr native_buf = buf == null ? IntPtr.Zero : buf.Handle ;
|
||||
int __result = unmanaged (this.Handle, offset, size, ref native_buf);
|
||||
buf = native_buf == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (native_buf, typeof (Gst.Buffer), true);
|
||||
return (Gst.FlowReturn) __result;
|
||||
}
|
||||
|
@ -1242,14 +1243,16 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate int AllocNativeDelegate (IntPtr inst, ulong offset, uint size, IntPtr buf);
|
||||
delegate int AllocNativeDelegate (IntPtr inst, ulong offset, uint size, out IntPtr buf);
|
||||
|
||||
static int Alloc_cb (IntPtr inst, ulong offset, uint size, IntPtr buf)
|
||||
static int Alloc_cb (IntPtr inst, ulong offset, uint size, out IntPtr buf)
|
||||
{
|
||||
try {
|
||||
BaseSrc __obj = GLib.Object.GetObject (inst, false) as BaseSrc;
|
||||
Gst.FlowReturn __result;
|
||||
__result = __obj.OnAlloc (offset, size, buf == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (buf, typeof (Gst.Buffer), false));
|
||||
Gst.Buffer mybuf;
|
||||
__result = __obj.OnAlloc (offset, size, out mybuf);
|
||||
buf = mybuf == null ? IntPtr.Zero : mybuf.Handle;
|
||||
return (int) __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -1259,21 +1262,23 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.Base.BaseSrc), ConnectionMethod="OverrideAlloc")]
|
||||
protected virtual Gst.FlowReturn OnAlloc (ulong offset, uint size, Gst.Buffer buf)
|
||||
protected virtual Gst.FlowReturn OnAlloc (ulong offset, uint size, out Gst.Buffer buf)
|
||||
{
|
||||
return InternalAlloc (offset, size, buf);
|
||||
return InternalAlloc (offset, size, out buf);
|
||||
}
|
||||
|
||||
private Gst.FlowReturn InternalAlloc (ulong offset, uint size, Gst.Buffer buf)
|
||||
private Gst.FlowReturn InternalAlloc (ulong offset, uint size, out Gst.Buffer buf)
|
||||
{
|
||||
AllocNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("alloc"));
|
||||
unmanaged = (AllocNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(AllocNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return (Gst.FlowReturn) 0;
|
||||
if (unmanaged == null) throw new InvalidOperationException ("No base method to invoke");
|
||||
|
||||
int __result = unmanaged (this.Handle, offset, size, buf == null ? IntPtr.Zero : buf.Handle);
|
||||
IntPtr native_buf;
|
||||
int __result = unmanaged (this.Handle, offset, size, out native_buf);
|
||||
buf = native_buf == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (native_buf, typeof (Gst.Buffer), true);
|
||||
return (Gst.FlowReturn) __result;
|
||||
}
|
||||
|
||||
|
@ -1597,6 +1602,17 @@ namespace Gst.Base {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_base_src_push_segment(IntPtr raw, IntPtr segment);
|
||||
|
||||
public bool PushSegment(Gst.Segment segment) {
|
||||
IntPtr native_segment = GLib.Marshaller.StructureToPtrAlloc (segment);
|
||||
bool raw_ret = gst_base_src_push_segment(Handle, native_segment);
|
||||
bool ret = raw_ret;
|
||||
Marshal.FreeHGlobal (native_segment);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_base_src_query_latency(IntPtr raw, out bool live, out ulong min_latency, out ulong max_latency);
|
||||
|
||||
|
|
|
@ -166,7 +166,7 @@ namespace Gst.Base {
|
|||
try {
|
||||
BaseTransform __obj = GLib.Object.GetObject (inst, false) as BaseTransform;
|
||||
Gst.Caps __result;
|
||||
__result = __obj.OnFixateCaps ((Gst.PadDirection) direction, caps == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (caps, typeof (Gst.Caps), false), othercaps == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (othercaps, typeof (Gst.Caps), false));
|
||||
__result = __obj.OnFixateCaps ((Gst.PadDirection) direction, caps == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (caps, typeof (Gst.Caps), false), othercaps == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (othercaps, typeof (Gst.Caps), true));
|
||||
return __result == null ? IntPtr.Zero : __result.OwnedCopy;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -190,6 +190,7 @@ namespace Gst.Base {
|
|||
}
|
||||
if (unmanaged == null) return null;
|
||||
|
||||
othercaps.Owned = false;
|
||||
IntPtr __result = unmanaged (this.Handle, (int) direction, caps == null ? IntPtr.Zero : caps.Handle, othercaps == null ? IntPtr.Zero : othercaps.Handle);
|
||||
return __result == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (__result, typeof (Gst.Caps), true);
|
||||
}
|
||||
|
@ -812,7 +813,7 @@ namespace Gst.Base {
|
|||
try {
|
||||
BaseTransform __obj = GLib.Object.GetObject (inst, false) as BaseTransform;
|
||||
bool __result;
|
||||
__result = __obj.OnSinkEvent (evnt == IntPtr.Zero ? null : (Gst.Event) GLib.Opaque.GetOpaque (evnt, typeof (Gst.Event), false));
|
||||
__result = __obj.OnSinkEvent (evnt == IntPtr.Zero ? null : (Gst.Event) GLib.Opaque.GetOpaque (evnt, typeof (Gst.Event), true));
|
||||
return __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -836,6 +837,7 @@ namespace Gst.Base {
|
|||
}
|
||||
if (unmanaged == null) return false;
|
||||
|
||||
evnt.Owned = false;
|
||||
bool __result = unmanaged (this.Handle, evnt == null ? IntPtr.Zero : evnt.Handle);
|
||||
return __result;
|
||||
}
|
||||
|
@ -870,7 +872,7 @@ namespace Gst.Base {
|
|||
try {
|
||||
BaseTransform __obj = GLib.Object.GetObject (inst, false) as BaseTransform;
|
||||
bool __result;
|
||||
__result = __obj.OnSrcEvent (evnt == IntPtr.Zero ? null : (Gst.Event) GLib.Opaque.GetOpaque (evnt, typeof (Gst.Event), false));
|
||||
__result = __obj.OnSrcEvent (evnt == IntPtr.Zero ? null : (Gst.Event) GLib.Opaque.GetOpaque (evnt, typeof (Gst.Event), true));
|
||||
return __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -894,6 +896,7 @@ namespace Gst.Base {
|
|||
}
|
||||
if (unmanaged == null) return false;
|
||||
|
||||
evnt.Owned = false;
|
||||
bool __result = unmanaged (this.Handle, evnt == null ? IntPtr.Zero : evnt.Handle);
|
||||
return __result;
|
||||
}
|
||||
|
|
|
@ -122,11 +122,12 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_bit_reader_init(IntPtr raw, byte[] data, uint size);
|
||||
static extern void gst_bit_reader_init(IntPtr raw, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] data, uint size);
|
||||
|
||||
public void Init(byte[] data, uint size) {
|
||||
public void Init(byte[] data) {
|
||||
IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf (this));
|
||||
System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false);
|
||||
uint size = (uint)(data == null ? 0 : data.Length);
|
||||
gst_bit_reader_init(this_as_native, data, size);
|
||||
ReadNative (this_as_native, ref this);
|
||||
System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native);
|
||||
|
|
|
@ -148,9 +148,9 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_bit_writer_put_bytes(IntPtr raw, byte data, uint nbytes);
|
||||
static extern bool gst_bit_writer_put_bytes(IntPtr raw, byte[] data, uint nbytes);
|
||||
|
||||
public bool PutBytes(byte data, uint nbytes) {
|
||||
public bool PutBytes(byte[] data, uint nbytes) {
|
||||
IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf (this));
|
||||
System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false);
|
||||
bool raw_ret = gst_bit_writer_put_bytes(this_as_native, data, nbytes);
|
||||
|
|
|
@ -125,11 +125,12 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_byte_writer_init_with_data(IntPtr raw, byte[] data, uint size, bool initialized);
|
||||
static extern void gst_byte_writer_init_with_data(IntPtr raw, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] data, uint size, bool initialized);
|
||||
|
||||
public void InitWithData(byte[] data, uint size, bool initialized) {
|
||||
public void InitWithData(byte[] data, bool initialized) {
|
||||
IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf (this));
|
||||
System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false);
|
||||
uint size = (uint)(data == null ? 0 : data.Length);
|
||||
gst_byte_writer_init_with_data(this_as_native, data, size, initialized);
|
||||
ReadNative (this_as_native, ref this);
|
||||
System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native);
|
||||
|
@ -160,11 +161,12 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_byte_writer_put_data(IntPtr raw, byte[] data, uint size);
|
||||
static extern bool gst_byte_writer_put_data(IntPtr raw, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] data, uint size);
|
||||
|
||||
public bool PutData(byte[] data, uint size) {
|
||||
public bool PutData(byte[] data) {
|
||||
IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf (this));
|
||||
System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false);
|
||||
uint size = (uint)(data == null ? 0 : data.Length);
|
||||
bool raw_ret = gst_byte_writer_put_data(this_as_native, data, size);
|
||||
bool ret = raw_ret;
|
||||
ReadNative (this_as_native, ref this);
|
||||
|
|
|
@ -35,6 +35,21 @@ namespace Gst.Base {
|
|||
return TypeFindHelperForBuffer (null, buf, out prob);
|
||||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_type_find_helper_for_buffer_with_caps(IntPtr obj, IntPtr buf, IntPtr caps, out int prob);
|
||||
|
||||
public static Gst.Caps TypeFindHelperForBufferWithCaps(Gst.Object obj, Gst.Buffer buf, Gst.Caps caps, out Gst.TypeFindProbability prob) {
|
||||
int native_prob;
|
||||
IntPtr raw_ret = gst_type_find_helper_for_buffer_with_caps(obj == null ? IntPtr.Zero : obj.Handle, buf == null ? IntPtr.Zero : buf.Handle, caps == null ? IntPtr.Zero : caps.Handle, out native_prob);
|
||||
Gst.Caps ret = raw_ret == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Caps), true);
|
||||
prob = (Gst.TypeFindProbability) native_prob;
|
||||
return ret;
|
||||
}
|
||||
|
||||
public static Gst.Caps TypeFindHelperForBufferWithCaps(Gst.Buffer buf, Gst.Caps caps, out Gst.TypeFindProbability prob) {
|
||||
return TypeFindHelperForBufferWithCaps (null, buf, caps, out prob);
|
||||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_type_find_helper_for_buffer_with_extension(IntPtr obj, IntPtr buf, IntPtr extension, out int prob);
|
||||
|
||||
|
@ -53,35 +68,53 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_type_find_helper_for_data(IntPtr obj, byte[] data, UIntPtr size, out int prob);
|
||||
static extern IntPtr gst_type_find_helper_for_data(IntPtr obj, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] data, UIntPtr size, out int prob);
|
||||
|
||||
public static Gst.Caps TypeFindHelperForData(Gst.Object obj, byte[] data, ulong size, out Gst.TypeFindProbability prob) {
|
||||
public static Gst.Caps TypeFindHelperForData(Gst.Object obj, byte[] data, out Gst.TypeFindProbability prob) {
|
||||
ulong size = (ulong)(data == null ? 0 : data.Length);
|
||||
int native_prob;
|
||||
IntPtr raw_ret = gst_type_find_helper_for_data(obj == null ? IntPtr.Zero : obj.Handle, data, new UIntPtr (size), out native_prob);
|
||||
IntPtr raw_ret = gst_type_find_helper_for_data(obj == null ? IntPtr.Zero : obj.Handle, data, new UIntPtr ((uint)size), out native_prob);
|
||||
Gst.Caps ret = raw_ret == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Caps), true);
|
||||
prob = (Gst.TypeFindProbability) native_prob;
|
||||
return ret;
|
||||
}
|
||||
|
||||
public static Gst.Caps TypeFindHelperForData(byte[] data, ulong size, out Gst.TypeFindProbability prob) {
|
||||
return TypeFindHelperForData (null, data, size, out prob);
|
||||
public static Gst.Caps TypeFindHelperForData(byte[] data, out Gst.TypeFindProbability prob) {
|
||||
return TypeFindHelperForData (null, data, out prob);
|
||||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_type_find_helper_for_data_with_extension(IntPtr obj, byte[] data, UIntPtr size, IntPtr extension, out int prob);
|
||||
static extern IntPtr gst_type_find_helper_for_data_with_caps(IntPtr obj, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] data, UIntPtr size, IntPtr caps, out int prob);
|
||||
|
||||
public static Gst.Caps TypeFindHelperForDataWithExtension(Gst.Object obj, byte[] data, ulong size, string extension, out Gst.TypeFindProbability prob) {
|
||||
public static Gst.Caps TypeFindHelperForDataWithCaps(Gst.Object obj, byte[] data, Gst.Caps caps, out Gst.TypeFindProbability prob) {
|
||||
ulong size = (ulong)(data == null ? 0 : data.Length);
|
||||
int native_prob;
|
||||
IntPtr raw_ret = gst_type_find_helper_for_data_with_caps(obj == null ? IntPtr.Zero : obj.Handle, data, new UIntPtr ((uint)size), caps == null ? IntPtr.Zero : caps.Handle, out native_prob);
|
||||
Gst.Caps ret = raw_ret == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Caps), true);
|
||||
prob = (Gst.TypeFindProbability) native_prob;
|
||||
return ret;
|
||||
}
|
||||
|
||||
public static Gst.Caps TypeFindHelperForDataWithCaps(byte[] data, Gst.Caps caps, out Gst.TypeFindProbability prob) {
|
||||
return TypeFindHelperForDataWithCaps (null, data, caps, out prob);
|
||||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_type_find_helper_for_data_with_extension(IntPtr obj, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] data, UIntPtr size, IntPtr extension, out int prob);
|
||||
|
||||
public static Gst.Caps TypeFindHelperForDataWithExtension(Gst.Object obj, byte[] data, string extension, out Gst.TypeFindProbability prob) {
|
||||
ulong size = (ulong)(data == null ? 0 : data.Length);
|
||||
IntPtr native_extension = GLib.Marshaller.StringToPtrGStrdup (extension);
|
||||
int native_prob;
|
||||
IntPtr raw_ret = gst_type_find_helper_for_data_with_extension(obj == null ? IntPtr.Zero : obj.Handle, data, new UIntPtr (size), native_extension, out native_prob);
|
||||
IntPtr raw_ret = gst_type_find_helper_for_data_with_extension(obj == null ? IntPtr.Zero : obj.Handle, data, new UIntPtr ((uint)size), native_extension, out native_prob);
|
||||
Gst.Caps ret = raw_ret == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Caps), true);
|
||||
GLib.Marshaller.Free (native_extension);
|
||||
prob = (Gst.TypeFindProbability) native_prob;
|
||||
return ret;
|
||||
}
|
||||
|
||||
public static Gst.Caps TypeFindHelperForDataWithExtension(byte[] data, ulong size, out Gst.TypeFindProbability prob) {
|
||||
return TypeFindHelperForDataWithExtension (null, data, size, null, out prob);
|
||||
public static Gst.Caps TypeFindHelperForDataWithExtension(byte[] data, out Gst.TypeFindProbability prob) {
|
||||
return TypeFindHelperForDataWithExtension (null, data, null, out prob);
|
||||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
|
@ -137,6 +170,19 @@ namespace Gst.Base {
|
|||
return TypeFindHelperGetRangeFull (obj, null, func, size, null, out caps, out prob);
|
||||
}
|
||||
|
||||
[DllImport("gstbase-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_type_find_list_factories_for_caps(IntPtr obj, IntPtr caps);
|
||||
|
||||
public static Gst.TypeFindFactory[] TypeFindListFactoriesForCaps(Gst.Object obj, Gst.Caps caps) {
|
||||
IntPtr raw_ret = gst_type_find_list_factories_for_caps(obj == null ? IntPtr.Zero : obj.Handle, caps == null ? IntPtr.Zero : caps.Handle);
|
||||
Gst.TypeFindFactory[] ret = (Gst.TypeFindFactory[]) GLib.Marshaller.ListPtrToArray (raw_ret, typeof(GLib.List), true, true, typeof(Gst.TypeFindFactory));
|
||||
return ret;
|
||||
}
|
||||
|
||||
public static Gst.TypeFindFactory[] TypeFindListFactoriesForCaps(Gst.Caps caps) {
|
||||
return TypeFindListFactoriesForCaps (null, caps);
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
|
|
@ -41,14 +41,16 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate int CreateNativeDelegate (IntPtr inst, IntPtr buf);
|
||||
delegate int CreateNativeDelegate (IntPtr inst, ref IntPtr buf);
|
||||
|
||||
static int Create_cb (IntPtr inst, IntPtr buf)
|
||||
static int Create_cb (IntPtr inst, ref IntPtr buf)
|
||||
{
|
||||
try {
|
||||
PushSrc __obj = GLib.Object.GetObject (inst, false) as PushSrc;
|
||||
Gst.FlowReturn __result;
|
||||
__result = __obj.OnCreate (buf == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (buf, typeof (Gst.Buffer), false));
|
||||
Gst.Buffer mybuf = buf == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (buf, typeof (Gst.Buffer), true);
|
||||
__result = __obj.OnCreate (ref mybuf);
|
||||
buf = mybuf == null ? IntPtr.Zero : mybuf.Handle;
|
||||
return (int) __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -58,12 +60,12 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.Base.PushSrc), ConnectionMethod="OverrideCreate")]
|
||||
protected virtual Gst.FlowReturn OnCreate (Gst.Buffer buf)
|
||||
protected virtual Gst.FlowReturn OnCreate (ref Gst.Buffer buf)
|
||||
{
|
||||
return InternalCreate (buf);
|
||||
return InternalCreate (ref buf);
|
||||
}
|
||||
|
||||
private Gst.FlowReturn InternalCreate (Gst.Buffer buf)
|
||||
private Gst.FlowReturn InternalCreate (ref Gst.Buffer buf)
|
||||
{
|
||||
CreateNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
|
@ -72,7 +74,9 @@ namespace Gst.Base {
|
|||
}
|
||||
if (unmanaged == null) return (Gst.FlowReturn) 0;
|
||||
|
||||
int __result = unmanaged (this.Handle, buf == null ? IntPtr.Zero : buf.Handle);
|
||||
IntPtr native_buf = buf == null ? IntPtr.Zero : buf.Handle ;
|
||||
int __result = unmanaged (this.Handle, ref native_buf);
|
||||
buf = native_buf == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (native_buf, typeof (Gst.Buffer), true);
|
||||
return (Gst.FlowReturn) __result;
|
||||
}
|
||||
|
||||
|
@ -99,14 +103,16 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate int AllocNativeDelegate (IntPtr inst, IntPtr buf);
|
||||
delegate int AllocNativeDelegate (IntPtr inst, out IntPtr buf);
|
||||
|
||||
static int Alloc_cb (IntPtr inst, IntPtr buf)
|
||||
static int Alloc_cb (IntPtr inst, out IntPtr buf)
|
||||
{
|
||||
try {
|
||||
PushSrc __obj = GLib.Object.GetObject (inst, false) as PushSrc;
|
||||
Gst.FlowReturn __result;
|
||||
__result = __obj.OnAlloc (buf == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (buf, typeof (Gst.Buffer), false));
|
||||
Gst.Buffer mybuf;
|
||||
__result = __obj.OnAlloc (out mybuf);
|
||||
buf = mybuf == null ? IntPtr.Zero : mybuf.Handle;
|
||||
return (int) __result;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
|
@ -116,21 +122,23 @@ namespace Gst.Base {
|
|||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.Base.PushSrc), ConnectionMethod="OverrideAlloc")]
|
||||
protected virtual Gst.FlowReturn OnAlloc (Gst.Buffer buf)
|
||||
protected virtual Gst.FlowReturn OnAlloc (out Gst.Buffer buf)
|
||||
{
|
||||
return InternalAlloc (buf);
|
||||
return InternalAlloc (out buf);
|
||||
}
|
||||
|
||||
private Gst.FlowReturn InternalAlloc (Gst.Buffer buf)
|
||||
private Gst.FlowReturn InternalAlloc (out Gst.Buffer buf)
|
||||
{
|
||||
AllocNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("alloc"));
|
||||
unmanaged = (AllocNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(AllocNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return (Gst.FlowReturn) 0;
|
||||
if (unmanaged == null) throw new InvalidOperationException ("No base method to invoke");
|
||||
|
||||
int __result = unmanaged (this.Handle, buf == null ? IntPtr.Zero : buf.Handle);
|
||||
IntPtr native_buf;
|
||||
int __result = unmanaged (this.Handle, out native_buf);
|
||||
buf = native_buf == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (native_buf, typeof (Gst.Buffer), true);
|
||||
return (Gst.FlowReturn) __result;
|
||||
}
|
||||
|
||||
|
|
|
@ -0,0 +1,34 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace Gst.Base {
|
||||
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
#region Autogenerated code
|
||||
public partial class TypeFindData : GLib.Opaque {
|
||||
|
||||
public TypeFindData(IntPtr raw) : base(raw) {}
|
||||
|
||||
|
||||
// Internal representation of the wrapped structure ABI.
|
||||
static GLib.AbiStruct _abi_info = null;
|
||||
static public GLib.AbiStruct abi_info {
|
||||
get {
|
||||
if (_abi_info == null)
|
||||
_abi_info = new GLib.AbiStruct (new List<GLib.AbiField>{
|
||||
});
|
||||
|
||||
return _abi_info;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// End of the ABI representation.
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
|
@ -104,20 +104,13 @@ namespace Gst.Net {
|
|||
}
|
||||
|
||||
[DllImport("gstnet-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_ptp_init(ulong clock_id, IntPtr[] interfaces);
|
||||
static extern bool gst_ptp_init(ulong clock_id, IntPtr interfaces);
|
||||
|
||||
public static bool PtpInit(ulong clock_id, string[] interfaces) {
|
||||
int cnt_interfaces = interfaces == null ? 0 : interfaces.Length;
|
||||
IntPtr[] native_interfaces = new IntPtr [cnt_interfaces + 1];
|
||||
for (int i = 0; i < cnt_interfaces; i++)
|
||||
native_interfaces [i] = GLib.Marshaller.StringToPtrGStrdup (interfaces[i]);
|
||||
native_interfaces [cnt_interfaces] = IntPtr.Zero;
|
||||
IntPtr native_interfaces = GLib.Marshaller.StringArrayToStrvPtr(interfaces, true);
|
||||
bool raw_ret = gst_ptp_init(clock_id, native_interfaces);
|
||||
bool ret = raw_ret;
|
||||
for (int i = 0; i < native_interfaces.Length - 1; i++) {
|
||||
interfaces [i] = GLib.Marshaller.Utf8PtrToString (native_interfaces[i]);
|
||||
GLib.Marshaller.Free (native_interfaces[i]);
|
||||
}
|
||||
GLib.Marshaller.StrFreeV (native_interfaces);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
|
@ -24,7 +24,7 @@ namespace Gst.Net {
|
|||
}
|
||||
|
||||
[DllImport("gstnet-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_net_time_packet_new(byte[] buffer);
|
||||
static extern IntPtr gst_net_time_packet_new([MarshalAs(UnmanagedType.LPArray, SizeConst=16)]byte[] buffer);
|
||||
|
||||
public static NetTimePacket New(byte[] buffer)
|
||||
{
|
||||
|
@ -58,19 +58,6 @@ namespace Gst.Net {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstnet-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern byte gst_net_time_packet_serialize(IntPtr raw);
|
||||
|
||||
public byte Serialize() {
|
||||
IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf (this));
|
||||
System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false);
|
||||
byte raw_ret = gst_net_time_packet_serialize(this_as_native);
|
||||
byte ret = raw_ret;
|
||||
ReadNative (this_as_native, ref this);
|
||||
System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstnet-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern unsafe IntPtr gst_net_time_packet_receive(IntPtr socket, out IntPtr src_address, out IntPtr error);
|
||||
|
||||
|
|
|
@ -69,13 +69,13 @@ namespace Gst.PbUtils {
|
|||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("starting")]
|
||||
public event System.EventHandler Starting {
|
||||
[GLib.Signal("source-setup")]
|
||||
public event Gst.PbUtils.SourceSetupHandler SourceSetup {
|
||||
add {
|
||||
this.AddSignalHandler ("starting", value);
|
||||
this.AddSignalHandler ("source-setup", value, typeof (Gst.PbUtils.SourceSetupArgs));
|
||||
}
|
||||
remove {
|
||||
this.RemoveSignalHandler ("starting", value);
|
||||
this.RemoveSignalHandler ("source-setup", value);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -89,16 +89,84 @@ namespace Gst.PbUtils {
|
|||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("source-setup")]
|
||||
public event Gst.PbUtils.SourceSetupHandler SourceSetup {
|
||||
[GLib.Signal("load-serialized-info")]
|
||||
public event Gst.PbUtils.LoadSerializedInfoHandler LoadSerializedInfo {
|
||||
add {
|
||||
this.AddSignalHandler ("source-setup", value, typeof (Gst.PbUtils.SourceSetupArgs));
|
||||
this.AddSignalHandler ("load-serialized-info", value, typeof (Gst.PbUtils.LoadSerializedInfoArgs));
|
||||
}
|
||||
remove {
|
||||
this.RemoveSignalHandler ("source-setup", value);
|
||||
this.RemoveSignalHandler ("load-serialized-info", value);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.Signal("starting")]
|
||||
public event System.EventHandler Starting {
|
||||
add {
|
||||
this.AddSignalHandler ("starting", value);
|
||||
}
|
||||
remove {
|
||||
this.RemoveSignalHandler ("starting", value);
|
||||
}
|
||||
}
|
||||
|
||||
static LoadSerializedInfoNativeDelegate LoadSerializedInfo_cb_delegate;
|
||||
static LoadSerializedInfoNativeDelegate LoadSerializedInfoVMCallback {
|
||||
get {
|
||||
if (LoadSerializedInfo_cb_delegate == null)
|
||||
LoadSerializedInfo_cb_delegate = new LoadSerializedInfoNativeDelegate (LoadSerializedInfo_cb);
|
||||
return LoadSerializedInfo_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideLoadSerializedInfo (GLib.GType gtype)
|
||||
{
|
||||
OverrideLoadSerializedInfo (gtype, LoadSerializedInfoVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideLoadSerializedInfo (GLib.GType gtype, LoadSerializedInfoNativeDelegate callback)
|
||||
{
|
||||
OverrideVirtualMethod (gtype, "load-serialized-info", callback);
|
||||
}
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate IntPtr LoadSerializedInfoNativeDelegate (IntPtr inst, IntPtr uri);
|
||||
|
||||
static IntPtr LoadSerializedInfo_cb (IntPtr inst, IntPtr uri)
|
||||
{
|
||||
try {
|
||||
Discoverer __obj = GLib.Object.GetObject (inst, false) as Discoverer;
|
||||
Gst.PbUtils.DiscovererInfo __result;
|
||||
__result = __obj.OnLoadSerializedInfo (GLib.Marshaller.Utf8PtrToString (uri));
|
||||
return __result == null ? IntPtr.Zero : __result.OwnedHandle;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
// NOTREACHED: above call does not return.
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.PbUtils.Discoverer), ConnectionMethod="OverrideLoadSerializedInfo")]
|
||||
protected virtual Gst.PbUtils.DiscovererInfo OnLoadSerializedInfo (string uri)
|
||||
{
|
||||
return InternalLoadSerializedInfo (uri);
|
||||
}
|
||||
|
||||
private Gst.PbUtils.DiscovererInfo InternalLoadSerializedInfo (string uri)
|
||||
{
|
||||
GLib.Value ret = new GLib.Value (GLib.GType.Object);
|
||||
GLib.ValueArray inst_and_params = new GLib.ValueArray (2);
|
||||
GLib.Value[] vals = new GLib.Value [2];
|
||||
vals [0] = new GLib.Value (this);
|
||||
inst_and_params.Append (vals [0]);
|
||||
vals [1] = new GLib.Value (uri);
|
||||
inst_and_params.Append (vals [1]);
|
||||
g_signal_chain_from_overridden (inst_and_params.ArrayPtr, ref ret);
|
||||
foreach (GLib.Value v in vals)
|
||||
v.Dispose ();
|
||||
Gst.PbUtils.DiscovererInfo result = (Gst.PbUtils.DiscovererInfo) ret;
|
||||
ret.Dispose ();
|
||||
return result;
|
||||
}
|
||||
|
||||
static FinishedNativeDelegate Finished_cb_delegate;
|
||||
static FinishedNativeDelegate FinishedVMCallback {
|
||||
get {
|
||||
|
@ -311,6 +379,66 @@ namespace Gst.PbUtils {
|
|||
unmanaged (this.Handle, source == null ? IntPtr.Zero : source.Handle);
|
||||
}
|
||||
|
||||
static LoadSerializeInfoNativeDelegate LoadSerializeInfo_cb_delegate;
|
||||
static LoadSerializeInfoNativeDelegate LoadSerializeInfoVMCallback {
|
||||
get {
|
||||
if (LoadSerializeInfo_cb_delegate == null)
|
||||
LoadSerializeInfo_cb_delegate = new LoadSerializeInfoNativeDelegate (LoadSerializeInfo_cb);
|
||||
return LoadSerializeInfo_cb_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
static void OverrideLoadSerializeInfo (GLib.GType gtype)
|
||||
{
|
||||
OverrideLoadSerializeInfo (gtype, LoadSerializeInfoVMCallback);
|
||||
}
|
||||
|
||||
static void OverrideLoadSerializeInfo (GLib.GType gtype, LoadSerializeInfoNativeDelegate callback)
|
||||
{
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) gtype.GetClassPtr()) + (long) class_abi.GetFieldOffset("load_serialize_info"));
|
||||
*raw_ptr = Marshal.GetFunctionPointerForDelegate((Delegate) callback);
|
||||
}
|
||||
}
|
||||
|
||||
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||||
delegate IntPtr LoadSerializeInfoNativeDelegate (IntPtr inst, IntPtr uri);
|
||||
|
||||
static IntPtr LoadSerializeInfo_cb (IntPtr inst, IntPtr uri)
|
||||
{
|
||||
try {
|
||||
Discoverer __obj = GLib.Object.GetObject (inst, false) as Discoverer;
|
||||
Gst.PbUtils.DiscovererInfo __result;
|
||||
__result = __obj.OnLoadSerializeInfo (GLib.Marshaller.Utf8PtrToString (uri));
|
||||
return __result == null ? IntPtr.Zero : __result.OwnedHandle;
|
||||
} catch (Exception e) {
|
||||
GLib.ExceptionManager.RaiseUnhandledException (e, true);
|
||||
// NOTREACHED: above call does not return.
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.DefaultSignalHandler(Type=typeof(Gst.PbUtils.Discoverer), ConnectionMethod="OverrideLoadSerializeInfo")]
|
||||
protected virtual Gst.PbUtils.DiscovererInfo OnLoadSerializeInfo (string uri)
|
||||
{
|
||||
return InternalLoadSerializeInfo (uri);
|
||||
}
|
||||
|
||||
private Gst.PbUtils.DiscovererInfo InternalLoadSerializeInfo (string uri)
|
||||
{
|
||||
LoadSerializeInfoNativeDelegate unmanaged = null;
|
||||
unsafe {
|
||||
IntPtr* raw_ptr = (IntPtr*)(((long) this.LookupGType().GetThresholdType().GetClassPtr()) + (long) class_abi.GetFieldOffset("load_serialize_info"));
|
||||
unmanaged = (LoadSerializeInfoNativeDelegate) Marshal.GetDelegateForFunctionPointer(*raw_ptr, typeof(LoadSerializeInfoNativeDelegate));
|
||||
}
|
||||
if (unmanaged == null) return null;
|
||||
|
||||
IntPtr native_uri = GLib.Marshaller.StringToPtrGStrdup (uri);
|
||||
IntPtr __result = unmanaged (this.Handle, native_uri);
|
||||
GLib.Marshaller.Free (native_uri);
|
||||
return GLib.Object.GetObject(__result, true) as Gst.PbUtils.DiscovererInfo;
|
||||
}
|
||||
|
||||
|
||||
// Internal representation of the wrapped structure ABI.
|
||||
static GLib.AbiStruct _class_abi = null;
|
||||
|
@ -346,14 +474,22 @@ namespace Gst.PbUtils {
|
|||
, -1
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr)) // source_setup
|
||||
, "discovered"
|
||||
, "load_serialize_info"
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr))
|
||||
, 0
|
||||
),
|
||||
new GLib.AbiField("load_serialize_info"
|
||||
, -1
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr)) // load_serialize_info
|
||||
, "source_setup"
|
||||
, "_reserved"
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr))
|
||||
, 0
|
||||
),
|
||||
new GLib.AbiField("_reserved"
|
||||
, -1
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr)) * 4 // _reserved
|
||||
, "source_setup"
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr)) * 3 // _reserved
|
||||
, "load_serialize_info"
|
||||
, null
|
||||
, (uint) Marshal.SizeOf(typeof(IntPtr))
|
||||
, 0
|
||||
|
|
|
@ -40,6 +40,17 @@ namespace Gst.PbUtils {
|
|||
}
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_discoverer_container_info_get_tags(IntPtr raw);
|
||||
|
||||
public new Gst.TagList Tags {
|
||||
get {
|
||||
IntPtr raw_ret = gst_discoverer_container_info_get_tags(Handle);
|
||||
Gst.TagList ret = raw_ret == IntPtr.Zero ? null : (Gst.TagList) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.TagList), false);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static DiscovererContainerInfo ()
|
||||
{
|
||||
|
|
|
@ -50,10 +50,10 @@ namespace Gst.PbUtils {
|
|||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_discoverer_info_get_audio_streams(IntPtr raw);
|
||||
|
||||
public Gst.PbUtils.DiscovererStreamInfo[] AudioStreams {
|
||||
public Gst.PbUtils.DiscovererAudioInfo[] AudioStreams {
|
||||
get {
|
||||
IntPtr raw_ret = gst_discoverer_info_get_audio_streams(Handle);
|
||||
Gst.PbUtils.DiscovererStreamInfo[] ret = (Gst.PbUtils.DiscovererStreamInfo[]) GLib.Marshaller.ListPtrToArray (raw_ret, typeof(GLib.List), true, true, typeof(Gst.PbUtils.DiscovererStreamInfo));
|
||||
Gst.PbUtils.DiscovererAudioInfo[] ret = (Gst.PbUtils.DiscovererAudioInfo[]) GLib.Marshaller.ListPtrToArray (raw_ret, typeof(GLib.List), true, true, typeof(Gst.PbUtils.DiscovererAudioInfo));
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
@ -61,10 +61,10 @@ namespace Gst.PbUtils {
|
|||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_discoverer_info_get_container_streams(IntPtr raw);
|
||||
|
||||
public Gst.PbUtils.DiscovererStreamInfo[] ContainerStreams {
|
||||
public Gst.PbUtils.DiscovererContainerInfo[] ContainerStreams {
|
||||
get {
|
||||
IntPtr raw_ret = gst_discoverer_info_get_container_streams(Handle);
|
||||
Gst.PbUtils.DiscovererStreamInfo[] ret = (Gst.PbUtils.DiscovererStreamInfo[]) GLib.Marshaller.ListPtrToArray (raw_ret, typeof(GLib.List), true, true, typeof(Gst.PbUtils.DiscovererStreamInfo));
|
||||
Gst.PbUtils.DiscovererContainerInfo[] ret = (Gst.PbUtils.DiscovererContainerInfo[]) GLib.Marshaller.ListPtrToArray (raw_ret, typeof(GLib.List), true, true, typeof(Gst.PbUtils.DiscovererContainerInfo));
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
@ -170,10 +170,10 @@ namespace Gst.PbUtils {
|
|||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_discoverer_info_get_subtitle_streams(IntPtr raw);
|
||||
|
||||
public Gst.PbUtils.DiscovererStreamInfo[] SubtitleStreams {
|
||||
public Gst.PbUtils.DiscovererSubtitleInfo[] SubtitleStreams {
|
||||
get {
|
||||
IntPtr raw_ret = gst_discoverer_info_get_subtitle_streams(Handle);
|
||||
Gst.PbUtils.DiscovererStreamInfo[] ret = (Gst.PbUtils.DiscovererStreamInfo[]) GLib.Marshaller.ListPtrToArray (raw_ret, typeof(GLib.List), true, true, typeof(Gst.PbUtils.DiscovererStreamInfo));
|
||||
Gst.PbUtils.DiscovererSubtitleInfo[] ret = (Gst.PbUtils.DiscovererSubtitleInfo[]) GLib.Marshaller.ListPtrToArray (raw_ret, typeof(GLib.List), true, true, typeof(Gst.PbUtils.DiscovererSubtitleInfo));
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
@ -181,6 +181,7 @@ namespace Gst.PbUtils {
|
|||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_discoverer_info_get_tags(IntPtr raw);
|
||||
|
||||
[Obsolete]
|
||||
public Gst.TagList Tags {
|
||||
get {
|
||||
IntPtr raw_ret = gst_discoverer_info_get_tags(Handle);
|
||||
|
@ -214,10 +215,10 @@ namespace Gst.PbUtils {
|
|||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_discoverer_info_get_video_streams(IntPtr raw);
|
||||
|
||||
public Gst.PbUtils.DiscovererStreamInfo[] VideoStreams {
|
||||
public Gst.PbUtils.DiscovererVideoInfo[] VideoStreams {
|
||||
get {
|
||||
IntPtr raw_ret = gst_discoverer_info_get_video_streams(Handle);
|
||||
Gst.PbUtils.DiscovererStreamInfo[] ret = (Gst.PbUtils.DiscovererStreamInfo[]) GLib.Marshaller.ListPtrToArray (raw_ret, typeof(GLib.List), true, true, typeof(Gst.PbUtils.DiscovererStreamInfo));
|
||||
Gst.PbUtils.DiscovererVideoInfo[] ret = (Gst.PbUtils.DiscovererVideoInfo[]) GLib.Marshaller.ListPtrToArray (raw_ret, typeof(GLib.List), true, true, typeof(Gst.PbUtils.DiscovererVideoInfo));
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -92,6 +92,17 @@ namespace Gst.PbUtils {
|
|||
}
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern int gst_discoverer_stream_info_get_stream_number(IntPtr raw);
|
||||
|
||||
public int StreamNumber {
|
||||
get {
|
||||
int raw_ret = gst_discoverer_stream_info_get_stream_number(Handle);
|
||||
int ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_discoverer_stream_info_get_stream_type_nick(IntPtr raw);
|
||||
|
||||
|
|
|
@ -18,6 +18,25 @@ namespace Gst.PbUtils {
|
|||
CreateNativeObject (new string [0], new GLib.Value [0]);
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_encoding_profile_get_element_properties(IntPtr raw);
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern void gst_encoding_profile_set_element_properties(IntPtr raw, IntPtr element_properties);
|
||||
|
||||
[GLib.Property ("element-properties")]
|
||||
public Gst.Structure ElementProperties {
|
||||
get {
|
||||
IntPtr raw_ret = gst_encoding_profile_get_element_properties(Handle);
|
||||
Gst.Structure ret = raw_ret == IntPtr.Zero ? null : (Gst.Structure) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Structure), true);
|
||||
return ret;
|
||||
}
|
||||
set {
|
||||
value.Owned = false;
|
||||
gst_encoding_profile_set_element_properties(Handle, value == null ? IntPtr.Zero : value.Handle);
|
||||
}
|
||||
}
|
||||
|
||||
[GLib.Property ("restriction-caps")]
|
||||
public Gst.Caps RestrictionCaps {
|
||||
get {
|
||||
|
|
|
@ -124,7 +124,7 @@ namespace Gst.PbUtils {
|
|||
public string Path {
|
||||
get {
|
||||
IntPtr raw_ret = gst_encoding_target_get_path(Handle);
|
||||
string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
|
||||
string ret = GLib.Marshaller.FilenamePtrToString (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -12,18 +12,20 @@ namespace Gst.PbUtils {
|
|||
public partial class Global {
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_codec_utils_aac_caps_set_level_and_profile(IntPtr caps, byte[] audio_config, uint len);
|
||||
static extern bool gst_codec_utils_aac_caps_set_level_and_profile(IntPtr caps, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] audio_config, uint len);
|
||||
|
||||
public static bool CodecUtilsAacCapsSetLevelAndProfile(Gst.Caps caps, byte[] audio_config, uint len) {
|
||||
public static bool CodecUtilsAacCapsSetLevelAndProfile(Gst.Caps caps, byte[] audio_config) {
|
||||
uint len = (uint)(audio_config == null ? 0 : audio_config.Length);
|
||||
bool raw_ret = gst_codec_utils_aac_caps_set_level_and_profile(caps == null ? IntPtr.Zero : caps.Handle, audio_config, len);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern uint gst_codec_utils_aac_get_channels(byte[] audio_config, uint len);
|
||||
static extern uint gst_codec_utils_aac_get_channels([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] audio_config, uint len);
|
||||
|
||||
public static uint CodecUtilsAacGetChannels(byte[] audio_config, uint len) {
|
||||
public static uint CodecUtilsAacGetChannels(byte[] audio_config) {
|
||||
uint len = (uint)(audio_config == null ? 0 : audio_config.Length);
|
||||
uint raw_ret = gst_codec_utils_aac_get_channels(audio_config, len);
|
||||
uint ret = raw_ret;
|
||||
return ret;
|
||||
|
@ -39,27 +41,30 @@ namespace Gst.PbUtils {
|
|||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_codec_utils_aac_get_level(byte[] audio_config, uint len);
|
||||
static extern IntPtr gst_codec_utils_aac_get_level([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] audio_config, uint len);
|
||||
|
||||
public static string CodecUtilsAacGetLevel(byte[] audio_config, uint len) {
|
||||
public static string CodecUtilsAacGetLevel(byte[] audio_config) {
|
||||
uint len = (uint)(audio_config == null ? 0 : audio_config.Length);
|
||||
IntPtr raw_ret = gst_codec_utils_aac_get_level(audio_config, len);
|
||||
string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_codec_utils_aac_get_profile(byte[] audio_config, uint len);
|
||||
static extern IntPtr gst_codec_utils_aac_get_profile([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] audio_config, uint len);
|
||||
|
||||
public static string CodecUtilsAacGetProfile(byte[] audio_config, uint len) {
|
||||
public static string CodecUtilsAacGetProfile(byte[] audio_config) {
|
||||
uint len = (uint)(audio_config == null ? 0 : audio_config.Length);
|
||||
IntPtr raw_ret = gst_codec_utils_aac_get_profile(audio_config, len);
|
||||
string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern uint gst_codec_utils_aac_get_sample_rate(byte[] audio_config, uint len);
|
||||
static extern uint gst_codec_utils_aac_get_sample_rate([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] audio_config, uint len);
|
||||
|
||||
public static uint CodecUtilsAacGetSampleRate(byte[] audio_config, uint len) {
|
||||
public static uint CodecUtilsAacGetSampleRate(byte[] audio_config) {
|
||||
uint len = (uint)(audio_config == null ? 0 : audio_config.Length);
|
||||
uint raw_ret = gst_codec_utils_aac_get_sample_rate(audio_config, len);
|
||||
uint ret = raw_ret;
|
||||
return ret;
|
||||
|
@ -75,18 +80,40 @@ namespace Gst.PbUtils {
|
|||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_codec_utils_h264_caps_set_level_and_profile(IntPtr caps, byte[] sps, uint len);
|
||||
static extern IntPtr gst_codec_utils_caps_from_mime_codec(IntPtr codecs_field);
|
||||
|
||||
public static bool CodecUtilsH264CapsSetLevelAndProfile(Gst.Caps caps, byte[] sps, uint len) {
|
||||
public static Gst.Caps CodecUtilsCapsFromMimeCodec(string codecs_field) {
|
||||
IntPtr native_codecs_field = GLib.Marshaller.StringToPtrGStrdup (codecs_field);
|
||||
IntPtr raw_ret = gst_codec_utils_caps_from_mime_codec(native_codecs_field);
|
||||
Gst.Caps ret = raw_ret == IntPtr.Zero ? null : (Gst.Caps) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Caps), true);
|
||||
GLib.Marshaller.Free (native_codecs_field);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_codec_utils_caps_get_mime_codec(IntPtr caps);
|
||||
|
||||
public static string CodecUtilsCapsGetMimeCodec(Gst.Caps caps) {
|
||||
IntPtr raw_ret = gst_codec_utils_caps_get_mime_codec(caps == null ? IntPtr.Zero : caps.Handle);
|
||||
string ret = GLib.Marshaller.PtrToStringGFree(raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_codec_utils_h264_caps_set_level_and_profile(IntPtr caps, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] sps, uint len);
|
||||
|
||||
public static bool CodecUtilsH264CapsSetLevelAndProfile(Gst.Caps caps, byte[] sps) {
|
||||
uint len = (uint)(sps == null ? 0 : sps.Length);
|
||||
bool raw_ret = gst_codec_utils_h264_caps_set_level_and_profile(caps == null ? IntPtr.Zero : caps.Handle, sps, len);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_codec_utils_h264_get_level(byte[] sps, uint len);
|
||||
static extern IntPtr gst_codec_utils_h264_get_level([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] sps, uint len);
|
||||
|
||||
public static string CodecUtilsH264GetLevel(byte[] sps, uint len) {
|
||||
public static string CodecUtilsH264GetLevel(byte[] sps) {
|
||||
uint len = (uint)(sps == null ? 0 : sps.Length);
|
||||
IntPtr raw_ret = gst_codec_utils_h264_get_level(sps, len);
|
||||
string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
|
||||
return ret;
|
||||
|
@ -104,27 +131,40 @@ namespace Gst.PbUtils {
|
|||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_codec_utils_h264_get_profile(byte[] sps, uint len);
|
||||
static extern IntPtr gst_codec_utils_h264_get_profile([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] sps, uint len);
|
||||
|
||||
public static string CodecUtilsH264GetProfile(byte[] sps, uint len) {
|
||||
public static string CodecUtilsH264GetProfile(byte[] sps) {
|
||||
uint len = (uint)(sps == null ? 0 : sps.Length);
|
||||
IntPtr raw_ret = gst_codec_utils_h264_get_profile(sps, len);
|
||||
string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_codec_utils_h265_caps_set_level_tier_and_profile(IntPtr caps, byte[] profile_tier_level, uint len);
|
||||
static extern bool gst_codec_utils_h264_get_profile_flags_level([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] codec_data, uint len, out byte profile, out byte flags, out byte level);
|
||||
|
||||
public static bool CodecUtilsH265CapsSetLevelTierAndProfile(Gst.Caps caps, byte[] profile_tier_level, uint len) {
|
||||
public static bool CodecUtilsH264GetProfileFlagsLevel(byte[] codec_data, out byte profile, out byte flags, out byte level) {
|
||||
uint len = (uint)(codec_data == null ? 0 : codec_data.Length);
|
||||
bool raw_ret = gst_codec_utils_h264_get_profile_flags_level(codec_data, len, out profile, out flags, out level);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_codec_utils_h265_caps_set_level_tier_and_profile(IntPtr caps, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] profile_tier_level, uint len);
|
||||
|
||||
public static bool CodecUtilsH265CapsSetLevelTierAndProfile(Gst.Caps caps, byte[] profile_tier_level) {
|
||||
uint len = (uint)(profile_tier_level == null ? 0 : profile_tier_level.Length);
|
||||
bool raw_ret = gst_codec_utils_h265_caps_set_level_tier_and_profile(caps == null ? IntPtr.Zero : caps.Handle, profile_tier_level, len);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_codec_utils_h265_get_level(byte[] profile_tier_level, uint len);
|
||||
static extern IntPtr gst_codec_utils_h265_get_level([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] profile_tier_level, uint len);
|
||||
|
||||
public static string CodecUtilsH265GetLevel(byte[] profile_tier_level, uint len) {
|
||||
public static string CodecUtilsH265GetLevel(byte[] profile_tier_level) {
|
||||
uint len = (uint)(profile_tier_level == null ? 0 : profile_tier_level.Length);
|
||||
IntPtr raw_ret = gst_codec_utils_h265_get_level(profile_tier_level, len);
|
||||
string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
|
||||
return ret;
|
||||
|
@ -142,45 +182,50 @@ namespace Gst.PbUtils {
|
|||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_codec_utils_h265_get_profile(byte[] profile_tier_level, uint len);
|
||||
static extern IntPtr gst_codec_utils_h265_get_profile([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] profile_tier_level, uint len);
|
||||
|
||||
public static string CodecUtilsH265GetProfile(byte[] profile_tier_level, uint len) {
|
||||
public static string CodecUtilsH265GetProfile(byte[] profile_tier_level) {
|
||||
uint len = (uint)(profile_tier_level == null ? 0 : profile_tier_level.Length);
|
||||
IntPtr raw_ret = gst_codec_utils_h265_get_profile(profile_tier_level, len);
|
||||
string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_codec_utils_h265_get_tier(byte[] profile_tier_level, uint len);
|
||||
static extern IntPtr gst_codec_utils_h265_get_tier([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] profile_tier_level, uint len);
|
||||
|
||||
public static string CodecUtilsH265GetTier(byte[] profile_tier_level, uint len) {
|
||||
public static string CodecUtilsH265GetTier(byte[] profile_tier_level) {
|
||||
uint len = (uint)(profile_tier_level == null ? 0 : profile_tier_level.Length);
|
||||
IntPtr raw_ret = gst_codec_utils_h265_get_tier(profile_tier_level, len);
|
||||
string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_codec_utils_mpeg4video_caps_set_level_and_profile(IntPtr caps, byte[] vis_obj_seq, uint len);
|
||||
static extern bool gst_codec_utils_mpeg4video_caps_set_level_and_profile(IntPtr caps, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] vis_obj_seq, uint len);
|
||||
|
||||
public static bool CodecUtilsMpeg4videoCapsSetLevelAndProfile(Gst.Caps caps, byte[] vis_obj_seq, uint len) {
|
||||
public static bool CodecUtilsMpeg4videoCapsSetLevelAndProfile(Gst.Caps caps, byte[] vis_obj_seq) {
|
||||
uint len = (uint)(vis_obj_seq == null ? 0 : vis_obj_seq.Length);
|
||||
bool raw_ret = gst_codec_utils_mpeg4video_caps_set_level_and_profile(caps == null ? IntPtr.Zero : caps.Handle, vis_obj_seq, len);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_codec_utils_mpeg4video_get_level(byte[] vis_obj_seq, uint len);
|
||||
static extern IntPtr gst_codec_utils_mpeg4video_get_level([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] vis_obj_seq, uint len);
|
||||
|
||||
public static string CodecUtilsMpeg4videoGetLevel(byte[] vis_obj_seq, uint len) {
|
||||
public static string CodecUtilsMpeg4videoGetLevel(byte[] vis_obj_seq) {
|
||||
uint len = (uint)(vis_obj_seq == null ? 0 : vis_obj_seq.Length);
|
||||
IntPtr raw_ret = gst_codec_utils_mpeg4video_get_level(vis_obj_seq, len);
|
||||
string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_codec_utils_mpeg4video_get_profile(byte[] vis_obj_seq, uint len);
|
||||
static extern IntPtr gst_codec_utils_mpeg4video_get_profile([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] vis_obj_seq, uint len);
|
||||
|
||||
public static string CodecUtilsMpeg4videoGetProfile(byte[] vis_obj_seq, uint len) {
|
||||
public static string CodecUtilsMpeg4videoGetProfile(byte[] vis_obj_seq) {
|
||||
uint len = (uint)(vis_obj_seq == null ? 0 : vis_obj_seq.Length);
|
||||
IntPtr raw_ret = gst_codec_utils_mpeg4video_get_profile(vis_obj_seq, len);
|
||||
string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
|
||||
return ret;
|
||||
|
@ -225,6 +270,24 @@ namespace Gst.PbUtils {
|
|||
return CodecUtilsOpusCreateHeader (rate, channels, channel_mapping_family, stream_count, coupled_count, null, pre_skip, output_gain);
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_codec_utils_opus_parse_caps(IntPtr caps, out uint rate, out byte channels, out byte channel_mapping_family, out byte stream_count, out byte coupled_count, [MarshalAs(UnmanagedType.LPArray, SizeConst=256)]out byte[] channel_mapping);
|
||||
|
||||
public static bool CodecUtilsOpusParseCaps(Gst.Caps caps, out uint rate, out byte channels, out byte channel_mapping_family, out byte stream_count, out byte coupled_count, out byte[] channel_mapping) {
|
||||
bool raw_ret = gst_codec_utils_opus_parse_caps(caps == null ? IntPtr.Zero : caps.Handle, out rate, out channels, out channel_mapping_family, out stream_count, out coupled_count, out channel_mapping);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_codec_utils_opus_parse_header(IntPtr header, out uint rate, out byte channels, out byte channel_mapping_family, out byte stream_count, out byte coupled_count, [MarshalAs(UnmanagedType.LPArray, SizeConst=256)]out byte[] channel_mapping, out ushort pre_skip, out short output_gain);
|
||||
|
||||
public static bool CodecUtilsOpusParseHeader(Gst.Buffer header, out uint rate, out byte channels, out byte channel_mapping_family, out byte stream_count, out byte coupled_count, out byte[] channel_mapping, out ushort pre_skip, out short output_gain) {
|
||||
bool raw_ret = gst_codec_utils_opus_parse_header(header == null ? IntPtr.Zero : header.Handle, out rate, out channels, out channel_mapping_family, out stream_count, out coupled_count, out channel_mapping, out pre_skip, out output_gain);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_encoding_list_all_targets(IntPtr categoryname);
|
||||
|
||||
|
@ -420,6 +483,15 @@ namespace Gst.PbUtils {
|
|||
return PbUtilsAddCodecDescriptionToTagList (taglist, null, caps);
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern int gst_pb_utils_get_caps_description_flags(IntPtr caps);
|
||||
|
||||
public static Gst.PbUtils.PbUtilsCapsDescriptionFlags PbUtilsGetCapsDescriptionFlags(Gst.Caps caps) {
|
||||
int raw_ret = gst_pb_utils_get_caps_description_flags(caps == null ? IntPtr.Zero : caps.Handle);
|
||||
Gst.PbUtils.PbUtilsCapsDescriptionFlags ret = (Gst.PbUtils.PbUtilsCapsDescriptionFlags) raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_pb_utils_get_codec_description(IntPtr caps);
|
||||
|
||||
|
@ -458,6 +530,15 @@ namespace Gst.PbUtils {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_pb_utils_get_file_extension_from_caps(IntPtr caps);
|
||||
|
||||
public static string PbUtilsGetFileExtensionFromCaps(Gst.Caps caps) {
|
||||
IntPtr raw_ret = gst_pb_utils_get_file_extension_from_caps(caps == null ? IntPtr.Zero : caps.Handle);
|
||||
string ret = GLib.Marshaller.PtrToStringGFree(raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_pb_utils_get_sink_description(IntPtr protocol);
|
||||
|
||||
|
|
|
@ -0,0 +1,18 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace Gst.PbUtils {
|
||||
|
||||
using System;
|
||||
|
||||
public delegate void LoadSerializedInfoHandler(object o, LoadSerializedInfoArgs args);
|
||||
|
||||
public class LoadSerializedInfoArgs : GLib.SignalArgs {
|
||||
public string Uri{
|
||||
get {
|
||||
return (string) Args [0];
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -0,0 +1,35 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace Gst.PbUtils {
|
||||
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
#region Autogenerated code
|
||||
[Flags]
|
||||
[GLib.GType (typeof (Gst.PbUtils.PbUtilsCapsDescriptionFlagsGType))]
|
||||
public enum PbUtilsCapsDescriptionFlags : uint {
|
||||
|
||||
Container = 1,
|
||||
Audio = 2,
|
||||
Video = 4,
|
||||
Image = 8,
|
||||
Subtitle = 16,
|
||||
Tag = 32,
|
||||
Generic = 64,
|
||||
Metadata = 128,
|
||||
}
|
||||
|
||||
internal class PbUtilsCapsDescriptionFlagsGType {
|
||||
[DllImport ("gstpbutils-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_pb_utils_caps_description_flags_get_type ();
|
||||
|
||||
public static GLib.GType GType {
|
||||
get {
|
||||
return new GLib.GType (gst_pb_utils_caps_description_flags_get_type ());
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
}
|
|
@ -0,0 +1,18 @@
|
|||
// This file was generated by the Gtk# code generator.
|
||||
// Any changes made will be lost if regenerated.
|
||||
|
||||
namespace Gst.Rtp {
|
||||
|
||||
using System;
|
||||
|
||||
public delegate void AddExtensionHandler(object o, AddExtensionArgs args);
|
||||
|
||||
public class AddExtensionArgs : GLib.SignalArgs {
|
||||
public Gst.Rtp.RTPHeaderExtension Ext{
|
||||
get {
|
||||
return (Gst.Rtp.RTPHeaderExtension) Args [0];
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -15,15 +15,17 @@ namespace Gst.Rtp {
|
|||
public const int RTCP_MAX_RB_COUNT = 31;
|
||||
public const int RTCP_MAX_SDES = 255;
|
||||
public const int RTCP_MAX_SDES_ITEM_COUNT = 31;
|
||||
public const int RTCP_REDUCED_SIZE_VALID_MASK = 57592;
|
||||
public const int RTCP_REDUCED_SIZE_VALID_MASK = 49400;
|
||||
public const int RTCP_VALID_MASK = 57598;
|
||||
public const int RTCP_VALID_VALUE = 200;
|
||||
public const int RTCP_VERSION = 2;
|
||||
public const string RTP_HDREXT_BASE = @"urn:ietf:params:rtp-hdrext:";
|
||||
public const string RTP_HDREXT_ELEMENT_CLASS = @"Network/Extension/RTPHeader";
|
||||
public const string RTP_HDREXT_NTP_56 = @"ntp-56";
|
||||
public const int RTP_HDREXT_NTP_56_SIZE = 7;
|
||||
public const string RTP_HDREXT_NTP_64 = @"ntp-64";
|
||||
public const int RTP_HDREXT_NTP_64_SIZE = 8;
|
||||
public const string RTP_HEADER_EXTENSION_URI_METADATA_KEY = @"RTP-Header-Extension-URI";
|
||||
public const string RTP_PAYLOAD_1016_STRING = @"1";
|
||||
public const string RTP_PAYLOAD_CELLB_STRING = @"25";
|
||||
public const string RTP_PAYLOAD_CN_STRING = @"13";
|
||||
|
|
|
@ -12,16 +12,17 @@ namespace Gst.Rtp {
|
|||
public partial class Global {
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_buffer_add_rtp_source_meta(IntPtr buffer, uint ssrc, uint csrc, uint csrc_count);
|
||||
static extern IntPtr gst_buffer_add_rtp_source_meta(IntPtr buffer, uint ssrc, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=3)]uint[] csrc, uint csrc_count);
|
||||
|
||||
public static Gst.Rtp.RTPSourceMeta BufferAddRtpSourceMeta(Gst.Buffer buffer, uint ssrc, uint csrc, uint csrc_count) {
|
||||
public static Gst.Rtp.RTPSourceMeta BufferAddRtpSourceMeta(Gst.Buffer buffer, uint ssrc, uint[] csrc) {
|
||||
uint csrc_count = (uint)(csrc == null ? 0 : csrc.Length);
|
||||
IntPtr raw_ret = gst_buffer_add_rtp_source_meta(buffer == null ? IntPtr.Zero : buffer.Handle, ssrc, csrc, csrc_count);
|
||||
Gst.Rtp.RTPSourceMeta ret = Gst.Rtp.RTPSourceMeta.New (raw_ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
public static Gst.Rtp.RTPSourceMeta BufferAddRtpSourceMeta(Gst.Buffer buffer, uint csrc_count) {
|
||||
return BufferAddRtpSourceMeta (buffer, 0, 0, csrc_count);
|
||||
public static Gst.Rtp.RTPSourceMeta BufferAddRtpSourceMeta(Gst.Buffer buffer) {
|
||||
return BufferAddRtpSourceMeta (buffer, 0, null);
|
||||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
|
@ -54,19 +55,21 @@ namespace Gst.Rtp {
|
|||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_rtcp_buffer_new_copy_data(byte[] data, uint n_length);
|
||||
static extern IntPtr gst_rtcp_buffer_new_copy_data([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] data, uint n_length);
|
||||
|
||||
public static Gst.Buffer RtcpBufferNewCopyData(byte[] data) {
|
||||
IntPtr raw_ret = gst_rtcp_buffer_new_copy_data(data, (uint) (data == null ? 0 : data.Length));
|
||||
uint n_length = (uint)(data == null ? 0 : data.Length);
|
||||
IntPtr raw_ret = gst_rtcp_buffer_new_copy_data(data, n_length);
|
||||
Gst.Buffer ret = raw_ret == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Buffer), true);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_rtcp_buffer_new_take_data(byte[] data, uint n_length);
|
||||
static extern IntPtr gst_rtcp_buffer_new_take_data([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] data, uint n_length);
|
||||
|
||||
public static Gst.Buffer RtcpBufferNewTakeData(byte[] data) {
|
||||
IntPtr raw_ret = gst_rtcp_buffer_new_take_data(data, (uint) (data == null ? 0 : data.Length));
|
||||
uint n_length = (uint)(data == null ? 0 : data.Length);
|
||||
IntPtr raw_ret = gst_rtcp_buffer_new_take_data(data, n_length);
|
||||
Gst.Buffer ret = raw_ret == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Buffer), true);
|
||||
return ret;
|
||||
}
|
||||
|
@ -81,18 +84,20 @@ namespace Gst.Rtp {
|
|||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_rtcp_buffer_validate_data(byte[] data, uint len);
|
||||
static extern bool gst_rtcp_buffer_validate_data([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] data, uint len);
|
||||
|
||||
public static bool RtcpBufferValidateData(byte[] data, uint len) {
|
||||
public static bool RtcpBufferValidateData(byte[] data) {
|
||||
uint len = (uint)(data == null ? 0 : data.Length);
|
||||
bool raw_ret = gst_rtcp_buffer_validate_data(data, len);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_rtcp_buffer_validate_data_reduced(byte[] data, uint len);
|
||||
static extern bool gst_rtcp_buffer_validate_data_reduced([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] data, uint len);
|
||||
|
||||
public static bool RtcpBufferValidateDataReduced(byte[] data, uint len) {
|
||||
public static bool RtcpBufferValidateDataReduced(byte[] data) {
|
||||
uint len = (uint)(data == null ? 0 : data.Length);
|
||||
bool raw_ret = gst_rtcp_buffer_validate_data_reduced(data, len);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
|
@ -206,6 +211,15 @@ namespace Gst.Rtp {
|
|||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_rtp_buffer_get_extension_onebyte_header_from_bytes(IntPtr bytes, ushort bit_pattern, byte id, uint nth, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=5)]out IntPtr[] data, out uint size);
|
||||
|
||||
public static bool RtpBufferGetExtensionOnebyteHeaderFromBytes(GLib.Bytes bytes, ushort bit_pattern, byte id, uint nth, out IntPtr[] data) {
|
||||
bool raw_ret = gst_rtp_buffer_get_extension_onebyte_header_from_bytes(bytes == null ? IntPtr.Zero : bytes.Handle, bit_pattern, id, nth, out data, out uint size);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_rtp_buffer_map(IntPtr buffer, int flags, IntPtr rtp);
|
||||
|
||||
|
@ -237,36 +251,49 @@ namespace Gst.Rtp {
|
|||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_rtp_buffer_new_copy_data(byte[] data, UIntPtr n_length);
|
||||
static extern IntPtr gst_rtp_buffer_new_copy_data([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] data, UIntPtr n_length);
|
||||
|
||||
public static Gst.Buffer RtpBufferNewCopyData(byte[] data) {
|
||||
IntPtr raw_ret = gst_rtp_buffer_new_copy_data(data, new UIntPtr ((ulong) (data == null ? 0 : data.Length)));
|
||||
ulong n_length = (ulong)(data == null ? 0 : data.Length);
|
||||
IntPtr raw_ret = gst_rtp_buffer_new_copy_data(data, new UIntPtr ((uint)n_length));
|
||||
Gst.Buffer ret = raw_ret == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Buffer), true);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_rtp_buffer_new_take_data(byte[] data, UIntPtr n_length);
|
||||
static extern IntPtr gst_rtp_buffer_new_take_data([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] data, UIntPtr n_length);
|
||||
|
||||
public static Gst.Buffer RtpBufferNewTakeData(byte[] data) {
|
||||
IntPtr raw_ret = gst_rtp_buffer_new_take_data(data, new UIntPtr ((ulong) (data == null ? 0 : data.Length)));
|
||||
ulong n_length = (ulong)(data == null ? 0 : data.Length);
|
||||
IntPtr raw_ret = gst_rtp_buffer_new_take_data(data, new UIntPtr ((uint)n_length));
|
||||
Gst.Buffer ret = raw_ret == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Buffer), true);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_rtp_hdrext_get_ntp_56(IntPtr[] data, uint size, out ulong ntptime);
|
||||
static extern IntPtr gst_rtp_get_header_extension_list();
|
||||
|
||||
public static bool RtpHdrextGetNtp56(IntPtr[] data, uint size, out ulong ntptime) {
|
||||
public static Gst.ElementFactory[] RtpGetHeaderExtensionList() {
|
||||
IntPtr raw_ret = gst_rtp_get_header_extension_list();
|
||||
Gst.ElementFactory[] ret = (Gst.ElementFactory[]) GLib.Marshaller.ListPtrToArray (raw_ret, typeof(GLib.List), true, true, typeof(Gst.ElementFactory));
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_rtp_hdrext_get_ntp_56([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]IntPtr[] data, uint size, out ulong ntptime);
|
||||
|
||||
public static bool RtpHdrextGetNtp56(IntPtr[] data, out ulong ntptime) {
|
||||
uint size = (uint)(data == null ? 0 : data.Length);
|
||||
bool raw_ret = gst_rtp_hdrext_get_ntp_56(data, size, out ntptime);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_rtp_hdrext_get_ntp_64(IntPtr[] data, uint size, out ulong ntptime);
|
||||
static extern bool gst_rtp_hdrext_get_ntp_64([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]IntPtr[] data, uint size, out ulong ntptime);
|
||||
|
||||
public static bool RtpHdrextGetNtp64(IntPtr[] data, uint size, out ulong ntptime) {
|
||||
public static bool RtpHdrextGetNtp64(IntPtr[] data, out ulong ntptime) {
|
||||
uint size = (uint)(data == null ? 0 : data.Length);
|
||||
bool raw_ret = gst_rtp_hdrext_get_ntp_64(data, size, out ntptime);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
|
|
|
@ -110,19 +110,21 @@ namespace Gst.Rtp {
|
|||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_rtcp_buffer_new_copy_data(byte[] data, uint n_length);
|
||||
static extern IntPtr gst_rtcp_buffer_new_copy_data([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] data, uint n_length);
|
||||
|
||||
public static Gst.Buffer NewCopyData(byte[] data) {
|
||||
IntPtr raw_ret = gst_rtcp_buffer_new_copy_data(data, (uint) (data == null ? 0 : data.Length));
|
||||
uint n_length = (uint)(data == null ? 0 : data.Length);
|
||||
IntPtr raw_ret = gst_rtcp_buffer_new_copy_data(data, n_length);
|
||||
Gst.Buffer ret = raw_ret == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Buffer), true);
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern IntPtr gst_rtcp_buffer_new_take_data(byte[] data, uint n_length);
|
||||
static extern IntPtr gst_rtcp_buffer_new_take_data([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] data, uint n_length);
|
||||
|
||||
public static Gst.Buffer NewTakeData(byte[] data) {
|
||||
IntPtr raw_ret = gst_rtcp_buffer_new_take_data(data, (uint) (data == null ? 0 : data.Length));
|
||||
uint n_length = (uint)(data == null ? 0 : data.Length);
|
||||
IntPtr raw_ret = gst_rtcp_buffer_new_take_data(data, n_length);
|
||||
Gst.Buffer ret = raw_ret == IntPtr.Zero ? null : (Gst.Buffer) GLib.Opaque.GetOpaque (raw_ret, typeof (Gst.Buffer), true);
|
||||
return ret;
|
||||
}
|
||||
|
@ -137,18 +139,20 @@ namespace Gst.Rtp {
|
|||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_rtcp_buffer_validate_data(byte[] data, uint len);
|
||||
static extern bool gst_rtcp_buffer_validate_data([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] data, uint len);
|
||||
|
||||
public static bool ValidateData(byte[] data, uint len) {
|
||||
public static bool ValidateData(byte[] data) {
|
||||
uint len = (uint)(data == null ? 0 : data.Length);
|
||||
bool raw_ret = gst_rtcp_buffer_validate_data(data, len);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_rtcp_buffer_validate_data_reduced(byte[] data, uint len);
|
||||
static extern bool gst_rtcp_buffer_validate_data_reduced([MarshalAs(UnmanagedType.LPArray, SizeParamIndex=1)]byte[] data, uint len);
|
||||
|
||||
public static bool ValidateDataReduced(byte[] data, uint len) {
|
||||
public static bool ValidateDataReduced(byte[] data) {
|
||||
uint len = (uint)(data == null ? 0 : data.Length);
|
||||
bool raw_ret = gst_rtcp_buffer_validate_data_reduced(data, len);
|
||||
bool ret = raw_ret;
|
||||
return ret;
|
||||
|
|
|
@ -35,11 +35,12 @@ namespace Gst.Rtp {
|
|||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_rtcp_packet_add_profile_specific_ext(IntPtr raw, byte[] data, uint len);
|
||||
static extern bool gst_rtcp_packet_add_profile_specific_ext(IntPtr raw, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] data, uint len);
|
||||
|
||||
public bool AddProfileSpecificExt(byte[] data, uint len) {
|
||||
public bool AddProfileSpecificExt(byte[] data) {
|
||||
IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf (this));
|
||||
System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false);
|
||||
uint len = (uint)(data == null ? 0 : data.Length);
|
||||
bool raw_ret = gst_rtcp_packet_add_profile_specific_ext(this_as_native, data, len);
|
||||
bool ret = raw_ret;
|
||||
ReadNative (this_as_native, ref this);
|
||||
|
@ -187,11 +188,12 @@ namespace Gst.Rtp {
|
|||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_rtcp_packet_bye_add_ssrcs(IntPtr raw, uint[] ssrc, uint len);
|
||||
static extern bool gst_rtcp_packet_bye_add_ssrcs(IntPtr raw, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]uint[] ssrc, uint len);
|
||||
|
||||
public bool ByeAddSsrcs(uint[] ssrc, uint len) {
|
||||
public bool ByeAddSsrcs(uint[] ssrc) {
|
||||
IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf (this));
|
||||
System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false);
|
||||
uint len = (uint)(ssrc == null ? 0 : ssrc.Length);
|
||||
bool raw_ret = gst_rtcp_packet_bye_add_ssrcs(this_as_native, ssrc, len);
|
||||
bool ret = raw_ret;
|
||||
ReadNative (this_as_native, ref this);
|
||||
|
@ -510,11 +512,12 @@ namespace Gst.Rtp {
|
|||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern bool gst_rtcp_packet_sdes_add_entry(IntPtr raw, int type, byte len, byte[] data);
|
||||
static extern bool gst_rtcp_packet_sdes_add_entry(IntPtr raw, int type, byte len, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] data);
|
||||
|
||||
public bool SdesAddEntry(Gst.Rtp.RTCPSDESType type, byte len, byte[] data) {
|
||||
public bool SdesAddEntry(Gst.Rtp.RTCPSDESType type, byte[] data) {
|
||||
IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf (this));
|
||||
System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false);
|
||||
byte len = (byte)(data == null ? 0 : data.Length);
|
||||
bool raw_ret = gst_rtcp_packet_sdes_add_entry(this_as_native, (int) type, len, data);
|
||||
bool ret = raw_ret;
|
||||
ReadNative (this_as_native, ref this);
|
||||
|
|
|
@ -20,6 +20,13 @@ namespace Gst.Rtp {
|
|||
Tool = 6,
|
||||
Note = 7,
|
||||
Priv = 8,
|
||||
H323Caddr = 9,
|
||||
Apsi = 10,
|
||||
Rgrp = 11,
|
||||
RtpStreamId = 12,
|
||||
RepairedRtpStreamId = 13,
|
||||
Ccid = 14,
|
||||
Mid = 15,
|
||||
}
|
||||
|
||||
internal class RTCPSDESTypeGType {
|
||||
|
|
|
@ -125,9 +125,10 @@ namespace Gst.Rtp {
|
|||
}
|
||||
|
||||
[DllImport("gstrtp-1.0-0.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
static extern int gst_rtp_base_audio_payload_push(IntPtr raw, byte[] data, uint payload_len, ulong timestamp);
|
||||
static extern int gst_rtp_base_audio_payload_push(IntPtr raw, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex=2)]byte[] data, uint payload_len, ulong timestamp);
|
||||
|
||||
public Gst.FlowReturn Push(byte[] data, uint payload_len, ulong timestamp) {
|
||||
public Gst.FlowReturn Push(byte[] data, ulong timestamp) {
|
||||
uint payload_len = (uint)(data == null ? 0 : data.Length);
|
||||
int raw_ret = gst_rtp_base_audio_payload_push(Handle, data, payload_len, timestamp);
|
||||
Gst.FlowReturn ret = (Gst.FlowReturn) raw_ret;
|
||||
return ret;
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue