Closed PandaDecSt closed 3 years ago
I had previously tried not drawing EmptyCells and it caused some weird drawing behavior with the other elements. I have on my to-do list enabling multithreading on drawing but haven't gotten around to it yet.
Also want to try populating a pixmap (using multithreading and performing one draw call on the pixmap. But have yet to try it.
I have become very busy with work recently and have not had time to work on this project. I will be picking this back up in the second half of 2021
I tried two different ways to multithread and change the drawing logic.
There is one other approach I can try to improve drawing performance but inevitably I will need to migrate this project to c++ since it is more performant and I am running into issues with LIBGDX.
Recently I have thought of several funny ways to improve performance.
1.Update the screen when a cell in the matrix changes, this will have better performance at least in static images.
2.Render the element itself through the element itself, Avoid traversing the array to render one by one.
3.Subdivide the matrix into chunks, then use the same principle as the first method.
Maybe it can be useful.
I also think that using c++ would be a good choice. At the same time, I also regret this version written in Java. I think this is the best FallingSand engine written in Java. Good luck!
Subdivide the matrix into chunks, then use the same principle as the first method
This is a good idea! I will try this out. Should be an easy change.
At the same time, I also regret this version written in Java. I think this is the best FallingSand engine written in Java. Good luck!
Thanks for the kind words! I mostly am running into issues with the framework I am using and not Java itself. So if I can find a good alternative I will just migrate the java code to a framework.
Subdivide the matrix into chunks, then use the same principle as the first method
Ok I just tried it and I definitely doesn't work. But just because of the weird drawing behavior of LIBGDX. I will definitely have to switch to another framework either way.
Hello, I found that your program does not run very smoothly on Android, so I have a few suggestions here, which may be able to help you.
1.Emptycell may not be drawn.
2.Use multiple threads to calculate parameters and draw.
Waiting for completion...