[Libav-user] Retrieve 10bit video frames

Michael Bradshaw mbradshaw at sorensonmedia.com
Thu May 17 00:59:18 CEST 2012


> However, the decoded frameYUV->data is of type uint8_t, and I would expect
> to get something able to store 10bit values like a uint16_t. So, what is
> returned in this 8bit array in this case? How can I proceed to get the 10bit
> values?

Just cast the buffer.

uint16_t* planes[3] = {(uint16_t*)frameYUV->data[0],
(uint16_t*)frameYUV->data[1], (uint16_t*)frameYUV->data[2]};

--Michael


More information about the Libav-user mailing list