
On Feb 11, 2009, at 16:17, Mark Burton wrote:
Robert (or anyone else that knows), is this exception caused by points being too close together? The code in BitWriter.java that's barfing is:
public void putn(int bval, int nb) { int val = bval & ((1<<nb) - 1); int n = nb;
// We need to be able to deal with more than 24 bits, but now we can't yet if (n >= 24) throw new IllegalArgumentException();
If so, what's the minimum distance between points?
If not, can you say why it needs 24 bits or more?
I don't know the BitWriter code, or why the limit of 24 bits. These bit streams come from LinePreparer, and each putn should correspond to one latitude or longitude delta between adjacent coordinates in a polyline. 24 bits seems quite large for a delta. A large delta should correspond to a large distance between coordinates, but since 2**24 map units is 360 degrees, this limit shouldn't really be reached. Perhaps it's some bug close to longitude 0? I think mkgmap puts out some debugging info from the LinePreparer: try java -Dlog.config=resources/logging.properties Cheers Robert