#ifndef KSW2_H_ #define KSW2_H_ #include #ifdef __cplusplus extern "C" { #endif /** * Global alignment with moving a band * * @param km memory pool, when used with kalloc * @param qlen query length * @param query query sequence with 0 <= query[i] < m * @param tlen target length * @param target target sequence with 0 <= target[i] < m * @param m number of residue types * @param mat m*m scoring mattrix in one-dimension array * @param gapo gap open penalty; a gap of length l cost "-(gapo+l*gape)" * @param gape gap extension penalty * @param w band width * @param n_cigar (out) number of CIGAR elements * @param cigar (out) BAM-encoded CIGAR; caller need to deallocate with kfree(km, ) * * @return score of the alignment */ int ksw_global(void *km, int qlen, const uint8_t *query, int tlen, const uint8_t *target, int8_t m, const int8_t *mat, int8_t gapo, int8_t gape, int w, int *n_cigar_, uint32_t **cigar_); int ksw_global2(void *km, int qlen, const uint8_t *query, int tlen, const uint8_t *target, int8_t m, const int8_t *mat, int8_t gapo, int8_t gape, int w, int *n_cigar_, uint32_t **cigar_); int ksw_global2_sse(void *km, int qlen, const uint8_t *query, int tlen, const uint8_t *target, int8_t m, const int8_t *mat, int8_t gapo, int8_t gape, int w, int *n_cigar_, uint32_t **cigar_); void ksw_gen_simple_mat(int m, int8_t *mat, int8_t a, int8_t b); #ifdef __cplusplus } #endif #endif