Skip to content
  • Sebastian Rasmussen's avatar
    rtpjpegpay: Ceil jpeg dimensions, instead of floor · c090201c
    Sebastian Rasmussen authored
    A JPEG image inside an RTP stream has a preceeding RFC2435 header that
    conveys width/height. The dimensions in this header are limited to be
    multiples of 8. Since JPEG uses an MCU of 8x8 pixels any image must
    already indirectly have image data dimensions that are rounded up in
    order to contain enough data to render the image. Therefore this fix
    safely rounds the image dimensions in the RFC2435 header up to the
    closest multiple of 8.
    c090201c