Installation/Windows: Difference between revisions

From MiToBo
Jump to navigationJump to search
(Created page with "== Windows == <br/>'''Notice:''' The ImageJ directory path depends on your ImageJ installation. Following, we assume that the ImageJ home directory is set up to ''C:\Program Fil...")
 
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
== Windows ==
== Using MiToBo with ImageJ on a Windows-based system ==


<br/>'''Notice:''' The ImageJ directory path depends on your ImageJ installation. Following, we assume that the ImageJ home directory is set up to ''C:\Program Files\ImageJ\''.<br\><br/>
<br/>'''Notice:''' The ImageJ directory path depends on your ImageJ installation. Following, we assume that the ImageJ home directory is set up to ''C:\Program Files\ImageJ\''.<br\><br/>
Line 7: Line 7:
For installing MiToBo into an existing ImageJ installation perform the following steps:
For installing MiToBo into an existing ImageJ installation perform the following steps:


# go to the '''MiToBo-bin\plugins\''' directory
# extract the mitobo-plugins-1.x binary zip file
#* copy the ''Mi_To_Bo.jar'' to your ''..\ImageJ\plugins\'' directory
# go to the '''mitobo-plugins-1.x\plugins\''' directory
#* copy all jars from ''MiToBo-bin\plugins\jars\'' to your ''..\ImageJ\plugins\jars\'' directory <span style="text-decoration: underline;">except</span> the ij.jar and jars already existing<br/>('''Notice:''' MiToBo requires explicite versions of some jars, other versions may not work probably, see [[downloads|requirements]].)<br/><br/>
#* copy the ''mitobo_plugins.jar'' to your ''..\ImageJ\plugins\'' directory
# go to the '''MiToBo-bin\macros\toolsets\''' directory
#* copy all jars from ''mitobo-plugins-1.x\plugins\jars\'' to your ''..\ImageJ\plugins\jars\'' directory <span style="text-decoration: underline;">'''except'''</span> the ij.jar and jars already existing<br/>('''Notice:''' MiToBo requires explicite versions of some jars, other versions may not work probably, see [[downloads|requirements]].)
#* copy the ''MiToBo_Runner.txt'' to your ''..\ImageJ\macros\toolsets\'' directory<br/><br/>
# go to the '''mitobo-plugins-1.x\macros\toolsets\''' directory
#* copy the ''MiToBo_Runner.txt'' to your ''..\ImageJ\macros\toolsets\'' directory
# Make the native libraries in lib/ of the MiToBo zip file available to Java (see the Native libraries section below) <br/><br/>


==== Native libraries ====
==== Native libraries ====
Line 23: Line 25:
===== <span style="text-decoration: underline;">32-Bit architecture</span> =====
===== <span style="text-decoration: underline;">32-Bit architecture</span> =====


# go to the '''MiToBo-bin\lib\''' directory
# go to the '''mitobo-plugins-1.x\lib\''' directory
#* copy the ''libwin32'' directory to your ''..\ImageJ\'' directory<br/><br/>
#* copy the ''libwin32'' directory to your ''..\ImageJ\'' directory<br/><br/>
# configurate your ImageJ startup
# configurate your ImageJ startup
Line 36: Line 38:
:::* type the following command:
:::* type the following command:
   java -Djava.library.path="C:\Program Files\ImageJ\libwin32" -Xmx1024m -cp "C:\Program Files\ImageJ\ij.jar" ij.ImageJ
   java -Djava.library.path="C:\Program Files\ImageJ\libwin32" -Xmx1024m -cp "C:\Program Files\ImageJ\ij.jar" ij.ImageJ
<br/>'''Notice:''' The ''-Xmx1024m'' variable sets the maximum memory heap size of Java to 1024 MB. This value can be increased, depending on your installed system memory and architecture.<br\><br/>


===== <span style="text-decoration: underline;">64-Bit architecture</span> =====
===== <span style="text-decoration: underline;">64-Bit architecture</span> =====
Line 42: Line 46:
Perform the following steps to run MiToBo on a 64-Bit architecture:
Perform the following steps to run MiToBo on a 64-Bit architecture:


# go to the '''MiToBo-bin\lib\''' directory
# go to the '''mitobo-plugins-1.x\lib\''' directory
#* copy the ''libwin32'' directory to your ''..\ImageJ\'' directory<br/><br/>
#* copy the ''libwin32'' directory to your ''..\ImageJ\'' directory<br/><br/>
# configurate your ImageJ startup
# configurate your ImageJ startup

