[Zooimage-commits] r238 - in pkg: . zooimage zooimage/inst zooimageJ zooimageJ/R zooimageJ/inst zooimageJ/inst/images zooimageJ/inst/java zooimageJ/inst/java/plugins zooimageJ/javasrc zooimageJ/javasrc/data zooimageJ/javasrc/src zooimageJ/javasrc/src/org zooimageJ/javasrc/src/org/sciviews zooimageJ/javasrc/src/org/sciviews/zooimage zooimageJ/javasrc/src/org/sciviews/zooimage/config zooimageJ/javasrc/src/org/sciviews/zooimage/debug zooimageJ/javasrc/src/org/sciviews/zooimage/exceptions zooimageJ/javasrc/src/org/sciviews/zooimage/files zooimageJ/javasrc/src/org/sciviews/zooimage/gui zooimageJ/javasrc/src/org/sciviews/zooimage/log zooimageJ/javasrc/src/org/sciviews/zooimage/macros zooimageJ/javasrc/src/org/sciviews/zooimage/macros/macrophoto_gray16 zooimageJ/javasrc/src/org/sciviews/zooimage/macros/microscope_color zooimageJ/javasrc/src/org/sciviews/zooimage/macros/scanner_color zooimageJ/javasrc/src/org/sciviews/zooimage/macros/scanner_gray16 zooimageJ/javasrc/src/org/sciviews/zooimage/plugins zooimageJ/javasrc/src/org/sciviews/zooimage/plugins/gui zooimageJ/javasrc/src/org/sciviews/zooimage/tools zooimageJ/javasrc/src/org/sciviews/zooimage/utils zooimageJ/man
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Wed Jan 30 19:21:43 CET 2013
Author: phgrosjean
Date: 2013-01-30 19:21:42 +0100 (Wed, 30 Jan 2013)
New Revision: 238
Added:
pkg/zooimageJ/
pkg/zooimageJ/DESCRIPTION
pkg/zooimageJ/NAMESPACE
pkg/zooimageJ/NEWS
pkg/zooimageJ/R/
pkg/zooimageJ/R/IJ.R
pkg/zooimageJ/R/IJWindowManager.R
pkg/zooimageJ/R/ImageJ.R
pkg/zooimageJ/R/raster.R
pkg/zooimageJ/R/zooimageJ-internal.R
pkg/zooimageJ/inst/
pkg/zooimageJ/inst/images/
pkg/zooimageJ/inst/images/R.jpg
pkg/zooimageJ/inst/java/
pkg/zooimageJ/inst/java/ij.jar
pkg/zooimageJ/inst/java/plugins/
pkg/zooimageJ/inst/java/plugins/_zooimage.jar
pkg/zooimageJ/inst/java/zooimage
pkg/zooimageJ/javasrc/
pkg/zooimageJ/javasrc/Makevars
pkg/zooimageJ/javasrc/build.xml
pkg/zooimageJ/javasrc/data/
pkg/zooimageJ/javasrc/data/plugins.config
pkg/zooimageJ/javasrc/data/zooimage.config
pkg/zooimageJ/javasrc/src/
pkg/zooimageJ/javasrc/src/org/
pkg/zooimageJ/javasrc/src/org/sciviews/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/EmptyTableException.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ImageFileProcessor.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/NoVignetteCreatedException.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/NotAllVignettesCreatedException.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ROIStore.txt
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ReadMe.txt
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ZimFileProcessor.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ZooImage.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ZooImageMacro.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ZooImagePlugin.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ZooImagePluginDescriptor.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ZooImagePluginGui.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ZooImageProcessList.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/config/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/config/CalibrationData.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/config/MeasurementsUtilities.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/config/ProcessOptions.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/config/ScaleConfig.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/debug/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/debug/Debug.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/exceptions/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/exceptions/ZooImageException.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/CmbImage.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/CouldNotOpenRawImageException.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/FailingMacroException.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/ImageFile.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/IncorrectZimFileException.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/MaskImage.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/MissingMacroException.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/NoImageException.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/OdcImage.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/OutImage.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/SecondaryImage.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/UnableToSaveImageException.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/Vignette.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/VisImage.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/WorkDirectoryIsNotDirectoryException.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/files/ZimFile.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/gui/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/gui/ZooImageGui.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/log/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/log/Log.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/ZooImageMacro_CMB.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/macrophoto_gray16/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/macrophoto_gray16/Macrophoto_Gray16_MSK.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/macrophoto_gray16/Macrophoto_Gray16_ODC.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/macrophoto_gray16/Macrophoto_Gray16_VIS.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/microscope_color/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/microscope_color/Microscope_Color_MSK.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/microscope_color/Microscope_Color_VIS.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/scanner_color/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/scanner_color/Scanner_Color_MSK.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/scanner_color/Scanner_Color_VIS.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/scanner_gray16/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/scanner_gray16/Scanner_Gray16_MSK.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/scanner_gray16/Scanner_Gray16_ODC.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/macros/scanner_gray16/Scanner_Gray16_VIS.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/plugins/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/plugins/Macrophoto_Gray16.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/plugins/Microscope_Color.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/plugins/Scanner_Color.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/plugins/Scanner_Gray16.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/plugins/gui/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/plugins/gui/Macrophoto_Gray16_Gui.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/plugins/gui/Microscope_Color_Gui.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/plugins/gui/Scanner_Color_Gui.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/plugins/gui/Scanner_Gray16_Gui.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/BufferUtilities.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/Directories.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/FileExtensions.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/FileUtilities.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/IJUtilities.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/ImageConstants.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/Images.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/PropertiesUtilities.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/RGB.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/SortUtilities.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/Threshold.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/Timer.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/VignetteUtilities.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/ZIJ.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/ZimUtilities.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/ZooImageFilenameFilter.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/tools/ZooImageIOException.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/utils/
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/utils/Duplicater.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/utils/Gray8.java
pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/utils/Threshold.java
pkg/zooimageJ/man/
pkg/zooimageJ/man/IJ.Rd
pkg/zooimageJ/man/IJWindowManager.Rd
pkg/zooimageJ/man/ImageJ.Rd
pkg/zooimageJ/man/as.raster.Rd
pkg/zooimageJ/man/zooimageJ-package.Rd
Removed:
pkg/zooimage/inst/imagej/
pkg/zooimage/javasrc/
Modified:
pkg/zooimage/NEWS
Log:
All java code moved out of zooimage into zooimageJ package
Modified: pkg/zooimage/NEWS
===================================================================
--- pkg/zooimage/NEWS 2012-12-21 16:08:02 UTC (rev 237)
+++ pkg/zooimage/NEWS 2013-01-30 18:21:42 UTC (rev 238)
@@ -16,6 +16,8 @@
(version 2) items. The list is now updated with new plots available in
zooimage 3 and mlearning 1.
+* All the java code (ImageJ + zooimage plugins) are now moved to zooimageJ.
+
== Changes in zooimage 3.0-0
Added: pkg/zooimageJ/DESCRIPTION
===================================================================
--- pkg/zooimageJ/DESCRIPTION (rev 0)
+++ pkg/zooimageJ/DESCRIPTION 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,18 @@
+Package: zooimageJ
+Type: Package
+Title: Analysis of numerical zooplankton images - ImageJ part
+Version: 3.0-0
+Date: 2013-01-28
+Author: Ph. Grosjean, K. Denis & R. Francois with contributions from P. Murrell
+Maintainer: Ph. Grosjean <Philippe.Grosjean at umons.ac.be>
+Depends: R (>= 2.14.0), svMisc (>= 0.9-68), svDialogs (>= 0.9-53), mlearning, zooimage (>= 3.0-0)
+Imports: filehash, jpeg, png, ipred, rpart, e1071, tree, utils, rJava (>= 0.8-5), grDevices
+Suggests: mlbench
+SystemRequirements: Java (>= 5.0)
+Description: ZooImage is a free (open source) solution for analyzing digital
+ images of zooplankton. In combination with ImageJ, a free image analysis
+ system, it processes digital images, measures individuals, trains for
+ automatic classification of taxa, and finally, measures zooplankton samples
+ (abundances, total and partial size spectra or biomasses, etc.)
+License: GPL (>= 3)
+URL: http://www.sciviews.org/zooimage
Property changes on: pkg/zooimageJ/DESCRIPTION
___________________________________________________________________
Added: svn:executable
+ *
Added: pkg/zooimageJ/NAMESPACE
===================================================================
--- pkg/zooimageJ/NAMESPACE (rev 0)
+++ pkg/zooimageJ/NAMESPACE 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,30 @@
+import(utils)
+#import(tcltk)
+#import(tcltk2)
+import(svMisc)
+#import(svWidgets)
+import(svDialogs)
+import(filehash)
+import(jpeg)
+import(png)
+#import(ipred)
+#import(MASS)
+#import(randomForest)
+#import(class)
+#import(rpart)
+#import(e1071)
+#import(nnet)
+#import(tree)
+#import(RWeka)
+import(mlearning)
+#import(party)
+import(zooimage)
+import(rJava)
+
+importFrom("grDevices", "as.raster")
+
+export(ImageJ,
+ IJ,
+ IJWindowManager)
+
+S3method("as.raster", "jobjRef")
Added: pkg/zooimageJ/NEWS
===================================================================
--- pkg/zooimageJ/NEWS (rev 0)
+++ pkg/zooimageJ/NEWS 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,7 @@
+= zooimage News
+
+== Changes in zooimageJ 3.0-0
+
+* This package collects code from RImageJ 0.2-146 and all java code (ImageJ and
+ zooimage plugins) out of zooimage. That way, zooimage becomes compatible with
+ CRAN specifications (no compiled code).
Added: pkg/zooimageJ/R/IJ.R
===================================================================
--- pkg/zooimageJ/R/IJ.R (rev 0)
+++ pkg/zooimageJ/R/IJ.R 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1 @@
+delayedAssign("IJ", .jnew("ij/IJ"))
Added: pkg/zooimageJ/R/IJWindowManager.R
===================================================================
--- pkg/zooimageJ/R/IJWindowManager.R (rev 0)
+++ pkg/zooimageJ/R/IJWindowManager.R 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1 @@
+delayedAssign("IJWindowManager", .jnew("ij/WindowManager"))
Added: pkg/zooimageJ/R/ImageJ.R
===================================================================
--- pkg/zooimageJ/R/ImageJ.R (rev 0)
+++ pkg/zooimageJ/R/ImageJ.R 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,4 @@
+delayedAssign("ImageJ", {
+ res <- try(.jnew("ij/ImageJ"), silent = TRUE)
+ if (inherits(res, "try-error")) NULL else res
+})
Added: pkg/zooimageJ/R/raster.R
===================================================================
--- pkg/zooimageJ/R/raster.R (rev 0)
+++ pkg/zooimageJ/R/raster.R 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,30 @@
+### Based on a contribution by Paul Murell
+
+#setGeneric("as.raster" )
+#
+#setMethod( "as.raster", "jobjRef", function (x) {
+as.raster.jobjRef <- function (x, ...)
+{
+ ## First check that this is an instance of ij.ImagePlus
+ if (!x %instanceof% "ij.ImagePlus")
+ stop("'x' must be a reference to an \"ImagePlus\" object")
+
+ ## Image dimensions
+ w <- x$getWidth()
+ h <- x$getHeight()
+ ## Force to RGB image
+ ijp <- x$getProcessor()
+ ijrgb <- ijp$convertToRGB()
+ ## Grab the pixels (which should now be integers)
+ pixels <- ijrgb$getPixels()
+ ## Convert the integers to R colours
+ colourChars <- as.character(as.hexmode(pixels))
+ red <- substr(colourChars, 3, 4)
+ green <- substr(colourChars, 5, 6)
+ blue <- substr(colourChars, 7, 8)
+ colours <- paste("#", red, green, blue, sep = "")
+ r <- colours
+ dim(r) <- c(h, w)
+ class(r) <- "raster"
+ return(r)
+}
Added: pkg/zooimageJ/R/zooimageJ-internal.R
===================================================================
--- pkg/zooimageJ/R/zooimageJ-internal.R (rev 0)
+++ pkg/zooimageJ/R/zooimageJ-internal.R 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,19 @@
+.onAttach <- function (libname, pkgname) {
+ #if (substring(R.Version()$os, 1, 6) == "darwin") {
+ # # There is a problem starting Java with AWT on Mac OS X (Snow) Leopard
+ # # This tries to correct it!
+ # options(java.parameters = paste(getOption("java.parameters"),
+ # "-Djava.awt.headless=true"))
+ #}
+ # Note: this does not solve *all* the problem because methods in IJ that
+ # rely on genericDialog still do not work. The only solution I [PhG]
+ # have found until now is to start RImageJ from within JGR.
+ .jpackage(pkgname)
+ if (!is.null(ImageJ)) ImageJ$show()
+ packageStartupMessage("ImageJ version: ", IJ$getVersion(), "\n", sep = "")
+}
+
+.onUnload <- function (libpath) {
+ ## Close ImageJ
+ try(ImageJ$quit(), silent = TRUE)
+}
Property changes on: pkg/zooimageJ/R/zooimageJ-internal.R
___________________________________________________________________
Added: svn:executable
+ *
Added: pkg/zooimageJ/inst/images/R.jpg
===================================================================
(Binary files differ)
Property changes on: pkg/zooimageJ/inst/images/R.jpg
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: pkg/zooimageJ/inst/java/ij.jar
===================================================================
(Binary files differ)
Property changes on: pkg/zooimageJ/inst/java/ij.jar
___________________________________________________________________
Added: svn:executable
+ *
Added: svn:mime-type
+ application/octet-stream
Added: pkg/zooimageJ/inst/java/plugins/_zooimage.jar
===================================================================
(Binary files differ)
Property changes on: pkg/zooimageJ/inst/java/plugins/_zooimage.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: pkg/zooimageJ/inst/java/zooimage
===================================================================
--- pkg/zooimageJ/inst/java/zooimage (rev 0)
+++ pkg/zooimageJ/inst/java/zooimage 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,4 @@
+#!/bin/bash
+
+java -Xmx900m -cp .:ij.jar:plugins/_zooimage.jar org.sciviews.zooimage.ZooImage $@
+
Property changes on: pkg/zooimageJ/inst/java/zooimage
___________________________________________________________________
Added: svn:executable
+ *
Added: pkg/zooimageJ/javasrc/Makevars
===================================================================
--- pkg/zooimageJ/javasrc/Makevars (rev 0)
+++ pkg/zooimageJ/javasrc/Makevars 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,8 @@
+.PHONY: all
+
+clean:
+ # ant clean
+
+all:
+ # ant build
+
Added: pkg/zooimageJ/javasrc/build.xml
===================================================================
--- pkg/zooimageJ/javasrc/build.xml (rev 0)
+++ pkg/zooimageJ/javasrc/build.xml 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,119 @@
+<project name="ZooImage ImageJ Plugins" basedir="." default="build" >
+
+ <!--{{{ properties -->
+ <property file="build.properties" />
+ <property name="target" value="../inst/imagej" />
+ <property name="jar_imagej" value="${target}/ij.jar" />
+ <!--}}}-->
+
+ <!--{{{ classpath -->
+ <path id="zooimage.class.path">
+ <pathelement location="${jar_imagej}" />
+ </path>
+ <!--}}}-->
+
+ <!--{{{ regular plugins -->
+ <!--{{{ clean -->
+ <target name="clean">
+ <delete dir="build"/>
+ <delete dir="dist"/>
+ <delete dir="bin"/>
+ </target>
+ <!--}}}-->
+
+ <!--{{{ compile the java files -->
+ <target name="compile" depends="clean">
+ <mkdir dir="bin"/>
+ <javac srcdir="src" destdir="bin" source="1.5" target="1.5" debug="true"
+ debuglevel="lines,vars,source">
+ <classpath refid="zooimage.class.path"/>
+ </javac>
+ </target>
+ <!--}}}-->
+
+ <!--{{{ build the jar file -->
+ <target name="build" depends="compile">
+
+ <jar jarfile="${target}/plugins/_zooimage.jar">
+ <fileset dir="bin" />
+ <fileset dir="src">
+ <include name="*.xml" />
+ <include name="**/*.props" />
+ <include name="**/*.properties" />
+ <include name="**/*.html" />
+ <include name="**/*.gif" />
+ <include name="**/*.png" />
+ <include name="**/*.txt" />
+ </fileset>
+ <fileset dir="data">
+ <include name="**" />
+ </fileset>
+ </jar>
+ </target>
+ <!--}}}-->
+
+ <!--{{{javadoc-->
+ <target name="javadoc" >
+ <javadoc
+ access="public"
+ destdir="javadoc"
+ author="true"
+ version="true"
+ use="true"
+ windowtitle="ZooImage"
+ >
+
+ <fileset dir="src" defaultexcludes="yes">
+ <include name="**/*.java"/>
+ </fileset>
+
+ </javadoc>
+ </target>
+ <!--}}}-->
+
+ <!--{{{ FIT VIS -->
+
+ <target name="clean_fitvis">
+ <delete dir="build_fitvis"/>
+ <delete dir="dist_fitvis"/>
+ <delete dir="bin_fitvis"/>
+ </target>
+
+ <!--{{{ compile the java files -->
+ <target name="compile_fitvis" depends="clean_fitvis">
+ <mkdir dir="bin_fitvis"/>
+ <javac srcdir="src_fitvis" destdir="bin_fitvis" source="1.5" target="1.5" debug="true"
+ debuglevel="lines,vars,source">
+ <classpath refid="zooimage.class.path"/>
+ </javac>
+ </target>
+ <!--}}}-->
+
+ <!--{{{ build the jar file -->
+ <target name="build_fitvis" depends="compile_fitvis">
+
+ <jar jarfile="${target}/plugins/_fitvis.jar">
+ <fileset dir="bin_fitvis" />
+ <fileset dir="src_fitvis">
+ <include name="*.xml" />
+ <include name="**/*.props" />
+ <include name="**/*.properties" />
+ <include name="**/*.html" />
+ <include name="**/*.gif" />
+ <include name="**/*.png" />
+ <include name="**/*.txt" />
+ </fileset>
+ <fileset dir="data_fitvis">
+ <include name="**" />
+ </fileset>
+ </jar>
+
+ <copy file="data_fitvis/FITVIS.macro" tofile="${target}/plugins/FITVIS.macro"/>
+
+ </target>
+ <!--}}}-->
+
+ <!--}}}-->
+
+
+</project>
Property changes on: pkg/zooimageJ/javasrc/build.xml
___________________________________________________________________
Added: svn:executable
+ *
Added: pkg/zooimageJ/javasrc/data/plugins.config
===================================================================
--- pkg/zooimageJ/javasrc/data/plugins.config (rev 0)
+++ pkg/zooimageJ/javasrc/data/plugins.config 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,11 @@
+# Name: Zoo_Image
+# Author: Philippe Grosjean
+# Version: 1.1
+# Date: 2008/03/14
+# Requires: ImageJ 1.37s
+
+Plugins>Zoo Image, "Microscope Color " , org.sciviews.zooimage.ZooImage("Microscope_Color")
+Plugins>Zoo Image, "Macrophoto Gray16" , org.sciviews.zooimage.ZooImage("Macrophoto_Gray16")
+Plugins>Zoo Image, "Scanner Color " , org.sciviews.zooimage.ZooImage("Scanner_Color")
+Plugins>Zoo Image, "Scanner Gray16 " , org.sciviews.zooimage.ZooImage("Scanner_Gray16")
+
Property changes on: pkg/zooimageJ/javasrc/data/plugins.config
___________________________________________________________________
Added: svn:executable
+ *
Added: pkg/zooimageJ/javasrc/data/zooimage.config
===================================================================
--- pkg/zooimageJ/javasrc/data/zooimage.config (rev 0)
+++ pkg/zooimageJ/javasrc/data/zooimage.config 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,17 @@
+
+ziplugin.Macrophoto_Gray16.description= A sophisticated image processor for digital camera images RAW images taken at 2400dpi/16 bits grays with spatial/gray calibration.
+ziplugin.Macrophoto_Gray16.version=1.1-0
+ziplugin.Macrophoto_Gray16.author=Ph Grosjean
+
+ziplugin.Microscope_Color.description=A simple image processor for microphotographies
+ziplugin.Microscope_Color.version=1.1-0
+ziplugin.Microscope_Color.author=Ph Grosjean
+
+ziplugin.Scanner_Color.description=A simple image processor for flatbed scanner color images scanned at 600dpi/24 bits colors with spatial calibration.
+ziplugin.Scanner_Color.version=1.1-0
+ziplugin.Scanner_Color.author=Ph Grosjean
+
+ziplugin.Scanner_Gray16.description=An image processor for flatbed scanner TIFF images with 16 bits grays and both spatial and gray calibration
+ziplugin.Scanner_Gray16.version=1.1-0
+ziplugin.Scanner_Gray16.author=Ph Grosjean
+
Added: pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/EmptyTableException.java
===================================================================
--- pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/EmptyTableException.java (rev 0)
+++ pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/EmptyTableException.java 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,18 @@
+package org.sciviews.zooimage;
+
+import org.sciviews.zooimage.exceptions.ZooImageException;
+
+/**
+ * Thrown when the result table is empty
+ *
+ * @author Romain Francois <francoisromain at free.fr>
+ * @see ImageFileProcessor#processVIG()
+ */
+public class EmptyTableException extends ZooImageException {
+
+ private static final long serialVersionUID = 622542671503596615L;
+
+ public EmptyTableException(){
+ super( "ERROR: not able to make vignettes; table empty or closed." ) ;
+ }
+}
Added: pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ImageFileProcessor.java
===================================================================
--- pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ImageFileProcessor.java (rev 0)
+++ pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ImageFileProcessor.java 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,388 @@
+package org.sciviews.zooimage;
+
+import ij.IJ;
+import ij.ImagePlus;
+import ij.measure.ResultsTable;
+import ij.plugin.filter.ParticleAnalyzer;
+
+import java.io.File;
+
+import org.sciviews.zooimage.config.CalibrationData;
+import org.sciviews.zooimage.config.MeasurementsUtilities;
+import org.sciviews.zooimage.config.ProcessOptions;
+import org.sciviews.zooimage.exceptions.ZooImageException;
+import org.sciviews.zooimage.files.CmbImage;
+import org.sciviews.zooimage.files.ImageFile;
+import org.sciviews.zooimage.files.MaskImage;
+import org.sciviews.zooimage.files.OdcImage;
+import org.sciviews.zooimage.files.OutImage;
+import org.sciviews.zooimage.files.Vignette;
+import org.sciviews.zooimage.files.VisImage;
+import org.sciviews.zooimage.files.ZimFile;
+import org.sciviews.zooimage.log.Log;
+import org.sciviews.zooimage.tools.FileExtensions;
+import org.sciviews.zooimage.tools.IJUtilities;
+import org.sciviews.zooimage.tools.Images;
+import org.sciviews.zooimage.tools.ZIJ;
+import org.sciviews.zooimage.utils.Threshold;
+
+/**
+ * Class that processes one image
+ *
+ * @author Romain Francois <francoisromain at free.fr>
+ *
+ */
+public class ImageFileProcessor {
+
+ /**
+ * Image file to process
+ */
+ protected ImageFile image ;
+
+ /**
+ * Calibration information
+ */
+ protected CalibrationData calibration ;
+
+ /**
+ * Process options
+ */
+ protected ProcessOptions options ;
+
+ /**
+ * Zim file associated with the image
+ */
+ protected ZimFile zim ;
+
+ /**
+ * Processor for the Zim file
+ */
+ protected ZimFileProcessor zimProcessor ;
+
+ /**
+ * The plugin that called the zim file processor
+ * that called this image processor
+ */
+ protected ZooImagePlugin plugin ;
+
+ /**
+ * VIS image associated with the image being processed
+ */
+ protected VisImage vis ;
+
+ /**
+ * ODC image associated with the image being processed
+ */
+ protected OdcImage odc ;
+
+ /**
+ * MSK image associated with the image being processed
+ */
+ protected MaskImage msk ;
+
+ /**
+ * OUT image associated with the image being processed
+ */
+ protected OutImage out ;
+
+ /**
+ * CMB image associated with the image being processed
+ */
+ protected CmbImage cmb ;
+
+ /**
+ * Result table created by the analyze particles part
+ */
+ protected ResultsTable results ;
+
+ /**
+ * Constructor
+ * @param image image file to process
+ * @param zimProcessor processor for the zim file associated with the image
+ */
+ public ImageFileProcessor( ImageFile image, ZimFileProcessor zimProcessor ){
+ this.image = image ;
+ this.calibration = zimProcessor.getCalibration( ) ;
+ this.options = zimProcessor.getOptions( );
+ this.zim = zimProcessor.getZim() ;
+ this.zimProcessor = zimProcessor ;
+ this.plugin = zimProcessor.getPlugin( ) ;
+ vis = new VisImage( this ) ;
+ odc = new OdcImage( this ) ;
+ msk = new MaskImage( this ) ;
+ out = new OutImage( this ) ;
+ cmb = new CmbImage( this ) ;
+ }
+
+ public ZimFileProcessor getZimProcessor() {
+ return zimProcessor;
+ }
+
+ /**
+ * Runs this job (Process the image)
+ */
+ public void run() throws ZooImageException {
+
+ // Make sure all images are closed
+ IJUtilities.closeAllImages() ;
+
+ // First, we need to check that we have all
+ // necessary gif images, and if we don't we
+ // need to make them
+ Log.debug( "Checking gifs" ) ;
+ boolean checkGif = vis.exists() ;
+ if (options.get("useOD") && checkGif) {
+ checkGif = odc.exists() ;
+ }
+ Log.debug( " ... ok" ) ;
+
+
+ // If at least one is missing, we need the RAW image
+ if (!checkGif) {
+
+ // Make sure all the required .gif files are made
+ processVIS() ;
+
+ // Make the MASK image if needed
+ processMSK() ;
+
+ // Process ODC
+ processODC() ;
+
+ }
+
+ // Now we can analyze the particles
+ analyzeParticles() ;
+
+ // Now we can make the vignettes
+ // Should we make the vignettes?
+ if ( options.get("makevigs" ) ){
+ processVIG() ;
+ }
+
+ // Should we compute the combined visual + outline file (only the last image)
+ if ( options.get("showoutline") && zimProcessor.isProcessingLastImage() ){
+ processCMB() ;
+ }
+
+ }
+
+ /**
+ * Makes the VIS image from the RAW image
+ */
+ public void processVIS() throws ZooImageException {
+
+ if( vis.exists() ) return ;
+
+ Log.debug( " <processVIS>" ) ;
+
+ // Does the actual processing, specific to each implementation
+ vis.getMacro().processAndSave(this, vis) ;
+
+ Log.debug( " </processVIS>" ) ;
+
+ }
+
+ /**
+ * Makes the MSK image from either the VIS image
+ * or the RAW image (depending on the "maskFromVis" option)
+ */
+ public void processMSK( ) throws ZooImageException {
+
+ if( msk.exists() ) return ;
+
+ Log.debug( " <processMSK>" ) ;
+
+ msk.getMacro().processAndSave(this, msk) ;
+
+ Log.debug( " </processMSK>" ) ;
+
+ }
+
+
+ public void processODC() throws ZooImageException {
+
+ // No need for this if we don't use it!
+ if (!options.get("useOD") | odc.exists() ) return ;
+
+ Log.debug( " <processODC>" ) ;
+
+ // call the actual treatment
+ odc.getMacro().processAndSave(this, odc) ;
+
+ Log.debug( " </processODC>" ) ;
+
+ }
+
+ public void analyzeParticles() throws ZooImageException {
+
+ // Analyze particles, using a mask (ImgMask), and an O.D. calibrated image (ImgOD)
+ ImagePlus mask_image = msk.open( zim.getSample() ) ;
+ mask_image.setTitle( zim.getSample() ) ;
+ if( Log.getMode() == Log.IMAGEJ){
+ mask_image.show() ;
+ }
+ IJ.freeMemory();
+
+ // Calibrate the picture in length (and possibly in grey levels)
+ ZIJ.run(mask_image, "Set Scale...", "distance=1 known=" + calibration.getPixsize() +
+ " pixel=1 unit=" + calibration.getPixelunit() + " global");
+
+ // Apply the 0-128 threshold
+ Threshold.applyThreshold(mask_image, 0, 128, false) ;
+
+ // We need minsize and maxsize in pixels, and it is currently in ECD (pixelunit) => convert
+ int pixminsize = calibration.getMinsizeAsPixel() ;
+ int pixmaxsize = calibration.getMaxsizeAsPixel() ;
+
+ results = new ResultsTable() ;
+
+ ParticleAnalyzer pa = new ParticleAnalyzer(
+ ParticleAnalyzer.SHOW_OUTLINES + ParticleAnalyzer.INCLUDE_HOLES ,
+ MeasurementsUtilities.getMeasurements( calibration.getPmes() ),
+ results, pixminsize, pixmaxsize ) ;
+ pa.setHideOutputImage(true);
+ pa.analyze( mask_image ) ;
+ out.save( pa.getOutputImage() ) ;
+ if( Log.getMode() == Log.IMAGEJ){
+ results.show("results" ) ;
+ }
+ mask_image.close();
+
+ }
+
+
+ /**
+ * Combine a visual and an outline for easier diagnostic of
+ * segmentation and particle analysis
+ *
+ */
+ public void processCMB( ) throws ZooImageException {
+
+ Log.debug( " <processCMB>" ) ;
+
+ // call the actual treatment
+ cmb.getMacro().processAndSave(this, cmb) ;
+
+ Log.debug( " </processCMB>" ) ;
+
+ }
+
+
+ /**
+ * Make vignettes for all blobs identified by the particles analysis
+ */
+ public void processVIG() throws ZooImageException {
+
+ // A table of measurements must be opened!
+ if( results == null){
+ throw new EmptyTableException( ) ;
+ }
+ int n = results.getCounter();
+ if (n == 0) {
+ throw new EmptyTableException( ) ;
+ }
+
+ ImagePlus vis_imp = vis.open( Images.imgVIS ) ;
+ vis_imp.setTitle(Images.imgVIS) ;
+ if( Log.getMode() == Log.IMAGEJ){
+ vis_imp.show( );
+ }
+ IJ.freeMemory();
+
+ // Copy the measurements table in this directory
+ String pathZIM2 = zim.getDirectory() + File.separator +
+ zim.getSampleDir() + File.separator +
+ zim.getSample() + FileExtensions.extDAT ;
+ zim.makeDATFile( plugin.getParams(), getResults(),
+ getZimProcessor().getCount(), pathZIM2 ) ;
+ // FileUtilities.copyFile( zim.getFile().getAbsolutePath() , pathZIM2 );
+
+ // Possibly sharpen the vignettes
+ if (options.get("sharpenvigs") ) {
+ ZIJ.run(vis_imp, "Sharpen");
+ }
+
+ // Make sure the spatial calibration is correct and in pixelunit
+ IJ.run(vis_imp, "Set Scale...", "distance=1 known=" +
+ calibration.getPixsize() + " pixel=1 unit=" +
+ calibration.getPixelunit() + " global");
+
+ // Switch jpeg quality to 75
+ IJ.run(vis_imp, "Input/Output...", "jpeg=75");
+
+ // Make vignettes
+ int nok = 0;
+ for (int i = 0; i < n; i++) {
+ Vignette vig = new Vignette( image, i, vis_imp, results) ;
+ if( vig.run() ){
+ nok++ ;
+ }
+ }
+
+ // Check result and report failure
+ if (nok < n) {
+ // Indicate how many vignettes are not created
+ if (nok == 0) {
+ throw new NoVignetteCreatedException( zim ) ;
+ } else {
+ throw new NotAllVignettesCreatedException( zim, n, nok ) ;
+ }
+ }
+
+ vis_imp.close( ) ;
+ }
+
+ public ResultsTable getResults() {
+ return results;
+ }
+
+ /**
+ * The raw image this processor is dealing with
+ *
+ * @return the raw image
+ */
+ public ImageFile getImage() {
+ return image ;
+ }
+
+ /**
+ * VIS image associated with the image being processed
+ */
+ public VisImage getVis(){
+ return vis ;
+ }
+
+ /**
+ * ODC image associated with the image being processed
+ */
+ public OdcImage getOdc() {
+ return odc ;
+ }
+
+ /**
+ * MSK image associated with the image being processed
+ */
+ public MaskImage getMsk() {
+ return msk ;
+ }
+
+ /**
+ * OUT image associated with the image being processed
+ */
+ public OutImage getOut(){
+ return out;
+ }
+
+ /**
+ * CMB image associated with the image being processed
+ */
+ public CmbImage getCmb(){
+ return cmb ;
+ }
+
+ public ZooImagePlugin getPlugin() {
+ return plugin ;
+ }
+
+}
Added: pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/NoVignetteCreatedException.java
===================================================================
--- pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/NoVignetteCreatedException.java (rev 0)
+++ pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/NoVignetteCreatedException.java 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,14 @@
+package org.sciviews.zooimage;
+
+import org.sciviews.zooimage.exceptions.ZooImageException;
+import org.sciviews.zooimage.files.ZimFile;
+
+public class NoVignetteCreatedException extends ZooImageException {
+
+ private static final long serialVersionUID = 6382053089793254173L;
+
+ public NoVignetteCreatedException( ZimFile zim ){
+ super( "ERROR: impossible to create vignettes for " + zim.getSample() ) ;
+ }
+
+}
Added: pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/NotAllVignettesCreatedException.java
===================================================================
--- pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/NotAllVignettesCreatedException.java (rev 0)
+++ pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/NotAllVignettesCreatedException.java 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,14 @@
+package org.sciviews.zooimage;
+
+import org.sciviews.zooimage.exceptions.ZooImageException;
+import org.sciviews.zooimage.files.ZimFile;
+
+public class NotAllVignettesCreatedException extends ZooImageException {
+
+ private static final long serialVersionUID = 2214157257170069436L;
+
+ public NotAllVignettesCreatedException( ZimFile zim, int n, int nok){
+ super( "ERROR: " + (n - nok) + " on " + n + " vignettes were not created for " + zim.getSample() ) ;
+ }
+
+}
Added: pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ROIStore.txt
===================================================================
--- pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ROIStore.txt (rev 0)
+++ pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ROIStore.txt 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,197 @@
+import ij.IJ;
+import ij.ImagePlus;
+import ij.WindowManager;
+import ij.gui.PolygonRoi;
+import ij.gui.Roi;
+import ij.gui.Wand;
+import ij.io.RoiDecoder;
+import ij.io.RoiEncoder;
+import ij.measure.ResultsTable;
+import ij.process.ImageProcessor;
+import ij.ImageJ;
+
+import java.awt.Rectangle;
+import java.io.BufferedOutputStream;
+import java.io.ByteArrayOutputStream;
+import java.io.DataOutputStream;
+import java.io.FileInputStream;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.util.Enumeration;
+import java.util.Hashtable;
+import java.util.zip.ZipEntry;
+import java.util.zip.ZipInputStream;
+import java.util.zip.ZipOutputStream;
+import java.util.Arrays;
+/**
+PlanktonJ Image ROI Store,
+by Nick Mortimer (nick.mortimer at csiro.au).
+license: GPL 2 or above at your convenience.
+*/
+
+public class ROIStore {
+ Hashtable rois = new Hashtable();
+ /**
+ * saveRois to a zip file
+ * @param path The full path and name of the ini file to be used.
+ */
+ public boolean saveRoiZip(String path) {
+ try {
+ Object [] ob = rois.keySet().toArray();
+ String [] Keys= new String [ob.length];
+ for (int i=0;i<ob.length;i++)
+ Keys[i] = ob[i].toString();
+ Arrays.sort(Keys);
+ ZipOutputStream zos = new ZipOutputStream(
+ new FileOutputStream(path));
+ DataOutputStream out = new DataOutputStream(
+ new BufferedOutputStream(zos));
+ RoiEncoder re = new RoiEncoder(out);
+ for (int i=0;i<Keys.length;i++) {
+ Roi roi = (Roi) rois.get(Keys[i]);
+ String label = Keys[i];
+ if (!label.endsWith(".roi"))
+ label += ".roi";
+ zos.putNextEntry(new ZipEntry(label));
+ re.write(roi);
+ out.flush();
+ }
+ out.close();
+ } catch (IOException e) {
+ IJ.error("" + e);
+ return false;
+ }
+ return true;
+ }
+ /**
+ * openRoiZip to a zip file
+ * @param path The full path and name of the ini file to be opend.
+ */
+ public void openRoiZip(String path) {
+ ZipInputStream in = null;
+ ByteArrayOutputStream out;
+ int nRois = 0;
+ try {
+ in = new ZipInputStream(new FileInputStream(path));
+ byte[] buf = new byte[1024];
+ int len;
+ ZipEntry entry = in.getNextEntry();
+ while (entry != null) {
+ String name = entry.getName();
+ if (name.endsWith(".roi")) {
+ out = new ByteArrayOutputStream();
+ while ((len = in.read(buf)) > 0)
+ out.write(buf, 0, len);
+ out.close();
+ byte[] bytes = out.toByteArray();
+ RoiDecoder rd = new RoiDecoder(bytes, name);
+ Roi roi = rd.getRoi();
+ if (roi != null) {
+ name = name.substring(0, name.length() - 4);
+ rois.put(name, roi);
+ nRois++;
+ }
+ }
+ entry = in.getNextEntry();
+ }
+ in.close();
+ } catch (IOException e) {
+ IJ.error(e.toString());
+ }
+ if (nRois == 0)
+ IJ
+ .error("This ZIP archive does not appear to contain \".roi\" files");
+ }
+
+ /**
+ * get roi
+ * @param key The key for the roi.
+ */
+ public Roi get(String key){
+ return ((Roi) rois.get(key));
+ }
+
+ /**
+ * remove roi
+ * @param key The key for the roi.
+ */
+ public void remove(String key){
+ rois.remove(key);
+ }
+
+ /**
+ * add roi
+ * @param key for the roi.
+ * @param roi for the roi.
+ */
+
+ public void add(String Key,Roi roi ) {
+ rois.put(Key, roi.clone());
+
+ }
+
+ /**
+ * addParticles
+ * @param sourceImg mask image
+ * @param rt results table
+ * @param BaseName results table (Type of roi eg. ROI)
+ * @param offx x offset if needed
+ * @param offy y offset if needed
+ */
+
+ public void addParticles(ImagePlus sourceImg, ResultsTable rt, String BaseName, int offx,int offy ){
+ ImageProcessor ip = sourceImg.getProcessor();
+ double t1 = ip.getMinThreshold();
+ int xcol = rt.getColumnIndex("XStart");
+ int ycol = rt.getColumnIndex("YStart");
+ int partcol = rt.getColumnIndex(PJUtils.PARTNO);
+ for (int i=0;i<rt.getCounter();i++){
+ int x = (int)rt.getValue(xcol,i);
+ int y = (int)rt.getValue(ycol,i);
+ int part = (int) rt.getValue(partcol,i);
+ Wand w = new Wand(ip);
+ w.autoOutline(x, y, t1, ip.getMaxThreshold());
+ if (w.npoints>0) {
+ Roi roi = new PolygonRoi(w.xpoints, w.ypoints, w.npoints, Roi.TRACED_ROI);
+ String label = PJUtils.makehashkey(i+1,part,BaseName);
+ roi.setName(label);
+ Rectangle rect =roi.getBoundingRect();
+ roi.setLocation(rect.x+offx,rect.y+offy);
+ rois.put(label, roi.clone());
+ }
+
+ }
+ }
+
+ /**
+ * addParticles
+ * @param sourceImg mask image
+ * @param startx start x point of item
+ * @param starty start y point of item
+ * @param BaseName results table (Type of roi eg. ROI)
+ * @param offx x offset if needed
+ * @param offy y offset if needed
+ */
+ public void addParticles(ImagePlus sourceImg,int startx,int starty, String BaseName,int item, int offx,int offy ){
+ ImageProcessor ip = sourceImg.getProcessor();
+ double t1 = ip.getMinThreshold();
+ Wand w = new Wand(ip);
+ w.autoOutline(startx, starty, t1, ip.getMaxThreshold());
+ if (w.npoints>0) {
+ Roi roi = new PolygonRoi(w.xpoints, w.ypoints, w.npoints, Roi.TRACED_ROI);
+ String start="";
+ if (item<10)
+ start="00";
+ else if (item<100)
+ start="0";
+ String label = start+item+"_"+BaseName;
+ roi.setName(label);
+ Rectangle rect =roi.getBoundingRect();
+ roi.setLocation(rect.x+offx,rect.y+offy);
+ rois.put(label, roi.clone());
+ }
+
+ }
+ }
+
+
Property changes on: pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ROIStore.txt
___________________________________________________________________
Added: svn:executable
+ *
Added: pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ReadMe.txt
===================================================================
--- pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ReadMe.txt (rev 0)
+++ pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ReadMe.txt 2013-01-30 18:21:42 UTC (rev 238)
@@ -0,0 +1,15 @@
+ZooImage1 analyze particle from the command line.
+It requires ImageJ 1.35b or later.
+by Ph. Grosjean, 2005 (phgrosjean at sciviews.org)
+license: GPL 2 or above at your convenience.
+
+(Not that this currently does not work with many plugins!!!)
+To run the program, use:
+
+ java -cp ij.jar:. Gray16bits_2400dpi blobs.tif > results.txt (Unix)
+ java -cp ij.jar;. Gray16bits_EPSON_2400dpi blobs.tif > results.txt (Windows)
+
+The files ij.jar, Gray16bits_2400dpi.class and blobs.tif are assumed to be in the current directory. The plugins directory must also be in the current directory if any plugins are called. Alternatively, define the "plugins.dir" property so it points to the directory that contains the plugins directory, as in these examples:
+
+ java -Dplugins.dir=/usr/local/ImageJ -cp /usr/local/ij.jar:.Gray16bits_2400dpi blobs.tif > results.txt (Unix)
+ java -Dplugins.dir=C:\ImageJ -cp C:\ImageJ\ij.jar;. Gray16bits_2400dpi blobs.tif > results.txt (Windows)
Property changes on: pkg/zooimageJ/javasrc/src/org/sciviews/zooimage/ReadMe.txt
[TRUNCATED]
To get the complete diff run:
svnlook diff /svnroot/zooimage -r 238
More information about the Zooimage-commits
mailing list