README.md 3.76 KB
Newer Older
hvernier's avatar
hvernier committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
## Demo Video

![Video](https://icube-forge.unistra.fr/lafabregue/Mustic/-/wikis/uploads/f8acb00bfa0804a2388a513849d4f3c5/MultIcubeVIDEO.mp4)

## MutIcube Install :<a id="install_guide"></a>

### Requirements :<a id="requirements"></a>

You will need java jre 1.8 or above (jdk is recommended) and git installed.

Note that all commands are designed to work with unix bash.

### Installation :<a id="install"></a>

##### Create a MutIcube directory and clone the four git project in it : <a id="cloneGit"></a>
```bash
    mkdir MultIcube
    cd MultIcube
    git clone https://icube-forge.unistra.fr/lafabregue/MultiCubeTools.git
    git clone https://icube-forge.unistra.fr/lafabregue/JCL.git
    git clone https://icube-forge.unistra.fr/lafabregue/JSL.git
    git clone https://icube-forge.unistra.fr/lafabregue/Mustic.git
```

##### Open your favourite java IDE but it is recommended to use eclipse. The following instruction will be based on eclipse interface.

* Change your workspace to the MultiCube directory
* Import the previous four projects into your IDE :
    * Import > General > Projects from Folder or Archive
    * Choose for each four projects the corresponding folder
* For each projet change its build path :
     * JCL : add project MultiCubeTools
     * JSL : add project MultiCubeTools
     * Mustic :
        * add project MultiCubeTools
        * add project JCL
        * add project JSL
        * add the directory « resources » as Class Folder in Libraries build path
        * change the Order of importation of ressources in the Order and Export tab to have
        the two highlighted libraries on top :

hvernier's avatar
hvernier committed
42
![image 1](https://icube-forge.unistra.fr/lafabregue/Mustic/-/wikis/uploads/c243fa6d76b68f5f5b2c32d9186abc39/image1.png)
hvernier's avatar
hvernier committed
43
44
45

* Add gdal external jars to the Mustic project :

hvernier's avatar
hvernier committed
46
![image 2](https://icube-forge.unistra.fr/lafabregue/Mustic/-/wikis/uploads/002a0be48017c19cf0baef306a7ce4cc/image2.png)
hvernier's avatar
hvernier committed
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80

* Run the mustic project :
Run > Java Application >
choose «MultiCube - mustic » among the different Main class
Use the Mustic/src/mustic/MultiCube.java if you don’t use eclipse
* Change the Run Configuration :
  * add the two following Environment variables :
    * Name : GDAL_DATA => Value: *../MultiCubeTools/share/*
    * ***for linux only :***
    * Name : LD_LIBRARY_PATH => Value: *../MultiCubeTools/lib:./lib*
  * ***for Windows and MacOS :***
  * add the following VM argument : -Djava.library.path=../MultiCubeTools/lib:./lib
  * it is also recommended to change the memory allocated, by adding the VM arguments :
    * -Xms<your_min_memory_to_use>m -Xmx<your_max_memory_available>m

On x64 unix platfrom you should normally be able to launch Mustic.
But if you import a picture and still have an error, or you want to use the project on MacOS
Windows, or x32 Unix you will have to change the dynamic libraries :
* For Windows : copy paste content of MultiCubeTools/lib/Windows/xx, xx beeing 64 or 32
depending of your architecture
* For MacOS : copy paste content of MultiCubeTools/lib/MacOS

If it does not fix your problem, you need to get the gdal binaries with java bidings :
* for Windows, you can refer to :
https://trac.osgeo.org/gdal/wiki/DownloadingGdalBinaries
* for Linux, you need to compile GDAL with the –with-java option, make the gdal-*/swig/java
sub-projet, and copy the resulting .so files and jar. For more details, you can refer to :
https://github.com/VertNet/reproject/wiki/GDAL-Java-Bindings (note that now there only one
.so file generated)
* for MacOS, the homebrew build no longer support the –with-java option, you need to
compile it yourself with the –with-java option, make the gdal-*/swig/java sub-projet, and
copy the resulting .so files and jar. For more details, you can refer to :
http://www.ecgs.lu/gilles/enabling-gdal-java-binding-for-geoserver-on-macos/