From 235c4f239a794abb77039ccd03284d765996e523 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=A1=D0=B0=D0=B2=D0=B5=D0=BB=D1=96=D0=B9=20=D0=A1=D0=B0?= =?UTF-8?q?=D0=B2=D1=91=D0=BD=D0=B0=D0=BA?= <1986developer@gmail.com> Date: Tue, 3 Jan 2023 00:40:13 +0300 Subject: [PATCH] fUNC --- FractalTreeGtk/Draw/Fractal.cs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/FractalTreeGtk/Draw/Fractal.cs b/FractalTreeGtk/Draw/Fractal.cs index 7eeff9d..4c1a279 100644 --- a/FractalTreeGtk/Draw/Fractal.cs +++ b/FractalTreeGtk/Draw/Fractal.cs @@ -1,4 +1,5 @@ using System; +using System.Diagnostics; using System.Threading; using System.Threading.Tasks; @@ -36,6 +37,7 @@ namespace FractalTreeGtk.Draw int x = 0; for (int i = 0; i < Fractallines[level - 1].Length; i++) { + Trace.WriteLine(level - 1); if (Fractallines[level - 1][i].left) { Fractallines[level][x] = new Branch( @@ -66,6 +68,11 @@ namespace FractalTreeGtk.Draw NextLevel(); } } + private int Modificator(int x, int level) + { + int count = Convert.ToInt32(Math.Pow(2, level)); + return Math.Abs(x - count) + level; + } //private int SumOfBranches() //{ // double sum = 0;