Class VkVideoEncodeAV1PictureInfoKHR

java.lang.Object
org.lwjgl.system.Pointer.Default
org.lwjgl.system.Struct<VkVideoEncodeAV1PictureInfoKHR>
org.lwjgl.vulkan.VkVideoEncodeAV1PictureInfoKHR
All Implemented Interfaces:
AutoCloseable, org.lwjgl.system.NativeResource, org.lwjgl.system.Pointer

public class VkVideoEncodeAV1PictureInfoKHR extends org.lwjgl.system.Struct<VkVideoEncodeAV1PictureInfoKHR> implements org.lwjgl.system.NativeResource
Structure specifies AV1 encode frame parameters.
Description

This structure is specified in the pNext chain of the VkVideoEncodeInfoKHR structure passed to CmdEncodeVideoKHR to specify the codec-specific picture information for an AV1 encode operation.

Encode Input Picture Information
Std Picture Information
  • flags.reserved and reserved1 are used only for padding purposes and are otherwise ignored;
  • pSegmentation must be NULL
    Note

    AV1 segmentation is currently not supported in video encode operations. Accordingly, the application needs to set flags.segmentation_enabled to 0 and pSegmentation to NULL.

  • pTileInfo is NULL or a pointer to a StdVideoAV1TileInfo structure specifying AV1 tile parameters;
  • the StdVideoAV1Quantization structure pointed to by pQuantization is interpreted as follows:
    • flags.reserved is used only for padding purposes and is otherwise ignored;
    • all other members of StdVideoAV1Quantization are interpreted as defined in section 6.8.11 of the AV1 Specification;
  • the StdVideoAV1LoopFilter structure pointed to by pLoopFilter is interpreted as follows:
    • flags.reserved is used only for padding purposes and is otherwise ignored;
    • update_ref_delta is a bitmask where bit index i is interpreted as the value of update_ref_delta corresponding to element i of loop_filter_ref_deltas as defined in section 6.8.10 of the AV1 Specification;
    • update_mode_delta is a bitmask where bit index i is interpreted as the value of update_mode_delta corresponding to element i of loop_filter_mode_deltas as defined in section 6.8.10 of the AV1 Specification;
    • all other members of StdVideoAV1LoopFilter are interpreted as defined in section 6.8.10 of the AV1 Specification;
  • if flags.enable_cdef is set in the active sequence header, then the members of the StdVideoAV1CDEF structure pointed to by pCDEF are interpreted as follows:
    • cdef_y_sec_strength and cdef_uv_sec_strength are the bitstream values of the corresponding syntax elements defined in section 5.9.19 of the AV1 Specification;
    • all other members of StdVideoAV1CDEF are interpreted as defined in section 6.10.14 of the AV1 Specification;
  • if flags.UsesLr is set in the active sequence header, then the StdVideoAV1LoopRestoration structure pointed to by pLoopRestoration is interpreted as follows:
    • LoopRestorationSize[plane] is interpreted as log2(size) - 5, where size is the value of LoopRestorationSize[plane] as defined in section 6.10.15 of the AV1 Specification;
    • all other members of StdVideoAV1LoopRestoration are defined as in section 6.10.15 of the AV1 Specification;
  • the members of the StdVideoAV1GlobalMotion structure provided in global_motion are interpreted as defined in section 7.10 of the AV1 Specification;
  • pExtensionHeader is NULL or a pointer to a StdVideoEncodeAV1ExtensionHeader structure whose temporal_id and spatial_id members specify the temporal and spatial layer ID of the reference frame, respectively (these IDs are encoded into the OBU extension header if VkVideoEncodeAV1PictureInfoKHR::generateObuExtensionHeader is set to TRUE for the encode operation);
  • if flags.buffer_removal_time_present_flag is set, then pBufferRemovalTimes is a pointer to an array of N number of unsigned integer values specifying the elements of the buffer_removal_time array, as defined in section 6.8.2 of the AV1 Specification, where N is the number of operating points specified for the active sequence header through VkVideoEncodeAV1SessionParametersCreateInfoKHR::stdOperatingPointCount;
  • all other members are interpreted as defined in section 6.8 of the AV1 Specification.

Reference picture setup is controlled by the value of StdVideoEncodeAV1PictureInfo::refresh_frame_flags. If it is not zero and a reconstructed picture is specified, then the latter is used as the target of picture reconstruction to activate the DPB slot specified in pEncodeInfo→pSetupReferenceSlot→slotIndex. If StdVideoEncodeAV1PictureInfo::refresh_frame_flags is zero, but a reconstructed picture is specified, then the corresponding picture reference associated with the DPB slot is invalidated, as described in the DPB Slot States section.

