9
septembre
2012
bibliothèque gstreamer-base-plugins pour Vala
septembre
2012
Un article de Rachel
1 Commentaire
voici une liste de classes écrites en Vala, qui reprend l’espace de nom Gst.BasePlugins de gstreamer-sharp.
using Gst;
namespace Gst.BasePlugins
{
public class DecodeBin2
{
Element decodebin2;
Gst.Caps caps;
string sub;
public DecodeBin2(){decodebin2 = ElementFactory.make("decodebin2","decodebin2");}
public DecodeBin2.from_string(string name){decodebin2 = ElementFactory.make("decodebin2",name);}
public static DecodeBin2 make(){DecodeBin2 db2 = new DecodeBin2();return db2;}
public static DecodeBin2 make_from_string(string name){DecodeBin2 db2 = new DecodeBin2.from_string(name);return db2;}
public Gst.Caps Caps{
get{decodebin2.get("caps",out caps);return caps;}
set{decodebin2.set("caps",value);}
}
public Gst.Caps SinkCaps{
get{decodebin2.get("sink-caps",out caps);return caps;}
set{decodebin2.set("sink-caps",value);}
}
public string SubtitleEncoding{
get{decodebin2.get("subtitle-encoding", out sub);return sub;}
set{decodebin2.set("subtitle-encoding",value);}
}
public void AutoplugContinue (Callback connect_func){Signal.connect(decodebin2,"autoplug-contiue",connect_func,null);}
public void AutoplugFactories (Callback connect_func){Signal.connect(decodebin2,"autoplug-factories",connect_func,null);}
public void AutoplugSelect (Callback connect_func){Signal.connect(decodebin2,"autoplug-select",connect_func,null);}
public void AutoplugSort (Callback connect_func){Signal.connect(decodebin2,"autoplug-sort",connect_func,null);}
public void Drained (Callback connect_func){Signal.connect(decodebin2,"drained",connect_func,null);}
}
public class PlayBin2 : GLib.Object
{
Element playbin2;
Pad pad;
GLib.Object o;
TagList tag_list;
string uri;
double volume;
Gst.Bus bus;
Element sink;
ulong u;
int i;
uint ui;
bool mute;
public PlayBin2(){playbin2 = ElementFactory.make("playbin2","playbin2");}
public PlayBin2.from_string(string name){playbin2 = ElementFactory.make("playbin2",name);}
public static PlayBin2 make(){PlayBin2 pb2 = new PlayBin2();return pb2;}
public static PlayBin2 make_from_string(string name){PlayBin2 pb2 = new PlayBin2.from_string(name);return pb2;}
public Pad GetAudioPad (int index){Signal.emit_by_name(playbin2,"get-audio-pad",index,out pad);return pad;}
public Pad GetTextPad (int index){Signal.emit_by_name(playbin2,"get-text-pad",index,out pad);return pad;}
public Pad GetVideoPad (int index){Signal.emit_by_name(playbin2,"get-video-pad",index,out pad);return pad;}
public TagList GetAudioTags (int index){Signal.emit_by_name(playbin2,"get-audio-tags",index,out tag_list);return tag_list.copy();}
public TagList GetVideoTags (int index){Signal.emit_by_name(playbin2,"get-video-tags",index,out tag_list);return tag_list.copy();}
public TagList GetTextTags (int index){Signal.emit_by_name(playbin2,"get-text-tags",index,out tag_list);return tag_list.copy();}
public Buffer ConvertFrame (Caps caps){Signal.emit_by_name(playbin2,"convert-frame",caps,out o);return (Buffer)o;}
public string Uri{
get{playbin2.get("uri", out uri);return uri;}
set{playbin2.set("uri",value);}
}
public double Volume{
get{playbin2.get("volume",out volume);return volume;}
set{playbin2.set("volume",value);}
}
public bool Mute{
get{return mute;}
set{mute = value;if(mute){playbin2.set("volume",0);}else{playbin2.set("volume",volume);}}
}
public Element AudioSink{
get{playbin2.get("audio-sink",out sink);return sink;}
set{playbin2.set("audio-sink",value);}
}
public Element VideoSink{
get{playbin2.get("video-sink",out sink);return sink;}
set{playbin2.set("video-sink",value);}
}
public Element Source{
get{playbin2.get("source",out sink);return sink;}
set{playbin2.set("source",value);}
}
public Element SubpicSink{
get{playbin2.get("subpic-sink", out sink);return sink;}
set{playbin2.set("subpic-sink",value);}
}
public string SubtitleEncoding{
get{playbin2.get("subtitle-encoding", out uri);return uri;}
set{playbin2.set("subtitle-encoding", value);}
}
public string SubtitleFontDesc{
get{playbin2.get("subtitle-font-desc", out uri);return uri;}
set{playbin2.set("subtitle-font-desc", value);}
}
public string SubUri{
get{playbin2.get("sub-uri", out uri); return uri;}
set{playbin2.set("sub-uri", value);}
}
public Buffer Frame{get{playbin2.get("frame", out o);return (Buffer)o;}}
public int NAudio{get{playbin2.get("n-audio",out i);return i;}}
public int NVideo{get{playbin2.get("n-video",out i);return i;}}
public int NText{get{playbin2.get("n-text",out i);return i;}}
public int CurrentAudio{get{playbin2.get("current-audio",out i);return i;}}
public int CurrentVideo{get{playbin2.get("current-video",out i);return i;}}
public int CurrentText{get{playbin2.get("current-text",out i);return i;}}
public Element TextSink{
get{playbin2.get("text-sink",out sink);return sink;}
set{playbin2.set("text-sink",value);}
}
public Element VisPlugin{
get{playbin2.get("vis-plugin", out sink);return sink;}
set{playbin2.set("vis-plugin", value);}
}
public ulong BufferDuration{
get{playbin2.get("buffer-duration", out u);return u;}
set{playbin2.set("buffer-duration",value);}
}
public int BufferSize{
get{playbin2.get("buffer-size", out i);return i;}
set{playbin2.set("buffer_size", value);}
}
public uint ConnectionSpeed{
get{playbin2.get("connection-speed",out ui);return ui;}
set{playbin2.set("connection-speed",value);}
}
public Gst.Bus Bus{
get{bus = playbin2.get_bus();return bus;}
set{playbin2.bus = value;}
}
public StateChangeReturn SetState(State new_state){return playbin2.set_state(new_state);}
public StateChangeReturn GetState(out State state,out State pending,ClockTime clock_time){return playbin2.get_state(out state, out pending, clock_time);}
public State CurrentState{get{return playbin2.current_state;}}
public void AboutToFinish(Callback connect_func)
{
Signal.connect(playbin2,"about-to-finish",connect_func,null);
}
public void AudioChanged(Callback connect_func)
{
Signal.connect(playbin2,"audio-changed",connect_func,null);
}
public void VideoChanged(Callback connect_func)
{
Signal.connect(playbin2,"video-changed",connect_func,null);
}
public void TextChanged(Callback connect_func)
{
Signal.connect(playbin2,"text-changed",connect_func,null);
}
}
public class XImageSink
{
Element ximagesink;
string str;
bool b;
public XImageSink(){ximagesink = ElementFactory.make("ximagesink","ximagesink");}
public XImageSink.from_string(string name){ximagesink = ElementFactory.make("ximagesink",name);}
public static XImageSink make(){XImageSink xis = new XImageSink();return xis;}
public static XImageSink make_from_string(string name){XImageSink xis = new XImageSink.from_string(name);return xis;}
public string Display{
get{ximagesink.get("display",out str);return str;}
set{ximagesink.set("display",value);}
}
public string PixelAspectRatio{
get{ximagesink.get("pixel-aspect-ratio",out str);return str;}
set{ximagesink.set("pixel-aspect-ratio",value);}
}
public bool ForceAspectRatio{
get{ximagesink.get("force-aspect-ratio",out b);return b;}
set{ximagesink.set("force-aspect-ratio",value);}
}
public bool HandleEvents{
get{ximagesink.get("handle-events",out b);return b;}
set{ximagesink.set("handle-events",value);}
}
public bool HandleExpose{
get{ximagesink.get("handle-expose",out b);return b;}
set{ximagesink.set("handle-expose",value);}
}
public bool ShowPrerollFrame{
get{ximagesink.get("show-preroll-frame",out b);return b;}
set{ximagesink.set("show-preroll-frame",value);}
}
public bool Synchronous{
get{ximagesink.get("synchronous",out b);return b;}
set{ximagesink.set("synchronous",value);}
}
}
public class XvImageSink
{
bool b;
string str;
int i;
Element xvimagesink;
public XvImageSink(){xvimagesink = ElementFactory.make("xvimagesink","xvimagesink");}
public XvImageSink.from_string(string name){xvimagesink = ElementFactory.make("xvimagesink",name);}
public static XvImageSink make(){XvImageSink xvis = new XvImageSink();return xvis;}
public static XvImageSink make_from_string(string name){XvImageSink xvis = new XvImageSink.from_string(name);return xvis;}
public string Display{
get{xvimagesink.get("display",out str);return str;}
set{xvimagesink.set("display",value);}
}
public string PixelAspectRatio{
get{xvimagesink.get("pixel-aspect-ratio",out str);return str;}
set{xvimagesink.set("pixel-aspect-ratio",value);}
}
public bool ForceAspectRatio{
get{xvimagesink.get("force-aspect-ratio",out b);return b;}
set{xvimagesink.set("force-aspect-ratio",value);}
}
public bool HandleEvents{
get{xvimagesink.get("handle-events",out b);return b;}
set{xvimagesink.set("handle-events",value);}
}
public bool HandleExpose{
get{xvimagesink.get("handle-expose",out b);return b;}
set{xvimagesink.set("handle-expose",value);}
}
public bool ShowPrerollFrame{
get{xvimagesink.get("show-preroll-frame",out b);return b;}
set{xvimagesink.set("show-preroll-frame",value);}
}
public bool Synchronous{
get{xvimagesink.get("synchronous",out b);return b;}
set{xvimagesink.set("synchronous",value);}
}
public bool AutopaintColorkey{
get{xvimagesink.get("auto-paint-colorkey",out b);return b;}
set{xvimagesink.set("auto-paint-colorkey",value);}
}
public int Brightness{
get{xvimagesink.get("brightness",out i);return i;}
set{xvimagesink.set("brightness",value);}
}
public int Colorkey{
get{xvimagesink.get("colorkey",out i);return i;}
set{xvimagesink.set("colorkey",value);}
}
public int Contrast{
get{xvimagesink.get("contrast",out i);return i;}
set{xvimagesink.set("contrast",value);}
}
public int Hue{
get{xvimagesink.get("hue",out i);return i;}
set{xvimagesink.set("hue",value);}
}
public int Saturation{
get{xvimagesink.get("saturation",out i);return i;}
set{xvimagesink.set("saturation",value);}
}
public string Device{
get{xvimagesink.get("device",out str);return str;}
set{xvimagesink.set("device",value);}
}
public string DeviceName{
get{xvimagesink.get("device-name",out str);return str;}
set{xvimagesink.set("device-name",value);}
}
public bool DoubleBuffer{
get{xvimagesink.get("double-buffer",out b);return b;}
set{xvimagesink.set("double-buffer",value);}
}
public bool DrawBorders{
get{xvimagesink.get("draw-borders",out b);return b;}
set{xvimagesink.set("draw-borders",value);}
}
}
}
namespace Gst.BasePlugins
{
public class DecodeBin2
{
Element decodebin2;
Gst.Caps caps;
string sub;
public DecodeBin2(){decodebin2 = ElementFactory.make("decodebin2","decodebin2");}
public DecodeBin2.from_string(string name){decodebin2 = ElementFactory.make("decodebin2",name);}
public static DecodeBin2 make(){DecodeBin2 db2 = new DecodeBin2();return db2;}
public static DecodeBin2 make_from_string(string name){DecodeBin2 db2 = new DecodeBin2.from_string(name);return db2;}
public Gst.Caps Caps{
get{decodebin2.get("caps",out caps);return caps;}
set{decodebin2.set("caps",value);}
}
public Gst.Caps SinkCaps{
get{decodebin2.get("sink-caps",out caps);return caps;}
set{decodebin2.set("sink-caps",value);}
}
public string SubtitleEncoding{
get{decodebin2.get("subtitle-encoding", out sub);return sub;}
set{decodebin2.set("subtitle-encoding",value);}
}
public void AutoplugContinue (Callback connect_func){Signal.connect(decodebin2,"autoplug-contiue",connect_func,null);}
public void AutoplugFactories (Callback connect_func){Signal.connect(decodebin2,"autoplug-factories",connect_func,null);}
public void AutoplugSelect (Callback connect_func){Signal.connect(decodebin2,"autoplug-select",connect_func,null);}
public void AutoplugSort (Callback connect_func){Signal.connect(decodebin2,"autoplug-sort",connect_func,null);}
public void Drained (Callback connect_func){Signal.connect(decodebin2,"drained",connect_func,null);}
}
public class PlayBin2 : GLib.Object
{
Element playbin2;
Pad pad;
GLib.Object o;
TagList tag_list;
string uri;
double volume;
Gst.Bus bus;
Element sink;
ulong u;
int i;
uint ui;
bool mute;
public PlayBin2(){playbin2 = ElementFactory.make("playbin2","playbin2");}
public PlayBin2.from_string(string name){playbin2 = ElementFactory.make("playbin2",name);}
public static PlayBin2 make(){PlayBin2 pb2 = new PlayBin2();return pb2;}
public static PlayBin2 make_from_string(string name){PlayBin2 pb2 = new PlayBin2.from_string(name);return pb2;}
public Pad GetAudioPad (int index){Signal.emit_by_name(playbin2,"get-audio-pad",index,out pad);return pad;}
public Pad GetTextPad (int index){Signal.emit_by_name(playbin2,"get-text-pad",index,out pad);return pad;}
public Pad GetVideoPad (int index){Signal.emit_by_name(playbin2,"get-video-pad",index,out pad);return pad;}
public TagList GetAudioTags (int index){Signal.emit_by_name(playbin2,"get-audio-tags",index,out tag_list);return tag_list.copy();}
public TagList GetVideoTags (int index){Signal.emit_by_name(playbin2,"get-video-tags",index,out tag_list);return tag_list.copy();}
public TagList GetTextTags (int index){Signal.emit_by_name(playbin2,"get-text-tags",index,out tag_list);return tag_list.copy();}
public Buffer ConvertFrame (Caps caps){Signal.emit_by_name(playbin2,"convert-frame",caps,out o);return (Buffer)o;}
public string Uri{
get{playbin2.get("uri", out uri);return uri;}
set{playbin2.set("uri",value);}
}
public double Volume{
get{playbin2.get("volume",out volume);return volume;}
set{playbin2.set("volume",value);}
}
public bool Mute{
get{return mute;}
set{mute = value;if(mute){playbin2.set("volume",0);}else{playbin2.set("volume",volume);}}
}
public Element AudioSink{
get{playbin2.get("audio-sink",out sink);return sink;}
set{playbin2.set("audio-sink",value);}
}
public Element VideoSink{
get{playbin2.get("video-sink",out sink);return sink;}
set{playbin2.set("video-sink",value);}
}
public Element Source{
get{playbin2.get("source",out sink);return sink;}
set{playbin2.set("source",value);}
}
public Element SubpicSink{
get{playbin2.get("subpic-sink", out sink);return sink;}
set{playbin2.set("subpic-sink",value);}
}
public string SubtitleEncoding{
get{playbin2.get("subtitle-encoding", out uri);return uri;}
set{playbin2.set("subtitle-encoding", value);}
}
public string SubtitleFontDesc{
get{playbin2.get("subtitle-font-desc", out uri);return uri;}
set{playbin2.set("subtitle-font-desc", value);}
}
public string SubUri{
get{playbin2.get("sub-uri", out uri); return uri;}
set{playbin2.set("sub-uri", value);}
}
public Buffer Frame{get{playbin2.get("frame", out o);return (Buffer)o;}}
public int NAudio{get{playbin2.get("n-audio",out i);return i;}}
public int NVideo{get{playbin2.get("n-video",out i);return i;}}
public int NText{get{playbin2.get("n-text",out i);return i;}}
public int CurrentAudio{get{playbin2.get("current-audio",out i);return i;}}
public int CurrentVideo{get{playbin2.get("current-video",out i);return i;}}
public int CurrentText{get{playbin2.get("current-text",out i);return i;}}
public Element TextSink{
get{playbin2.get("text-sink",out sink);return sink;}
set{playbin2.set("text-sink",value);}
}
public Element VisPlugin{
get{playbin2.get("vis-plugin", out sink);return sink;}
set{playbin2.set("vis-plugin", value);}
}
public ulong BufferDuration{
get{playbin2.get("buffer-duration", out u);return u;}
set{playbin2.set("buffer-duration",value);}
}
public int BufferSize{
get{playbin2.get("buffer-size", out i);return i;}
set{playbin2.set("buffer_size", value);}
}
public uint ConnectionSpeed{
get{playbin2.get("connection-speed",out ui);return ui;}
set{playbin2.set("connection-speed",value);}
}
public Gst.Bus Bus{
get{bus = playbin2.get_bus();return bus;}
set{playbin2.bus = value;}
}
public StateChangeReturn SetState(State new_state){return playbin2.set_state(new_state);}
public StateChangeReturn GetState(out State state,out State pending,ClockTime clock_time){return playbin2.get_state(out state, out pending, clock_time);}
public State CurrentState{get{return playbin2.current_state;}}
public void AboutToFinish(Callback connect_func)
{
Signal.connect(playbin2,"about-to-finish",connect_func,null);
}
public void AudioChanged(Callback connect_func)
{
Signal.connect(playbin2,"audio-changed",connect_func,null);
}
public void VideoChanged(Callback connect_func)
{
Signal.connect(playbin2,"video-changed",connect_func,null);
}
public void TextChanged(Callback connect_func)
{
Signal.connect(playbin2,"text-changed",connect_func,null);
}
}
public class XImageSink
{
Element ximagesink;
string str;
bool b;
public XImageSink(){ximagesink = ElementFactory.make("ximagesink","ximagesink");}
public XImageSink.from_string(string name){ximagesink = ElementFactory.make("ximagesink",name);}
public static XImageSink make(){XImageSink xis = new XImageSink();return xis;}
public static XImageSink make_from_string(string name){XImageSink xis = new XImageSink.from_string(name);return xis;}
public string Display{
get{ximagesink.get("display",out str);return str;}
set{ximagesink.set("display",value);}
}
public string PixelAspectRatio{
get{ximagesink.get("pixel-aspect-ratio",out str);return str;}
set{ximagesink.set("pixel-aspect-ratio",value);}
}
public bool ForceAspectRatio{
get{ximagesink.get("force-aspect-ratio",out b);return b;}
set{ximagesink.set("force-aspect-ratio",value);}
}
public bool HandleEvents{
get{ximagesink.get("handle-events",out b);return b;}
set{ximagesink.set("handle-events",value);}
}
public bool HandleExpose{
get{ximagesink.get("handle-expose",out b);return b;}
set{ximagesink.set("handle-expose",value);}
}
public bool ShowPrerollFrame{
get{ximagesink.get("show-preroll-frame",out b);return b;}
set{ximagesink.set("show-preroll-frame",value);}
}
public bool Synchronous{
get{ximagesink.get("synchronous",out b);return b;}
set{ximagesink.set("synchronous",value);}
}
}
public class XvImageSink
{
bool b;
string str;
int i;
Element xvimagesink;
public XvImageSink(){xvimagesink = ElementFactory.make("xvimagesink","xvimagesink");}
public XvImageSink.from_string(string name){xvimagesink = ElementFactory.make("xvimagesink",name);}
public static XvImageSink make(){XvImageSink xvis = new XvImageSink();return xvis;}
public static XvImageSink make_from_string(string name){XvImageSink xvis = new XvImageSink.from_string(name);return xvis;}
public string Display{
get{xvimagesink.get("display",out str);return str;}
set{xvimagesink.set("display",value);}
}
public string PixelAspectRatio{
get{xvimagesink.get("pixel-aspect-ratio",out str);return str;}
set{xvimagesink.set("pixel-aspect-ratio",value);}
}
public bool ForceAspectRatio{
get{xvimagesink.get("force-aspect-ratio",out b);return b;}
set{xvimagesink.set("force-aspect-ratio",value);}
}
public bool HandleEvents{
get{xvimagesink.get("handle-events",out b);return b;}
set{xvimagesink.set("handle-events",value);}
}
public bool HandleExpose{
get{xvimagesink.get("handle-expose",out b);return b;}
set{xvimagesink.set("handle-expose",value);}
}
public bool ShowPrerollFrame{
get{xvimagesink.get("show-preroll-frame",out b);return b;}
set{xvimagesink.set("show-preroll-frame",value);}
}
public bool Synchronous{
get{xvimagesink.get("synchronous",out b);return b;}
set{xvimagesink.set("synchronous",value);}
}
public bool AutopaintColorkey{
get{xvimagesink.get("auto-paint-colorkey",out b);return b;}
set{xvimagesink.set("auto-paint-colorkey",value);}
}
public int Brightness{
get{xvimagesink.get("brightness",out i);return i;}
set{xvimagesink.set("brightness",value);}
}
public int Colorkey{
get{xvimagesink.get("colorkey",out i);return i;}
set{xvimagesink.set("colorkey",value);}
}
public int Contrast{
get{xvimagesink.get("contrast",out i);return i;}
set{xvimagesink.set("contrast",value);}
}
public int Hue{
get{xvimagesink.get("hue",out i);return i;}
set{xvimagesink.set("hue",value);}
}
public int Saturation{
get{xvimagesink.get("saturation",out i);return i;}
set{xvimagesink.set("saturation",value);}
}
public string Device{
get{xvimagesink.get("device",out str);return str;}
set{xvimagesink.set("device",value);}
}
public string DeviceName{
get{xvimagesink.get("device-name",out str);return str;}
set{xvimagesink.set("device-name",value);}
}
public bool DoubleBuffer{
get{xvimagesink.get("double-buffer",out b);return b;}
set{xvimagesink.set("double-buffer",value);}
}
public bool DrawBorders{
get{xvimagesink.get("draw-borders",out b);return b;}
set{xvimagesink.set("draw-borders",value);}
}
}
}
[…] à ce précédent post, (inspiré de l’espace de nom en c#) je propose d’aller plus […]