-
Notifications
You must be signed in to change notification settings - Fork 51
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
sdlgfx behaviour showing noise (reads wrong memory) on newer macs #282
Comments
The engine we made for these student projects we called nanopy, if someone wants to look into this I can grant access to this private project on our github. |
Hi @JASlotman, thanks for the bug report! It's entirely possible there's a weird ARM64 or Apple Silicon bug with In your example code, I also noticed there's no call to fill the rendering context between each refresh and drawing. Is that correct? If so, I can imagine that might cause some undefined system-specific behaviour! Also depending on the context, you may be better off using a Python-based drawing library like Pillow or Aggdraw and then using |
Thank you for your input, I will test the gfxdrawing.py when I can access a mac again that has the issue. I'll also look into the fill and the pillow library. Thanks a lot and I will report back |
@a-hurst I've looked into the gfxdrawing example and there is one essential difference to the behavior we want to achieve. But we might be going about it wrong. In the example many shapes are drawn to a black background. What we want to do is not clear the surface in between but write to the exsisting drawing. And that's when we run into our problem. What would be the correct way to do this? (i.e. in the gfxdrawing example not writing the next shapes to a new surface but adding them to the existing one) |
What doesn't work?
We made a small engine that we use for students, so we can test many different architectures. We stumbled upon a bug where when we use the drawcricle and other shapes from the gfx library and update a surface or window it draws a noisy reactangles around the shapes we want to display.
How To Reproduce
Any code that reproduces the bug, e.g.:
Sorry I dont have a minimal code that creates this bug here are three minimal tidbits of our code that give the problem
Platform (if relevant):
Additional context
Only drawing a single element also causes this unless we first do a clear. When a student that was working on an other project used and saw that the rectangles were not filled with random noise but with an image that he loaded into memory for another project, which makes us beleive sdl2 might be accessing a wrong memory area in these newer macs. (my guess is these are the M1 or higher machines)
The text was updated successfully, but these errors were encountered: