Altera Video and Image Processing Suite User Manual

Page 166

Advertising
background image

Types

Description

Double-buffering

• When you select double-buffering, external RAM uses two frame buffers.

Input pixels flow through the input port and into one buffer while pixels are

read from the other buffer, processed and output.

• When both the input and output sides have finished processing a frame, the

buffers swap roles so that the frame that the output can use the frame that

you have just input. You can overwrite the frame that the function uses to

create the output with a fresh input.

• The motion-adaptive algorithm uses four fields to build a progressive output

frame and the output side has to read pixels from two frame buffers rather

than one. Consequently, the motion-adaptive algorithm actually uses three

frame buffers in external RAM when you select double-buffering.

• When the input and output sides finish processing a frame, the output side

exchanges its buffer containing the oldest frame, frame n-2, with the frame it

receives at the input side, frame n. It keeps frame n-1 for one extra iteration

because it uses it with frame n to produce the next output.

Triple-buffering

• When you use triple-buffering, external RAM usually uses three frame

buffers. The function uses four frame buffers when you select the motion-

adaptive algorithm. At any time, one buffer is in use by the input and one

(two for the motion adaptive case) is (are) in use by the output in the same

way as the double-buffering case. The last frame buffer is spare.

• This configuration allows the input and output sides to swap asynchronously.

When the input finishes, it swaps with the spare frame if the spare frame

contains data that the output frame uses. Otherwise the function drops the

frame which you have just wrote and the function writes a fresh frame over

the dropped frame.

• When the output finishes, it also swaps with the spare frame and continues if

the spare frame contains fresh data from the input side. Otherwise it does not

swap and just repeats the last frame.

• Triple-buffering allows simple frame rate conversion. For example, suppose

you connect the Deinterlacing IP core’s input to a HDTV video stream in

1080i60 format and connect its output i to a 1080p50 monitor. The input has

60 interlaced fields per second, but the output tries to pull 50 progressive

frames per second.

If you configure the Deinterlacing IP cores to output one frame for each input field, it produces 60 frames

of output per second. If you enable triple-buffering, on average the function drops one frame in six so that

it produces 50 frames per second. If you select one frame output for every pair of fields input, the Deinter‐

lacing IP cores produce 30 frames per second output and triple-buffering leads to the function repeating

two out of every three frames on average.
When you select double or triple-buffering, the Deinterlacing IP cores have two or more Avalon-MM

master ports. These must be connected to an external memory with enough space for all of the frame

buffers required. The amount of space varies depending on the type of buffering and algorithm selected.

An estimate of the required memory is shown in the Deinterlacing IP cores parameter editor.

UG-VIPSUITE

2015.05.04

Frame Buffering

12-7

Deinterlacing IP Cores

Altera Corporation

Send Feedback

Advertising