Hi,
I need to merge multiple S57 Layers into one. I’ve read this sample: wiki.thinkgeo.com/wiki/Sourc…091008.zip and I have two questions: Is it possible to merge S57 layers, if so how? Is there any sample for Desktop Edition?
Merging S-57 maps
Hi Bart,
Simple change can makes the sample works for desktop edition.
1. Replace DrawImage() to winformMaps1.Refresh();
2. Create Overlay when TestForm_Load like this:
LayerOverlay overlay = new LayerOverlay();
winformMaps1.Overlays.Add(overlay);
3. Replace mapEngine.StaticLayers to (winformsMap1.Overlays[0] as LayerOverlay).Layers
replace mapEngine.CurrentExtent to winformsMap1.CurrentExtent
delete mapEngine.BackgroundFillBrush = new GeoSolidBrush(GeoColor.GeographicColors.ShallowOcean);
add winformsMap1.MapUnit = GeographyUnit.DecimalDegree;
add winformsMap1.BackgroundOverlay.BackgroundBrush = new GeoSolidBrush(GeoColor.GeographicColors.ShallowOcean);
I am not sure whether S57 layers support merget because we haven’t tested that before, but if it’s not image but only data container, I think it can be merged.
Any question please let me know.
Regards,
Don
This sample is using, e.g. ShapeFileFeatureSource.CreateShapeFile(). I can’t use it to create S57 file, can I? I would like to know how to combine two S57FeatureLayers into one.
Hi Bart,
Sorry I maybe give you incorrect information, I missed something in the sample.
Today I review related code about S57, it looks we just support read it now, but not for edit. But the merge opearation need create or edit a exsiting S57 file. So merge shouldn’t works to S57 file.
But from the sample code I think merge two S57 files to a shape file should be possible.
Regards,
Don