Skip to content
  • Gwenole Beauchesne's avatar
    jpeg: rework and optimize parser. · f52dfe57
    Gwenole Beauchesne authored
    Split the input buffer data into decoder units that represent a JPEG
    segment. Handle scan decoder unit specifically so that it can include
    both the scan header (SOS) but also any other ECS or RSTi segment.
    
    That way, we parse the input buffer stream only once at the gst-vaapi
    level instead of (i) in gst_vaapi_decoder_jpeg_parse() to split the
    stream into frames SOI .. EOI and (ii) in decode_buffer() to further
    determine segment boundaries and decode them.
    
    In practice, this is a +15 to +25% performance improvement.
    f52dfe57