Beispiel #1
0
 private PPM(PPM other)
 {
     width    = other.width;
     height   = other.height;
     maxColor = other.maxColor;
     pixels   = other.pixels.ToList();
     type     = other.type;
 }
Beispiel #2
0
        private static PPM ToCreateThroughAnExistentFile(string path)
        {
            PPM ppm = new PPM();

            ppm.ReadFile(path);

            return(ppm);
        }
Beispiel #3
0
        public static PPM Create(int width, int height, int maxColor, TypeData type)
        {
            PPM ppm = new PPM();

            ppm.width    = width;
            ppm.height   = height;
            ppm.maxColor = maxColor;
            ppm.type     = type;
            ppm.CreatePixels();

            return(ppm);
        }