--- fslview-3.1.2+4.1.4.orig/doc/fslview/atlas.html +++ fslview-3.1.2+4.1.4/doc/fslview/atlas.html @@ -7,7 +7,7 @@

Anatomical atlas tools

These tools provide feedback via various atlases included in the + href="atlas-descriptions.html">atlases included in the FSL/FSLView distributions. Labels from selected atlases can be displayed, summary images overlaid, structures located and single structure probabilty maps shown.

--- fslview-3.1.2+4.1.4.orig/doc/fslview/atlas-reference.html +++ fslview-3.1.2+4.1.4/doc/fslview/atlas-reference.html @@ -0,0 +1,94 @@ + + + + Atlas Reference + + +

The atlas tool data and file format reference

+ +

Introduction

+ +

+ The atlas data is represented by a set of image files (e.g. 3/4D + NIFTI files) along with an atlas description file in XML. The + image files contain voxel classification values while the XML + file caries the associated label and summary image information. +

+ +

Atlases come in two flavours: + +

+

+ +

XML Specification

+ + + + + + + + + + + + + + + + + + + + +
Tag nameDescriptionAttributes
Tags in header section
nameA text sting to be displayed in any tools when refering to this atlas.
typeProbabilistic, Label.
imagefileRelative path to the location of the atlas image
summaryimagefileRelative path to the location of the atlas summary image
Tags in data section
labelText corresponding to this volume's label +
+
index
+
x
+
y
+
z
+
+
+ +
Example
+ +
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<atlas version="1.0">
+  <header>
+    <name>MNI Structural Probability Atlas</name>
+    <type>Probabalistic</type>
+    <images>
+      <imagefile>/MNI/MNI-prob-2mm</imagefile>
+      <summaryimagefile>/MNI/MNI-maxprob-thr25-2mm</summaryimagefile>
+    <images>
+  </header>
+  <data>
+    <label index="0" x="39" y="73" z="35">Caudate</label>
+    <label index="1" x="34" y="32" z="15">Cerebellum</label>
+    <label index="2" x="45" y="90" z="29">Frontal Lobe</label>
+    <label index="3" x="27" y="73" z="30">Insula</label>
+    <label index="4" x="50" y="20" z="37">Occipital Lobe</label>
+    <label index="5" x="45" y="33" z="61">Parietal Lobe</label>
+    <label index="6" x="56" y="69" z="34">Putamen</label>
+    <label index="7" x="16" y="53" z="35">Temporal Lobe</label>
+    <label index="8" x="48" y="55" z="38">Thalamus</label>
+  </data>
+</atlas>
+
+ + +

Hints and tips for atlas developers

+ + + + + --- fslview-3.1.2+4.1.4.orig/doc/fslview/atlas-descriptions.html +++ fslview-3.1.2+4.1.4/doc/fslview/atlas-descriptions.html @@ -0,0 +1,223 @@ + + + + FSL + + +

Brain Atlases included with FSL

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+

Harvard-Oxford cortical and subcortical structural atlases

+

Probabilistic atlases covering 48 cortical and 21 + subcortical structural areas, derived from structural data + and segmentations kindly provided by + the Harvard + Center for Morphometric Analysis.

+

T1-weighted images of 21 healthy male and 16 healthy + female subjects (ages 18-50) were individually segmented + by the CMA using semi-automated tools developed + in-house. The T1-weighted images were affine-registered to + MNI152 space using FLIRT (FSL), and the transforms then + applied to the individual labels. Finally, these were + combined across subjects to form population probability + maps for each label.

+

We are very grateful to the following for providing the + segmentations used to create these atlases: David Kennedy + and Christian + Haselgrove, Centre for + Morphometric Analysis, Harvard; Bruce Fischl, + the Martinos Center + for Biomedical Imaging, MGH (NIH grants + P41-RR14075, R01 RR16594-01A1, R01 NS052585-01); Janis + Breeze and Jean Frazier from + the Child + and Adolescent Neuropsychiatric Research Program, + Cambridge Health Alliance; Larry Seidman and Jill + Goldstein from + the Department of + Psychiatry of Harvard Medical School.

+
+

+

Jülich histological (cyto- and myelo-architectonic) atlas

+ +

A probabilistic atlas created by averaging multi-subject + post-mortem cyto- and myelo-architectonic segmentations, + performed by the team of Profs Zilles and Amunts at the Research + Center Jülich and kindly provided by Simon + Eickhoff.

+ +

The atlas contains 32 grey matter structures and 10 white + matter structures. This is the same data as used in + Eickhoff's + Anatomy Toolbox v1.5. The atlas is based on the + miscroscopic and quantitative histological examination of + ten human post-mortem brains. The histological volumes of + these brains were 3D reconstructed and spatially + normalised into the space of the MNI single subject + template to create a probabilistic map of each area. For + the FSL version of this atlas, these probabilistic maps + were then linearly transformed into MNI152 space.

+ +

