It is getting more number of applications use GStreamer for video playing. That include few webcam applications (e.g. Cheese) and computer vision software (e.g. Lasertraq). Although they are working fine , they usually lack a user interface to tune camera parameter. User may only use default camera parameter unless they know how to construct GStreamer pipeline description, which is too complicated for end-user.
Example of pipeline description:
# Capture image from a webcam with resolution of 320x240 and 30fps.The usage of rvtk-gst-pg is quite similar to zenity. It will display few Gtk+ dialogs , and return the user input to standard output for shell scripting:
gst-launch-0.10 -v v4l2src name=source queue-size=2 ! video/x-raw-yuv,width=320,height=240,framerate=30/1 ! ffmpegcolorspace ! ximagesink
# Play a AVI file.
gst-launch-0.10 filesrc location=video.avi ! decodebin ! ffmpegcolorspace ! ximagesink
$ rvtk-gst-pg --helpExample script: play video from webcam or local media by gst-launch:
Usage:
rvtk-gst-pg [OPTION...] [sink element]
Help Options:
-?, --help Show help options
--help-all Show all help options
--help-gtk Show GTK+ Options
Application Options:
-v, --var Export variable name
--display=DISPLAY X display to use
PIPELINE=`rvtk-gst-pg xvimagesink`Firstly, it will prompt a dialog to ask for the location of media source. The first tab contains the detected capture device list , another tab shows a file selection browser to choose their local media file.
if [ ! -z "$PIPELINE" ]
then
gst-launch $PIPELINE
fi
If a capture device is chosen , it will prompt another dialog for more options of capture device. That include the image format , resolution and FPS.
Finally , rvtk-gst-pg will print out the pipeline description according to the media chosen and the passed argument to standard output.
Example video : rvtk-gst-pd + levelhead
Although Rvtk 0.3 is not released yet , the source of rvtk-gst-pg is already available in Launchpad: https://code.launchpad.net/rvtk