[FFmpeg-trac] #1854(swscale:new): libswscale has unreasonable alignment constraints

FFmpeg trac at avcodec.org
Sat Oct 27 13:51:07 CEST 2012


#1854: libswscale has unreasonable alignment constraints
---------------------------------+---------------------------------------
             Reporter:  gjdfgh   |                     Type:  enhancement
               Status:  new      |                 Priority:  normal
            Component:  swscale  |                  Version:  unspecified
             Keywords:           |               Blocked By:
             Blocking:           |  Reproduced by developer:  0
Analyzed by developer:  0        |
---------------------------------+---------------------------------------
 First of, there's a difference between alignment of single pixels, and
 alignment of the image start pointer. It's reasonable to demand strict
 alignment constraints on single pixels, e.g. that a pixels of size 4
 should be aligned to 4.

 But having a 16 byte alignment on a pixel start pointer is not reasonable.
 For example, this doesn't allow passing cropped images to libswscale.
 (Unless the images are cropped in a way they satisfy the alignment
 constraints again.)

 Rather than fully reverting to the slow path in this case, libswscale
 should use the slow path only for the first N unaligned pixels, until an
 aligned pixel is reached, and then continue with an accelerated SIMD code
 path.

-- 
Ticket URL: <https://ffmpeg.org/trac/ffmpeg/ticket/1854>
FFmpeg <http://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list