示例#1
0
 public static bool TypeFindRegister(string name, uint rank, Gst.TypeFindFunction func, Gst.Caps possible_caps)
 {
     return(TypeFindRegister(null, name, rank, func, null, possible_caps));
 }
示例#2
0
        public PadTemplate(string name_template, Gst.PadDirection direction, Gst.PadPresence presence, Gst.Caps caps, GLib.GType pad_type) : base(IntPtr.Zero)
        {
            if (GetType() != typeof(PadTemplate))
            {
                var vals  = new List <GLib.Value>();
                var names = new List <string>();
                names.Add("name_template");
                vals.Add(new GLib.Value(name_template));
                names.Add("direction");
                vals.Add(new GLib.Value(direction));
                names.Add("presence");
                vals.Add(new GLib.Value(presence));
                if (caps != null)
                {
                    names.Add("caps");
                    vals.Add(new GLib.Value(caps));
                }
                CreateNativeObject(names.ToArray(), vals.ToArray());
                return;
            }
            IntPtr native_name_template = GLib.Marshaller.StringToPtrGStrdup(name_template);

            Raw = gst_pad_template_new_with_gtype(native_name_template, (int)direction, (int)presence, caps == null ? IntPtr.Zero : caps.Handle, pad_type.Val);
            GLib.Marshaller.Free(native_name_template);
        }
		protected virtual Gst.Caps OnUpdateCaps (Gst.Caps caps)
		{
			return InternalUpdateCaps (caps);
		}
示例#4
0
 public static void AddAudioPadTemplate(Gst.Caps allowed_caps)
 {
     gst_audio_filter_class_add_pad_templates(allowed_caps == null ? IntPtr.Zero : allowed_caps.Handle);
 }
示例#5
0
 public Query(Gst.Caps caps, bool need_pool)
 {
     Raw = gst_query_new_allocation(caps == null ? IntPtr.Zero : caps.Handle, need_pool);
 }
示例#6
0
        public static bool PbUtilsAddCodecDescriptionToTagList(Gst.TagList taglist, string codec_tag, Gst.Caps caps)
        {
            IntPtr native_codec_tag = GLib.Marshaller.StringToPtrGStrdup(codec_tag);
            bool   raw_ret          = gst_pb_utils_add_codec_description_to_tag_list(taglist == null ? IntPtr.Zero : taglist.Handle, native_codec_tag, caps == null ? IntPtr.Zero : caps.Handle);
            bool   ret = raw_ret;

            GLib.Marshaller.Free(native_codec_tag);
            return(ret);
        }
 protected virtual bool OnSetSinkCaps(Gst.Caps caps)
 {
     return(InternalSetSinkCaps(caps));
 }
 public void UpdateRestrictionCaps(Gst.Caps caps)
 {
     ges_track_update_restriction_caps(Handle, caps == null ? IntPtr.Zero : caps.Handle);
 }
        public static Gst.FlowReturn TypeFindHelperGetRangeFull(Gst.Object obj, Gst.Object parent, Gst.Base.TypeFindHelperGetRangeFunction func, ulong size, string extension, out Gst.Caps caps, out Gst.TypeFindProbability prob)
        {
            Gst.BaseSharp.TypeFindHelperGetRangeFunctionWrapper func_wrapper = new Gst.BaseSharp.TypeFindHelperGetRangeFunctionWrapper(func);
            IntPtr native_extension = GLib.Marshaller.StringToPtrGStrdup(extension);
            IntPtr native_caps;
            int    native_prob;
            int    raw_ret = gst_type_find_helper_get_range_full(obj == null ? IntPtr.Zero : obj.Handle, parent == null ? IntPtr.Zero : parent.Handle, func_wrapper.NativeDelegate, size, native_extension, out native_caps, out native_prob);

            Gst.FlowReturn ret = (Gst.FlowReturn)raw_ret;
            GLib.Marshaller.Free(native_extension);
            caps = native_caps == IntPtr.Zero ? null : (Gst.Caps)GLib.Opaque.GetOpaque(native_caps, typeof(Gst.Caps), true);
            prob = (Gst.TypeFindProbability)native_prob;
            return(ret);
        }
示例#10
0
 public void AddPadTemplates(Gst.Caps allowed_caps)
 {
     gst_audio_filter_class_add_pad_templates(LookupGType().GetClassPtr(), allowed_caps == null ? IntPtr.Zero : allowed_caps.Handle);
 }
		public Gst.Sdp.SDPResult AttributesToCaps(Gst.Caps caps) {
			int raw_ret = gst_sdp_message_attributes_to_caps(Handle, caps == null ? IntPtr.Zero : caps.Handle);
			Gst.Sdp.SDPResult ret = (Gst.Sdp.SDPResult) raw_ret;
			return ret;
		}
