Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Register
  • Sign in
  • mesa mesa
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 3.2k
    • Issues 3.2k
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 1k
    • Merge requests 1k
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • MesaMesa
  • mesamesa
  • Merge requests
  • !22108

Add some video codecs support for virgl

  • Review changes

  • Download
  • Patches
  • Plain diff
Open Huang Rui requested to merge rui/mesa:upstream-for-xen into main Mar 24, 2023
  • Overview 4
  • Commits 10
  • Pipelines 6
  • Changes 6

Background


We are working to add some Video codecs support on Xen with QEMU, please see details on XEN mail list. But the virtio video with virgl implementation is not related with hypervisor. So here, please kindly review virgl video patches and see the corresponding Virglrenderer implementation at virgl/virglrenderer!1068

Implementation Notes


Currently, there are a small number of video formats in mesa that can be hardware accelerated decoding in VM, and these patches are aimed at adding more video formats to let them can be hardware accelerated decoding.

Those formats are added: mpeg12, vc1, jpeg, hevc10bit and vp9. Different virgl_picture_desc structures are added in virgl_video_hw.h, parameter will be bypassed into virgl_picture_desc in different fill_picture_desc function. Virtio gpu libva backend will bypass all the video parameter and command into virglrenderer, it will call the host libva to decode video and feedback the results back to the guest. Therefore, this modification should be used with the relevant modifications in virglenderer to take effect. And for qemu part, function get_drm_fd callback is added to let the guest OS can get render node.

Currently, many video decoding formats have been added, but the efficiency of decoding in the VM is not very high. This is mainly due to the inefficient video data transmission method between the host and the guest. In the future, blob memory may will be used to improve the efficiency of video decoding.

Reference


Screenshot: VirtIO_Video_Xen

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: upstream-for-xen