| 1143 | |
| 1144 | template <bool excludeSecondaries> |
| 1145 | int fillTempLineArray(splitLine_t * block, state_t * state, int mask, bool flagValue) |
| 1146 | { |
| 1147 | // Count the secondaries we have for this read (if any), and store their ptrs into an array. |
| 1148 | int count = 0; |
| 1149 | for (splitLine_t * line = block; line != NULL; line = line->next) |
| 1150 | { |
| 1151 | // For all the ones that are the current read of interest.... |
| 1152 | // Check if they are a primary or complementary alignment. |
| 1153 | if (checkFlag(line, mask) == flagValue && !(excludeSecondaries && isSecondaryAlignment(line))) |
| 1154 | { |
| 1155 | // Add the ptr to this line to the sort array. |
| 1156 | // If it won't fit, double the array size. |
| 1157 | if (count >= state->splitterArrayMaxSize) |
| 1158 | { |
| 1159 | state->splitterArrayMaxSize *= 2; |
| 1160 | state->splitterArray = (splitLine_t **)(realloc(state->splitterArray, |
| 1161 | state->splitterArrayMaxSize * sizeof(splitLine_t *))); |
| 1162 | } |
| 1163 | state->splitterArray[count] = line; |
| 1164 | count += 1; |
| 1165 | } |
| 1166 | } |
| 1167 | return count; |
| 1168 | } |
| 1169 | |
| 1170 | void markSplitterUnmappedClipped(splitLine_t * block, state_t * state, int mask, bool flagValue) |
| 1171 | { |
nothing calls this directly
no test coverage detected