Opened 16 years ago

Closed 16 years ago

#601 closed defect (fixed)

MapGuide Maestro: image tiling in composite mode is not working

Reported by: dumas65 Owned by: ksgeograf
Priority: low Milestone:
Component: Maestro Version:
Severity: trivial Keywords:
Cc: External ID:

Description

I use MGOS 2.0.1 and MGM 1.0.7.4 Work flow: adding dataconnection, selecting composite mode, adding files. No errors everything looks fine. But in config file result look like this.

Please contact me if you need any additional information. Regards, D. See attachet files.

Attachments (10)

config (595.5 KB ) - added by dumas65 16 years ago.
config file
7722.ecw (1.1 MB ) - added by dumas65 16 years ago.
Example of ecw
2146.tfw (132 bytes ) - added by dumas65 16 years ago.
Example of tiff world file
config2 (4.2 KB ) - added by ksgeograf 16 years ago.
config2.2 (4.2 KB ) - added by dumas65 16 years ago.
New config file: coordinates detected but image not displayed.
config.2 (5.7 KB ) - added by dumas65 16 years ago.
Config file for 4 ecw imager in [] are real coordinates
2663.ecw (1.3 MB ) - added by dumas65 16 years ago.
1 of 4 ecw images
2664.ecw (1.4 MB ) - added by dumas65 16 years ago.
2 of 4 ecw images
2763.ecw (1.3 MB ) - added by dumas65 16 years ago.
3 of 4 ecw images
2764.ecw (1.5 MB ) - added by dumas65 16 years ago.
4 of 4 ecw images

Change History (35)

by dumas65, 16 years ago

Attachment: config added

config file

comment:1 by ksgeograf, 16 years ago

From the config file, it seems that GDal does not like your files. If you create a new data source, use "single file" mode, and add just one of the files what happens when you press the "refresh" button in the coordinate system override box?

I would expect that it is reporting a "default" coordinate systems, which is an indication that it does not work.

If it displays the correct coordinate system, try adding the file as the only file in composite mode, and then click "refresh" in the coordinate system override box.

Let me know what happens.

comment:2 by dumas65, 16 years ago

Yes, you are right. After clicking refresh "default" is reported. However, after deleting coordinate system override, image is displayed correctly in the map (correct place, length etc.)

Is this problem in file?

by dumas65, 16 years ago

Attachment: 7722.ecw added

Example of ecw

by dumas65, 16 years ago

Attachment: 2146.tfw added

Example of tiff world file

comment:3 by dumas65, 16 years ago

In case I'm missing something obvious. Few more examples. tiff world file and ecw file I use. It does not matter what format to use, same result.

comment:4 by ksgeograf, 16 years ago

I have now tried loading you ECW file. I placed it in a folder (C:\ecw2) and created a featuresource with just that one file. Then I created a layer, and referenced the featuresource. Then I created a map with the layer, and used the "Set extent to selected layer". I got these values: 585000, 6010000, 590000, 6015000.

I then tried the exact same procedure, but instead of using a single file, I added it as a composite. The resulting config file is attached. The result was the same.

