src/rotateorthlow.c
l_uint8 *
makeReverseByteTab2(void)
{
l_int32   i;
l_uint8  *tab;

    PROCNAME("makeReverseByteTab2");

    if ((tab = (l_uint8 *)CALLOC(256, sizeof(l_uint8))) == NULL)
        return (l_uint8 *)ERROR_PTR("calloc fail for tab", procName, NULL);

    for (i = 0; i < 256; i++)
        tab[i] = ((0xc0 & i) >> 6) |
                 ((0x30 & i) >> 2) |
                 ((0x0c & i) << 2) |
                 ((0x03 & i) << 6);
    return tab;
}
/*!
 *  makeReverseByteTab2()
 *
 *  Notes:
 *      (1) This generates an 8 bit lookup table for reversing
 *          the order of four 2-bit pixels.
 */
makeReverseByteTab2()
Notes:
(1) This generates an 8 bit lookup table for reversing
the order of four 2-bit pixels.
makeReverseByteTab2 () Notes : ( 1 ) This generates an 8 bit lookup table for reversing the order of four 2 - bit pixels .
l_uint8 *
makeReverseByteTab2(void)
{
l_int32   i;
l_uint8  *tab;
    PROCNAME("makeReverseByteTab2");
    if ((tab = (l_uint8 *)CALLOC(256, sizeof(l_uint8))) == NULL)
        return (l_uint8 *)ERROR_PTR("calloc fail for tab", procName, NULL);
    for (i = 0; i < 256; i++)
        tab[i] = ((0xc0 & i) >> 6) |
                 ((0x30 & i) >> 2) |
                 ((0x0c & i) << 2) |
                 ((0x03 & i) << 6);
    return tab;
}
l_uint8 * makeReverseByteTab2 ( void ) { l_int32 i ; l_uint8 * tab ; PROCNAME ( " " ) ; if ( ( tab = ( l_uint8 * ) CALLOC ( 256 , sizeof ( l_uint8 ) ) ) == NULL ) return ( l_uint8 * ) ERROR_PTR ( " " , procName , NULL ) ; for ( i = 0 ; i < 256 ; i ++ ) tab [ i ] = ( ( 0xc0 & i ) >> 6 ) | ( ( 0x30 & i ) >> 2 ) | ( ( 0x0c & i ) << 2 ) | ( ( 0x03 & i ) << 6 ) ; return tab ; }
makeReverseByteTab2()
  Notes:
      (1) This generates an 8 bit lookup table for reversing
          the order of four 2-bit pixels.
makeReverseByteTab2 () Notes : ( 1 ) This generates an 8 bit lookup table for reversing the order of four 2 - bit pixels .