Recent

Author Topic: RegEx Patterns: Fractals  (Read 2833 times)

Boleeman

  • Hero Member
  • *****
  • Posts: 768
RegEx Patterns: Fractals
« on: September 24, 2024, 07:50:45 pm »
Make some Nice Patterns from Regular Expressions (some are deviated Fractals and some are not).

The patterns seem to be XOR deviations of fractal patterns.
The sizes of the images seem unusually small
(I think the patterns are made of only a few colours but placed in intricate positions)

Got the idea from the attached JavaScript


Anyhow. Enjoy my little creation.
« Last Edit: January 07, 2025, 03:20:48 pm by Boleeman »

Boleeman

  • Hero Member
  • *****
  • Posts: 768
Re: Nice Patterns From Regular Expressions
« Reply #1 on: September 24, 2024, 10:16:43 pm »
Some more presets
« Last Edit: September 24, 2024, 10:18:47 pm by Boleeman »

Boleeman

  • Hero Member
  • *****
  • Posts: 768
Re: Nice Patterns From Regular Expressions
« Reply #2 on: September 25, 2024, 06:25:34 am »
and  ... 104 Presets for 104 Patterns

Download the "testsave4.txt" and copy into the program folder and load it. Then click on a Listbox Row enrty.

Getting Modulo Fractal (in the 1st attached png notice how there is another blue pattern in the background)

Getting 3D Contrasting Type Illusion (2nd attached png)

Getting Colorful XOR Patterns (3rd attached png)

« Last Edit: September 25, 2024, 08:38:12 am by Boleeman »

circular

  • Hero Member
  • *****
  • Posts: 4377
    • Personal webpage
Re: Nice Patterns From Regular Expressions
« Reply #3 on: September 25, 2024, 11:22:19 am »
Now this gives a new dimension to regexes!  :)
Conscience is the debugger of the mind

Boleeman

  • Hero Member
  • *****
  • Posts: 768
Re: Nice Patterns From Regular Expressions
« Reply #4 on: September 26, 2024, 06:25:35 am »
Now ... 238 presets to play around with. (attached below as presets testsave5.txt )

Yes, Circular these patterns seem to be XOR deviations of fractal patterns.

I've seen something like this happen in a Vb6 program that I made that XORs and also in my Blade pattern that I made in Vb6 (in which I mixed XORing with Lines in a Plane). In the vb6 program only red, green or blue was set, whereas in the Lazarus RegX program multiple colors are present.

I have been noticing a few more things with the RegX patterns:

Changing a 1 to a 3 alters the direction of the striped pattern.
(the striped pattern also seems to be formed by splitting colors into wavelengths)
Also the addition of a dot in a certain position after the question mark alters the width of the stripes.
(..*?...)([1.4]+)(..p*) very thin vertical stripes
(..*?..)([14]+)(..p*)  wider vertical stripes
(..*?.)([1.4]+)(..p*)  even wider vertical stripes


To make horizontal stripes:
(..*?...)([3.4]+)(..p*) very thin horizontal stripes
(..*?..)([3.4]+)(..p*)  wider horizontal stripes
(..*?.)([3.4]+)(..p*)  even wider horizontal stripes




Changing the number of dots and their position alters:
The frequency of the pattern
The colour of the pattern
The size of the black squares
The intensity of the color.


Look at the attached png files to see what I mean.


Lastly the sizes of the images seem unusually small (I think the patterns are made of only a few colours but placed in intricate positions)
« Last Edit: September 26, 2024, 07:11:10 am by Boleeman »

Boleeman

  • Hero Member
  • *****
  • Posts: 768
Re: Nice Patterns From Regular Expressions
« Reply #5 on: October 06, 2024, 05:44:10 am »
151 New Presets.

Boleeman

  • Hero Member
  • *****
  • Posts: 768
Re: RegEx Patterns: Now Auto Save the Png's
« Reply #6 on: October 19, 2024, 04:54:39 am »
I have found almost 500 new patterns.

Has anyone found any nice patterns?

Attached below are six of my latest favorite patterns:

TRon

  • Hero Member
  • *****
  • Posts: 3811
Re: RegEx Patterns: Now Auto Save the Png's
« Reply #7 on: October 19, 2024, 12:35:01 pm »
I like these examples Boleeman.

They remind me of a website that imo has many similarity to your adventures with Lazarus and which was named DelphiForFun (I believe a copy of that website is now listed here).

It had/has many examples of math sometimes stuffed into a graphical representation thereby informing the reader of 2 important things, e.g. how to program something with Delphi and how to understand the math/mechanics behind it and visualize it.

You have now made so many interesting examples that these are imo a worthy competitors/successors to those examples listed at that website.

Keep up the good work and have fun !
I do not have to remember anything anymore thanks to total-recall.

carl_caulkett

  • Hero Member
  • *****
  • Posts: 649
Re: RegEx Patterns: Now Auto Save the Png's
« Reply #8 on: October 19, 2024, 01:34:13 pm »
@Boleeman! You should get in touch with Transport for London (TFL) because these patterns really remind me of the moquettes used for underground seat cushions ;)

https://www.ltmuseum.co.uk/collections/stories/design/history-moquette
"It builds... ship it!"

Boleeman

  • Hero Member
  • *****
  • Posts: 768
Re: RegEx Patterns: New Variation Version
« Reply #9 on: October 30, 2024, 09:54:15 am »
Made a new Variation Version

Now you can:

Alter the depth of recursion (low depth blocky/pixelated curves and high depth has very fine curves)
Set the Back Colour and Curve Colour
Use a Colouring function with varied effects based on colour brightness/darkness
Use any square pixel size canvas


Still would like to try to make that gradient rendered version using hamming distance.
Perhaps one day will work it out.

Meanwhile please enjoy this Variation Version of the RegEx Fractal Renderer.
« Last Edit: October 30, 2024, 11:19:54 am by Boleeman »

lainz

  • Hero Member
  • *****
  • Posts: 4667
  • Web, Desktop & Android developer
    • https://lainz.github.io/
Re: RegEx Patterns: Fractals
« Reply #10 on: January 10, 2025, 08:49:51 pm »
Do you have a website with a collection of all your programs?

Make one today, it's free at github :)

Boleeman

  • Hero Member
  • *****
  • Posts: 768
Re: RegEx Patterns: Fractals
« Reply #11 on: January 17, 2025, 01:43:40 am »
With the help of a few people, I managed to port the Java version of RegEx Gradient Fractal to CSharp.

Would be nice to also port to Lazarus, but it uses something called dk.briks automation which only exists in Java form, CSharp form and JavaScript.

Is there any way of running a DLL from CSharp (called Fare.dll), as this has the dk.briks automation.

Attached are a few results from the ported CSharp version.

If any one is interested in the csharp source I can share it or I could upload the Net 6.0 compiled version to a share site!
« Last Edit: January 17, 2025, 01:47:15 am by Boleeman »

 

TinyPortal © 2005-2018