from opengl wiki:
if updating small section, use glbuffersubdata. if update entire vbo, use glbufferdata (this information reportedly comes nvidia document). however, approach reputed work when updating entire buffer call glbufferdata null pointer, , glbuffersubdata new contents. null pointer glbufferdata lets driver know don't care previous contents it's free substitute totally different buffer, , helps driver pipeline uploads more efficiently.
i realize research, mean "helps pipeline upload more efficiently" allows asynchronous buffer writes makes dynamic buffers faster.
however, excerpt , others seem suggest "null" argument glbufferdata important, , it's cause orphaning , it's promotes asynchronous writes.
but common sense telling me, doesn't need null, can put pointer of data there instead of null. important part orphaning fact you're calling glbufferdata again , therefore reallocating storage of buffer, therefore orphaning old storage, therefore allowing asynchronous writes. correct thinking this?
Comments
Post a Comment