Advertisement
fx159159

Untitled

Oct 30th, 2017
50
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.42 KB | None | 0 0
  1. int32_t display_matrix[9];
  2.  
  3. if (ctx->sensor_orientation) {
  4.     av_display_rotation_set(display_matrix, 360 - ctx->sensor_orientation);
  5. }
  6.  
  7. if (ctx->lens_facing == ACAMERA_LENS_FACING_FRONT) {
  8.     av_display_matrix_flip(display_matrix, 1, 0);
  9. }
  10.  
  11. uint8_t *side_data = av_packet_new_side_data(&pktl_next->pkt, AV_PKT_DATA_DISPLAYMATRIX, sizeof(display_matrix));
  12. memcpy(side_data, display_matrix, sizeof(display_matrix));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement