Exemple #1
0
        // ----------------------------------------------------------------------------------------
        #region Visual

        public override void Randomize(Random random)
        {
            base.Randomize(random);
            Clear();
            float a1        = (float)random.BoxMuller1(PI / 50d);
            float l1        = (float)random.Weibull(20d, 2d);
            float w1        = (float)random.Weibull(25d, 2d);
            int   nSegments = (int)random.Weibull(25d, 2d);

            for (int i = 0; i < nSegments; i++)
            {
                Segment segment = new Segment();
                segment.Length = l1;
                segment.Width  = w1;
                segment.Angle  = a1;
                Add(segment);
            }
        }