Download Video and Image Processing Suite User Guide

Transcript
5–66
Chapter 5: Functional Descriptions
Stall Behavior and Error Recovery
Stall Behavior and Error Recovery
The Video and Image Processing Suite MegaCore functions do not continuously
process data. Instead, they use flow-controlled Avalon-ST interfaces, which allow
them to stall the data while they perform internal calculations.
During control packet processing, the MegaCore functions might stall frequently and
read/write less than once per clock cycle. During data processing, the MegaCore
functions generally process one input/output per clock cycle. There are, however,
some stalling cycles. Typically, these are for internal calculations between rows of
image data and between frames/fields.
When stalled, the MegaCore function signals that it is not ready to receive or produce
data. The time spent in the stalled state varies between MegaCore functions and their
parameterizations. In general, it is a few cycles between rows and a few more between
frames. Details of exceptions to this behavior and details of stalling due to internal
buffering are given for each MegaCore function in the following sections.
If data is not available at the input when required, all of the MegaCore functions stall,
and thus do not output data. With the exceptions of the Deinterlacer and Frame Buffer
in double or triple-buffering mode, none of the MegaCore functions ever overlap the
processing of consecutive frames. The first sample of frame F + 1 is not input until
after the last sample of frame F has been output.
The following sections give bounds and guidelines describing the stalling and
throughput of the MegaCore functions but do not attempt to specify precise behavior
down to the last clock cycle. When an endofpacket signal is received unexpectedly
(early or late), the MegaCore function recovers from the error and prepares itself for
the next valid packet (control or data). The time taken to do this is described in each of
the following sections.
The exact behavior of the MegaCore functions may vary between releases or if any of
the parameters are changed.
Color Space Converter
In all parameterizations, the Color Space Converter only stalls between frames and
not between rows. It has no internal buffering apart from the registers of its
processing pipeline so there are only a few clock cycles of latency.
Error Recovery
The Color Space Converter MegaCore function processes video packets until an
endofpacket signal is received; the control packets are not used. For this MegaCore
function, there is no such condition as an early or late endofpacket, any mismatch of
the endofpacket signal and the frame size is propagated unchanged to the next
MegaCore function.
Chroma Resampler
All modes of the Chroma Resampler stall for a few cycles between frames and
between lines. Latency from input to output varies depending on the operation mode
of the Chroma Resampler MegaCore function. The only modes with latency of more
than a few cycles are 4:2:0 to 4:2:2 and 4:2:0 to 4:4:4. These modes have a latency
corresponding to one line of 4:2:0 data.
Video and Image Processing Suite User Guide
July 2010 Altera Corporation