Tizen 2.0 Release
[framework/multimedia/gst-plugins-bad0.10.git] / gst / gaudieffects / burn-example.py
1 #!/usr/bin/python
2 import gobject; gobject.threads_init()
3 import pygst; pygst.require("0.10")
4 import gst
5
6 p = gst.parse_launch ("""
7    v4l2src !
8    ffmpegcolorspace ! queue ! video/x-raw-rgb,width=320,height=240,framerate=30/1 ! burn qos=true name=vf ! ffmpegcolorspace !
9    timeoverlay ! xvimagesink
10    """)
11
12 m = p.get_by_name ("vf")
13 m.set_property ("adjustment", 128)
14
15 control = gst.Controller(m, "adjustment")
16 control.set_interpolation_mode("adjustment", gst.INTERPOLATE_LINEAR)
17 control.set("adjustment", 0 * gst.SECOND, 128)
18 control.set("adjustment", 5 * gst.SECOND, 256)
19 control.set("adjustment", 25 * gst.SECOND, 0)
20
21 p.set_state (gst.STATE_PLAYING)
22
23 gobject.MainLoop().run()