• Create Account

### #Actualeppo

Posted 16 June 2012 - 02:41 PM

You have to write data per row/scanline as the driver may add extra padding at the end of each row.

e.g. for a single array slice:


for(int i = 0; i < 256; ++i) memcpy((byte*)databox.pData + databox.RowPitch * i, sysmem + 256 * 4 * i, 256 * 4);



### #2eppo

Posted 16 June 2012 - 02:41 PM

You have to write data per row/scanline as the driver may add extra padding at the end of each row.

e.g. for a single array slice:


[left]for(int i = 0; i <[/left]
[left]256[/left]
[left]; ++i) memcpy((byte*)databox.pData + databox.RowPitch * i, sysmem + 256 * 4 * i,[/left]
[left]256 * 4[/left]
[left]);[/left]



### #1eppo

Posted 16 June 2012 - 02:39 PM

You have to write data per row/scanline as the driver may add extra padding at the end of each row.

e.g. for a single array slice:

for(int i = 0; i <

256

; ++i) memcpy((byte*)databox.pData + databox.RowPitch * i, sysmem + 256 * 4 * i,

256 * 4

);

PARTNERS