- Home /
Can a iOS game camera have the Bloom optimized effect with clear flags = depth only?
I'm trying to add the bloom optimized effect to one of the cameras in my scene, but for some reason my frame rate drops to 3 fps when testing on an iPhone 5c. After some testing I have found that the combination of Bloom Optimized and Clear flags = Depth only is what is causing the drop. Profiling my game I have found what is causing the drop is Camera.AAResolve-->RenderTexture.GrabPixels. I know that camera effects on mobile are not recommended, but I have found that if I set clear flags to either Skybox or solid color and keep the bloom my game runs at a solid 30 fps. The reason why I have to have the camera with depth only is because I have three cameras on my scene and each one renders different parts of the game. My scene cameras settings are.
-Main Camera: Clear flags: Depth only, Culling Mask: All game props and characters(Everything on top of the floor), Projection: Orthographic, Size: 15, Clipping planes: .3 to 100, Depth 0, Rendering path: Forward rendering, Target texture: none, Occlusion culling: false, HDR: false.
-Floor Camera: Clear flags: Don't Clear, Culling Mask: Only the floor, Projection: Orthographic, Size: 15, Clipping planes: .3 to 100, Depth -1, Rendering path: Forward rendering, Target texture: none, Occlusion culling: false, HDR: false.
-Background Camera: Clear flags: Solid Color, Culling Mask: Nothing, Projection: Orthographic, Size: 15, Clipping planes: .3 to 100, Depth -2, Rendering path: Forward rendering, Target texture: none, Occlusion culling: false, HDR: false.
This is my scene setup although I have tested on a empty project with only one camera with Bloom and Depth Only and the drop it is also occurring.
It's important to know that because the way the game is built I need to render the floor separately from the rest of the objects to avoid zbuffering issues with the floor and some planes that are placed at the same height.
Update: So the issue only happens on an iphone 5c so that leads to think that it might has something to do with open gl 2.0. Testing in devices that can use open gl 3.0, metal and so do not have the issue.
Your answer
Follow this Question
Related Questions
How to improve FPS on mobile? 1 Answer
Maximum RAM memory exceeded causes app to crash in iOS 1 Answer
Why did my render time increase after lowering the vertex count? 2 Answers
Unity AR + Postprocess 1 Answer
Delta touch trembling 0 Answers