Go to the documentation of this file.00001
00002
00003
00004
00005
00006 #ifndef GO_REGIONUTIL_H
00007 #define GO_REGIONUTIL_H
00008
00009 #include "SgBlackWhite.h"
00010 #include "SgVector.h"
00011 #include "SgPoint.h"
00012
00013 class GoBoard;
00014 class SgPointSet;
00015
00016
00017
00018 namespace GoRegionUtil
00019 {
00020
00021 bool StaticIs1VitalAndConnected(const GoBoard& board,
00022 const SgPointSet& pts,
00023 SgBlackWhite color);
00024
00025
00026 bool Has2SureLiberties(const GoBoard& board, const SgPointSet& pts,
00027 SgBlackWhite color,
00028 const SgVector<SgPoint>& boundaryAnchors);
00029
00030
00031
00032
00033
00034 bool Has2IPorEyes(const GoBoard& board, const SgPointSet& pts,
00035 SgBlackWhite color,
00036 const SgVector<SgPoint>& boundaryAnchors);
00037
00038
00039
00040 bool IsSingleBlock(const GoBoard& board, const SgPointSet& pts,
00041 SgBlackWhite color);
00042
00043
00044
00045
00046
00047 bool IsSmallRegion(const GoBoard& board, const SgPointSet& pts,
00048 SgBlackWhite opp);
00049
00050
00051
00052
00053
00054 void FindCurrentAnchors(const GoBoard& board,
00055 const SgVector<SgPoint>& origAnchors,
00056 SgVector<SgPoint>* currentAnchors);
00057
00058 }
00059
00060
00061
00062 #endif // GO_REGIONUTIL_H