version 1.4.63b
[polyglot.git] / hash.h
1
2 // hash.h
3
4 #ifndef HASH_H
5 #define HASH_H
6
7 // includes
8
9 #include "board.h"
10 #include "util.h"
11
12 // defines
13
14 #define RandomPiece          0
15 // 12 * 64
16 #define RandomCastle       768
17 // 4
18 #define RandomEnPassant    772
19 // 8
20 #define  RandomTurn        780
21 // 1
22
23 // functions
24
25 extern void   hash_init       ();
26
27 extern uint64 hash_key        (const board_t * board);
28
29 extern uint64 hash_piece_key  (int piece, int square);
30 extern uint64 hash_castle_key (int flags);
31 extern uint64 hash_ep_key     (int square);
32 extern uint64 hash_turn_key   (int colour);
33
34 extern uint64 hash_random_64  (int index);
35
36 #endif // !defined HASH_H
37
38 // end of hash.h
39