Skip to content

[Improvement] Use VK_KHR_video_maintenance1 #53

Open

Description

@DatCaptainHorse

Motivation

VK_KHR_video_maintenance1 extension is pretty much supported by any Vulkan Video API encode-capable hardware.

It allows creating codec profile-independent picture buffers with VK_BUFFER_CREATE_VIDEO_PROFILE_INDEPENDENT_BIT_KHR, this allows simplifying code and also pixelforge wouldn't then need to own the input images, just read them directly like DMA-BUFs. (Also VK_IMAGE_CREATE_VIDEO_PROFILE_INDEPENDENT_BIT_KHR).

The extension also brings VK_VIDEO_SESSION_CREATE_INLINE_QUERIES_BIT_KHR, simplifies code a bit without needing separate begin/end command query pairs.

@hgaiser This would be good with or after #50 work, as it would touch the import API.

Device support

Windows
Windows

Linux
Image

Activity

  1. hgaiser commented on Nov 2, 2026

    @hgaiser
    Owner

    Interesting! I'll have a look 👍

  2. hgaiser commented on Nov 4, 2026

    @hgaiser
    Owner

    Do I understand it correctly that this only helps if we're encoding RGB directly?

  3. DatCaptainHorse commented on Nov 5, 2026

    @DatCaptainHorse
    ContributorAuthor

    @hgaiser It helps everywhere, especially with reducing the per-codec buffer/image code, since VK_BUFFER_CREATE_VIDEO_PROFILE_INDEPENDENT_BIT_KHR and VK_IMAGE_CREATE_VIDEO_PROFILE_INDEPENDENT_BIT_KHR allow for profile (and codec) agnostic buffers + images.

    VK_VIDEO_SESSION_CREATE_INLINE_QUERIES_BIT_KHR reduces code a bit less, though might improve efficiency a bit as well.

    Best explained thru the extension doc I'd say: https://docs.vulkan.org/refpages/latest/refpages/source/VK_KHR_video_maintenance1.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions