[fdo-users] Conversion from Fgf to Wkb format.

prem pkbalakrishnan at tatapowersed.com
Mon Apr 8 02:02:39 PDT 2013


 This post was updated on Apr 08, 2013; 2:31pm.
hi,

I wanted to store geometry in my database in WKB format.
Presently with below lines of code,i am able to store geometry in
database,but not sure it is in which format Wkb or Fgf.
(if it is not Wkb)How to convert from Fgf to Wkb????
               
double OverlayLineString[]={59.0, 18.0, 67.0, 18.0,67.0, 13.0, 59.0, 13.0,
59.0, 18.0};
FdoInt32  numOverlayLineOrdinates=10;
FdoPtr<FdoILineString> overlayline;
overlayline=sampleGeometryFactory->CreateLineString(FdoDimensionality_XY,numOverlayLineOrdinates,OverlayLineString);
                               
FdoByteArray * geometryByteArray
=sampleGeometryFactory->GetFgf(overlayline);
sampleGeometryValue->SetGeometry(geometryByteArray);

If i change GetFgf() to GetWkb() as below, no data is written into database.

FdoByteArray * geometryByteArray
=sampleGeometryFactory->GetWkb(overlayline);
sampleGeometryValue->SetGeometry(geometryByteArray);

Thanks,
Prem 



--
View this message in context: http://osgeo-org.1560.n6.nabble.com/Conversion-from-Fgf-to-Wkb-format-tp5045173.html
Sent from the FDO Users mailing list archive at Nabble.com.


More information about the fdo-users mailing list