libcaption: fix parity code calculation

A misplaced parenthesis was causing the odd parity bit to
be set based on an incomplete version of the preamble
This commit is contained in:
Mathieu Duponchelle 2020-11-20 21:32:30 +01:00
parent 084c9d1447
commit a3dafea688

View file

@ -46,8 +46,8 @@ eia608_row_pramble (int row, int chan, int x, int underline)
{
row = eia608_reverse_row_map[row & 0x0F];
return eia608_parity (0x1040 | (chan ? 0x0800 : 0x0000) | ((row << 7) &
0x0700) | ((row << 5) & 0x0020)) | ((x << 1) & 0x001E) | (underline ?
0x0001 : 0x0000);
0x0700) | ((row << 5) & 0x0020) | ((x << 1) & 0x001E) | (underline ?
0x0001 : 0x0000));
}
uint16_t