Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Smoke effect not working correctly on 64x64 Hub75 matrix. #534

Open
mikejohnau opened this issue Nov 21, 2023 · 3 comments
Open

Smoke effect not working correctly on 64x64 Hub75 matrix. #534

mikejohnau opened this issue Nov 21, 2023 · 3 comments

Comments

@mikejohnau
Copy link

I have a 64x64 Hub75 matrix hardwired to an ESP32-Wrover dev board. Most effects seem to work fine, Audiograph, Metaballs, Fireplace, SuperNova and Pnog Clock all work. The some effect appears to run but the frame is fractured and large diagonal lines appear accross the frame.

Sample video is at https://user-images.githubusercontent.com/26905608/284036081-3890110a-ef98-4420-9a42-e43d738cc517.mov

Bug report

64x64 Hub75 matrix not displaying Smoke effect correctly

Problem
64x64 Hub75 matrix not displaying Smoke effect correctly. I have tried different Matrix_Tye settings none have had any effect.

Steps

  1. Connect 64x64 Hub matrix
  2. Load Smoke effect.
@robertlipe
Copy link
Contributor

Timely. In antoher window, I'd just stumbled across
pixelmatix/SmartMatrix#81
which makes a similar conclusion about the noise fill and noise traversal not actually matching as I made in earlier discussion #526 (comment) to someone about
#486 and
#525

I don't like the diagonal wipe, but the alternative we agreed was better was silently shouted down. I think the fundamental problem on the negative space is the fill and the traversal sizes not matching. It was the SetNoise inside the loop with the hardcoded constants (that I didn't at all understand) that was causing the black bars before.

As I wrote before, I wonder if rolling that file back to the original noise system makes it better or worse. Can you try that? I don't think you even have to roll back the whole project; just that file should do it, I think.

I'll admit I've seen videos of this author coding his effects on YouTube and I don't at all understand where his numerology is grounded. He's clearly not making up numbers, but he doesn't explain it in a way I understand it. My only discovery was that fillNoise and the code traversing it didn't match the sizes. It's likely that doubling the pixel space makes that worse and a root cause needs to be found.

@mikejohnau
Copy link
Author

Going back to the previous build
9e1bf8f

Appears better. The panel now seems divided into quarters that float up and down and generally move around the screen. The wipers are also less slightly visible. I did have to remove the g()->Clear() line after the EVERY_N_MILLISECONDS line. With that in place I could only see the wipers.

latest video..

Old_build.mov

Just looking at the code and your comments above. Are we actually touching the smartmatrix include with this effect? It looks to my untrained eyes that this is all GFXbase.

Last part of code for reference.

EVERY_N_MILLISECONDS(100)
{
 // g()->Clear();
  g()->SetNoise(1000, 1000, 1000, 4000, 4000);
  // (orig) "speed of movement through the noise array"
  // Calling SetNoise() in here will index past what was
  // FillGetNoised, which returns slowly scrolling bars
  // of black along X and Y axes.
  g()->FillGetNoise();
}

// Lower number for thicker, more static fog. Higher for more wisp.
g()->MoveFractionalNoiseX(3);
g()->MoveFractionalNoiseY(3);

// Without this, we get tornadoes where the diagonals cross as there's
// an excess of set pixels there.
g()->BlurFrame(20);

}

@robertlipe
Copy link
Contributor

robertlipe commented Nov 22, 2023 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants