annotate pyPRADA_1.2/tools/bwa-0.5.7-mh/bwt_lite.h @ 0:acc2ca1a3ba4

Uploaded
author siyuan
date Thu, 20 Feb 2014 00:44:58 -0500
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
1 #ifndef BWT_LITE_H_
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
2 #define BWT_LITE_H_
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
3
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
4 #include <stdint.h>
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
5
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
6 typedef struct {
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
7 uint32_t seq_len, bwt_size, n_occ;
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
8 uint32_t primary;
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
9 uint32_t *bwt, *occ, *sa, L2[5];
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
10 uint32_t cnt_table[256];
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
11 } bwtl_t;
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
12
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
13 #define bwtl_B0(b, k) ((b)->bwt[(k)>>4]>>((~(k)&0xf)<<1)&3)
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
14
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
15 #ifdef __cplusplus
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
16 extern "C" {
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
17 #endif
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
18
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
19 bwtl_t *bwtl_seq2bwtl(int len, const uint8_t *seq);
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
20 inline uint32_t bwtl_occ(const bwtl_t *bwt, uint32_t k, uint8_t c);
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
21 inline void bwtl_occ4(const bwtl_t *bwt, uint32_t k, uint32_t cnt[4]);
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
22 inline void bwtl_2occ4(const bwtl_t *bwt, uint32_t k, uint32_t l, uint32_t cntk[4], uint32_t cntl[4]);
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
23 void bwtl_destroy(bwtl_t *bwt);
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
24
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
25 #ifdef __cplusplus
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
26 }
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
27 #endif
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
28
acc2ca1a3ba4 Uploaded
siyuan
parents:
diff changeset
29 #endif