Hi
Will there be much better performance with writing the buffer only once in one large chunk, than writing the buffer several times with small chunks, and just adjusting the offset for each write?
Performance with HardwareBuffer.writeData()
-
- Gnoblar
- Posts: 18
- Joined: Tue Jan 18, 2005 8:33 pm
-
- OGRE Retired Team Member
- Posts: 3067
- Joined: Tue Feb 10, 2004 12:53 pm
- Location: The Netherlands
- x 1
Yes.. or use lock() to get the memory pointer and only write the areas that you want to change (if the buffer is really big and you only need to change some areas) then unlock() .
Multiple write calls is worst as it locks/unlocks the buffer multiple times.
But in general you want to overwrite the entire buffer, yes.
Multiple write calls is worst as it locks/unlocks the buffer multiple times.
But in general you want to overwrite the entire buffer, yes.