15-02-2020, 05:38 AM
(26-11-2019, 01:49 PM)josemendez Wrote: The SimpleFluid scene is optimized for mobile, all other scenes are optimized for multicore desktop computers.Hello, I have same issue on mobile.
Performance is the result of multiple factors:
- Amount of particles being simulated. The lower, the better for performance.
- The fluid blueprint's smoothing radius (see:http://obi.virtualmethodstudio.com/tutorials/emittermaterials.html). Again, the lower the better.
- Timestep settings (Unity's fixed timestep and max fixed tilmestep). The higher (longer) the timestep, the better.
- Solver settings (amount of substeps and density iterations). Fewer substeps/iterations result in better performance.
- Rendering resolution. Lower resolution yields better performance.
In mobile, the bottleneck is generally rendering. You can only determine this trough profiling your app in the device, using Unity's profiler. If rendering is indeed the bottleneck, then you should consider what your rendering needs are:
- If you need full 3D rendering with specular highlights, reflection, refraction, transmittance, turbidity and foam, using the standard FluidRenderer is your best bet. Slightly tweaking buffer resolution and shader code to improve performance should be viable. I can help you with tweaking if you need.
- If you need simpler 2D rendering with refraction and transmittance, then start from SimpleFluidRenderer.
For most games, you'd want to write your own custom-tailored FluidRenderer anyway, as you might want some of the advanced features of the standard renderer, but not all.
Beside, when I copy Solver(Emitter), Obi Simple Fluid Renderer from SimpleFluid Scene to my own Scene, change to Mode3D. It doesn't work, the water is invisible.
But when I use BOTH Obi Simple Fluid Renderer & Obi Fluid Renderer, the water comes out.
Finally, if I need Mode3d + SimpleFluid(without depth testing, refraction, uniform color, no lightning), How can I tweak for better performance at mobile device?
Thank you very much!