Kistaro Windrider, Reptillian Situation Assessor (kistaro) wrote,
Kistaro Windrider, Reptillian Situation Assessor

  • Mood:
  • Music:


I just finished a CS101 assignment... with a few modifications. The assignment was to make a recursive function to subdivide a square into a lot of little tiny squares, four pixels to a side, by splitting a box into quadrants, splitting each of those boxes into quadrants, splitting each of those boxes into quadrants, splitting each of those boxes into quadrants... until it's small enough.

I did that, but modified the program. (Someone else already did this sort of modification, so I know it's accepted.) I've now got it tiling a 512x512-pixel area, down to a single pixel instead of four-pixel squares.

But it's not spitting out a solid black blob; the algorigthm, instead of painting black lines, starts out with gray lines and then determines the next inner level of lines to draw by taking the current level's color and randomly modifying it slightly. The end result is this beautiful fractal pattern of color-sectors, not easily described without seeing it.

Screenshot to follow. The program is still running; no surprise, considering it's going to have to use over two hundred thousand (200,000) function calls to draw the picture. I'll screenshot the output, upload it somewhere, and let y'all ooh and ahh over it. Then I'll set it as my desktop wallpaper.

It's a lot of fun to watch, too. All you Java programmers out there- the source is availible for the asking.

  • Last LJ post

    Hey all, I joined the LJ exodus train before it was cool</hipster>, but with recent developments in LiveJournal server location (…

  • (no subject)

    I want to assemble things that nobody else could ever assemble, and when they are done, I want to have done it in ways that nobody of average skill…

  • Failing, etc.

    That feeling of being 99% sure a social space would have been better for everyone without you in it, but you can't apologize or talk about it or…

  • Post a new comment


    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded