Org.BouncyCastle.Crypto.Engines.IdeaEngine.IdeaFunc C# (CSharp) Method

IdeaFunc() private method

private IdeaFunc ( int workingKey, byte input, int inOff, byte outBytes, int outOff ) : void
workingKey int
input byte
inOff int
outBytes byte
outOff int
return void
        private void IdeaFunc(
            int[]   workingKey,
            byte[]  input,
            int     inOff,
            byte[]  outBytes,
            int     outOff)
        {
            int     x0, x1, x2, x3, t0, t1;
            int     keyOff = 0;
            x0 = BytesToWord(input, inOff);
            x1 = BytesToWord(input, inOff + 2);
            x2 = BytesToWord(input, inOff + 4);
            x3 = BytesToWord(input, inOff + 6);
            for (int round = 0; round < 8; round++)
            {
                x0 = Mul(x0, workingKey[keyOff++]);
                x1 += workingKey[keyOff++];
                x1 &= MASK;
                x2 += workingKey[keyOff++];
                x2 &= MASK;
                x3 = Mul(x3, workingKey[keyOff++]);
                t0 = x1;
                t1 = x2;
                x2 ^= x0;
                x1 ^= x3;
                x2 = Mul(x2, workingKey[keyOff++]);
                x1 += x2;
                x1 &= MASK;
                x1 = Mul(x1, workingKey[keyOff++]);
                x2 += x1;
                x2 &= MASK;
                x0 ^= x1;
                x3 ^= x2;
                x1 ^= t1;
                x2 ^= t0;
            }
            WordToBytes(Mul(x0, workingKey[keyOff++]), outBytes, outOff);
            WordToBytes(x2 + workingKey[keyOff++], outBytes, outOff + 2);  /* NB: Order */
            WordToBytes(x1 + workingKey[keyOff++], outBytes, outOff + 4);
            WordToBytes(Mul(x3, workingKey[keyOff]), outBytes, outOff + 6);
        }
        /**