Advertisement

copying arrays

Started by February 05, 2000 09:54 AM
1 comment, last by Jimbo 24 years, 10 months ago
I have two 2d-arrays; buffer1 and buffer2 (created with: BYTE buffer1[76800]), and want to copy the contents of buffer1 to buffer2. Is there a good and fast way of doing this?
sure, just do this:
memcpy(buffer1,buffer2, 76800);
that should work
Advertisement
one thing to remember about memcpy is that it copies bytes, so if you memcpy anything larger than a byte, be sure to go:

memcpy(dest,source,elements*sizeof(elemant_data_type));
-PoesRaven

This topic is closed to new replies.

Advertisement