00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 #ifndef GEOS_OP_BUFFER_SUBGRAPHDEPTHLOCATER_H
00020 #define GEOS_OP_BUFFER_SUBGRAPHDEPTHLOCATER_H
00021
00022 #include <geos/export.h>
00023
00024 #include <vector>
00025
00026 #include <geos/geom/LineSegment.h>
00027
00028
00029 namespace geos {
00030 namespace geom {
00031 class Coordinate;
00032 }
00033 namespace geomgraph {
00034 class DirectedEdge;
00035 }
00036 namespace operation {
00037 namespace buffer {
00038 class BufferSubgraph;
00039 class DepthSegment;
00040 }
00041 }
00042 }
00043
00044 namespace geos {
00045 namespace operation {
00046 namespace buffer {
00047
00059 class GEOS_DLL SubgraphDepthLocater {
00060
00061 public:
00062
00063 SubgraphDepthLocater(std::vector<BufferSubgraph*> *newSubgraphs)
00064 :
00065 subgraphs(newSubgraphs)
00066 {}
00067
00068 ~SubgraphDepthLocater() {}
00069
00070 int getDepth(const geom::Coordinate &p);
00071
00072 private:
00073
00074 std::vector<BufferSubgraph*> *subgraphs;
00075
00076 geom::LineSegment seg;
00077
00086 void findStabbedSegments(const geom::Coordinate &stabbingRayLeftPt,
00087 std::vector<DepthSegment*>& stabbedSegments);
00088
00098 void findStabbedSegments(const geom::Coordinate &stabbingRayLeftPt,
00099 std::vector<geomgraph::DirectedEdge*> *dirEdges,
00100 std::vector<DepthSegment*>& stabbedSegments);
00101
00111 void findStabbedSegments(const geom::Coordinate &stabbingRayLeftPt,
00112 geomgraph::DirectedEdge *dirEdge,
00113 std::vector<DepthSegment*>& stabbedSegments);
00114
00115 };
00116
00117
00118 }
00119 }
00120 }
00121
00122 #endif // ndef GEOS_OP_BUFFER_SUBGRAPHDEPTHLOCATER_H
00123