| 214 | } |
| 215 | |
| 216 | static void SetSpans(int sBlkSize, int tBlkSize, s32* tSpan, s32* sBlkSpan, s32* tBlkSpan, s32* writeStride) |
| 217 | { |
| 218 | // width is 1 less than the number of pixels of width |
| 219 | u32 width = bpmem.copyTexSrcWH.x >> bpmem.triggerEFBCopy.half_scale; |
| 220 | u32 alignedWidth = (width + sBlkSize) & (~(sBlkSize-1)); |
| 221 | |
| 222 | u32 readStride = 3 << bpmem.triggerEFBCopy.half_scale; |
| 223 | |
| 224 | *tSpan = (640 - sBlkSize) * readStride; // bytes to advance src pointer after each row of texels in a block |
| 225 | *sBlkSpan = ((-640 * tBlkSize) + sBlkSize) * readStride; // bytes to advance src pointer after each block |
| 226 | *tBlkSpan = ((640 * tBlkSize) - alignedWidth) * readStride; // bytes to advance src pointer after each row of blocks |
| 227 | |
| 228 | *writeStride = bpmem.copyMipMapStrideChannels * 32; |
| 229 | } |
| 230 | |
| 231 | #define ENCODE_LOOP_BLOCKS \ |
| 232 | for (int tBlk = 0; tBlk < tBlkCount; tBlk++) { \ |
no outgoing calls
no test coverage detected