| 72 | } |
| 73 | |
| 74 | char *msShapeToWKT(shapeObj *shape) |
| 75 | { |
| 76 | #ifdef USE_GEOS |
| 77 | char* pszGEOSStr; |
| 78 | char* pszStr; |
| 79 | pszGEOSStr = msGEOSShapeToWKT(shape); |
| 80 | pszStr = (pszGEOSStr) ? msStrdup(pszGEOSStr) : NULL; |
| 81 | msGEOSFreeWKT(pszGEOSStr); |
| 82 | return pszStr; |
| 83 | #elif defined(USE_OGR) |
| 84 | return msOGRShapeToWKT(shape); |
| 85 | #else |
| 86 | msSetError(MS_MISCERR, "WKT support is not available, please compile MapServer with GEOS or OGR support.", "msShapeToWKT()"); |
| 87 | return NULL; |
| 88 | #endif |
| 89 | } |
| 90 | |
| 91 | void msInitShape(shapeObj *shape) |
| 92 | { |
no test coverage detected