tholman / generative-artistry

A website for self coding generative art tutorials.
https://generativeartistry.com
Other
842 stars 45 forks source link

Content proposal: Hours of Dark #31

Open brunoimbrizi opened 3 years ago

brunoimbrizi commented 3 years ago

Hi Tim,

This is a great project! The tutorials look great and I happily recommend them to anyone asks me about getting started on creative coding.

I would like to know if you'd be interested in a contribution to the tutorial section showing how to recreate Accept & Proceed's Hours of Dark 2011. It's pure canvas 2D, black on white and ~60 lines of code, so it should be in tune with the other tutorials.

I read the other thread with @maxwellito and the process is clear to me. If you think this would be interesting I can send a PR soon.

Cheers, Bruno

brunoimbrizi commented 3 years ago

Here is the first draft (just the code, no copy yet) and what the result looks like.

tholman commented 3 years ago

Wow this is great! I love it

On Thu, May 13, 2021 at 7:36 PM Bruno Imbrizi @.***> wrote:

Here is the first draft https://raw.githubusercontent.com/brunoimbrizi/generative-artistry/master/content/tutorials/hours-of-dark.md (just the code, no copy yet) and what the result looks like https://github.com/brunoimbrizi/generative-artistry/blob/master/static/img/09-hours-of-dark.png .

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/tholman/generative-artistry/issues/31#issuecomment-840894873, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAGCC5ZYO2RSPVGKCTAD67LTNRO7FANCNFSM443HEASA .

-- Tim Holman tholman.com

brunoimbrizi commented 3 years ago

I'm very glad you liked the proposal. I worked on the copy this morning and made a few minor tweaks to the code. Pull request sent. Please feel free to edit the copy or ask me anything in case things aren't clear.

tholman commented 3 years ago

You absolutely nailed this! Succinct and beautiful!

tholman commented 3 years ago

Ahh, perhaps a little offset bug in the live rendering at the end there, will try to debug at lunch! Either way, so good!

Screen Shot 2021-05-14 at 10 46 20 AM
brunoimbrizi commented 3 years ago

Ahh, no! I wonder if the issue is related to retina screens. It was (and still is) working fine on Windows non-retina modern browsers. I'll try to find the cause here as well.

brunoimbrizi commented 3 years ago

Found it. I should use size instead of canvas.width or canvas.height. Both are the same on non-retina screens, so I didn't notice the issue. Fixed and PR coming.