CSJ2K.j2k.image.forwcomptransf.ForwCompTransf.initForwRCT C# (CSharp) Метод

initForwRCT() приватный Метод

Initialize some variables used with RCT. It must be called, at least, at the beginning of each new tile.
private initForwRCT ( ) : void
Результат void
        private void initForwRCT()
        {
            int i;
            int tIdx = TileIdx;

            if (src.NumComps < 3)
            {
                throw new System.ArgumentException();
            }
            // Check that the 3 components have the same dimensions
            if (src.getTileCompWidth(tIdx, 0) != src.getTileCompWidth(tIdx, 1) || src.getTileCompWidth(tIdx, 0) != src.getTileCompWidth(tIdx, 2) || src.getTileCompHeight(tIdx, 0) != src.getTileCompHeight(tIdx, 1) || src.getTileCompHeight(tIdx, 0) != src.getTileCompHeight(tIdx, 2))
            {
                throw new System.ArgumentException("Can not use RCT " + "on components with different " + "dimensions");
            }
            // Initialize bitdepths
            int[] utd; // Premix bitdepths
            utd = new int[src.NumComps];
            for (i = utd.Length - 1; i >= 0; i--)
            {
                utd[i] = src.getNomRangeBits(i);
            }
            tdepth = calcMixedBitDepths(utd, FORW_RCT, null);
        }