Skip to content
Permalink
Browse files
fix msvc build errors
git-svn-id: http://svn.osgeo.org/qgis/trunk@10485 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
jef committed Apr 6, 2009
1 parent 846a43c commit 472848e036bf06e30166d6132974e381f9f7be02
@@ -274,7 +274,7 @@ namespace pal {
bool computeLineSegIntersection (double x1, double y1, double x2, double y2, // 1st line
double x3, double y3, double x4, double y4, // 2nd segment
double *x, double *y) {
double cp1, cp2, cp3, cp4;
double cp1, cp2;
cp1 = cross_product (x1, y1, x2, y2, x3, y3);
cp2 = cross_product (x1, y1, x2, y2, x4, y4);

@@ -53,7 +53,7 @@ namespace pal {
class Pal;
class SimpleMutex;

struct Feat;
class Feat;

/**
* \brief A layer of spacial entites
@@ -40,6 +40,9 @@
#include <list>
#include <iostream>

#ifdef _MSC_VER
#include <time.h>
#endif

// TODO ${MAJOR} ${MINOR} etc instead of 0.2

@@ -1317,7 +1317,7 @@ namespace pal {
std::cout << " Conflictual..." << std::endl;
#endif
int feat, rfeat;
bool sub = ctx->featWrap;
bool sub = ctx->featWrap!=NULL;

feat = lp->probFeat;
if (sub) {
@@ -1578,6 +1578,8 @@ namespace pal {
} catch (int i) {
#ifdef _DEBUG_FULL_
std::cout << "catch int " << i << std::endl;
#else
i;
#endif
while (conflicts->size() > 0)
conflicts->pop_front();
@@ -1838,6 +1840,8 @@ namespace pal {
} catch (int i) {
#ifdef _DEBUG_FULL_
std::cout << "catch Cycle in chain" << std::endl;
#else
i;
#endif
while (conflicts->size() > 0)
conflicts->pop_front();
@@ -247,8 +247,6 @@ namespace pal {
void extractXYCoord (Feat *f) {
int i, j;

double phi, lambda;

//Projection *proj = pal->proj;

const GEOSCoordSequence *coordSeq;
@@ -58,7 +58,8 @@ namespace pal {
/**
* \brief For translating feature from GEOS to Pal
*/
typedef struct Feat {
class Feat {
public:
const GEOSGeometry *geom;
const char *id;
int type;
@@ -72,7 +73,7 @@ namespace pal {
int nbHoles;
PointSet **holes;

} Feat;
};


/**
@@ -182,8 +182,8 @@ int QgsCentralPointPositionManager::findObjectPosition(const unsigned char* wkb,
}
currentPosition+= sizeof(int);

double x[numberOfPoints];
double y[numberOfPoints];
double *x = new double[numberOfPoints];
double *y = new double[numberOfPoints];

for(int i = 0; i < numberOfPoints; ++i)
{
@@ -197,7 +197,11 @@ int QgsCentralPointPositionManager::findObjectPosition(const unsigned char* wkb,
}
}
double centroidX, centroidY;
if(calculatePolygonCentroid(x, y, numberOfPoints, centroidX, centroidY) != 0)
int res = calculatePolygonCentroid(x, y, numberOfPoints, centroidX, centroidY);
delete [] x;
delete [] y;

if( res != 0)
{
return 1;
}
@@ -40,6 +40,7 @@ QgsOverlayObject& QgsOverlayObject::operator=(const QgsOverlayObject& other)
mPositions = other.positions();
mRotation = other.rotation();
mGeometry = new QgsGeometry(*(other.geometry()));
return *this;
}

GEOSGeometry* QgsOverlayObject::getGeosGeometry()
@@ -158,4 +158,5 @@ bool QgsBarDiagramFactory::_writeXML(QDomNode& factory_node, QDomDocument& doc)
QDomText barWidthText = doc.createTextNode(QString::number(mBarWidth));
barWidthElem.appendChild(barWidthText);
factory_node.appendChild(barWidthElem);
return true;
}
@@ -30,9 +30,9 @@ class QDomNode;
class QImage;

//structure that describes a renderer entry
struct QgsDiagramItem
class QgsDiagramItem
{

public:
QVariant value;
int size;
};

0 comments on commit 472848e

Please sign in to comment.