Main references (to reference individual + structures' maps, please see the publication list at the start + of the Anatomy Toolbox manual):

    +
  • Amunts et al. Neuroanatomical Tract-Tracing 3: + Molecules, Neurons and Systems, ch18. Springer (2006)
  • +
  • Eickhoff et al. A new SPM toolbox for combining + probabilistic cytoarchitectonic maps and functional imaging + data. Neuroimage 25(4):1325-35 (2005)
  • +
  • Toga et al. Towards multimodal atlases of the human + brain. Nature Reviews Neuroscience 7:952-966 (2006)
  • +
  • Eickhoff et al., Assignment of functional activations to probabilistic cytoarchitectonic areas revisited. NeuroImage, 36(3): 511-521 (2007)
  • +
+

+

+

JHU DTI-based white-matter atlases

+

There are two white-matter atlases, both kindly provided + by Dr. Susumu + Mori, Laboratory of + Brain Anatomical MRI, Johns Hopkins + University:

+ +

In the ICBM-DTI-81 white-matter labels atlas, 50 white + matter tract labels were created by hand segmentation of a + standard-space average of diffusion MRI tensor maps from + 81 subjects; mean age 39 (18:59), M:42, F: 39. The + diffusion data was kindly provided by the ICBM DTI + workgroup.

+ +

In the JHU white-matter tractography atlas, 20 + structures were identified probabilistically by averaging + the results of running deterministic tractography on 28 + normal subjects (mean age 29, M:17, F:11).

+ +

References: +

    +
  • Mori et al. MRI Atlas of Human White + Matter. Elsevier, Amsterdam, The Netherlands + (2005)
  • +
  • Wakana et al. Reproducibility of quantitative tractography methods applied to cerebral white matter. NeuroImage 36:630-644 (2007)
  • +
  • Hua et al. Tract probability maps in stereotaxic spaces: analysis of white matter anatomy and tract-specific quantification. NeuroImage, in press
  • +
+

+

Oxford thalamic connectivity atlas

+

A probabilistic atlas of 7 sub-thalamic regions, segmented according to their + white-matter connectivity to cortical areas, kindly provided + by Heidi Johansen-Berg and Timothy Behrens, FMRIB.

+

This connectivity atlas reports probability of anatomical + connection from points in the thalamus to each of 7 cortical + zones. These probabilties are calculated using + probabilistic diffusion tractography in multiple + subjects. For more details see + the Thalamic + Connectivity Atlas web page.

+

References:

    +
  • Behrens et al. Non-invasive mapping of connections + between human thalamus and cortex using diffusion imaging. Nature + Neuroscience 6(7):750-757 (2003)
  • +
  • Behrens et al. Characterisation and propagation of + uncertainty in diffusion weighted MR imaging. Magnetic Resonance in + Medicine 50:1077-1088 (2003)


+

Talairach atlas

+

A conversion of the original Talairach structural + labellings, kindly provided by Jack Lancaster and Diana + Tordesillas Gutiérrez at + the Research Imaging + Center, UTHSCSA, Texas.

+

This is a digitised version of the original (coarsely + sliced) Talairach atlas (Lancaster 2000) after the + application of a correcting affine transform (Lancaster + 2007) to register it into MNI152 space.

+

References: +

    +
  • Talairach et al. Co-planar stereotaxic atlas of the + human brain. Thieme, New York. (1988)
  • +
  • Lancaster et al. Bias between MNI and Talairach + coordinates analyzed using the ICBM-152 brain + template. Human Brain Mapping (in press) (2007)
  • +
  • Lancaster et al. Automated Talairach Atlas labels for + functional brain mapping. Human Brain Mapping 10:120-131 (2000)
  • +
+

+

+

MNI structural atlas

+

9 anatomical structural regions, kindly provided by Jack + Lancaster at + the Research Imaging + Center, UTHSCSA, Texas (originally from + the McConnell + Brain Imaging Centre, MNI).

+

A single subject's structural image was hand segmented, + and the labels were then propagated to more than 50 + subjects' structural images using nonlinear + registration. Each resulting labelled brain was then + transformed into MNI152 space using affine registration, + before averaging segmentations across subjects to produce + the final probability images. For more details see the + Talairach Daemon.

+

References: +

    +
  • Collins et al. Automatic 3-D model-based + neuroanatomical segmentation. Human Brain Mapping + 3(3): 190-208. (1995)
  • +
  • Mazziotta et al. A probabilistic atlas and reference + system for the human brain: International Consortium + for Brain Mapping (ICBM). Phil. Trans. Royal Soc. B + Biol. Sci. 356(1412):1293-1322 (2001)
  • +
+

+

+ + --- fslview-3.1.2+4.1.4.orig/doc/fslview/fslview.adp +++ fslview-3.1.2+4.1.4/doc/fslview/fslview.adp @@ -72,7 +72,7 @@ -
+
--- fslview-3.1.2+4.1.4.orig/fsl/CMakeLists.txt +++ fslview-3.1.2+4.1.4/fsl/CMakeLists.txt @@ -6,4 +6,5 @@ INCLUDE_DIRECTORIES( ${FSL_DIR}/extras/include/zlib ) ADD_DEFINITIONS ( -DHAVE_ZLIB ) -SUBDIRS(znzlib niftiio fslio newmat libprob cprob miscmaths utils) +# Debian: do not build stuff available from other Debian package +SUBDIRS( fslio utils cprob miscmaths ) --- fslview-3.1.2+4.1.4.orig/fsl/utils/opttst.cc +++ fslview-3.1.2+4.1.4/fsl/utils/opttst.cc @@ -3,6 +3,7 @@ #include #include +#include #include using namespace std; @@ -84,7 +85,7 @@ opttst -d -m -r \n\ opttst --verbose\n"; -int main(unsigned int argc, char **argv) { +int main(int argc, char **argv) { OptionParser options(title, examples); --- fslview-3.1.2+4.1.4.orig/fsl/utils/time_tracer.h +++ fslview-3.1.2+4.1.4/fsl/utils/time_tracer.h @@ -12,6 +12,7 @@ #include #include #include +#include #include #include #include --- fslview-3.1.2+4.1.4.orig/fsl/fslio/fslio.h +++ fslview-3.1.2+4.1.4/fsl/fslio/fslio.h @@ -25,8 +25,8 @@ #define __FSLIO_H #include -#include "niftiio/nifti1_io.h" -#include "znzlib/znzlib.h" +#include +#include #include "dbh.h" #ifdef __cplusplus --- fslview-3.1.2+4.1.4.orig/debian/fslview.1 +++ fslview-3.1.2+4.1.4/debian/fslview.1 @@ -0,0 +1,67 @@ +.TH "FSLVIEW" "1" "April 2009" "Michael Hanke" "User Commands" +.SH "NAME" +fslview \- viewer for 3d and 4d MRI data and DTI images +.SH "SYNOPSIS" +.B fslview +[\-m \fI\fR] [\fI [\fIimageoptions\fR] ... ] +.SH "DESCRIPTION" +\fBFSLView\fR is an interactive display tool for 3D, 4D and DTI data. FSLView can read Analyze and NIFTI files, either uncompressed or compressed, and either as a single file (e.g. image.nii.gz) or two files (e.g. image.hdr & image.img). \fBFSLView\fR supports multiple image overlays with indivdual color maps. + +.PP +There are four different image viewing modes: +.IP +\fBOrtho\fR \- the default view showing axial, orthogonal and sagittal slices. +.IP +\fBLightbox\fR \- shows all axial slices simultaneously. +.IP +\fBSingle\fR \- shows only a single slice \- the orientation can be switched between axial, orthogonal and sagittal and you can also turn on auto\-scrolling through the slices. +.IP +\fB3d\fR \- renders the volume in 3d with optional clipping of brain parts and overlays of metrical data. +.PP +In addition to viewing images \fBFSLView\fR can be used to create image masks and manually edit images. +.SH "OPTIONS" +.TP +\fB\-V\fR, \fB\-\-verbose\fR +Switch on diagnostic messages. + +.TP +\fB\-h\fR, \fB\-\-help\fR +Display a short usage description. + +.TP +\fB\-m\fR, \fB\-\-mode\fR \fI3d|ortho|lightbox\fR +Initial viewer mode (see above mode descriptions). + +.SH "PER-IMAGE OPTIONS" +.TP +\fB\-l\fR, \fB\-\-lut\fR \fI\fR +Color lookup table name. The full list is available via the \fBFSLView\fR GUI (e.g. on of: \fIGreyscale\fR, \fIRed\-Yellow\fR, \fIBlue\-Lightblue\fR, \fIRed\fR, \fIGreen\fR, \fIBlue\fR, \fIYellow\fR, \fIPink\fR, \fIHot\fR, \fICool\fR, \fICopper\fR, ...) +.TP +\fB\-b\fR, \fB\-\-bricon\fR \fI,\fR +Initial bricon range, e.g., "2.3,6" +.TP +\fB-t\fR, \fB\-\-trans\fR \fI\fR +Initial transparency, e.g., 0.2 + +.SH "BUGREPORTS" +If you discover an bugs please report them either to the FSL mailing list or to \fIfslview\-bugs@fmrib.ox.ac.uk\fR. +.SH "AUTHOR" +\fBFSLView\fR was written by Dave Flitney, James Saunders, Mark Jenkinson, Steve Smith and V Rama Aravind. +.PP +This manual page was written by Michael Hanke , +for the Debian project (but may be used by others). +.SH "NOTES" +\fBFSLView\fR is able to use brain atlas data to identify locations in brain +volumes. However, the brain atlases that come with FSL are licensed under a +non-free (non-commercial) license. Therefore they cannot be included in the +FSLView package, which only contains free software. + +Please see /usr/share/doc/fslview/README.Debian for more information. + +.SH "SEE ALSO" +.BR atlasquery "(1)", +.BR fsl "(1)" +.TP +\fBFSLView Homepage:\fR http://www.fmrib.ox.ac.uk/fsl/fslview/index.html +.TP +\fBFSL Homepage:\fR http://www.fmrib.ox.ac.uk/fsl/ --- fslview-3.1.2+4.1.4.orig/debian/compat +++ fslview-3.1.2+4.1.4/debian/compat @@ -0,0 +1 @@ +5 --- fslview-3.1.2+4.1.4.orig/debian/fslview.desktop +++ fslview-3.1.2+4.1.4/debian/fslview.desktop @@ -0,0 +1,13 @@ +[Desktop Entry] +Encoding=UTF-8 +GenericName=MRI Image Viewer +GenericName[de]=Betrachter für MRT-Daten +Name=FSLView +Exec=fslview %F +TryExec=fslview +Type=Application +Terminal=false +Comment=This program is part of FSL +Comment[de]=Dieses Programm gehört zu FSL +Categories=Graphics;Science;MedicalSoftware;Qt;Viewer; +Icon=fslview.xpm --- fslview-3.1.2+4.1.4.orig/debian/rules +++ fslview-3.1.2+4.1.4/debian/rules @@ -0,0 +1,48 @@ +#!/usr/bin/make -f +# -*- makefile -*- + +# attempt to fix/workaround #502083 +AS_NEEDED_BROKEN = zarmelz zarmebz +ifneq (,$(findstring z$(DEB_HOST_ARCH)z,$(AS_NEEDED_BROKEN))) +LDFLAGS = +else +LDFLAGS = -Wl,--as-needed -Wl,--no-undefined +endif + +# The CMake flags for Debian: +# - Choose Qt3 explicitely (necessary as building fails with Qt4 present). +# - Search for VTK instead of a fixed path to be compatible with post-etch +# versions and Ubuntu. + +# add Debian-specific include paths +CXXFLAGS += -I$(CURDIR)/fsl/libprob \ + -I/usr/include/newmat \ + -I/usr/include/qwt \ + -I/usr/include/nifti +CFLAGS += $(CXXFLAGS) + +DEB_CMAKE_EXTRA_FLAGS = \ + -DCMAKE_EXE_LINKER_FLAGS:STRING="$(LDFLAGS)" \ + -DCMAKE_MODULE_LINKER_FLAGS:STRING="$(LDFLAGS)" \ + -DCMAKE_SHARED_LINKER_FLAGS:STRING="$(LDFLAGS)" \ + -DVTK_DIR:PATH=$$(dirname $$(find /usr/lib -name VTKConfig.cmake|head -n1)) \ + -DDESIRED_QT_VERSION=3 \ + -DQT_MOC_EXECUTABLE=/usr/bin/moc-qt3 \ + -DQT_UIC_EXECUTABLE=/usr/bin/uic-qt3 \ + -DQWT_DIR=/usr \ + -DFSL_DIR=$(CURDIR)/fsl \ + -DFSL_BUILD:BOOL=ON + + +# do not compress the html docs as they are used as online help sources +# for FSLView via the Qt-Assistant +DEB_COMPRESS_EXCLUDE = .html .png .adp .jpg + +include /usr/share/cdbs/1/rules/debhelper.mk +include /usr/share/cdbs/1/class/cmake.mk + + +install/fslview:: + # make fsl icon + convert doc/fslview/fsl-logo.png -resize x32 -crop 32x32+5+0 \ + debian/tmp/fslview.xpm --- fslview-3.1.2+4.1.4.orig/debian/README.Debian +++ fslview-3.1.2+4.1.4/debian/README.Debian @@ -0,0 +1,27 @@ +fslview for Debian +------------------ + +FSLView can make use of brain atlases to provide information about stereotaxic +coordinates. While FSL provides nine different atlases that can be used with +fslview (and atlasquery), these atlases are covered by a non-commercial +license and are not part of Debian. + +However, as the format of the atlases is documented in the HTML documentation +of FSLView it is easy the produce new atlases (at least technically). + +Additionally users may download the FSL source tarball from + + http://www.fmrib.ox.ac.uk/fsl/ + +and extract the contained 'fsl/data/atlases' subdirectory that contains the +above mentioned atlases. Atlases should be put into /usr/share/fsl/data/atlases. + +There is also an unofficial Debian package of the atlases and other datasets +available. For convenience the fslview package recommends the unofficial atlas +package although it is not part of Debian. + +For the time being unoffical FSL binary and data packages are available from: + + http://neuro.debian.net/pkgs/fsl.html + + -- Michael Hanke Wed, 30 Sep 2009 21:34:23 +0200 --- fslview-3.1.2+4.1.4.orig/debian/atlasquery.1 +++ fslview-3.1.2+4.1.4/debian/atlasquery.1 @@ -0,0 +1,60 @@ +.TH "ATLASQUERY" "1" "August 2007" "Michael Hanke" "User Commands" + +.SH "NAME" +atlasquery \- commandline tool to query brain atlases about stereotaxic +coordinates + +.SH "SYNOPSIS" +.B atlasquery +\-a \fI""\fR [\fI\-m \fR] [\fI\-c ,,\fR] + +.SH "DESCRIPTION" +\fBatlasquery\fR provides information about stereotaxic brain coordinates +by querying brain atlases. FSL provides nine different atlases that can be +used with atlasquery. Please note that these atlases are covered by a +non-commercial licenses and are not part of Debian. + +However, as the format of the atlases is documented in the HTML documentation +of FSLView it is easy the produce new atlases (at least technically). + +The \fB-a\fR option which selects the to be queried atlas is compulsory. + +Atlases should be put into \fI/usr/share/fsl/data/atlases\fR. By setting the +environment variable \fIFSLATLASPATH\fR to a different path one can customize +this location. + +Please see /usr/share/doc/fslview/README.Debian for more information. + +.SH "OPTIONS" +.TP +\fB\-V\fR, \fB\-\-verbose\fR +Switch on diagnostic messages. + +.TP +\fB\-h\fR, \fB\-\-help\fR +Display a short usage description. + +.TP +\fB\-m\fR, \fB\-\-mask\fR +A mask image to use during structural lookups. +.TP +\fB\-c\fR, \fB\-\-dumpatlases\fR +Print a list of the available atlases. + +.SH "BUGREPORTS" +If you discover an bugs please report them either to the FSL mailing list or +to \fIfslview\-bugs@fmrib.ox.ac.uk\fR. + +.SH "AUTHOR" +\fBatlasqeury\fR was written by Dave Flitney. +.PP +This manual page was written by Michael Hanke , +for the Debian project (but may be used by others). + +.SH "SEE ALSO" +.BR fslview "(1)", +.BR fsl "(1)" +.TP +\fBFSLView Homepage:\fR http://www.fmrib.ox.ac.uk/fsl/fslview +.TP +\fBFSL Homepage:\fR http://www.fmrib.ox.ac.uk/fsl/ --- fslview-3.1.2+4.1.4.orig/debian/repackage-fsl +++ fslview-3.1.2+4.1.4/debian/repackage-fsl @@ -0,0 +1,141 @@ +#!/bin/sh +# Repackage FSL upstream sources. Removes unnecessary 3rd party software and +# non-free binaries. Additionally FSL is split into 3 individual source +# packages. +# 1 GPL'ed: fslview (application) +# 2 non-free: fsl (applications), fsldata (datasets) +# +# Usage: +# repackage-fsl +# + +set -e + +# make working directory +CURDIR=$(pwd) +WDIR=$(mktemp -d) +ORIG_VERSION=$1 +ORIGSRC=$2 + +# put upstream source tarball into working dir +ORIGSRC_PATH=$(readlink -f ${ORIGSRC}) +cd $WDIR +ln -s $ORIGSRC_PATH + +# unpack the source tarball +echo "Unpacking sources" +if [ "${ORIGSRC##*.}" == "bz2" ]; then TARARG="j" +elif [ "${ORIGSRC##*.}" == "gz" ]; then TARARG="z" +elif [ "${ORIGSRC##*.}" == "tar" ]; then TARARG=""; fi +tar xvf${TARARG} $ORIGSRC_PATH + +############### +# repackaging # +############### +echo "Repackaging" + +# obsolete in FSL 4.1 +#echo "Remove unnecessary 3rd-party binaries" +#rm -rf fsl/src/freeware/ + +# perform a make distclean in all relevant source dirs +#echo "Run 'distclean'" +#find fsl/src -maxdepth 1 -type d -print -exec bash -c 'export FSLCONFDIR=`pwd`/fsl/config && export FSLMACHTYPE=generic && cd {} && make distclean' \; +#find fsl/extras/src -maxdepth 1 -type d -print -exec bash -c 'export FSLCONFDIR=`pwd`/fsl/config && export FSLMACHTYPE=generic && cd {} && make distclean' \; + +# build information for other operation systems are unecessary +rm -rf fsl/config/*gcc* + +echo "Remove old dependency files" +find fsl -name depend.mk -exec rm -f {} \; + +echo "Remove CVS stuff" +find fsl -type d -name CVS -exec rm -rf {} \; + +echo "Remove backup files" +find fsl -name '*~' -exec rm -rf {} \; + +# obsolete in FSL 4.1 +#echo "Rescue IRTK par files" +#mkdir -p fsl/extras/irtk +#cp fsl/extras/src/irtk/common/*.par fsl/extras/irtk + +echo "Purge unnecessary source code of external software" +parts="libiconv libgd libgdc libpng newmat newran zlib include irtk tcl tk" +for p in $parts; do + rm -rf fsl/extras/src/$p +done +rm -rf fsl/extras/include + +echo "Remove FSL parts that are available from other packages" +parts="niftiio znzlib newmat" +for p in $parts; do + rm -rf fsl/src/$p +done + +echo "Cleanup FSLView sources" +parts="fsl/niftiio fsl/znzlib fsl/newmat" +for p in $parts; do + rm -rf fsl/src/fslview/$p +done + + +# Unecessarily many files have executable permissions. +echo "Fix file permissions" +find fsl -type f -regex '.*.\(ppm\|gif\|tcl\|xbm\|ico\|png\|css\|fig\|cc\|h\|cpp\|c\|html\|jpg\)$' -exec chmod -x {} \; + +# Only these file need to be executable. +#chmod +x fsl/build +#chmod +x fsl/extras/build +#chmod +x fsl/config/common/buildproj +#chmod +x fsl/src/siena/makedoc + + +echo "Split sources into multiple source trees" +# split fslview +mkdir fslview +mv fsl/src/fslview/* fslview/ +rm -rf fsl/src/fslview +cp fsl/doc/fsl/licence.html fslview/ + +# put all non-free data in the fsldata package +mkdir fsldata +mv fsl/data/* fsldata/ +rm -r fsl/data +# finally copy the license +cp fsl/doc/fsl/licence.html fsldata/ + + +echo -n "Determine FSLView version: " +fslview_major=$(egrep "^const char \*Version.*\".*\"" fslview/src/fslview/version.cpp | awk -F '"' '{ print $2 }') +fslview_minor=$(egrep "^const char \*Release.*\".*\"" fslview/src/fslview/version.cpp | awk -F '"' '{ print $2 }') +fslview_version="${fslview_major}.${fslview_minor}+${ORIG_VERSION}" +echo ${fslview_version} + + +echo "Append version to source directory names" +mv fsl fsl-$ORIG_VERSION.orig +mv fsldata fsldata-${ORIG_VERSION}.orig +mv fslview fslview-${fslview_version}.orig + + +echo "Compress repackaged tarballs" +tar czf fsl_$ORIG_VERSION.orig.tar.gz fsl-$ORIG_VERSION.orig +tar czf fslview_${fslview_version}.orig.tar.gz fslview-${fslview_version}.orig +tar cf fsldata_$ORIG_VERSION.orig.tar fsldata-$ORIG_VERSION.orig + + +echo "Copy tarballs to final destination" +mv fsl_$ORIG_VERSION.orig.tar.gz $CURDIR +mv fslview_${fslview_version}.orig.tar.gz $CURDIR +mv fsldata_$ORIG_VERSION.orig.tar $CURDIR + + +echo "Clean working directory" +rm -rf $WDIR + + +echo "Done" + +exit 0 + --- fslview-3.1.2+4.1.4.orig/debian/TODO +++ fslview-3.1.2+4.1.4/debian/TODO @@ -0,0 +1,3 @@ +* Figure out how much cprob (CEPHES) library is modified to determine whether + it is worth making a separate library package of it, so labplot and fslview + could use it. --- fslview-3.1.2+4.1.4.orig/debian/watch +++ fslview-3.1.2+4.1.4/debian/watch @@ -0,0 +1,4 @@ +version=3 +opts="uversionmangle=s/^/3.0+/" \ +http://pkg-exppsy.alioth.debian.org/watchhelper/fsl.html \ + .*fsl-(.*)-sources\.tar\.gz --- fslview-3.1.2+4.1.4.orig/debian/fslview.install +++ fslview-3.1.2+4.1.4/debian/fslview.install @@ -0,0 +1,3 @@ +debian/fslview.desktop usr/share/applications +debian/tmp/usr/bin/* usr/bin +debian/tmp/fslview.xpm usr/share/pixmaps --- fslview-3.1.2+4.1.4.orig/debian/fslview-doc.install +++ fslview-3.1.2+4.1.4/debian/fslview-doc.install @@ -0,0 +1 @@ +debian/tmp/usr/doc/fslview/* usr/share/doc/fslview-doc/html --- fslview-3.1.2+4.1.4.orig/debian/README.Debian-source +++ fslview-3.1.2+4.1.4/debian/README.Debian-source @@ -0,0 +1,30 @@ +Debian source package of FSLView +-------------------------------- + +The FSL sources are a mixture of free and non-free source code as well as +non-free datasets. Additionally it contains 3rd party software as sources +or in binary form. Most of this software is available as proper Debian +packages. + +For these reasons and the huge size of the tarball (approx. 1.1 GB) the +original sources were split into three individual source package: two packages +with source -- one free and one non-free each and one pure data package. + +The data package was separated as it contains datasets that are very +unlikely to change between major releases or even less frequently. These +dataset are the biggest part of the sources (already more than one GB). + +For the exact repackaging and split procedure, please look at the +'repackage-fsl' script in the Debian packaging of the Debian 'fslview' source +package. + +This source package provides the DFSG-compliant source code of the FSLView +application. + +The Debian packaging introduces some hardcoded paths in the sources. This is +done, because FSL (and FSLView) depends on a certain environment setup. To +reduce the maintainance overhead the Debian maintainer hardcoded certain +paths, because they are invariant on Debian systems and don't need +customization (e.g. paths to Qt3 install directory, qt-assistant, html-docs). + +-- Michael Hanke , Fri, 26 Apr 2009 20:33:27 +0200 --- fslview-3.1.2+4.1.4.orig/debian/changelog +++ fslview-3.1.2+4.1.4/debian/changelog @@ -0,0 +1,148 @@ +fslview (3.1.2+4.1.4-2build1) maverick; urgency=low + + * No change rebuild for vtk transition + + -- Scott Kitterman Mon, 16 Aug 2010 10:21:15 -0400 + +fslview (3.1.2+4.1.4-2) unstable; urgency=low + + * Bumped Standards-Version to 3.8.3.0, no changes necessary. + * Updated information about unofficial FSL data packages. + * Fixed minor whitespace errors in Debian packaging. + + -- Michael Hanke Wed, 30 Sep 2009 21:43:14 -0400 + +fslview (3.1.2+4.1.4-1) unstable; urgency=low + + * New upstream release. Merged few patches from previous Debian package + release. This version is now compatible with the recent boost 1.38.0 + (Closes: #530465). + + -- Michael Hanke Wed, 03 Jun 2009 19:34:36 +0200 + +fslview (3.1.0+4.1.3-1) unstable; urgency=low + + * New upstream release. + * Bumped Standards-Version to 3.8.1, no changes necessary. + * Update debhelper compat level to 5. + * Switch Debian packaging to use CDBS -- simplifying debian/rules quite a + bit. + * Reduce Debian diff by reverting back to static linking. The previous + approach of splitting unversioned shared libs to be used by FSL has proven + to be too error-prone and time consuming to maintain (Closes: #522484). + * Updated fslview.1 to reflect new command line option. + * Update debian/copyright for the year 2009. + + -- Michael Hanke Mon, 27 Apr 2009 20:42:01 +0200 + +fslview (3.0.2+4.1.2-2) unstable; urgency=low + + * Compile internal libraries as shared libs and install them under + /usr/lib/fsl/lib, so FSL itself can use them as well. + * Expose FSL's internal libs via RPATH to the included binaries. + That should be appropriate, since they are built from the same package + and are not intended to be used by other packages than FSL (hence, no -dev + package). + * Added patch to prevent fslview from crashing with images that have dim4=0. + Thanks to Wim Otte. + * Build package with -Wl,--no-undefined. + * Added 'XS-DM-Upload-Allowed: yes' to debian/control. + + -- Michael Hanke Fri, 06 Feb 2009 12:13:24 +0100 + +fslview (3.0.2+4.1.2-1) UNRELEASED; urgency=low + + * New Upstream Version. + * Updated repackaging to keep fslio in the sources (will soon be removed from + nifticlib package). + + -- Michael Hanke Thu, 29 Jan 2009 19:19:15 +0100 + +fslview (3.0.2+4.1.0-3) unstable; urgency=low + + * Fix the fix to #502083 -- which has the condition reversed. Additionally, + the 'fix' is not necessary on ARM (Closes: #502083). + + -- Michael Hanke Thu, 16 Oct 2008 14:59:20 +0200 + +fslview (3.0.2+4.1.0-2) unstable; urgency=low + + * Prevent using -Wl,--as-needed linker flags on arm, armel and armeb + (Closes: #502083). Thanks to Riku Voipio for pointing to the workaround. + * Update 'repackage-fsl' script to not remove fslio anymore, since the + im scripts are required by FSL. + + -- Michael Hanke Tue, 14 Oct 2008 20:03:24 +0200 + +fslview (3.0.2+4.1.0-1) unstable; urgency=low + + * New Upstream Version. + * Bumped Standards-Version to 3.8.0, no changes necessary. + + -- Michael Hanke Thu, 14 Aug 2008 12:59:52 +0200 + +fslview (3.0+4.0.2-5) unstable; urgency=low + + * Specify Qt3 dev tools explicitly to be compatible with cmake 2.6 and + add missing include path (Closes: #482209). + + -- Michael Hanke Wed, 21 May 2008 19:38:18 +0200 + +fslview (3.0+4.0.2-4) unstable; urgency=low + + * Do not recommend fsl-atlases package anymore as it is not in Debian + main. However, this package is available from other repositories. + Therefore keeping the reference in the suggested packages + (Closes: #474447). + * Add explicite build-dependency on libqt3-compat-headers (Closes: #475993). + + -- Michael Hanke Tue, 15 Apr 2008 00:33:03 +0200 + +fslview (3.0+4.0.2-3) unstable; urgency=low + + * Link with --as-needed to significantly reduce the number of package + dependencies. + * Fix typo in changelog. + * Updated build-deps for libnifti transition. + * Bumped Standards-version to 3.7.3, no changes necessary. + * Fixed missing headers for GCC 4.3 compatibility (Closes: #456099). + * Changed section of fslview-doc package to 'doc'. + + -- Michael Hanke Thu, 03 Jan 2008 09:51:05 +0100 + +fslview (3.0+4.0.2-2) unstable; urgency=low + + * Resurrect atlasquery and install it again in the package. + + -- Michael Hanke Sun, 18 Nov 2007 13:00:48 +0100 + +fslview (3.0+4.0.2-1) unstable; urgency=low + + * New upstream release. + * Use new-style Homepage field in debian/control. + * Add VCS information to debian/control. + + -- Michael Hanke Fri, 16 Nov 2007 08:02:37 +0100 + +fslview (3.0+4.0.1-2) unstable; urgency=low + + * Build-depend on libniftiio1-dev by default. + + -- Michael Hanke Mon, 17 Sep 2007 14:16:55 +0200 + +fslview (3.0+4.0.1-1) unstable; urgency=low + + * New upstream bugfix release. + + -- Michael Hanke Sat, 01 Sep 2007 10:49:00 +0200 + +fslview (3.0+4.0.0-1) unstable; urgency=low + + * Initial release. + * Modified default path setting to match the Debian environment. + * Use dynamic linking to external libs whenever possible. + * Wrote manpages for fslview and atlasquery. + * Created an FSL icon that can be used for menu entries. + * Added a desktop file. + + -- Michael Hanke Wed, 15 Aug 2007 21:17:01 +0200 --- fslview-3.1.2+4.1.4.orig/debian/fslview.manpages +++ fslview-3.1.2+4.1.4/debian/fslview.manpages @@ -0,0 +1,2 @@ +debian/fslview.1 +debian/atlasquery.1 --- fslview-3.1.2+4.1.4.orig/debian/fslview.menu +++ fslview-3.1.2+4.1.4/debian/fslview.menu @@ -0,0 +1,8 @@ +?package(fslview): \ + needs="X11" \ + section="Applications/Science/Medicine" \ + title="FSLView" \ + longtitle="FSL Image Viewer for (f)MRI and DTI" \ + icon="fslview.xpm" \ + command="/usr/bin/fslview" \ + hints="MRI,fMRI,FSL" --- fslview-3.1.2+4.1.4.orig/debian/copyright +++ fslview-3.1.2+4.1.4/debian/copyright @@ -0,0 +1,101 @@ +This package was debianized by Michael Hanke on +Thu, 12 Jul 2007 10:21:50 +0200. + +It was downloaded from http://www.fmrib.ox.ac.uk/fsldownloads/ + +Upstream Authors: + Dave Flitney + James Saunders + Mark Jenkinson + Steve Smith + V Rama Aravind + + +Copyright: (C) 1999-2009, The University of Oxford + +License: + + This package 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 package 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 package; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +On Debian systems, the complete text of the GNU General +Public License can be found in `/usr/share/common-licenses/GPL'. + + +src/fsl/cprob +------------- +This code comes from the CEPHES library. Although the library sources itself +contains no proper license statement, the copyright holder previously agreed +to release it under the terms of the GPL. This is documented in the Debian +packaging of the labplot package. Please see + +http://packages.debian.org/changelogs/pool/main/l/labplot/labplot_1.5.1-1/labplot.copyright + +for references. + +Here is a verbatim copy of the statement: + + This email from Steve Moshier, the copyright owner of cephes, to Helen + Faulkner (Debian maintainer of labplot), and other interested parties + (labplot and grace authors, grace maintainer and labplot sponsor), confirms + that we may release labplot with cephes licensed under the GPL. + + + -------- Original Message -------- + Subject: Re: licensing of cephes + Date: Sun, 2 Jan 2005 21:48:02 -0500 (EST) + From: Steve Moshier + To: Helen Faulkner + CC: twerner@debian.org, Ben Burton , evgeny@stambulchik.net, + Stefan Gerlach + References: <41D14354.4040506@yahoo.co.uk> + + <41D17BE3.3020708@yahoo.co.uk> + + <41D1FB8D.6030002@yahoo.co.uk> + + <41D2D8EF.9010702@yahoo.co.uk> + + <41D41B2E.80508@yahoo.co.uk> + + + + On Thu, 30 Dec 2004, Helen Faulkner wrote: + + > http://www.debian.org/social_contract#guidelines + + This is fine with me. To acknowedge your terms explicily, + how about augmenting the permission to read something like + the following -- + + This software is derived from the Cephes Math Library. It is + incorporated herein, and licensed in accordance with DFSG, + by permission of the author. + + + If you are trying to get me to suggest a specific form for your + license, then from looking at Debian programs such as dpkg it seems to + me that you would find the GPL to be appropriate and the permission + statement could reference one of the GPL documents instead of DFSG. + Alternatively, the packages you have been talking about distributing + with Debian presumably come with some sort of licenses and it would + make sense to propose those licenses. + + + +Debian Packaging +---------------- + +The Debian packaging is (C) 2007-2009, Michael Hanke +and is licensed under the GPL, see above. --- fslview-3.1.2+4.1.4.orig/debian/control +++ fslview-3.1.2+4.1.4/debian/control @@ -0,0 +1,38 @@ +Source: fslview +Section: science +Priority: optional +Maintainer: Michael Hanke +Uploaders: Yaroslav Halchenko +Build-Depends: debhelper (>= 5), cdbs, libboost-dev, libvtk5-dev, libqwt-dev, qt3-apps-dev, libqt3-compat-headers, libvtk5-qt3-dev, libtiff4-dev, libnewmat10-dev, cmake, imagemagick, libnifti1-dev | libnifti-dev +Standards-Version: 3.8.3.0 +Homepage: http://www.fmrib.ox.ac.uk/fsl/fslview +Vcs-Browser: http://git.debian.org/?p=pkg-exppsy/fslview.git +Vcs-Git: git://git.debian.org/git/pkg-exppsy/fslview.git +XS-DM-Upload-Allowed: yes + + +Package: fslview +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Recommends: fslview-doc +Suggests: fsl-atlases +Conflicts: fsl-fslview +Replaces: fsl-fslview +Description: viewer for (f)MRI and DTI data + This package provides a viewer for 3d and 4d MRI data as well as DTI images. + FSLView is able to display ANALYZE and NIFTI files. The viewer supports + multiple 2d viewing modes (orthogonal, lightbox or single slices), but also + 3d volume rendering. Additionally FSLView is able to visualize timeseries and + can overlay metrical and stereotaxic atlas data. + . + FSLView is part of FSL. + + +Package: fslview-doc +Architecture: all +Section: doc +Depends: qt3-assistant, ${misc:Depends} +Description: Documentation for FSLView + This package provides the online documentation for FSLView. + . + FSLView is part of FSL. --- fslview-3.1.2+4.1.4.orig/src/storage/image.cpp +++ fslview-3.1.2+4.1.4/src/storage/image.cpp @@ -21,7 +21,9 @@ throw Exception("Failed to open file " + filename); m_imageInfo = ImageInfo::init(m_avw,filename); m_cachedVolumes.clear(); - m_cachedVolumes.resize(m_imageInfo->inqNumVolumes()); + /* Do not explode if dim4 == 0 (e.g. image origin is ITK) */ + int nv = m_imageInfo->inqNumVolumes(); + m_cachedVolumes.resize(m_imageInfo && nv == 0 ? 1 : nv); } Image::Image(ImageInfo::Handle info): --- fslview-3.1.2+4.1.4.orig/src/fslview/clusterdata.cpp +++ fslview-3.1.2+4.1.4/src/fslview/clusterdata.cpp @@ -33,7 +33,7 @@ }; BaseCluster::BaseCluster(const ColumnList& cl): - m_impl(new Implementation), m_columns(cl) + m_columns(cl), m_impl(new Implementation) { m_headings.insert(std::make_pair("Cluster Index", Index)); m_headings.insert(std::make_pair("Voxels", Voxels)); --- fslview-3.1.2+4.1.4.orig/src/fslview/assistantclient.cpp +++ fslview-3.1.2+4.1.4/src/fslview/assistantclient.cpp @@ -24,7 +24,9 @@ AssistantClient* AssistantClient::getInstance() { if(!m_instance) { - QString path( Preferences::getInstance()->inqAssistantPath() ); + // Debian has fixed path + //QString path( Preferences::getInstance()->inqAssistantPath() ); + QString path("/usr/share/qt3/bin"); m_instance = new AssistantClient(path); } return m_instance; @@ -33,7 +35,9 @@ AssistantClient::AssistantClient(const QString& path): QAssistantClient( path, qApp->mainWidget()) { - m_docPath = Preferences::getInstance()->inqFSLDir() + QString("/doc/fslview"); + // Debian specific path setting + //m_docPath = Preferences::getInstance()->inqFSLDir() + QString("/doc/fslview"); + m_docPath = QString("/usr/share/doc/fslview-doc/html"); QStringList args; args << "-profile" << QString("%1/fslview.adp").arg(m_docPath); --- fslview-3.1.2+4.1.4.orig/src/fslview/preferences.cpp +++ fslview-3.1.2+4.1.4/src/fslview/preferences.cpp @@ -25,6 +25,10 @@ Implementation() : m_assistantpath(""), m_atlaspath(""), m_fsldir(""), m_mni(""), m_w(0), m_h(0), m_x(0), m_y(0) { + // Debian default path settings + m_fsldir = string(getenv("FSLDIR") ? getenv("FSLDIR") : "/usr/share/fsl"); + m_atlaspath = string(getenv("FSLATLASPATH") ? getenv("FSLATLASPATH") : m_fsldir + "/data/atlases"); + m_mni = m_fsldir + "/data/standard/MNI152_T1_2mm.nii.gz"; } string m_assistantpath; --- fslview-3.1.2+4.1.4.orig/src/fslview/CMakeLists.txt +++ fslview-3.1.2+4.1.4/src/fslview/CMakeLists.txt @@ -192,7 +192,8 @@ FILE( GLOB qwtlibs ${QWT_DIR}/lib/*.so* ) FILE( GLOB qtlibs ${QT_QT_LIBRARY}* ${QT_QASSISTANTCLIENT_LIBRARY}* ) FILE( GLOB assistant ${QT_INCLUDE_DIR}/../bin/assistant ) - INSTALL(FILES ${vtklibs} ${osmesa} ${qtlibs} ${qwtlibs} DESTINATION lib) +# no installation of system files on Debian +# INSTALL(FILES ${vtklibs} ${osmesa} ${qtlibs} ${qwtlibs} DESTINATION lib) # INSTALL(FILES ${assistant} DESTINATION lib) # INSTALL(TARGETS fslview atlasquery RUNTIME DESTINATION /bin ) ENDIF(APPLE)