[mapguide-users] Re: how to convert agf to wkt?

mahpooya mahpooya at gmail.com
Mon May 23 08:06:05 EDT 2011


In this API Reference:
http://mapguide.osgeo.org/files/mapguide/docs/2.0/d5/da0/class_mg_wkt_reader_writer.htm

It convert $agfTextPoint to MgGeometry:

$agfTextPoint = "POINT XY (0 0)";
$pointGeometryFromWkt = $wktReaderWriter->Read($agfTextPoint);

And then convert it into MgByteReader : 

$byteReader = $agfReaderWriter->Write($pointGeometryFromAgfText);

And again convert it to MgGeometry:

$pointGeometryFromBytes = $agfReaderWriter->Read($byteReader);

And again convert it to AGF text format:

$agfTextPoint = $wktReaderWriter->Write($pointGeometryFromBytes);

This means farce work
This means AGF to AGF converting
But i want convert AGF to WKT for passing to oracle.

The API Reference Says MgWktReaderWriter::write with one parameter(in
MgGeometry format) is write a geometry object to a string in AGF Text
format. 
And MgWktReaderWriter::write with two parameters(in MgGeometry format,in
MgTransform format) is writes a geometry object to a string in WKT format
applying the specified transform during the write. 
But i dont know what i should pass as second parameter.
Please help me.


--
View this message in context: http://osgeo-org.1803224.n2.nabble.com/how-to-convert-agf-to-wkt-tp6391716p6394132.html
Sent from the MapGuide Users mailing list archive at Nabble.com.


More information about the mapguide-users mailing list