Wednesday, March 31, 2010

[Cpp-Programming] Why would this fail?

I have this piece of code that simply copies one array into another it
worked for a while now it fails what could make this fail?

bits = new BYTE[acc*dwn];
...

bits = flip();

BYTE* bitmap::flip(){

BYTE * temp = new BYTE[acc*dwn];

for (int index=0; index < dwn; index++)
// memcpy(&temp[((dwn-1) - index)*acc],
// &bits[index*acc], acc);


return temp;

--
You received this message because you are subscribed to the Google Groups "C++ Programming" group.
To post to this group, send email to cpp-programming@googlegroups.com.
To unsubscribe from this group, send email to cpp-programming+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/cpp-programming?hl=en.

0 Comments:

Post a Comment

<< Home