I can see both layers in a clean map/weblayout. I suspect that you are missing either the gdal_ecw plugin or the libecwj2.dll. What happens when you try to run the server in interactive mode? (See this page: http://trac.osgeo.org/fdo/wiki/FdoGdalNotes#DebuggingRastersinMapGuide)

by ksgeograf, 16 years ago

Attachment: config2 added

comment:5 by ksgeograf, 16 years ago

If you want to add the layer to a map with existing layers, the feature source MUST have a coordinate system override with the maps EXACT coordinate system.

comment:6 by dumas65, 16 years ago

OK, I was searching for gdal_ecw and libecwj2.dll, but no results. Maybe this is the case. During installations I was following instruction written in http://mapguide.osgeo.org/sites/mapguide.osgeo.org/files/GettingStarted.pdf installing MapGuide Server and MapGuide Web Server Extensions on winXP. I changed parameter from console to install both server and extensiontions to drive F:

I tried to play around with mapguide in virtual machine running win2000 using default paths for server and extensions, but eventually had same problems.

There is some of output from interactive mode:
GDAL: GDALOpen(E:\Data\ORT10LT-2006\2//2749.aux) succeeds as HFA.
GDAL: GDALClose(E:\Data\ORT10LT-2006\2//2748.tif)
GDAL: GDALOpen(E:\Data\ORT10LT-2006\2//2749.tif) succeeds as GTiff.
GDAL: GDALClose(E:\Data\ORT10LT-2006\2//2748.aux)
GDAL: GDALOpen(E:\Data\ORT10LT-2006\2//2750.aux) succeeds as HFA.
GDAL: GDALClose(E:\Data\ORT10LT-2006\2//2749.tif)
GDAL: GDALOpen(E:\Data\ORT10LT-2006\2//2750.tif) succeeds as GTiff.
GDAL: GDALClose(E:\Data\ORT10LT-2006\2//2749.aux)

Looks like world files *.tfw are not detected.

comment:7 by ksgeograf, 16 years ago

ECW and MrSID is NOT supported by a regular MapGuide Installation, because of some license issues. You must manually download and install the plugins. Instructions and links are here: http://trac.osgeo.org/fdo/wiki/FdoGdalNotes

comment:8 by ksgeograf, 16 years ago

Version: 2.0.1

comment:9 by dumas65, 16 years ago

I installed Ecw libraries according that link. It didn't help. MapGuide maestro still can not project files.

Rechecked again. It is not only ecw case. I tried with esri tiff (tiff and external world file) and simple geotiff. All files were not projected correctly, same result like in attached files.

If I add resource form alias (e.g tiffs with external world files), data is displayed correctly in the map. Pushing 'set view to current layers extent' in map properties returns correct coordinates. Even in data source properties 'coordinate system override' displays correctly - "Transverse Mercator units...

If A add same data using composite option in 'coordinate system override' I have default. In map properties 'set view to current layers extent' I have -10000000,-10000000,10000000,1000000.

Again, this happens with ecw, tiff and geotiff file formats.

Any more ideas?

comment:10 by ksgeograf, 16 years ago

Are you saying that it works when you use an alias, but not when using direct path?

If so, does the path have spaces in it? I think there was some reports of trouble with spaces in the path for GDal.

comment:11 by dumas65, 16 years ago

Yes and no. In dataconnection properties I used - 'Single file or folder'. In this case coordinates are detected. But if I use 'composite' for same raster, coordinates are not detected. Directories have no spaces, I even tried directly from drive F:/

by the way, it was impossible to add rasters from alias in composite mode. I chose browse alias, then selected files, after pressing OK window still was empty.

comment:12 by dumas65, 16 years ago

I'm sorry. Alias directory loads ok, but its impossible to load singe files from alias. However, using composite mode and loading files from alias coordinates are not detected for both ecw and tiff files.

comment:13 by ksgeograf, 16 years ago

Status: newassigned

Ok. I see there is a bug/weird behavior when you select a single file, rather than a folder. I will fix that.

I will try to reproduce.

comment:14 by dumas65, 16 years ago

Thats great. Its most wanted feature for me at the moment. I have 2000 ortophoto images. So it takes time to load it to MGOS project.

If you need any help on reproducing or testing please contact me.

comment:15 by ksgeograf, 16 years ago

Ok, I just tried again.

I have one single file (from this post): C:\ecw2\7722.ecw

I have an Alias for C:, named CDrev. I have created four different featuresources:

  1. Single file or folder, path: C:\ecw2\7722.ecw
  2. Single file or folder, path: %MG_DATA_PATH_ALIAS[CDrev]%ecw2/
  3. Composite, add folder, selected [CDrev]ecw2
  4. Composite, add file, selected C:\ecw2\7722.ecw

For each of these, I have create a layer. I then insert all four layers into a map. Then I click on "Set view to current layers extent".

For all four layers, I get the exact same result: the correct coordinates.

Does your setup differ in any noticeable way? Can you reproduce my results?

comment:16 by ksgeograf, 16 years ago

In the 1.0.8 version of Maestro, there is now a button to inspect the spatial information. Hope that helps out.

in reply to:  16 comment:17 by dumas65, 16 years ago

Replying to ksgeograf:

In the 1.0.8 version of Maestro, there is now a button to inspect the spatial information. Hope that helps out.

I will install version 1.0.8 tomorrow. Actually I think I did same way you wrote. Anyway will try to do same you did. Will write news of course.

comment:18 by dumas65, 16 years ago

So, after Upgrading to 1.0.8 coordinates are detected OK. I did same things like before and same you wrote to here. That's fantastic. Unfortunately MGOS can not display more than one image: 1. If data source is created using 'single file or folder'. All cordinates OK (spatial contex) Layer is displayed in the map correctly. 2 If datasource is created using composite mode (sigle file, alias or folder -it does not matter). Coordinates are detected, (spatial context and config file.) But in map images are not displayed. I tested data with 'set view to current layers extent' coordinates are detected, however layer is not displayd in the map. Attaching config files.

by dumas65, 16 years ago

Attachment: config2.2 added

New config file: coordinates detected but image not displayed.

comment:19 by dumas65, 16 years ago

A'm Sorry. I was working on same feature datasourse, and just changing properties of composite (to same some time on creating layers and adding it to map). Now I tried with new datasourse. It seems that i can see images added in composite mode. At least when I add 1 image. If I add more than one image. There is problem in cordinate detection and images are resized. I will add config files tommorow.

comment:20 by dumas65, 16 years ago

I made little research on composite mode and image tiling. Look what I found on my system: 1.Adding one ecw file works perfect. Everething detected fine, displayed correctly.

  1. Adding more then one image does not work. Some min/max points are wrong detected (config and ecw files will be attached for checking). Map view only image 2764.ecw is displayed and its takes all view extend.
  2. Same using alias. some coordinates are misdetected, but image in map is not shown.

Can you check you have same?

by dumas65, 16 years ago

Attachment: config.2 added

Config file for 4 ecw imager in [] are real coordinates

by dumas65, 16 years ago

Attachment: 2663.ecw added

1 of 4 ecw images

by dumas65, 16 years ago

Attachment: 2664.ecw added

2 of 4 ecw images

by dumas65, 16 years ago

Attachment: 2763.ecw added

3 of 4 ecw images

by dumas65, 16 years ago

Attachment: 2764.ecw added

4 of 4 ecw images

comment:21 by dumas65, 16 years ago

I added all images to datasource. First image coordinates are OK all other with some mistakes: Min X: all same. Like minX of datasource Min Y: about 60% are same like minY of datasource. Looks like others are not correct to. Max X: This one looks OK. I checked some coordinates and did not found any mistakes. Max Y: all same. Like minY of datasource

comment:22 by ksgeograf, 16 years ago

I will try this shortly (I've been on vacation).

comment:23 by ksgeograf, 16 years ago

I have found a bug that made the coordinates for a single tile become the current maximum extent, rather than the extent of the single image.

I found it because you put the correct values besides the wrong ones in the config.

I have put up a preview release r3235 that should fix this. I am unable to display any of the images on my machine, but hopefully it works on yours.

Please let me know if this fixes the problem.

comment:24 by dumas65, 16 years ago

Last week I was on vacation too. I tried prievew release. Seems that everything working now. I was able to build dataset with 400files via composite mode. All images are displayed correctly.

Thanks for help! I see no problem to close this bug now.

comment:25 by ksgeograf, 16 years ago

Resolution: fixed
Status: assignedclosed

Cool. Thank you for reporting it, and supplying test data.

Note: See TracTickets for help on using tickets.