Skip to content
  • Max Reitz's avatar
    sdl2: Support all virtio-gpu formats · 1abcfe9e
    Max Reitz authored
    
    
    There are some 2D resource formats that can be used through virtio-gpu,
    but which are not supported by SDL2 when used for a scanout; these are
    all alpha-channel formats and also XBGR (RGBX in non-BE pixman).
    
    Add these formats in the switch converting pixman to SDL format
    constants so a guest cannot crash the VM by triggering the
    g_assert_not_reached() with an unsupported format.
    
    Signed-off-by: default avatarMax Reitz <mreitz@redhat.com>
    Message-id: 20181008185013.19371-1-mreitz@redhat.com
    
    [ kraxel: also update sdl2_2d_check_format() ]
    
    Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
    1abcfe9e