Пример #1
0
        public ColorGradientFormatting(ILittleEndianInput in1)
        {
            in1.ReadShort(); // Ignored
            in1.ReadByte();  // Reserved
            int numI = in1.ReadByte();
            int numG = in1.ReadByte();

            if (numI != numG)
            {
                //log.Log(POILogger.WARN, "Inconsistent Color Gradient defintion, found " + numI + " vs " + numG + " entries");
            }
            options = (byte)in1.ReadByte();

            thresholds = new ColorGradientThreshold[numI];
            for (int i = 0; i < thresholds.Length; i++)
            {
                thresholds[i] = new ColorGradientThreshold(in1);
            }
            colors = new ExtendedColor[numG];
            for (int i = 0; i < colors.Length; i++)
            {
                in1.ReadDouble(); // Slightly pointless step counter
                colors[i] = new ExtendedColor(in1);
            }
        }
Пример #2
0
        public Object Clone()
        {
            ColorGradientThreshold rec = new ColorGradientThreshold();

            base.CopyTo(rec);
            rec.position = position;
            return(rec);
        }