Thanks to Circular and Josh for replying with your respective fixes.
With Circular's code there was still a small gap in the center part of the curve, as the at end line needed to draw back to start ordinates. With Josh's code the gap is now gone. I originally tried ACanvas.MoveTo before asking for help, but for some reason could not get it working properly.
As mentioned in 1st post, the original CSharp code had TRANSFORM parts to it like translate and scale, so as to move the curve and to size the curve.
I wanted to do some TRANSFORMS like:
scale := Min(PaintBox1.ClientWidth * 0.45, PaintBox1.ClientHeight * 0.45);
Canvas.Scale(scale, scale);
Canvas.Translate(PaintBox1.ClientWidth / 2, PaintBox1.ClientHeight / 2);
which I think BGRABmp can do.
I would still like to know how to perform the transforms in BGRABmp.
I ended up doing:
pt0 := Point(Round(X(a, b, h, t) * scale) + Round(PaintBox1.ClientWidth / 2),
Round(Y(a, b, h, t) * scale) + Round(PaintBox1.ClientHeight / 2));
to perform the transformations another way.
Attached is a filled pattern, with a Bulge effect done in Paint.Net (making the central shapes more elongated).
I wonder if something in BGRABmp can be used to achieve a similar shape distortion effect?
I just tried out Josh's Animated Version in the next thread. Nice.
Really like the Animate H with Color Cycle and A=19 and B=15 and linewidth=2 and Speed Adjust.
There is another effect at the circumference, where the colors appear to be rotating, while the pulsating effect is happening.
Actually single color animation also works well (I had Yellow curve with black background, Animating H value).
With the other animation parameters (A and B parameters), it seems you have to start them at certain spots to get differing effects.
Nicely done by Josh.