| 677 | } |
| 678 | |
| 679 | void CopyFrameYV12(const UINT lines, BYTE* dst, UINT dst_pitch, const BYTE* src, int src_pitch) |
| 680 | { |
| 681 | ASSERT(src_pitch > 0); |
| 682 | |
| 683 | if (dst_pitch == src_pitch) { |
| 684 | memcpy(dst, src, dst_pitch * lines); |
| 685 | return; |
| 686 | } |
| 687 | |
| 688 | const UINT chromaheight = lines / 3; |
| 689 | const UINT lumaheight = chromaheight * 2; |
| 690 | |
| 691 | for (UINT y = 0; y < lumaheight; ++y) { |
| 692 | memcpy(dst, src, src_pitch); |
| 693 | src += src_pitch; |
| 694 | dst += dst_pitch; |
| 695 | } |
| 696 | |
| 697 | src_pitch /= 2; |
| 698 | dst_pitch /= 2; |
| 699 | for (UINT y = 0; y < chromaheight; ++y) { |
| 700 | memcpy(dst, src, src_pitch); |
| 701 | src += src_pitch; |
| 702 | dst += dst_pitch; |
| 703 | memcpy(dst, src, src_pitch); |
| 704 | src += src_pitch; |
| 705 | dst += dst_pitch; |
| 706 | } |
| 707 | } |
| 708 | |
| 709 | void CopyFrameV210(const UINT lines, BYTE* dst, UINT dst_pitch, const BYTE* src, int src_pitch) |
| 710 | { |
nothing calls this directly
no outgoing calls
no test coverage detected