Class VkVideoEncodeH264PictureInfoKHR

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

public class VkVideoEncodeH264PictureInfoKHR extends org.lwjgl.system.Struct<VkVideoEncodeH264PictureInfoKHR> implements org.lwjgl.system.NativeResource
Structure specifies H.264 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 H.264 encode operation.

Encode Input Picture Information
Std Picture Information
  • flags.reserved and reserved1 are used only for padding purposes and are otherwise ignored;
  • flags.IdrPicFlag as defined in section 7.4.1 of the ITU-T H.264 Specification;
  • flags.is_reference as defined in section 3.136 of the ITU-T H.264 Specification;
  • seq_parameter_set_id and pic_parameter_set_id are used to identify the active parameter sets, as described below;
  • primary_pic_type as defined in section 7.4.2 of the ITU-T H.264 Specification;
  • PicOrderCnt as defined in section 8.2 of the ITU-T H.264 Specification;
  • temporal_id as defined in section G.7.4.1.1 of the ITU-T H.264 Specification;
  • if pRefLists is not NULL, then it is a pointer to a StdVideoEncodeH264ReferenceListsInfo structure that is interpreted as follows:
    • flags.reserved is used only for padding purposes and is otherwise ignored;
    • ref_pic_list_modification_flag_l0 and ref_pic_list_modification_flag_l1 as defined in section 7.4.3.1 of the ITU-T H.264 Specification;
    • num_ref_idx_l0_active_minus1 and num_ref_idx_l1_active_minus1 as defined in section 7.4.3 of the ITU-T H.264 Specification;
    • RefPicList0 and RefPicList1 as defined in section 8.2.4 of the ITU-T H.264 Specification where each element of these arrays either identifies an active reference picture using its DPB slot index or contains the value STD_VIDEO_H264_NO_REFERENCE_PICTURE to indicate “no reference picture”;
    • if refList0ModOpCount is not zero, then pRefList0ModOperations is a pointer to an array of refList0ModOpCount number of StdVideoEncodeH264RefListModEntry structures specifying the modification parameters for the reference list L0 as defined in section 7.4.3.1 of the ITU-T H.264 Specification;
    • if refList1ModOpCount is not zero, then pRefList1ModOperations is a pointer to an array of refList1ModOpCount number of StdVideoEncodeH264RefListModEntry structures specifying the modification parameters for the reference list L1 as defined in section 7.4.3.1 of the ITU-T H.264 Specification;
    • if refPicMarkingOpCount is not zero, then refPicMarkingOperations is a pointer to an array of refPicMarkingOpCount number of StdVideoEncodeH264RefPicMarkingEntry structures specifying the reference picture marking parameters as defined in section 7.4.3.3 of the ITU-T H.264 Specification;
  • all other members are interpreted as defined in section 7.4.3 of the ITU-T H.264 Specification.

Reference picture setup is controlled by the value of StdVideoEncodeH264PictureInfo::flags.is_reference. If it is set 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 StdVideoEncodeH264PictureInfo::flags.is_reference is not set, 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.

Active Parameter Sets
  • The active SPS is the SPS identified by the key specified in StdVideoEncodeH264PictureInfo::seq_parameter_set_id.
  • The active PPS is the PPS identified by the key specified by the pair constructed from StdVideoEncodeH264PictureInfo::seq_parameter_set_id and StdVideoEncodeH264PictureInfo::pic_parameter_set_id.

H.264 encoding uses explicit weighted sample prediction for a slice, as defined in section 8.4.2.3 of the ITU-T H.264 Specification, if any of the following conditions are true for the active PPS and the pStdSliceHeader member of the corresponding element of pNaluSliceEntries:

  • pStdSliceHeader→slice_type is STD_VIDEO_H264_SLICE_TYPE_P and weighted_pred_flag is enabled in the active PPS.
  • pStdSliceHeader→slice_type is STD_VIDEO_H264_SLICE_TYPE_B and weighted_bipred_idc in the active PPS equals STD_VIDEO_H264_WEIGHTED_BIPRED_IDC_EXPLICIT.
Valid Usage
Valid Usage (Implicit)
See Also

VkVideoEncodeH264NaluSliceInfoKHR

Layout


 struct VkVideoEncodeH264PictureInfoKHR {
     VkStructureType sType();
     void const * pNext();
     uint32_t naluSliceEntryCount();
     VkVideoEncodeH264NaluSliceInfoKHR const * pNaluSliceEntries();
     StdVideoEncodeH264PictureInfo const * pStdPictureInfo();
     VkBool32 generatePrefixNalu();
 }