GStreamer is a pipeline based multimedia framework written in the C programming language with the type system based on GObject . GStreamer allows you to create a variety of media-handling components , including simple audio playback , audio and video playback, recording, streaming , and editing. The pipeline design serves as a base to create many types of multimedia applications such as video editors , streaming media broadcasters , and media players .
- 所有操作的前提是你已经配置好了GCC开发环境, gstreamer是一个开源多媒体框架,可以很容易的 开发多媒体程序.
- 在UBUNTU中构建 gstreamer 开发环境非常简单 ,使用下面命令安装gstreamer这样就可以了.
- sudo apt-get install gstreamer0.10-tools gstreamer0.10-x gstreamer0.10-plugins-base gstreamer0.10-plugins-good gstreamer0.10-plugins-ugly gstreamer0.10-plugins-bad gstreamer0.10-ffmpeg gstreamer0.10-alsa gstreamer0.10-schroedinger gstreamer0.10-pulseaudio
-
只是编译是要注意下,需要借助 pkg-config
下面是段测试代码:
//////////////////////////////////////////
//////////////mu.c////////////////////////////
#include <gst/gst.h>
int
main (int argc,
char *argv[])
{
const gchar *nano_str;
guint major, minor, micro, nano;
gst_init (&argc, &argv);
gst_version (&major, &minor, µ, &nano);
if (nano == 1)
nano_str = "(CVS)";
else if (nano == 2)
nano_str = "(Prerelease)";
else
nano_str = "";
printf ("This program is linked against GStreamer %d.%d.%d %s/n",
major, minor, micro, nano_str);
return 0;
}
//////////////////////////////////////////
//////////////////////////////////////////
编译命令: gcc -Wall mu.c `pkg-config "gstreamer-0.10" --cflags --libs`
l@l-desktop:~/workspace/gstmu$ ls
a.out mu.c
l@l-desktop:~/workspace/gstmu$ ./a.out
This program is linked against GStreamer 0.10.21
成功则输出 :This program is linked against GStreamer 0.10.21
这里是 Application Development Manual
http://gstreamer.freedesktop.org/data/doc/gstreamer/head/manual/html/index.html
从这里可以得到更多资料
We have a website at
http://gstreamer.freedesktop.org/
You should start by going through our FAQ at
http://gstreamer.freedesktop.org/data/doc/gstreamer/head/faq/html/
There is more documentation; go to
http://gstreamer.freedesktop.org/documentation
You can subscribe to our mailing lists; see the website for details.
We track bugs in GNOME's bugzilla; see the website for details.
You can join us on IRC - #gstreamer on irc.freenode.org
GStreamer 0.10 series