Top
audio_capture
audio_decode
audio_encode
audio_lowpower
audio_mixer
audio_processor
audio_render
audio_splitter
image_decode
image_encode
image_fx
image_read
image_write
resize
source
transition
write_still
clock
null_sink
text_scheduler
visualisation
read_media
write_media
camera
egl_render
video_decode
video_encode
video_render
video_scheduler
video_splitter
Custom Index
Metadata

OMX.broadcom.video_encode

200
video_encode
201

This component accepts raw video frames and compresses them, emitting encoded video. It can accept YUV420 packed planar format, providing the slice height is the same as the frame height so a single buffer is a full frame. To gain efficiency it also accepts a proprietary image format from the camera component.

Header bytes from the codec are sent in buffers (before any data) with the buffer flag OMX_BUFFERFLAG_CODECCONFIG set. The last of these buffers will also have OMX_BUFFERFLAG_ENDOFFRAME set.

PortIndexNotes
200OMX_IndexParamPortDefinition Query / set the format of the raw video frames. eColorFormat must be OMX_COLOR_FormatYUV420PackedPlanar, OMX_COLOR_FormatYUV420PackedSemiPlanar, OMX_COLOR_Format16bitRGB565, OMX_COLOR_Format24bitBGR888, or OMX_COLOR_Format32bitABGR8888. nSliceHeight must be the same as nFrameHeight rounded up to the nearest multiple of 16. nStride must be a multiple of 32. Additional proprietary formats are allowed. This port also accepts being tunnelled with an image domain output port, and will convert fields as necessary.
OMX_IndexParamCameraPoolToEncoderFunction Used to set up proprietary communication with the previous component.
OMX_IndexConfigBrcmUseProprietaryCallback Forces use of proprietary tunnelling between ports.
201OMX_IndexParamPortDefinition Query / set the output format. eCompressionFormat specifies the format to which to encode. nBitrate specifies the target bit rate (unless overridden by OMX_IndexParamVideoBitrate). The output will either use VBR, or no rate control at all if the bitrate is zero.
OMX_IndexParamVideoBitrate Query / set the output bitrate type and target bitrate. Overrides any setting made via the port definition. Can only be set when in LOADED.
OMX_IndexConfigVideoBitrate Allows changing the target bitrate while the component is EXECUTING. Only valid if rate control is enabled (see OMX_IndexParamVideoBitrate).
OMX_IndexParamVideoProfileLevelCurrent Get or set the current profile and level, provided this is supported by the codec itself. At present only the H.264 codec supports this. Setting the level merely sets the bits sent in the headers, and does not change the way that encoding happens.

A value of -1 for either profile or level will result in using the codec's internal defaults for that property.

OMX_IndexParamVideoProfileLevelQuerySupported Allows to client to enumerate the various profile and level supported by the port. Only the highest level is reported for each supported profile.
OMX_IndexConfigVideoAVCIntraPeriod Enable and configure the IDR and intra periodicity for the AVC encoder.
OMX_IndexConfigBrcmVideoEncodedSliceSize Video encoding output slice size.

This config allows the client to set the slice size used in bytes, as opposed to the standard OMX parameters which are in macroblocks.

