Jump to content
Turry

Sierpinski's Triangle C++ SFML

Recommended Posts

Posted (edited)

Un fractal facut in C++ SFML. Fractalul se numeste Sierpinski's triangle.

'Algoritmul' folosit:

Alege 3 puncte in plan. (De preferat sa nu fie coliniare ca nu prea poti face un triunghi cu 3 puncte coliniare..)

Se alege un numar random de la 0 la 2.

In functie de numarul care a picat se duce jumatate din distanta spre acel punct.

(  (actualPoint.x + point.x)/2 )

Link Wikipedia.

Link catre video.

(Sper ca are sens ce am scris, sunt destul de obosit.. In caz de sunt greseli, feel free to tell me about them).

Edited by Turry

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...