Maintenance will be performed on git.ligo.org, chat.ligo.org, containers.ligo.org, and docs.ligo.org on Tuesday 22nd September 2020 starting at approximately 9am MST.It is expected to take around 15 minutes and there will be a short period of downtime towards the end of the maintenance window. Please address any comments, questions, or concerns to computing-help@igwn.org.

Commit 2cdd771a authored by kipp's avatar kipp

Initial checkin.

parents
#!/bin/sh
# Check with the user
echo "This script (re-)builds the source tree's configuration and build system."
read -p "Press CTRL-C to abort, or RETURN to continue... "
# Get it done
{
{ echo "running aclocal (please ignore \"underquoted\" warnings)..." ; aclocal ; } &&
#{ echo "running autoheader..." ; autoheader ; } &&
{ echo "running automake..." ; automake -a -c ; } &&
{ echo "running autoconf..." ; autoconf ; } &&
echo "$0 complete." ;
} || { echo "$0 failed." ; false ; }
This diff is collapsed.
SUBDIRS = src
#
# Preamble
#
AC_INIT([gstlal],[0.1.0],[kcannon@ligo.caltech.edu],[gstlal])
AC_COPYRIGHT([Copyright (C) 2008 Kipp C. Cannon])
# a file whose existance can be used to use to check that we are in the
# top-level directory of the source tree
AC_CONFIG_SRCDIR([gnuscripts/ltmain.sh])
AC_CONFIG_AUX_DIR([gnuscripts])
AM_INIT_AUTOMAKE([foreign])
AC_CONFIG_FILES([ \
Makefile \
src/Makefile \
src/plugins/Makefile \
src/utilities/Makefile \
])
#
# Documentation boilerplate
#
AC_SUBST([docdir], [${datadir}/doc])
AC_SUBST([pkgdocdir], [${docdir}/${PACKAGE_NAME}-${PACKAGE_VERSION}])
#
# Check for programs
#
AC_PROG_CC
AC_PROG_INSTALL
AC_PROG_LIBTOOL
PKG_PROG_PKG_CONFIG()
#
# CFLAGS
#
AC_SUBST([AM_CFLAGS], [-Wall])
#
# Check for GStreamer 0.10
#
AC_SUBST([GSTREAMER_RELEASE], [0.10])
AC_SUBST([MIN_GSTREAMER_VERSION], [0.10.0])
PKG_CHECK_MODULES([gstreamer], [gstreamer-${GSTREAMER_RELEASE} >= ${MIN_GSTREAMER_VERSION} gstreamer-base-${GSTREAMER_RELEASE} >= ${MIN_GSTREAMER_VERSION}], , [echo "Not Found!" ; exit 1])
AC_SUBST([gstreamer_CFLAGS])
AC_SUBST([gstreamer_LIBS])
AC_SUBST([plugindir], [${libdir}/gstreamer-${GSTREAMER_RELEASE}])
AC_SUBST([GSTREAMER_PLUGIN_LDFLAGS], ["-module -avoid-version -export-symbols-regex [_]*\(gst_\|Gst\|GST_\).*"])
#
# Check for LAL
#
PKG_CHECK_MODULES([LAL], [lal lalframe lalmetaio lalsupport], , [echo "Not Found!" ; exit 1])
AC_SUBST([LAL_CFLAGS])
AC_SUBST([LAL_LIBS])
#
# Output configure information
#
AC_PROG_MAKE_SET
AC_OUTPUT
# A gst-launch pipeline to encode h(t) into a OGG/Vorbis file
LALCACHE="/home/kipp/scratch_local/874000000-20063/cache/data.cache"
GPSSTART="874000000"
#GPSSTOP="874020000"
GPSSTOP="874000120"
INSTRUMENT="H1"
CHANNEL="LSC-STRAIN"
OUTPUT="hoft.ogm"
gst-launch \
lal_framesrc \
blocksize=65536 \
location="${LALCACHE}" \
instrument="${INSTRUMENT}" \
channel-name="${CHANNEL}" \
start-time-gps="${GPSSTART}" \
stop-time-gps="${GPSSTOP}" \
! audioconvert \
! audio/x-raw-float, width=64 \
! audiochebband \
lower-frequency=45 \
upper-frequency=2500 \
poles=8 \
! audioconvert \
! audio/x-raw-float, width=32 \
! audioamplify \
amplification=2e+17 \
! progressreport \
update-freq=2 \
! vorbisenc \
! oggmux \
! filesink \
location="${OUTPUT}"
# A gst-launch pipeline to play AS_Q through a sound card.
LALCACHE="/home/kipp/scratch_local/874000000-20063/cache/data.cache"
GPSSTART="874000000"
GPSSTOP="874020000"
INSTRUMENT="H1"
CHANNEL="LSC-AS_Q"
gst-launch \
lal_framesrc \
blocksize=65536 \
location="${LALCACHE}" \
instrument="${INSTRUMENT}" \
channel-name="${CHANNEL}" \
start-time-gps="${GPSSTART}" \
stop-time-gps="${GPSSTOP}" \
! queue \
! audioconvert \
! audio/x-raw-float, width=64 \
! audiochebband \
lower-frequency=40 \
upper-frequency=2500 \
poles=8 \
! audioconvert \
! audio/x-raw-float, width=32 \
! audioamplify \
amplification=3e-1 \
! audioconvert \
! alsasink
# A gst-launch pipeline to play h(t) through a sound card.
LALCACHE="/home/kipp/scratch_local/874000000-20063/cache/data.cache"
GPSSTART="874000000"
GPSSTOP="874020000"
INSTRUMENT="H1"
CHANNEL="LSC-STRAIN"
gst-launch \
lal_framesrc \
blocksize=65536 \
location="${LALCACHE}" \
instrument="${INSTRUMENT}" \
channel-name="${CHANNEL}" \
start-time-gps="${GPSSTART}" \
stop-time-gps="${GPSSTOP}" \
! queue \
! audioconvert \
! audio/x-raw-float, width=64 \
! audiochebband \
lower-frequency=45 \
upper-frequency=2500 \
poles=8 \
! audioconvert \
! audio/x-raw-float, width=32 \
! audioamplify \
amplification=2e+17 \
! audioconvert \
! alsasink
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
SUBDIRS = plugins utilities
plugin_LTLIBRARIES = libgstlal.la
libgstlal_la_SOURCES = gstlal.h gstlal.c gstlal_framesrc.h gstlal_framesrc.c
libgstlal_la_CFLAGS = $(AM_CFLAGS) ${gstreamer_CFLAGS} ${LAL_CFLAGS}
libgstlal_la_LIBADD = ${gstreamer_LIBS} ${LAL_LIBS}
libgstlal_la_LDFLAGS = ${GSTREAMER_PLUGIN_LDFLAGS}
noinst_HEADERS = gstlal.h
/*
* Various bits of LAL wrapped in gstreamer elements.
*
* Copyright (C) 2008 Kipp C. Cannon
*
* 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.
*
* 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.
*
* 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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
/*
* ============================================================================
*
* Preamble
*
* ============================================================================
*/
#include <gst/gst.h>
#include <gstlal.h>
#include <gstlal_framesrc.h>
/*
* ============================================================================
*
* Data
*
* ============================================================================
*/
/*
* types is a 0-terminated array of type constants. e.g.,
*
* caps = gstlal_get_template_caps({G_TYPE_INT, 0});
*/
GstCaps *gstlal_get_template_caps(const GType *types)
{
GstCaps *caps = gst_caps_new_empty();
/*
* 1073741824 = 2^30, the highest power of two that won't roll-over
* a 32-bit signed integer
*/
while(*types) {
switch(*types++) {
case G_TYPE_FLOAT:
gst_caps_append(caps, gst_caps_new_simple(
"audio/x-raw-float",
"rate", GST_TYPE_INT_RANGE, 1, 1073741824,
"channels", G_TYPE_INT, 1,
"endianness", G_TYPE_INT, G_BYTE_ORDER,
"width", G_TYPE_INT, 32,
NULL
));
break;
case G_TYPE_DOUBLE:
gst_caps_append(caps, gst_caps_new_simple(
"audio/x-raw-float",
"rate", GST_TYPE_INT_RANGE, 1, 1073741824,
"channels", G_TYPE_INT, 1,
"endianness", G_TYPE_INT, G_BYTE_ORDER,
"width", G_TYPE_INT, 64,
NULL
));
break;
case G_TYPE_INT:
gst_caps_append(caps, gst_caps_new_simple(
"audio/x-raw-int",
"rate", GST_TYPE_INT_RANGE, 1, 1073741824,
"channels", G_TYPE_INT, 1,
"endianness", G_TYPE_INT, G_BYTE_ORDER,
"width", G_TYPE_INT, 32,
"depth", G_TYPE_INT, 32,
"signed", G_TYPE_BOOLEAN, TRUE,
NULL
));
break;
}
}
return caps;
}
/*
* ============================================================================
*
* Plugin Entry Point
*
* ============================================================================
*/
static gboolean plugin_init(GstPlugin *plugin)
{
struct {
const gchar *name;
GType (*type)(void);
} *element, elements[] = {
{"lal_framesrc", gstlal_framesrc_get_type},
{NULL, NULL},
};
/* tell gstreamer about the elements */
for(element = elements; element->name; element++)
if(!gst_element_register(plugin, element->name, GST_RANK_NONE, element->type()))
return FALSE;
return TRUE;
}
/*
* This is the structure that gst-register looks for.
*/
GST_PLUGIN_DEFINE(GST_VERSION_MAJOR, GST_VERSION_MINOR, "gstlal", "Various bits of the LIGO Algorithm Library wrapped in gstreamer elements", plugin_init, PACKAGE_VERSION, "GPL", PACKAGE_NAME, "http://www.lsc-group.phys.uwm.edu/daswg")
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment