Skip to main content
Up and Coming
September 2, 2015

Huge cpu usage spike when near meshes

I am experiencing a bizarre situation, my game comes to a crawl when I get near meshes in my scene. My framerate goes from 75fps down to 40fps. I am using windows 10, sdk 0.7, AMD gpu and Unity 5.1.2f1.

What is really odd about it is, I can look at plenty of identical high poly meshes in my scene at a distance, and maintain a solid 75fps, but the moment I get to close to a mesh my framerate tanks.

Here are some pics from the profiler, first screen shows cpu usage with a large group of identical meshes in view at a distance:

https://www.dropbox.com/s/r6vlsp5g6edty2l/awayFromMesh.png?dl=0

And close to a isolated mesh that is identical to the meshes in the group:

https://www.dropbox.com/s/we9124b9dhlqd6u/nearMesh.png?dl=0


If anyone has any idea what is going on, I would really appreciate some help with this. I am stumped!

Thanks
    This topic has been closed for replies.

    3 replies

    Up and Coming
    September 2, 2015
    I observed this problem too ... but I explained it, that it had something to do with the ssao post effect (ssao pro)
    The closer I got to an object (with ssao pro enable) the more the framerate broke down.

    So when I turned off the post effect it was better, observed with the native unity solution.
    CurtisAuthor
    Up and Coming
    September 2, 2015
    Thanks for the suggestion, but that is the funny thing... I am only using post AA, and when I disable that I still have the same cpu spike. I even downloaded the oculus utilities and used the OVR player controller and I am still having the problem.

    I am just starting this project, so I have a super simple scene at the moment. Very basic cube geometry, a simple "floater/star" particle effect to give the scene some life/depth and some low poly trees (about 1000 verts each). when I get near a tree, that is when the problem happens.

    The spike seems to kick in when the mesh takes up most of the screen, but that could just be a coincidence.
    CurtisAuthor
    Up and Coming
    September 3, 2015
    Well.... I found the problem. I was using some older shaders, and when I replaced them with unity 5s standard shader everything seems to run much smoother.

    my mistake!