- Home /
How to clone all pixels from a 3d mesh to use them in following frames to optimize performance of GPU?
We are creating a mobile game where camera position is static.
Camera angle is only dynamic variable in camera statistics. Now, everytime we try to change the camera angle, the performance drops and player's screen looks awful (there are big trees, which are complicated 3d meshes).
I have a solution idea but I don't how to implement it, can you help me?
My solution idea is following:
Since the camera position is static, every stable 3d mesh are looking identical in the player screen (as long as there are no changes in lighting).
When turning camera angle, I guess game engine is using complicated mesh calculations for big trees to show them properly to the player instead of simply copying the area of 2d pixels showed to the player of an earlier frame.
What do I mean, a tree looks exactly the same the whole session player spends in a place, let say 10 minutes. During this session, player may change the camera rotation but it doesn't effect how the trees are rendered to the screen. Trees looks always same in the screen, their position in the screen only changes.
So my solution idea is that we store all pixels of each tree from the very first frame and then use stored pixel color values during the last 10 minutes a player will be playing to render the trees properly without slowing down the GPU. I guess this performance trick is achievable using shaders, is it?
(SHADERS?)
So, how do I clone all pixels from a 3d mesh to use them in following frames to optimize performance of GPU?
Your answer
Follow this Question
Related Questions
Should Particle Systems be marked as static? And what about GameObjects using waving Shaders? 0 Answers
Multiple Meshes VS Armature 1 Answer
How can I force a mesh to render behind all other meshes? 0 Answers
Change vertex colours based on steepness 1 Answer
Performance Issue On Certain Devices 0 Answers