示例#12
0
 public StructureEnumerator(Gst.Caps caps)
 {
     this.caps = caps;
     index     = -1;
 }
 protected virtual bool OnSetInfo(Gst.Caps incaps, Gst.Video.VideoInfo in_info, Gst.Caps outcaps, Gst.Video.VideoInfo out_info)
 {
     return(InternalSetInfo(incaps, in_info, outcaps, out_info));
 }
 void InvokeNative(uint propability, Gst.Caps caps)
 {
     native_cb(IntPtr.Zero, propability, caps.Handle);
 }
示例#15
0
 public static void ConfigSetParams(Gst.Structure config, Gst.Caps caps, uint size, uint min_buffers, uint max_buffers)
 {
     gst_buffer_pool_config_set_params(config == null ? IntPtr.Zero : config.Handle, caps == null ? IntPtr.Zero : caps.Handle, size, min_buffers, max_buffers);
 }
 public static Gst.FlowReturn TypeFindHelperGetRangeFull(Gst.Object obj, Gst.Base.TypeFindHelperGetRangeFunction func, ulong size, out Gst.Caps caps, out Gst.TypeFindProbability prob)
 {
     return(TypeFindHelperGetRangeFull(obj, null, func, size, null, out caps, out prob));
 }
示例#17
0
        public static Event NewCaps(Gst.Caps caps)
        {
            Event result = new Event(gst_event_new_caps(caps == null ? IntPtr.Zero : caps.Handle));

            return(result);
        }
示例#18
0
 protected virtual Gst.Caps OnGetCaps(Gst.Pad pad, Gst.Caps filter)
 {
     return(InternalGetCaps(pad, filter));
 }
示例#19
0
 public static bool PbUtilsAddCodecDescriptionToTagList(Gst.TagList taglist, Gst.Caps caps)
 {
     return(PbUtilsAddCodecDescriptionToTagList(taglist, null, caps));
 }
 public MIKEYMessage(Gst.Caps caps)
 {
     Raw = gst_mikey_message_new_from_caps(caps == null ? IntPtr.Zero : caps.Handle);
 }
 protected virtual Gst.Caps OnGetSinkCaps(Gst.Caps filter)
 {
     return(InternalGetSinkCaps(filter));
 }
示例#22
0
 public void Suggest(uint probability, Gst.Caps caps)
 {
     gst_type_find_suggest(Handle, probability, caps == null ? IntPtr.Zero : caps.Handle);
 }
示例#23
0
 public Query(Gst.Caps caps)
 {
     Raw = gst_query_new_accept_caps(caps == null ? IntPtr.Zero : caps.Handle);
 }
示例#24
0
 public void Append(Gst.Caps caps2)
 {
     caps2.Owned = false;
     gst_caps_append(Handle, caps2 == null ? IntPtr.Zero : caps2.Handle);
 }
示例#25
0
        public static Query NewCaps(Gst.Caps filter)
        {
            Query result = new Query(gst_query_new_caps(filter == null ? IntPtr.Zero : filter.Handle));

            return(result);
        }
示例#26
0
        public static bool TypeFindRegister(Gst.Plugin plugin, string name, uint rank, Gst.TypeFindFunction func, string extensions, Gst.Caps possible_caps)
        {
            IntPtr native_name = GLib.Marshaller.StringToPtrGStrdup(name);

            GstSharp.TypeFindFunctionWrapper func_wrapper = new GstSharp.TypeFindFunctionWrapper(func);
            IntPtr data;

            GLib.DestroyNotify data_notify;
            if (func == null)
            {
                data        = IntPtr.Zero;
                data_notify = null;
            }
            else
            {
                data        = (IntPtr)GCHandle.Alloc(func_wrapper);
                data_notify = GLib.DestroyHelper.NotifyHandler;
            }
            IntPtr native_extensions = GLib.Marshaller.StringToPtrGStrdup(extensions);
            bool   raw_ret           = gst_type_find_register(plugin == null ? IntPtr.Zero : plugin.Handle, native_name, rank, func_wrapper.NativeDelegate, native_extensions, possible_caps == null ? IntPtr.Zero : possible_caps.Handle, IntPtr.Zero, data_notify);
            bool   ret = raw_ret;

            GLib.Marshaller.Free(native_name);
            GLib.Marshaller.Free(native_extensions);
            return(ret);
        }
示例#27
0
文件: Caps.cs 项目: jwzl/ossbuild
 public StructureEnumerator (Gst.Caps caps) {
   this.caps = caps;
   index = -1;
 }
示例#28
0
		protected virtual void OnFindBestFormat (Gst.Caps downstream_caps, Gst.Video.VideoInfo best_info, bool at_least_one_alpha)
		{
			InternalFindBestFormat (downstream_caps, best_info, at_least_one_alpha);
		}