Menu

#3 Bug in org.wkb4j.engine.readPoints(int, int)

open
nobody
None
5
2008-12-18
2008-12-18
No

---------------------------------------------------------
OLD:
---------------------------------------------------------
/**
* Reads a number of Points.
* @param pointCount
* @param dimension unused parameter
* @throws IOException
*/
protected void readPoints(int pointCount, int dimension)
throws IOException {
pointCount <<= 1;
double[] sendVal = new double[pointCount];
for (int i = 0; i < pointCount; i++) {
sendVal[i] = (float) inputStream.readDouble();

}
factory.addPoints(sendVal);
}
---------------------------------------------------------
New:
---------------------------------------------------------
/**
* Reads a number of Points.
* @param pointCount
* @param dimension unused parameter
* @throws IOException
*/
protected void readPoints(int pointCount, int dimension)
throws IOException {
pointCount <<= 1;
double[] sendVal = new double[pointCount];
for (int i = 0; i < pointCount; i++) {
// sendVal[i] = (float) inputStream.readDouble();
sendVal[i] = inputStream.readDouble();
}
factory.addPoints(sendVal);
}

Discussion


Log in to post a comment.

MongoDB Logo MongoDB