Bitrate And Frame Type - Texas Instruments DSP/BIOS Real-Time Analysis (RTA User Manual

Dsp/bios real-time analysis (rta) and debugging applied to a video application
Table of Contents

Advertisement

These estimates are fairly accurate for the color conversion functions in the input and display
tasks, but the estimates are less accurate for the encoder and decoder algorithms in the
processing task. Ideally, the memory bus utilization should be available in the status structure or
estimated on the data sheet of an algorithm. It is recommended that you request this information
from third-party algorithm providers during application development, particularly for applications
above D1 (720x480) resolution.
The estimates of the memory bus utilization of the algorithms and major functions in the system
are defined in rtaVideodebug.h as:
#define EST_ENCODE_BUSUTIL_IN_FRAMES 2.5
#define EST_DECODE_BUSUTIL_IN_FRAMES 2.5
#define EST_CAP_BUSUTIL_IN_FRAMES 3.5
#define EST_DIS_BUSUTIL_IN_FRAMES 3.5
The number 2.5 * frame size (in pixels) was chosen for the encoder and decoder as an estimate
of the bus utilization. Actual values may vary, so you can modify this estimate, or can replace it
with an actual calculation if the algorithm can provide that data in its status structure.
The bus utilization benchmarks are reset by the benchmarking routines every 30 frames, and
are logged to the STS object named sts+"task"+BusUtil for viewing in the DSP/BIOS Statistics
View tool. This results in a bus utilization statistic in bytes per second.
4.8

Bitrate and Frame Type

Bitrate is important in applications that do encoding or decoding. The bitrate of encoded video
often varies greatly with different video content, increasing to high values during periods of high
motion and image complexity, and decreasing to low values during relatively still video with less
image complexity. Encoder applications must trade off bitrate for quality, so the capability to
accurately measure and monitor bitrate is an important tool for video system designers.
This example provides a mechanism for real-time bitrate measurement and control. This is
possible because the H.263 encoder algorithm used by the application allows control and
monitoring of the bitrate.
#ifdef RTA_INCLUDED
while( MBX_pend( &mbxProcess, &rxMsg, 0) ) // poll with zero timeout value, which
{
switch(rxMsg.cmd)
case BITRATECHANGED:
h263encParams.bitRate = rxMsg.arg2; // controlVideoProc.bitRateTarget from GEL
H263ENC_cellControl(&(chanHandle->cellSet[CELLH263ENC]), IH263ENC_SETPARAMS,
break;
case FRAMERATECHANGED:
frameRateTarget = rxMsg.arg2; // controlVideoProc.bitRateTarget from GEL
h263encParams.frameRate = frameRateTarget;
H263ENC_cellControl(&(chanHandle->cellSet[CELLH263ENC]), IH263ENC_SETPARAMS,
break;
}
} // end polling of MBX
#endif // #ifdef RTA_INCLUDED
// returns zero right away if no message is available
{
(void *)&h263encParams);
(void *)&h263encParams);
DSP/BIOS Real-Time Analysis (RTA) and Debugging Applied to a Video Application
SPRAA56
17

Advertisement

Table of Contents
loading

This manual is also suitable for:

Dsp/bios real-time analysisDsp/bios rta

Table of Contents