Rezmason / matrix

matrix (web-based green code rain, made with love)
https://rezmason.github.io/matrix
MIT License
3.29k stars 212 forks source link

option to start with a blank (black) screen #18

Closed mcanepa closed 2 months ago

mcanepa commented 1 year ago

First of all, this is fantastic! great job!!! and thanks for sharing it and the detail explanations you give on every issue.

Maybe I have missed some configuration option, but if there isn't it would be great for the code to start raining from the top like the opening titles. Right now when the code starts is already all over the screen.

Rezmason commented 1 year ago

Thank you for your interest and your kind words!

You're absolutely right— at the moment there's no mode to begin with a blank screen. I had an idea for how to add that this morning, actually, and I'll give it a try in a couple days.

Rezmason commented 1 year ago

Here's what I came up with, feedback welcome! Thanks again for the suggestion.

avidrucker commented 2 months ago

@Rezmason Please forgive the post on an already closed issue, but it appears that the screen does not start out completely blank/black for me on https://rezmason.github.io/matrix/?skipIntro=false - instead it starts with glowing blocks of code. I am using the Chrome browser for Linux. Is there a way to turn these off these glowing blocks as well to start from a completely black/empty background? Please let me know if you'd rather I make a new issue.

Edit: I can confirm that the rain does indeed start from a blank/black background on Mozilla Firefox.

image

Rezmason commented 2 months ago

@avidrucker That's incredible. There are people that want this to be able to intentionally happen and I'm kind of one of them. The bug is an artist. Also, it's a bug in Chrome, but that won't stop me from addressing it here.

If I had to guess, the textures that store the rain aren't properly blanked in Chrome. If so, you should be able to see the blocks in this screenshot slowly giving way to normal matrix rain, from the top of the screen downward. Can you confirm?

To fix this— this is a note for my future self— there should probably be some blank data passed into makeDoubleBuffer on line 19 of the rainPass.

Rezmason commented 2 months ago

Repro'd in Chrome on Macintosh

Rezmason commented 2 months ago

Pushed a fix, works in Chrome on Macintosh. @avidrucker , please test it on Linux and let me know if it's fixed for you too 🌈

avidrucker commented 2 months ago

It appears fixed for me (starting out from a black/blank screen now), and I greatly appreciate you doing this! That said, I feel kinda sad that you like the "blocky remnants" effect yet still took it out. I agree that the bug is an artist :smile: Perhaps you might bring it back as an intentional setting? Either way, thank you again.

Rezmason commented 2 months ago

That's exactly what I'll do, after I do the dozen other things I've said I would in the project this year 😆 thanks for giving me an easy accomplishment, it honestly helps to build my momentum