Mapinfo to JTS geometry ?

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Mapinfo to JTS geometry ?

Baroudi Malek
Hello,
Did you know how can I transform mapinfo geometry to JTS geometry ?

Pline
10 -----> Multiline ou line ?
1513820.32 5037093.09
1513902.08 5037090.51
1513970.04 5037065.27
    Pen (1,2,0) 
Region  1 -----> Multipolygon  ??
  15
1513414.09 5037279.15
1513562.28 5037323.47
1513679.8 5037268.84
1513786.09 5037190.5
    Pen (1,2,0) 
    Brush (2,16777215,16777215)
    Center 1513515.78 5037046.19
Pline Multiple 3  ----------> Multiline ??
  8
1513581.65 5036642.7
1513626.79 5036632.88
1513679.9 5036634.67
  5
1514016.27 5036499.85
1514102.13 5036423.97
  6
1514183.57 5036223.09
1514187.99 5036136.49
1514068.49 5036058.81
    Pen (1,2,0)

Regards Mbaroudi


_______________________________________________
jts-devel mailing list
[hidden email]
http://lists.refractions.net/mailman/listinfo/jts-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Mapinfo to JTS geometry ?

Sunburned Surveyor
Baroudi,

I don't work with Mapinfo, but if that is the geometry format it
shouldn't be too difficult to convert to JTS. You'll need to write a
parser that reads the Mapinfo geometry information and that constructs
JTS geometry information.

I see that the Mapinfo format includes styling information. Note that
JTS is a geometry library, and its geometry definitions do not store
styling information. You would need to find a "non-JTS" way to store
this styling information. OpenJUMP uses Layer objects to do this.

I hope this helps. I don't have time to code a converter for you, but
if you know some Java programming I can help get you started. Or you
could offer to hire someone for the work...Maybe Martin is interested.
:]

The Sunburned Surveyor

On Thu, Aug 21, 2008 at 9:18 AM, Baroudi Malek <[hidden email]> wrote:

> Hello,
> Did you know how can I transform mapinfo geometry to JTS geometry ?
>
> Pline 10 -----> Multiline ou line ?
> 1513820.32 5037093.09
> 1513902.08 5037090.51
> 1513970.04 5037065.27
>     Pen (1,2,0)
> Region  1 -----> Multipolygon  ??
>   15
> 1513414.09 5037279.15
> 1513562.28 5037323.47
> 1513679.8 5037268.84
> 1513786.09 5037190.5
>     Pen (1,2,0)
>     Brush (2,16777215,16777215)
>     Center 1513515.78 5037046.19
> Pline Multiple 3  ----------> Multiline ??
>   8
> 1513581.65 5036642.7
> 1513626.79 5036632.88
> 1513679.9 5036634.67
>   5
> 1514016.27 5036499.85
> 1514102.13 5036423.97
>   6
> 1514183.57 5036223.09
> 1514187.99 5036136.49
> 1514068.49 5036058.81
>     Pen (1,2,0)
>
> Regards Mbaroudi
>
>
> _______________________________________________
> jts-devel mailing list
> [hidden email]
> http://lists.refractions.net/mailman/listinfo/jts-devel
>
>
_______________________________________________
jts-devel mailing list
[hidden email]
http://lists.refractions.net/mailman/listinfo/jts-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Mapinfo to JTS geometry ?

michaelm-2
In reply to this post by Baroudi Malek
Hi,

Here, you will find a plugin I wrote for OpenJUMP to load mif/mid files :

http://geo.michaelm.free.fr/OpenJUMP/resources/drivers/

in the file named plugin-oj-mmdriver-dist-0.4.1.zip, you should find the
source with the code to convert mif geometries to jts geometries.
see class MifMidParser, method parseGeometry

Hope that helps,

Michaël


Baroudi Malek a écrit :

> Hello,
> Did you know how can I transform mapinfo geometry to JTS geometry ?
> *
> Pline* 10 -----> Multiline ou line ?
> 1513820.32 5037093.09
> 1513902.08 5037090.51
> 1513970.04 5037065.27
>     Pen (1,2,0)
> *Region * 1 -----> Multipolygon  ??
>   15
> 1513414.09 5037279.15
> 1513562.28 5037323.47
> 1513679.8 5037268.84
> 1513786.09 5037190.5
>     Pen (1,2,0)
>     Brush (2,16777215,16777215)
>     Center 1513515.78 5037046.19
> *Pline Multiple* 3  ----------> Multiline ??
>   8
> 1513581.65 5036642.7
> 1513626.79 5036632.88
> 1513679.9 5036634.67
>   5
> 1514016.27 5036499.85
> 1514102.13 5036423.97
>   6
> 1514183.57 5036223.09
> 1514187.99 5036136.49
> 1514068.49 5036058.81
>     Pen (1,2,0)
>
> Regards Mbaroudi
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> jts-devel mailing list
> [hidden email]
> http://lists.refractions.net/mailman/listinfo/jts-devel
>  

_______________________________________________
jts-devel mailing list
[hidden email]
http://lists.refractions.net/mailman/listinfo/jts-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Mapinfo to JTS geometry ?

Sunburned Surveyor
Michael,

You're awsome. :]

SS

On Fri, Aug 22, 2008 at 10:04 AM, Michael Michaud
<[hidden email]> wrote:

> Hi,
>
> Here, you will find a plugin I wrote for OpenJUMP to load mif/mid files :
>
> http://geo.michaelm.free.fr/OpenJUMP/resources/drivers/
>
> in the file named plugin-oj-mmdriver-dist-0.4.1.zip, you should find the
> source with the code to convert mif geometries to jts geometries.
> see class MifMidParser, method parseGeometry
>
> Hope that helps,
>
> Michaël
>
>
> Baroudi Malek a écrit :
>>
>> Hello,
>> Did you know how can I transform mapinfo geometry to JTS geometry ?
>> *
>> Pline* 10 -----> Multiline ou line ?
>> 1513820.32 5037093.09
>> 1513902.08 5037090.51
>> 1513970.04 5037065.27
>>    Pen (1,2,0) *Region * 1 -----> Multipolygon  ??
>>  15
>> 1513414.09 5037279.15
>> 1513562.28 5037323.47
>> 1513679.8 5037268.84
>> 1513786.09 5037190.5
>>    Pen (1,2,0)    Brush (2,16777215,16777215)
>>    Center 1513515.78 5037046.19
>> *Pline Multiple* 3  ----------> Multiline ??
>>  8
>> 1513581.65 5036642.7
>> 1513626.79 5036632.88
>> 1513679.9 5036634.67
>>  5
>> 1514016.27 5036499.85
>> 1514102.13 5036423.97
>>  6
>> 1514183.57 5036223.09
>> 1514187.99 5036136.49
>> 1514068.49 5036058.81
>>    Pen (1,2,0)
>>
>> Regards Mbaroudi
>>
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> jts-devel mailing list
>> [hidden email]
>> http://lists.refractions.net/mailman/listinfo/jts-devel
>>
>
> _______________________________________________
> jts-devel mailing list
> [hidden email]
> http://lists.refractions.net/mailman/listinfo/jts-devel
>
_______________________________________________
jts-devel mailing list
[hidden email]
http://lists.refractions.net/mailman/listinfo/jts-devel
Loading...