another example

Original commit message from CVS:
another example
This commit is contained in:
Thomas Vander Stichele 2002-09-15 13:15:18 +00:00
parent d616f28fcd
commit 277726f4a1
3 changed files with 12 additions and 8 deletions

View file

@ -16,7 +16,7 @@
</para> </para>
<programlisting> <programlisting>
/* example-begin helloworld.c */
#include &lt;gst/gst.h&gt; #include &lt;gst/gst.h&gt;
int int
@ -27,7 +27,7 @@ main (int argc, char *argv[])
gst_init(&amp;argc, &amp;argv); gst_init(&amp;argc, &amp;argv);
if (argc != 2) { if (argc != 2) {
g_print ("usage: %s &lt;filename&gt;\n", argv[0]); g_print ("usage: %s &lt;mp3 filename&gt;\n", argv[0]);
exit (-1); exit (-1);
} }
@ -64,7 +64,7 @@ main (int argc, char *argv[])
exit (0); exit (0);
} }
/* example-end helloworld.c */
</programlisting> </programlisting>
<para> <para>
@ -72,7 +72,8 @@ main (int argc, char *argv[])
</para> </para>
<para> <para>
The first thing you have to do is to include the standard <application>GStreamer</application> headers and The first thing you have to do is to include the standard
<application>GStreamer</application> headers and
initialize the framework. initialize the framework.
</para> </para>
<programlisting> <programlisting>

View file

@ -16,7 +16,7 @@
</para> </para>
<programlisting> <programlisting>
/* example-begin helloworld.c */
#include &lt;gst/gst.h&gt; #include &lt;gst/gst.h&gt;
int int
@ -27,7 +27,7 @@ main (int argc, char *argv[])
gst_init(&amp;argc, &amp;argv); gst_init(&amp;argc, &amp;argv);
if (argc != 2) { if (argc != 2) {
g_print ("usage: %s &lt;filename&gt;\n", argv[0]); g_print ("usage: %s &lt;mp3 filename&gt;\n", argv[0]);
exit (-1); exit (-1);
} }
@ -64,7 +64,7 @@ main (int argc, char *argv[])
exit (0); exit (0);
} }
/* example-end helloworld.c */
</programlisting> </programlisting>
<para> <para>
@ -72,7 +72,8 @@ main (int argc, char *argv[])
</para> </para>
<para> <para>
The first thing you have to do is to include the standard <application>GStreamer</application> headers and The first thing you have to do is to include the standard
<application>GStreamer</application> headers and
initialize the framework. initialize the framework.
</para> </para>
<programlisting> <programlisting>

View file

@ -18,6 +18,7 @@
</para> </para>
<programlisting> <programlisting>
/* example-begin helloworld.c */
#include &lt;gst/gst.h&gt; #include &lt;gst/gst.h&gt;
static void gst_play_have_type (GstElement *typefind, GstCaps *caps, GstElement *pipeline); static void gst_play_have_type (GstElement *typefind, GstCaps *caps, GstElement *pipeline);
@ -78,6 +79,7 @@ main (int argc, char *argv[])
exit(0); exit(0);
} }
/* example-end helloworld.c */
</programlisting> </programlisting>
<para> <para>
We start by constructing a 'filesrc' element and an 'autobin' element that We start by constructing a 'filesrc' element and an 'autobin' element that