Hi! Sorry for this late answer, I was a bit swamped lately.
> NSData wouldn't let you, but NSMutableData would, with methods like > appendBytes:length:, appendData:, increaseLengthBy:, etc. The underlying > buffer might have to move around if it cannot be extended in place, just as > it would if you use C realloc() calls. In fact, I overlooked that completely. I just fear building a buffer from zero to something like 400,000 * 3 * 4 bytes = just under 5 MiB would imply too many moves as you mention. Now, I am anyway moving towards a binary file that would be fed directly into the buffer rather than needing decoding, and partitioning it into several chunks in order to optimize the number of triangles displayed. I think I’ll use NSData to store these chunks. Thanks to all for the precious help! Vincent _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com