Skip to content

Commit

Permalink
Add Comment
Browse files Browse the repository at this point in the history
  • Loading branch information
kobanium committed May 17, 2018
1 parent 4d5c576 commit 198964c
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 6 deletions.
6 changes: 6 additions & 0 deletions src/SgfExtractor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ static int GetPlayerName( SGF_record_t *kifu, char *sgf_text, int cursor, int co
static int SkipData( SGF_record_t *kifu, char *sgf_text, int cursor );


//////////////////
// 着手の抽出 //
//////////////////
int
GetKifuMove( const SGF_record_t *kifu, int n )
{
Expand All @@ -41,6 +44,9 @@ GetKifuMove( const SGF_record_t *kifu, int n )
}


////////////////////////////
// SGFファイルの読み込み //
////////////////////////////
void
ExtractKifu( const char *file_name, SGF_record_t *kifu )
{
Expand Down
14 changes: 8 additions & 6 deletions src/SgfExtractor.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,22 +11,24 @@ struct SGF_record_t {
int handicap_x[20]; // 置き石(x座標)
int handicap_y[20]; // 置き石(y座標)
int board_size; // 盤のサイズ
char black_name[256];
char white_name[256];
char black_name[256]; // 黒番のプレイヤーの名前
char white_name[256]; // 白番のプレイヤーの名前
double komi; // コミ
};


enum KIFU_RESULT {
R_JIGO,
R_BLACK,
R_WHITE,
R_UNKNOWN,
R_JIGO, // 持碁
R_BLACK, // 黒勝ち
R_WHITE, // 白勝ち
R_UNKNOWN, // 不明
};


// SGFファイルの読み込み
void ExtractKifu( const char *file_name, SGF_record_t *kifu );

// 着手を抽出
int GetKifuMove( const SGF_record_t *kifu, int n );

#endif

0 comments on commit 198964c

Please sign in to comment.