Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help  Android Performance Issue (Due to lots of particles)
#1
Hi,

I am working on a project for a while and it's almost done. I was making test on my Samsung Galaxy Note 8 mobile phone and FPS was dropping a bit when I use 3500 particles in the scene. It wasn't a big deal until I tested on a slower phone...

I have tested the game on an HTC One M7. FPS was dropping around 0.5 when there are 3500 particles in the screen. Which makes game almost freeze and even closing the application is getting harder.

So, my question is: Is it possible to make particles bigger?

I'm using 1x scale 3500 particles now. Is it possible to make it 10x scale with 350 particles?

That's my only obstacle before releasing my game. I would be glad if we can figure it out.

(I'm using Simple2DFluid for better performance)
Reply
#2
I have a similar question.

in my game i want to fill up a tank with liquid, but the particles are so small it requires a ton of particles to get any real volume. I played with the particle renderer radius scale and the emitter material fluid resolution. This allowed me to make the particles really big but then they stuck outside the walls.

So i am also curious to see if there is a sweet spot to increase the volume without increasing the number of particles (or am i doing it exactly how it is intended to be)?
Reply
#3
(28-11-2018, 01:44 AM)gadgetkk Wrote: I have a similar question.

in my game i want to fill up a tank with liquid, but the particles are so small it requires a ton of particles to get any real volume. I played with the particle renderer radius scale and the emitter material fluid resolution. This allowed me to make the particles really big but then they stuck outside the walls.

So i am also curious to see if there is a sweet spot to increase the volume without increasing the number of particles (or am i doing it exactly how it is intended to be)?

To increase the volume, you need to increase the amount of particles because each particle represents a fixed volume.

Start by setting the renderer radius scale to 1 (so that particles are drawn at their true size), and decreasing material resolution. Once you've got the desired performance for your volume, then being increasing the radius scale until any gaps between particles are filled. Then turn on the Fluid Renderer, and increase thickness cutoff until only the bulk volume of your fluid is rendered.
Reply
#4
(27-11-2018, 08:04 PM)Tuna.Y Wrote: Hi,

I am working on a project for a while and it's almost done. I was making test on my Samsung Galaxy Note 8 mobile phone and FPS was dropping a bit when I use 3500 particles in the scene. It wasn't a big deal until I tested on a slower phone...

I have tested the game on an HTC One M7. FPS was dropping around 0.5 when there are 3500 particles in the screen. Which makes game almost freeze and even closing the application is getting harder.

So, my question is: Is it possible to make particles bigger?

I'm using 1x scale 3500 particles now. Is it possible to make it 10x scale with 350 particles?

That's my only obstacle before releasing my game. I would be glad if we can figure it out.

(I'm using Simple2DFluid for better performance)

Yep, simply decrease fluid resolution. This parameter controls how many particles are used per cubic (square in 2D) meter of volume:

http://obi.virtualmethodstudio.com/tutor...rials.html
Reply
#5
(28-11-2018, 08:13 AM)josemendez Wrote: Yep, simply decrease fluid resolution. This parameter controls how many particles are used per cubic (square in 2D) meter of volume:

http://obi.virtualmethodstudio.com/tutor...rials.html

Thank you Jose. But I have already tried that. Circle colliders for water particles are not growing in the same ratio when I increase the resolution. Because of that, particles are getting into each other.
Reply
#6
(28-11-2018, 08:36 AM)Tuna.Y Wrote: Thank you Jose. But I have already tried that. Circle colliders for water particles are not growing in the same ratio when I increase the resolution. Because of that, particles are getting into each other.

If you set the renderer radius scale to 1, particles should not get into each other at all. By increasing resolution you make them smaller, not bigger by the way.
Reply
#7
(28-11-2018, 09:41 AM)josemendez Wrote: If you set the renderer radius scale to 1, particles should not get into each other at all. By increasing resolution you make them smaller, not bigger by the way.

Hi Jose,

I have tried to decrease resolution step by step and set radius scale to 1 but it makes fluids look like little balls and these particles are going through 2d edge collider when they are pressed together.

Do you have any suggestion for that?
Reply
#8
(29-11-2018, 11:23 AM)Tuna.Y Wrote: Hi Jose,

I have tried to decrease resolution step by step and set radius scale to 1 but it makes fluids look like little balls and these particles are going through 2d edge collider when they are pressed together.

Do you have any suggestion for that?

If the fluid looks too "bubbly" because its particle-based structure is made apparent, increase the solver's max anisotropy. This will allow particles to warp their shape to adapt to the fluid's surface. See:
http://obi.virtualmethodstudio.com/tutor...olver.html

Quote:particles are going through 2d edge collider when they are pressed together.

This is a common issue to all realtime physics, called "tunneling". Try decreasing the tilmestep or increasing the amount of collision constraint iterations in the solver.
Reply
#9
(29-11-2018, 12:16 PM)josemendez Wrote: If the fluid looks too "bubbly" because its particle-based structure is made apparent, increase the solver's max anisotropy. This will allow particles to warp their shape to adapt to the fluid's surface. See:
http://obi.virtualmethodstudio.com/tutor...olver.html


This is a common issue to all realtime physics, called "tunneling". Try decreasing the tilmestep or increasing the amount of collision constraint iterations in the solver.

Thank you Jose, problems are almost solved. Last question; is it possible to change "round-bubble" water with "square" or change it's shape somehow?
Reply