Advertisement
Guest User

Untitled

a guest
Jan 27th, 2018
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. void X264_Decode_Convert_gbr24p_to_packed32(const uint8_t** src, uint8_t *dst, int width, int height) {
  2.     int arrlen = width * height * 4;
  3.  
  4.     uint32_t *dp = (uint32_t*)dst;
  5.     const uint8_t* __restrict gp = src[0];
  6.     const uint8_t* __restrict bp = src[1];
  7.     const uint8_t* __restrict rp = src[2];
  8.     for (int i = 0; i < arrlen; i++) {
  9.     {
  10.         *(dp++) = (0xff<<24) | *rp++ << 16 | *gp++ << 8 | *bp++;
  11.     }
  12. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement