19#ifndef GEOS_IDX_QUADTREE_DOUBLEBITS_H
20#define GEOS_IDX_QUADTREE_DOUBLEBITS_H
22#include <geos/export.h>
23#include <geos/platform.h>
44class GEOS_DLL DoubleBits {
48 static const int EXPONENT_BIAS=1023;
50 static double powerOf2(
int exp);
52 static int exponent(
double d);
54 static double truncateToPowerOfTwo(
double d);
56 static std::string toBinaryString(
double d);
58 static double maximumCommonMantissa(
double d1,
double d2);
60 DoubleBits(
double nx);
62 double getDouble()
const;
70 void zeroLowerBits(
int nBits);
72 int getBit(
int i)
const;
std::string toString() const
A representation of the Double bits formatted for easy readability.
int numCommonMantissaBits(const DoubleBits &db) const
This computes the number of common most-significant bits in the mantissa.
int getExponent() const
Determines the exponent for the number.
int64 biasedExponent() const
Determines the exponent for the number.
Contains classes that implement a Quadtree spatial index.
Definition DoubleBits.h:29
Provides classes for various kinds of spatial indexes.
Definition IndexedNestedRingTester.h:31
Basic namespace for all GEOS functionalities.
Definition IndexedNestedRingTester.h:25