Select your cookie preferences

We use essential cookies and similar tools that are necessary to provide our site and services. We use performance cookies to collect anonymous statistics, so we can understand how customers use our site and make improvements. Essential cookies cannot be deactivated, but you can choose “Customize” or “Decline” to decline performance cookies.

If you agree, AWS and approved third parties will also use cookies to provide useful site features, remember your preferences, and display relevant content, including relevant advertising. To accept or decline all non-essential cookies, choose “Accept” or “Decline.” To make more detailed choices, choose “Customize.”

Network Abstraction Layer (NAL) adaptation flag reference

Focus mode
Network Abstraction Layer (NAL) adaptation flag reference - Amazon Kinesis Video Streams

This section contains information about available flags for the StreamInfo.NalAdaptationFlags enumeration.

The elementary stream in an application can be in either Annex-B or AVCC format:

  • The Annex-B format delimits NALUs (Network Abstraction Layer units) with two bytes of zeroes, followed by one or three bytes of zeroes, followed by the number 1 (called a start code, for example, 00000001).

  • The AVCC format also wraps NALUs, but each NALU is preceded by a value that indicates the size of the NALU (usually four bytes).

Many encoders produce the Annex-B bitstream format. Some higher-level bitstream processors (such as a playback engine or the Media Source Extensions (MSE) player in the AWS Management Console) use the AVCC format for their frames.

The codec private data (CPD), which is SPS/PPS (Sequence Parameter Set/Picture Parameter Set) for the H.264 codec, can also be in Annex-B or AVCC format. However, for the CPD, the formats are different from those described previously.

The flags tell the SDK to adapt the NALUs to AVCC or Annex-B for frame data and CPD as follows:

Flag Adaptation
NAL_ADAPTATION_FLAG_NONE No adaptation.
NAL_ADAPTATION_ANNEXB_NALS Adapt Annex-B NALUs to AVCC NALUs.
NAL_ADAPTATION_AVCC_NALS Adapt AVCC NALUs to Annex-B NALUs.
NAL_ADAPTATION_ANNEXB_CPD_NALS Adapt Annex-B NALUs for the codec private data to AVCC format NALUs.
NAL_ADAPTATION_ANNEXB_CPD_AND_FRAME_NALS Adapt Annex-B NALUs for the codec and frame private data to AVCC format NALUs.

For more information about NALU types, see Section 1.3: Network Abstraction Layer Unit Types in RFC 3984.

PrivacySite termsCookie preferences
© 2025, Amazon Web Services, Inc. or its affiliates. All rights reserved.