示例#1
0
 public Computation(MandelbrotJSON mandelbrotJSON)
 {
     center        = mandelbrotJSON.Center;
     maxIterations = mandelbrotJSON.MaxIterations;
     zoom          = mandelbrotJSON.Zoom;
     WidthPixel    = mandelbrotJSON.WidthPixel;
     HeightPixel   = mandelbrotJSON.HeightPixel;
 }
示例#2
0
        static Bitmap ManageComputationRequest(string message)
        {
            MandelbrotJSON mandelbrotJSON = ConverterJSON.ReadFromString(message);
            if(mandelbrotJSON==null)
            {
                TcpConnector.End();
                TcpConnector.Serve();
            }

            Computation computation = new Computation(mandelbrotJSON);
            return computation.ComputeMandelbrot();
        }