Latest revision as of 09:36, 5 November 2015

Using MiToBo with ImageJ on a Windows-based system


Notice: The ImageJ directory path depends on your ImageJ installation. Following, we assume that the ImageJ home directory is set up to C:\Program Files\ImageJ\.<br\>

Use MiToBo with an existing ImageJ installation

For installing MiToBo into an existing ImageJ installation perform the following steps:

  1. extract the mitobo-plugins-1.x binary zip file
  2. go to the mitobo-plugins-1.x\plugins\ directory
    • copy the mitobo_plugins.jar to your ..\ImageJ\plugins\ directory
    • copy all jars from mitobo-plugins-1.x\plugins\jars\ to your ..\ImageJ\plugins\jars\ directory except the ij.jar and jars already existing
      (Notice: MiToBo requires explicite versions of some jars, other versions may not work probably, see requirements.)
  3. go to the mitobo-plugins-1.x\macros\toolsets\ directory
    • copy the MiToBo_Runner.txt to your ..\ImageJ\macros\toolsets\ directory
  4. Make the native libraries in lib/ of the MiToBo zip file available to Java (see the Native libraries section below)

Native libraries

Some operators of MiToBo use native code via the Java Native Interface (JNI).
The 'lib/' directory in the zip file provides precompiled JNI-libraries for 32-Bit (lib/libwin32) Windows systems.
At the moment, JNI-libraries for Windows are only available for 32-Bit architectures, but can also be used with an 64-Bit architecture (see below).
For using the native code add the libraries to the library path.
The path to the native libraries must be available to any java application which uses MiToBo operators that depend on these libraries.

32-Bit architecture
  1. go to the mitobo-plugins-1.x\lib\ directory
    • copy the libwin32 directory to your ..\ImageJ\ directory

  2. configurate your ImageJ startup
    • edit ImageJ configuration file ..\ImageJ\ImageJ.cfg and add the library path

      -Djava.library.path="C:\Program Files\ImageJ\libwin32"

      Example of an ImageJ.cfg file:
   C:\Program Files\ImageJ\
   C:\Program Files\Java\jre6\bin\javaw.exe
   -Djava.library.path="C:\Program Files\ImageJ\libwin32" -Xmx1024m -cp "C:\Program Files\ImageJ\ij.jar" ij.ImageJ


  • as an alternative you can start ImageJ from command line
  • open your Windows command line
  • move to the ..\ImageJ\ directoy
  • type the following command:
  java -Djava.library.path="C:\Program Files\ImageJ\libwin32" -Xmx1024m -cp "C:\Program Files\ImageJ\ij.jar" ij.ImageJ


Notice: The -Xmx1024m variable sets the maximum memory heap size of Java to 1024 MB. This value can be increased, depending on your installed system memory and architecture.<br\>

64-Bit architecture

Using a 64-Bit architecture requires a 32-Bit Java installed on the system to use the 32-Bit JNI-libraries.
Perform the following steps to run MiToBo on a 64-Bit architecture:

  1. go to the mitobo-plugins-1.x\lib\ directory
    • copy the libwin32 directory to your ..\ImageJ\ directory

  2. configurate your ImageJ startup
    • edit ImageJ configuration file ..\ImageJ\ImageJ.cfg and add the library path

      -Djava.library.path="C:\Program Files (x86)\ImageJ\libwin32"

      Example of an ImageJ.cfg file:
   C:\Program Files (x86)\ImageJ\
   C:\Program Files (x86)\Java\jre6\bin\javaw.exe
   -Djava.library.path="C:\Program Files (x86)\ImageJ\libwin32" -Xmx1024m -cp "C:\Program Files (x86)\ImageJ\ij.jar" ij.ImageJ


  • as an alternative you can start ImageJ from command line
  • open your Windows command line
  • move to the ..\ImageJ\ directoy
  • type the following command:
  C:\Program Files (x86)\Java\jre6\bin\javaw.exe -Djava.library.path="C:\Program Files (x86)\ImageJ\libwin32" -Xmx1024m -cp "C:\Program Files (x86)\ImageJ\ij.jar" ij.ImageJ


Notice: The -Xmx1024m variable sets the maximum memory heap size of Java to 1024 MB. This value can be increased, depending on your installed system memory and architecture.<br\>