Ejemplo n.º 1
0
        public override Channel Clone()
        {
            ChannelDouble clone = new ChannelDouble(Width, Height);

            for (int x = 0; x < Width; x++)
            {
                for (int y = 0; y < Height; y++)
                {
                    clone[x, y] = Pixels[x, y];
                }
            }
            return(clone);
        }
Ejemplo n.º 2
0
        public override GenericChannel <double> Add(GenericChannel <double> other)
        {
            ChannelDouble outcome = new ChannelDouble(Width, Height);

            for (int x = 0; x < Width; x++)
            {
                for (int y = 0; y < Height; y++)
                {
                    double newValue = this[x, y] + other[x, y];
                    if (newValue > 1.0)
                    {
                        newValue = 1.0;
                    }
                    outcome[x, y] = newValue;
                }
            }
            return(outcome);
        }
Ejemplo n.º 3
0
 public ImageDoubleRGB(uint width, uint height) : base(width, height)
 {
     R = new ChannelDouble(width, height);
     G = new ChannelDouble(width, height);
     B = new ChannelDouble(width, height);
 }