OMX_IndexConfigBrcmVideoIntraPeriodTime Configure the time between intra frames, in microseconds. Only valid if the framerate is zero (and hence the framerate is inferred from timestamps). This overrides the setting in OMX_IndexConfigBrcmVideoIntraPeriod.
OMX_IndexConfigBrcmVideoIntraPeriod Configure the number of frames between intra frames. This overrides the setting in OMX_IndexConfigBrcmVideoIntraPeriodTime.
OMX_IndexParamBrcmPixelAspectRatio Allows configuring the pixel aspect ratio. Allowed values are: 1:1, 10:11, 16:11, 40:33, 59:54, and 118:81.
OMX_IndexParamBrcmPixelValueRange Allows configuring the pixel value range.
OMX_IndexParamVideoIntraRefresh Configures the intra refresh mode, if supported by the codec.
OMX_IndexConfigBrcmVideoIntraRefresh Configures the intra refresh mode, if supported by the codec. Can be used when the component is executing.
OMX_IndexConfigBrcmVideoEncoderMBRowsPerSlice Configures the number of macro-block rows per slice. Setting the value to zero resets to the default (one slice per frame).
OMX_IndexConfigVideoFramerate Allows run-time changing of the encoder frame rate setting. Overrides any framerate setting found from the source component.
OMX_IndexParamILFifoConfig Allows configuration of the FIFO settings. The FIFO size itself is ignored (the value from the codec is used) but the number of FIFO headers can be modified.
OMX_IndexParamBrcmVideoAVCSEIEnable Enable/disable SEI messages. Enable or disable Supplemental Enhancement Information (SEI) messages to be inserted in the H.264 bitstream.
OMX_IndexParamVideoQuantization Query / set the quantization parameters for P and I frames. Only used if rate control has been disabled.
OMX_IndexParamVideoErrorCorrection Allows configuring the error correction modes. Resynch marker spacing is ignored.
OMX_IndexParamCodecConfig Query for codec-specific information.
OMX_IndexParamBrcmNALSSeparate Force NALs to come out in separate buffers. With this enabled, those encoders that support it will produce NALs in separate OMX buffers.
OMX_IndexParamVideoMpeg4 This parameter is handled but only partially filled in by the component. A query might return some zero values and some values might be ignored upon a set depending on what the encoder supports.
OMX_IndexParamVideoAvc This parameter is handled but only partially filled in by the component. A query might return some zero values and some values might be ignored upon a set depending on what the encoder supports.
OMX_IndexParamVideoH263 This parameter is handled but only partially filled in by the component. A query might return some zero values and some values might be ignored upon a set depending on what the encoder supports.
OMX_IndexParamBrcmCRC Query for the latest CRC for output data on this port.
OMX_IndexParamBrcmDataUnit Query the type of data delivery for the encoded data. This port emits OMX_DataUnitCodedPicture format data.
OMX_IndexParamNalStreamFormatSupported Query the supported NAL stream formats (valid only for H.264). For now only OMX_NaluFormatStartCodes and OMX_NaluFormatFourByteInterleaveLength are supported.
OMX_IndexParamNalStreamFormat Query the native NAL stream format (valid only for H.264). The native format is always OMX_NaluFormatStartCodes.
OMX_IndexParamNalStreamFormatSelect Set the NAL stream format (valid only for H.264).
OMX_IndexConfigEncLevelExtension Allow the video encoder to encode at extended capabilities (frame size, bitrate, number of macroblocks per second), instead of those specified by the requested level. Enabled for AVC encoder only.
OMX_IndexParamBrcmVideoEncodeMinQuant Query / set the codec's minimum quantization level.
OMX_IndexParamBrcmVideoEncodeMaxQuant Query / set the codec's maximum quantization level.
200 201OMX_IndexConfigBrcmPortStats Return port statistics.
OMX_IndexParamVideoPortFormat Query / set the video port format. The input port supports uncompressed pixel data, the output port supports a varietary of compressed formats.
 OMX_IndexParamBrcmAllowMemChange Allow the component to change the amount of memory allocated when it goes from LOADED to IDLE and has already allocated memory during an earlier transition. Enabled by default.
OMX_IndexParamBrcmRetainMemory Controls memory allocating during state transitions.
OMX_IndexParamBrcmImmutableInput Require the encoder to not modify the input images. This uses the standard OMX_CONFIG_BOOLEANTYPE structure. If set to OMX_TRUE, the encoder will not modify the input images. Only relevant when using proprietary tunnels.
OMX_IndexConfigBrcmVideoRequestIFrame Request an I frame. If set to OMX_TRUE, the next job submitted will be flagged to be converted as an I-frame. This automatically resets itself. This works with proprietary tunnelling and OMX buffers.
OMX_IndexParamBrcmCRCEnable Query / set whether this component should calcualte CRCs on output data. Setting this index resets CRCs to zero. CRC calculation defaults to off.
OMX_IndexConfigMinimiseFragmentation Query / set whether the component should minimise the fragmentation of output data when copying into genuine OMX buffers. This does not change the behaviour when a pointer to the output FIFO is used as the output buffer with appropriate offsets and lengths.
OMX_IndexParamComponentName Sets the component name to be used in internal logging messages.
OMX_IndexParamBrcmEEDEEnable Allow video encoder to enable end to end distortion estimator. Enabling/disabling can only be performed at setup time. 1 enables EEDE, 0 disables EEDE. By default, EEDE is disabled.
OMX_IndexParamBrcmEEDELossRate Sets the packet loss rate used by end to end distortion estimator. This can be done during setup or runtime. The loss rate is an integer value, for example, 5 means 5% packet loss. By default, loss rate is set to be 0 to begin with.
OMX_IndexConfigBrcmPoolMemAllocSize Query for the size of the allocated image pool.
OMX_IndexParamRateControlModel Query / set the rate control method to be used. This parameter uses internal configuration to determine used, so should not be changed without explicit internal knowledge.