Std Tile Parameters
  • flags.reserved and reserved1 are used only for padding purposes and are otherwise ignored;
  • TileCols and TileRows specify the number of tile columns and tile rows as defined in section 6.8.14 of the AV1 Specification;
  • tile_size_bytes_minus_1 is ignored, as its value, as defined in section 6.8.14 of the AV1 Specification, is determined as the result of the encoding process;
  • pMiColStarts and pMiRowStarts are ignored, as the elements of the MiColStarts and MiRowStarts arrays defined in section 6.8.14 of the AV1 Specification are determined by the implementation based on the tile widths and heights determined by the implementation or specified through the pWidthInSbsMinus1 and pHeightInSbsMinus1 arrays, respectively;
  • pWidthInSbsMinus1 is NULL or a pointer to an array of TileCols number of unsigned integers that corresponds to width_in_sbs_minus_1 defined in section 6.8.14 of the AV1 Specification;
  • pHeightInSbsMinus1 is NULL or is a pointer to an array of TileRows number of unsigned integers that corresponds to height_in_sbs_minus_1 defined in section 6.8.14 of the AV1 Specification;
  • all other members of StdVideoAV1TileInfo are interpreted as defined in section 6.8.14 of the AV1 Specification.

If flags.uniform_tile_spacing_flag is set, then pWidthInSbsMinus1 and pHeightInSbsMinus1 are ignored.

If flags.uniform_tile_spacing_flag is not set and pWidthInSbsMinus1 is NULL, then the width of individual tile columns is determined in an implementation-dependent manner.

If flags.uniform_tile_spacing_flag is not set and pHeightInSbsMinus1 is NULL, then the height of individual tile rows is determined in an implementation-dependent manner.

Note

In general, implementations are expected to respect the application-specified AV1 tile parameters. However, as implementations may have restrictions on the combination of tile column and row counts, and tile widths and heights with respect to the extent of the encoded frame beyond the restrictions specified in the AV1 Specification and this specification (through video profile capabilities), certain parameter combinations may require the implementation to override them in order to conform to such implementation-specific limitations.

Active Parameter Sets
The active sequence header is the AV1 sequence header stored in the bound video session parameters object.
Valid Usage
Valid Usage (Implicit)
  • sType must be STRUCTURE_TYPE_VIDEO_ENCODE_AV1_PICTURE_INFO_KHR
  • predictionMode must be a valid VkVideoEncodeAV1PredictionModeKHR value
  • rateControlGroup must be a valid VkVideoEncodeAV1RateControlGroupKHR value
  • pStdPictureInfo must be a valid pointer to a valid StdVideoEncodeAV1PictureInfo value

Layout


 struct VkVideoEncodeAV1PictureInfoKHR {
     VkStructureType sType();
     void const * pNext();
     VkVideoEncodeAV1PredictionModeKHR predictionMode();
     VkVideoEncodeAV1RateControlGroupKHR rateControlGroup();
     uint32_t constantQIndex();
     StdVideoEncodeAV1PictureInfo const * pStdPictureInfo();
     int32_t referenceNameSlotIndices()[VK_MAX_VIDEO_AV1_REFERENCES_PER_FRAME_KHR];
     VkBool32 primaryReferenceCdfOnly();
     VkBool32 generateObuExtensionHeader();
 }
  • Field Details

    • SIZEOF

      public static final int SIZEOF
      The struct size in bytes.
    • ALIGNOF

      public static final int ALIGNOF
      The struct alignment in bytes.
    • STYPE

      public static final int STYPE
      The struct member offsets.
    • PNEXT

      public static final int PNEXT
      The struct member offsets.
    • PREDICTIONMODE

      public static final int PREDICTIONMODE
      The struct member offsets.
    • RATECONTROLGROUP

      public static final int RATECONTROLGROUP
      The struct member offsets.
    • CONSTANTQINDEX

      public static final int CONSTANTQINDEX
      The struct member offsets.
    • PSTDPICTUREINFO

      public static final int PSTDPICTUREINFO
      The struct member offsets.
    • REFERENCENAMESLOTINDICES

      public static final int REFERENCENAMESLOTINDICES
      The struct member offsets.
    • PRIMARYREFERENCECDFONLY

      public static final int PRIMARYREFERENCECDFONLY
      The struct member offsets.
    • GENERATEOBUEXTENSIONHEADER

      public static final int GENERATEOBUEXTENSIONHEADER
      The struct member offsets.
  • Constructor Details

    • VkVideoEncodeAV1PictureInfoKHR

      public VkVideoEncodeAV1PictureInfoKHR(ByteBuffer container)
      Creates a VkVideoEncodeAV1PictureInfoKHR instance at the current position of the specified ByteBuffer container. Changes to the buffer's content will be visible to the struct instance and vice versa.

      The created instance holds a strong reference to the container object.

  • Method Details