summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2004-10-27 22:45:31 +0000
committerLennart Poettering <lennart@poettering.net>2004-10-27 22:45:31 +0000
commit4be3e6fdbf067f75eed9ba59e2768890f6b317fa (patch)
tree2224a4cc76a575882e29991c4a9d6bbcb834a9f6
parent16d8cdb78f70d967547e329279100a8640889e13 (diff)
prepare next release
git-svn-id: file:///home/lennart/svn/public/gst-pulse/trunk@6 bb39ca4e-bce3-0310-b5d4-eea78a553289
-rw-r--r--Makefile.am4
-rw-r--r--configure.ac10
-rw-r--r--doc/Makefile.am36
-rw-r--r--doc/README.html.in108
-rw-r--r--doc/style.css34
-rw-r--r--doc/todo6
-rw-r--r--src/Makefile.am24
-rw-r--r--src/polypsink.c49
8 files changed, 246 insertions, 25 deletions
diff --git a/Makefile.am b/Makefile.am
index 5ab9c3c..22a5b47 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -26,8 +26,8 @@ noinst_DATA = README
README:
rm -f README
-# $(MAKE) -C doc README
-# cd $(srcdir) && ln -s doc/README README
+ $(MAKE) -C doc README
+ cd $(srcdir) && ln -s doc/README README
homepage: all dist
test -d $$HOME/homepage/private
diff --git a/configure.ac b/configure.ac
index 24a169b..217ad2f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -20,7 +20,7 @@
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
AC_PREREQ(2.57)
-AC_INIT([gst-polyp],[0.2],[mzkzzfcbylc (at) 0pointer (dot) de])
+AC_INIT([gst-polyp],[0.1],[mzkzzfcbylc (at) 0pointer (dot) de])
AC_CONFIG_SRCDIR([src/plugin.c])
AC_CONFIG_HEADERS([config.h])
AM_INIT_AUTOMAKE([foreign -Wall])
@@ -47,10 +47,10 @@ ACX_PTHREAD
if test -d ../polypaudio ; then
POLYP_CFLAGS='-I$(top_srcdir)/../polypaudio'
- POLYP_LIBS='-L$(top_srcdir)/../polypaudio/polyp -lpolyp-0.5 -lpolyp-error-0.5 -lpolyp-mainloop-0.5'
+ POLYP_LIBS='-L$(top_srcdir)/../polypaudio/polyp -lpolyp-0.6 -lpolyp-error-0.6 -lpolyp-mainloop-0.6'
echo "*** Found polypaudio in ../polypaudio, using that version ***"
else
- PKG_CHECK_MODULES(POLYP, [ polyplib >= 0.5 ])
+ PKG_CHECK_MODULES(POLYP, [ polyplib >= 0.6 ])
fi
AC_SUBST(POLYP_LIBS)
@@ -60,7 +60,7 @@ PKG_CHECK_MODULES(GST, [ gstreamer-0.8 >= 0.8.4 ])
AC_SUBST(GST_LIBS)
AC_SUBST(GST_CFLAGS)
-y
+
# If using GCC specifiy some additional parameters
if test "x$GCC" = "xyes" ; then
CFLAGS="$CFLAGS -pipe -Wall -W -Wno-unused-parameter"
@@ -85,5 +85,5 @@ fi
AM_CONDITIONAL([USE_LYNX], [test "x$lynx" = xyes])
-AC_CONFIG_FILES([Makefile src/Makefile]) # doc/Makefile doc/README.html])
+AC_CONFIG_FILES([Makefile src/Makefile doc/Makefile doc/README.html])
AC_OUTPUT
diff --git a/doc/Makefile.am b/doc/Makefile.am
new file mode 100644
index 0000000..86a684f
--- /dev/null
+++ b/doc/Makefile.am
@@ -0,0 +1,36 @@
+# $Id$
+
+# This file is part of gst-polyp.
+#
+# gst-polyp is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# gst-polyp is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with gst-polyp; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+
+noinst_DATA = README.html README
+EXTRA_DIST = $(noinst_DATA) style.css README.html.in
+
+MAINTAINERCLEANFILES = README README.html
+CLEANFILES =
+
+if USE_LYNX
+README: README.html
+ lynx --dump $^ | sed 's,file://localhost/.*/doc/README.html,README,' > $@
+
+CLEANFILES += README
+endif
+
+tidy: README.html
+ tidy -e < README.html
+
+.PHONY: tidy
+
diff --git a/doc/README.html.in b/doc/README.html.in
new file mode 100644
index 0000000..6e5057c
--- /dev/null
+++ b/doc/README.html.in
@@ -0,0 +1,108 @@
+<?xml version="1.0" encoding="iso-8859-1"?> <!-- -*-html-helper-*- -->
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+<head>
+<title>gst-polyp @PACKAGE_VERSION@</title>
+<link rel="stylesheet" type="text/css" href="style.css" />
+</head>
+
+<body>
+<h1><a name="top">gst-polyp @PACKAGE_VERSION@</a></h1>
+
+<p><i>Copyright 2004 Lennart Poettering &lt;@PACKAGE_BUGREPORT@&gt;</i></p>
+
+<ul class="toc">
+ <li><a href="#license">License</a></li>
+ <li><a href="#news">News</a></li>
+ <li><a href="#overview">Overview</a></li>
+ <li><a href="#status">Status</a></li>
+ <li><a href="#documentation">Documentation</a></li>
+ <li><a href="#requirements">Requirements</a></li>
+ <li><a href="#installation">Installation</a></li>
+ <li><a href="#acks">Acknowledgements</a></li>
+ <li><a href="#download">Download</a></li>
+</ul>
+
+<h2><a name="license">License</a></h2>
+
+<p>This program is free software; you can redistribute it and/or
+modify it under the terms of the GNU General Public License as
+published by the Free Software Foundation; either version 2 of the
+License, or (at your option) any later version.</p>
+
+<p>This program is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.</p>
+
+<p>You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.</p>
+
+<h2><a name="news">News</a></h2>
+
+<div class="news-date">Thu Oct 28 2004: </div> <p class="news-text"><a
+href="@PACKAGE_URL@gst-polyp-0.1.tar.gz">Version 0.1</a> released</p>
+
+<h2><a name="overview">Overview</a></h2>
+
+<p><tt>gst-polyp</tt> is a <a href="http://www.gstreamer.net/">GStreamer 0.8</a> sink for the <a href="http://0pointer.de/lennart/projects/polypaudio/"><tt>polypaudio</tt></a> sound server.</p>
+
+<h2><a name="status">Status</a></h2>
+
+<p>It ist tested and works quite fine with Rhythmbox. However, there's much room for improvements:</p>
+
+<ul>
+ <li>There is no source for recording yet, only an output sink.</li>
+ <li>The polypaudio stream clock is not yet exported to the GStreamer API.</li>
+ <li>The latency information is not yet exported to the GStreamer API</li>
+ <li>Volume manipulation via the GStreamer API is not yet impemented</li>
+</ul>
+
+<h2><a name="documentation">Documentation</a></h2>
+
+<p>There is not much to say. Just install this software, the driver is than available as <tt>polypsink</tt>.</p>
+
+<h2><a name="requirements">Requirements</a></h2>
+
+<p>Currently, <tt>gst-polyp</tt> is tested on Linux only.</p>
+
+<p><tt>gst-polyp</tt> was developed and tested on Debian GNU/Linux
+"testing" from October 2004, it should work on most other Linux
+distributions (and maybe Unix versions) since it uses GNU autoconf for
+source code configuration.</p>
+
+<p>Obviously <tt>gst-polyp</tt> requires an installation of
+<tt>polypaudio</tt> (version 0.6) and <tt>gstreamer</tt> 0.8.x.</p>
+
+<h2><a name="installation">Installation</a></h2>
+
+<p>As this package is made with the GNU autotools you should run
+<tt>./configure</tt> inside the distribution directory for configuring
+the source tree. After that you should run <tt>make</tt> for
+compilation and <tt>make install</tt> (as root) for installation of
+<tt>gst-polyp</tt>.</p>
+
+<h2><a name="acks">Acknowledgements</a></h2>
+
+<p>None so far.</p>
+
+<h2><a name="download">Download</a></h2>
+
+<p>The newest release is always available from <a href="@PACKAGE_URL@">@PACKAGE_URL@</a></p>
+
+<p>The current release is <a href="@PACKAGE_URL@gst-polyp-@PACKAGE_VERSION@.tar.gz">@PACKAGE_VERSION@</a></p>
+
+<p>Get <tt>gst-polyp</tt>'s development sources from the <a href="http://subversion.tigris.org/">Subversion</a> <a href="svn://seth.intheinter.net/gst-polyp">repository</a> (<a href="http://0pointer.de/cgi-bin/viewcvs.cgi/?root=gst-polyp">viewcvs</a>): </p>
+
+<pre>svn checkout svn://seth.intheinter.net/gst-polyp/trunk gst-polyp</pre>
+
+<p>If you want to be notified whenever I release a new version of this software use the subscription feature of <a href="http://freshmeat.net/projects/gst-polyp/">Freshmeat</a>.</p>
+
+<hr/>
+<address class="grey">Lennart Poettering &lt;@PACKAGE_BUGREPORT@&gt;, October 2004</address>
+<div class="grey"><i>$Id$</i></div>
+
+</body>
+</html>
diff --git a/doc/style.css b/doc/style.css
new file mode 100644
index 0000000..a929242
--- /dev/null
+++ b/doc/style.css
@@ -0,0 +1,34 @@
+/* $Id$ */
+
+/***
+ * This file is part of gst-polyp.
+ *
+ * gst-polyp is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * gst-polyp is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with gst-polyp; if not, write to the Free Software Foundation,
+ * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+ ***/
+
+body { color: black; background-color: white; margin: 0.5cm; }
+a:link, a:visited { color: #900000; }
+p { margin-left: 0.5cm; margin-right: 0.5cm; }
+div.news-date { margin-left: 0.5cm; font-size: 80%; color: #4f0000; }
+p.news-text { margin-left: 1cm; }
+h1 { color: #00009F; }
+h2 { color: #00009F; }
+h3 { color: #00004F; margin-left: 0.5cm; }
+ul { margin-left: .5cm; }
+ol { margin-left: .5cm; }
+pre { margin-left: .5cm; background-color: #f0f0f0; padding: 0.4cm;}
+.grey { color: #afafaf; }
+table { margin-left: 1cm; border:1px solid lightgrey; padding: 0.2cm; }
+td { padding-left:10px; padding-right:10px; }
diff --git a/doc/todo b/doc/todo
new file mode 100644
index 0000000..72b9c56
--- /dev/null
+++ b/doc/todo
@@ -0,0 +1,6 @@
+* polypsource
+* mixer interface
+* latency measurement
+* timer
+
+$Id$
diff --git a/src/Makefile.am b/src/Makefile.am
index 1bd1fae..8027091 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1,14 +1,34 @@
+# $Id$
+#
+# This file is part of gst-polyp.
+#
+# gst-polyp is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# gst-polyp is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with gst-polyp; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+# USA.
+
plugindir=/tmp/
-plugin_LTLIBRARIES = libgstpolyp.la
+pkglib_LTLIBRARIES = libgstpolyp.la
libgstpolyp_la_SOURCES = plugin.c polypsink.c
libgstpolyp_la_CFLAGS = $(GST_CFLAGS) $(POLYP_CFLAGS)
libgstpolyp_la_LIBADD = $(POLYP_LIBS) $(GST_LIBS)
+install-exec-hook: reg
reg:
- gst-register-0.8 --gst-plugin-path=`pwd`
+ gst-register-0.8 --gst-plugin-path=$(pkglibdir)
inspect:
gst-inspect-0.8 polypsink
diff --git a/src/polypsink.c b/src/polypsink.c
index 70f5b41..6376662 100644
--- a/src/polypsink.c
+++ b/src/polypsink.c
@@ -29,25 +29,25 @@ static void gst_polypsink_base_init(gpointer g_class) {
GST_PAD_ALWAYS,
GST_STATIC_CAPS(
"audio/x-raw-int, "
- "endianness = (int) 1234, " /*{ LITTLE_ENDIAN , BIG_ENDIAN }, "*/
+ "endianness = (int) { LITTLE_ENDIAN , BIG_ENDIAN }, "
"signed = (boolean) TRUE, "
"width = (int) 16, "
"depth = (int) 16, "
- "rate = (int) 44100, " /*[ 1000, 192000 ], "*/
- "channels = (int) [ 1, 16 ]" /*[ 1, 16 ];"*/
-
-/* "audio/x-raw-float, " */
-/* "endianness = (int) { LITTLE_ENDIAN, BIG_ENDIAN }, " */
-/* "width = (int) 32, " */
-/* "rate = (int) [ 1000, 192000 ], " */
-/* "channels = (int) [ 1, 16 ];" */
+ "rate = (int) [ 1, MAX ], "
+ "channels = (int) [ 1, 16 ];"
+
+ "audio/x-raw-float, "
+ "endianness = (int) { LITTLE_ENDIAN, BIG_ENDIAN }, "
+ "width = (int) 32, "
+ "rate = (int) [ 1, MAX ], "
+ "channels = (int) [ 1, 16 ];"
-/* "audio/x-raw-int, " */
-/* "signed = (boolean) FALSE, " */
-/* "width = (int) 8, " */
-/* "depth = (int) 8, " */
-/* "rate = (int) [ 1000, 192000 ], " */
- /* "channels = (int) [ 1, 16 ]"*/)
+ "audio/x-raw-int, "
+ "signed = (boolean) FALSE, "
+ "width = (int) 8, "
+ "depth = (int) 8, "
+ "rate = (int) [ 1, MAX ], "
+ "channels = (int) [ 1, 16 ]")
);
static const GstElementDetails details = {
@@ -294,7 +294,7 @@ static void create_stream(GstPolypSink *polypsink) {
pa_stream_set_state_callback(polypsink->stream, stream_state_callback, polypsink);
pa_stream_set_write_callback(polypsink->stream, stream_write_callback, polypsink);
- pa_stream_connect_playback(polypsink->stream, NULL, NULL, PA_VOLUME_NORM);
+ pa_stream_connect_playback(polypsink->stream, NULL, NULL, 0, PA_VOLUME_NORM);
}
static void create_context(GstPolypSink *polypsink) {
@@ -506,6 +506,22 @@ static GstPadLinkReturn gst_polypsink_link(GstPad *pad, const GstCaps *caps) {
return GST_PAD_LINK_OK;
}
+static GstCaps* gst_polypsink_sink_fixate(GstPad *pad, const GstCaps *caps) {
+ GstCaps *newcaps;
+ GstStructure *structure;
+
+ newcaps = gst_caps_new_full(gst_structure_copy(gst_caps_get_structure(caps, 0)), NULL);
+ structure = gst_caps_get_structure(newcaps, 0);
+
+ if (gst_caps_structure_fixate_field_nearest_int (structure, "rate", 44100) ||
+ gst_caps_structure_fixate_field_nearest_int (structure, "depth", 16) ||
+ gst_caps_structure_fixate_field_nearest_int (structure, "width", 16) ||
+ gst_caps_structure_fixate_field_nearest_int (structure, "channels", 2))
+ return newcaps;
+
+ gst_caps_free (newcaps);
+ return NULL;
+}
static void gst_polypsink_init(GTypeInstance* instance, gpointer g_class) {
GstPolypSink *polypsink = GST_POLYPSINK(instance);
@@ -517,6 +533,7 @@ static void gst_polypsink_init(GTypeInstance* instance, gpointer g_class) {
gst_element_add_pad(GST_ELEMENT(polypsink), polypsink->sinkpad);
gst_pad_set_chain_function(polypsink->sinkpad, gst_polypsink_chain);
gst_pad_set_link_function(polypsink->sinkpad, gst_polypsink_link);
+ gst_pad_set_fixate_function (polypsink->sinkpad, gst_polypsink_sink_fixate);
/* GST_FLAG_SET(polypsink, GST_ELEMENT_THREAD_SUGGESTED); */
GST_FLAG_SET(polypsink, GST_ELEMENT_EVENT_AWARE);