public static int op_avg2(int a, int b, byte[] cm_base, int cm_offset) { return (int)((((a) + cm_base[cm_offset + (((b) + 512) >> 10)] + 1) >> 1)); }