opengl - Having a lot of vertices -
opengl - Having a lot of vertices -
i'm trying draw opengl 3d terrain , started wonder if there huge cpu headache if have lot of vertices without drawing triangles them.
there can overhead, should not huge. lot of highly platform dependent.
gpus utilize address spaces different cpu uses. create memory pages accessible gpu, pages have mapped gpu address space. there per-page overhead create these mappings. memory pages accessed gpu may have pinned/wired prevent them beingness paged off while gpu accessing them. again, there can per-page overhead wire pages.
as long buffer remains mapped, pay cost these operations once, , not each frame. if resource limits reached, either application, or in combination other applications using gpu, buffers may unmapped, , overhead can become repeated.
if have enormous buffers, , typically using little part of them, may beneficial split geometry multiple smaller buffers. of course of study that's practical if can grouping vertices utilize vertices little number of buffers given frame. there overhead binding each buffer, having many buffers not desirable either.
if vertices utilize draw phone call in limited index range, can using gldrawrangeelements() drawing. call, provide index range can used draw call, gives driver chance map part of buffer instead of entire buffer.
opengl cpu-usage vertices
Comments
Post a Comment