Lines Matching refs:codewords

50 {	/* Log of the step size multiplier. Operated on by codewords. */
119 /* Table mapping codewords to scale factor deltas. */
126 /* Table mapping codewords to quantized delta interval steps. */
152 static void nms_adpcm_block_pack_16 (const int16_t codewords [], uint16_t block [], int16_t rms) ;
153 static void nms_adpcm_block_pack_24 (const int16_t codewords [], uint16_t block [], int16_t rms) ;
154 static void nms_adpcm_block_pack_32 (const int16_t codewords [], uint16_t block [], int16_t rms) ;
156 static void nms_adpcm_block_unpack_16 (const uint16_t block [], int16_t codewords [], int16_t *rms) ;
157 static void nms_adpcm_block_unpack_24 (const uint16_t block [], int16_t codewords [], int16_t *rms) ;
158 static void nms_adpcm_block_unpack_32 (const uint16_t block [], int16_t codewords [], int16_t *rms) ;
438 ** All codewords are nibbles, with the least significant bits dropped as
448 ** Reads 21 shorts from block, unpacks 160 codewords of 2-bits each, writing
449 ** each to its sequential array index of codewords. If rms is non-null, the
453 nms_adpcm_block_unpack_16 (const uint16_t block [], int16_t codewords [], int16_t *rms)
466 codewords [k++] = (w >> 12) & 0xc ;
467 codewords [k++] = (w >> 8) & 0xc ;
468 codewords [k++] = (w >> 4) & 0xc ;
469 codewords [k++] = w & 0xc ;
481 ** Reads 31 shorts from block, unpacks 160 codewords of 3-bits each, writing
482 ** each to its sequential array index of codewords. If rms is non-null, the
486 nms_adpcm_block_unpack_24 (const uint16_t block [], int16_t codewords [], int16_t *rms)
503 codewords [k++] = (w >> 12) & 0xe ;
504 codewords [k++] = (w >> 8) & 0xe ;
505 codewords [k++] = (w >> 4) & 0xe ;
506 codewords [k++] = w & 0xe ;
518 ** Reads 41 shorts from block, unpacks 160 codewords of 4-bits each, writing
519 ** each to its sequential array index of codewords. If rms is non-null, the
523 nms_adpcm_block_unpack_32 (const uint16_t block [], int16_t codewords [], int16_t *rms)
529 codewords [k++] = (w >> 12) & 0xf ;
530 codewords [k++] = (w >> 8) & 0xf ;
531 codewords [k++] = (w >> 4) & 0xf ;
532 codewords [k++] = w & 0xf ;
543 ** Reads 160 indicies of codewords for one 2-bit codeword each, packing them
547 nms_adpcm_block_pack_16 (const int16_t codewords [], uint16_t block [], int16_t rms)
552 { w = codewords [k++] << 12 ;
553 w |= codewords [k++] << 8 ;
554 w |= codewords [k++] << 4 ;
555 w |= codewords [k++] ;
556 w |= codewords [k++] << 10 ;
557 w |= codewords [k++] << 6 ;
558 w |= codewords [k++] << 2 ;
559 w |= codewords [k++] >> 2 ;
569 ** Reads 160 indicies of codewords for one 3-bit codeword each, packing them
573 nms_adpcm_block_pack_24 (const int16_t codewords [], uint16_t block [], int16_t rms)
579 { w [0] = codewords [k++] << 12 ;
580 w [0] |= codewords [k++] << 8 ;
581 w [0] |= codewords [k++] << 4 ;
582 w [0] |= codewords [k++] ;
584 w [1] = codewords [k++] << 12 ;
585 w [1] |= codewords [k++] << 8 ;
586 w [1] |= codewords [k++] << 4 ;
587 w [1] |= codewords [k++] ;
589 w [2] = codewords [k++] << 12 ;
590 w [2] |= codewords [k++] << 8 ;
591 w [2] |= codewords [k++] << 4 ;
592 w [2] |= codewords [k++] ;
594 residual = codewords [k++] << 12 ;
595 residual |= codewords [k++] << 8 ;
596 residual |= codewords [k++] << 4 ;
597 residual |= codewords [k++] ;
616 ** Reads 160 indicies of codewords for one 4-bit codeword each, packing them
620 nms_adpcm_block_pack_32 (const int16_t codewords [], uint16_t block [], int16_t rms)
625 { w = codewords [k++] << 12 ;
626 w |= codewords [k++] << 8 ;
627 w |= codewords [k++] << 4 ;
628 w |= codewords [k++] ;