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