Embodiments of the present invention are directed to video coding systems that support playback of video at variably selected sizes. In particular, they are directed to video coding systems that support intra-frame coding schemes as those found in video editing applications.
Modern video editing applications are software based tools that permit an operator (an ‘editor’) to generate an output video sequence from a plurality of candidate input video sequences. Video editing applications are used to develop movie and television programming from a variety of different image sources. To capture a conversation between two characters in an interesting manner, for example, an editor may generate an output sequence that jumps among two or more different camera angles. The editor may select a first video sequence for an amount of time, then dissolve to a second video sequence for a second amount of time. To support this editing function, the video editor may provide a graphical user interface that represents the various candidate input sequences along a common time axis. The editor may specify cuts between the input streams that will occur in the output streams and also any effects (such as dissolves) that occur between them. These are draft editing settings that can be modified at will until final settings are obtained.
Video editing applications permit the editing settings to be tested at any time. The applications typically have access to coded video data representing each of the candidate input streams. The applications' graphical user interface also may provide a window that occupies some percentage of its display to permit playback of the editing settings. When playback is performed, the application may cause one or more of the stored video data sequences to be decoded and any effects to be applied before the resulting video sequence is displayed. Rendering displayable video sequences in real time display requires these decoding and effects operations to be performed once per frame interval (typically 1/30th of a second). To render the decode operations as fast as possible, traditional video editing applications have accepted coded video data that is intra-predicted only. That is, each frame may be decoded without temporal prediction.
Designers of video editing applications may be compelled to accept a wider variety of coded video data, including data coded according to temporal prediction. To keep the decoding operations as fast as possible, the inventors determined that it would be advantageous to decode the input video data from its coding format and re-code the data according to an intra-prediction technique. Also the decoding and recoding is likely to result in less compression than the input data and, therefore, larger file sizes, it also is likely to result in faster decoding during the testing operation.
The inventors also realized that the decoding and re-coding of input data provide an opportunity to provide further optimizations to the decoding processes that are performed during the testing modes for video settings.
Embodiments of the present invention provide a coding system that codes data according to a pair of coding chains. A first coding chain generates coded video data that can be decoded by itself to represent a source video sequence of a small size, such as a size sufficient to support the real time playback and display features of a video editing application. The second coding chain generates coded video data representing supplementary data, which when decoded in conjunction with the coded video data of the first coding chain, yields the source video sequence for full-size display. The output of the first coding chain may be stored in memory in a file structure that can be accessed independently of the second chain's output and, therefore, it facilitates real time decoding and playback.
The video coding system 100 may include a transform unit 110, a quantizer 120, a splitter 130 and a plurality of processing chains 140, 150. The processing chains each may contain respective run length coders 142, 152 and variable length coders 144, 156.
The transform circuit 110 transforms blocks of pixel data from a source frame to blocks of coefficient data according to a predetermined transform. For example, the transform unit 110 may operate according to a discrete cosine transform (“DCT”). Conventionally, DCT coefficients are described as being a two-dimensional array of coefficients. The most common implementation is to convert an 8 pixel by 8 pixel block of source data to an 8×8 array of DCT coefficients, such as the array shown in
The quantizer 120 truncates coefficients by dividing them by a quantization parameter (qp). This reduces the magnitude of the coefficients that are used for subsequent coding operations. Some low level coefficients are truncated to zero. The quantization parameter may vary among blocks of a frame and among different frames. Thus, information regarding the quantization parameter itself may be included among the coded data output by the video coding system 100 so that, during decode operations, the quantization parameter may be reconstructed and the quantization operation may be inverted.
The splitter 130 represents a demultiplexing operation performed by the video coding system 100 to route coefficients of each block to one of a pair of coding chains 140, 150. According to an embodiment, for each block of coefficient data input to the splitter 130, the splitter 130 may forward a set of lower frequency coefficients to a first coding chain 140 and the remaining coefficients to the second coding chain 150. For example, to recover a displayable video signal at one quarter the size of the source image, it is sufficient to code one quarter of the lowest frequency coefficients together in the first coding chain (16 of the 64 coefficients generated for an 8×8 block) and code the remaining coefficients in the second coding chain. Other display sizes are permitted.
The coding chains 140 and 150 each may include a run length encoder 142, 152 and a variable length coder 144, 154. In an embodiment, the run length encoders 142, 152 each may perform run length coding according to a traditional zigzag scan direction. Starting from an origin, the run length coder traverses various coefficient positions and counts the number of positions that are traverse before the coder reaches a coefficient having a non-zero value. The number of traversed positions is output as a run length and the non-zero coefficient value is output as a level. The coder resumes traversing the block, outputting subsequent runs and levels until the scan traverses the entire block.
Of course, for the first chain 140, the run length coder 142 need only traverse the coefficients that are input to it. Using the example provided above, a one quarter sized display would yield a plurality of 4×4 blocks, such as the array shown in
For the second chain 150, the run length coder 152 traverses the remaining coefficients from the blocks, which typically are irregular arrays of coefficient values due to the absence of the coefficients that are passed instead to the first chain 140 (
Alternatively, the run length encoder 152 may traverse the remainder block according to a traditional zig-zag scan in a manner that skips over coefficient positions that are passed to the first chain 140. Referring again to
In a further embodiment, the block remainder may be parsed into sub-blocks for independent run length encoding according to a zig-zag scan direction. In the embodiment of
According to another embodiment of the present invention, a variable length coder may perform coding according to one of a plurality of reversible coding algorithms. A reversible coding algorithm permits direct decoding of VLC data to run length data by a direct computation rather than reference to some look up table. Direct computation of the source data provides for faster real-time decoding than a look up table, particularly in software implementations of a decoder. By way of example, the variable length coders may operate according to the family of Golomb-Rice codes or exp-Golomb codes, among others.
The variable length coders 144, 154 of the two chains 140, 150 may code the run, level pair data output from the run length encoders 142, 152. In still another embodiment, the run length coding 142, 152 of the processing chains 140, 150 may be omitted altogether. In this embodiment, the variable length encoders 144, 154 may operate directly on the coefficient data output from the splitter 130. For this reason, the run length coders 142, 152 are illustrated in
Coded video data of each frame may be stored in a file 160 in a storage device. According to an embodiment, the coded video data output from the first processing chain 140 may be stored in a contiguous area of the file for easy access (shown as group 1162). The coded video data output from the second processing chain 150 may be stored in another area 164 of the file 160. During playback, if it is desired to generate only a small sized video sequence, the coded video data of group 1162 may be retrieved and decoded. Alternatively, if it is desired to decode a full-sized video sequence, both groups 162,164 may be retrieved and decoded. Accordingly, the present invention facilitates real time playback of images of various sizes.
According to an embodiment, all frames may be coded as intra-coded frames (“I frames”). Intra-coding permits video data of one block in a frame to be coded from video data of another block in the frame. Thus, video content of a given block X may be coded from data of a block horizontally or vertically adjacent to block X. For example, the techniques described the MPEG-4 standard, sec 7.4.3 may be applied in the present coder 100. See, Information technology—Coding of audio-visual objects—Part 2: Visual Amendment 1: Visual extensions, ISO/IEC JTC 1/SC 29/WG 11 N 3056 (2000). For ease of illustration, such operations may be considered subsumed in the transform block 110.
According to an embodiment, the run length encoder 142 may operate according to a modified zigzag scan across a pair of small blocks.
The embodiment of
In another embodiment, the coding algorithm to be applied to data may change dynamically according to different data patterns that are input to a variable length coder 440. The variable length coder 440 is shown as including a coding unit 450 and a plurality of coding assignment tables 460. Responsive to a selection input, a VLC selector 470 may couple one of the assignment tables to the coding unit 450. The selection input may change dynamically, for example, on a block-by-block basis, a tile-by-tile basis or on a frame-by-frame basis. The VLC selection signal may be based on the block's type (e.g., carrying luminance data vs. chrominance data), based upon the coding chain to which the variable length coder belongs (chain 140 or 150), or based on a tile to which the block belongs. Additionally, a block may be coded by several VLC assignments to permit a compression efficiency comparison to be made between them. The coding results that achieve the highest compression could be used for storage.
During coding, even if it uses a reversible coding algorithm, the variable length coder 500 may code input data by either direct calculation or through resort to a look up table.
In an alternate embodiment, the transform unit 110 may operate according to a wavelet transform. Multi-resolution wavelet decomposition is one of the most efficient schemes for coding image information. Image information to be coded is represented as a linear combination of locally supported wavelets. An array of wavelet coefficients is shown in
The principles of the present invention may be extended to a wavelet-based coder. Such a coder may include a coding chain for each level or band of wavelet coefficients that appear in a tile. The transform unit 110 may generate wavelet coefficients, which are truncated by the quantizer 120. A splitter 130 may route wavelet coefficients of each level or of each band of coefficients to respective first coding chains 140, 150, etc., for further coding. Alternatively, the coder 100 may include only a pair of coding chains: a first coding chain 140 dedicated to a set of tile coefficients and/or levels that are necessary to reconstruct a small image and a second coding chain dedicated to remaining sets of coefficients from the tile that are to be used to reconstruct a full size image. In either embodiment, coded coefficients of each coding chain may be stored separately for fast retrieval during decoding.
During operation, one or both of the processing chains 640, 650 will be active. If only the first processing chain 640 is active, coded video data of the small blocks may be retrieved from storage, variable length decoded 644 and run length decoded 642. If the second processing chain 650 is active, coded video data of the block remainders also may be retrieved from storage, variable length decoded 654 and run length decoded 652. If the multiplexer 630 receives data from both processing chains 640, 650, it merges the data together in a format for further processing by the dequantizer 620 and inverse transform unit 610.
The dequantizer 620 recovers transform values by multiplying the input coefficient values by the quantizer parameter (qp) that was applied by the quantizer 120 of
In an embodiment, the operation of the inverse transform unit 610 and the dequantizer 620 may receive an indicator of a decoding mode that is in use. When full size decoding is performed, these units 610, 620 may operate in a conventional manner. When small size decoding is performed, however, the inverse transform unit 610 may omit transform calculations that refer solely to coefficients that occur in the remainder block—coefficients that would be output from the second processing chain 650. Since the chain 650 is rendered inactive by the selection signal, the transform calculations would perform no useful work. Omitting such calculations optimizes throughput of the inverse transform unit 610. Similarly, the dequantizer 620 need not scale any omitted coefficient by a quantizer parameter, since it also does not perform useful work (e.g., coefficient×qp=0, whenever coefficient=0).
The inverse transform unit 610 may be a wavelet transform unit to generate pixel data from wavelet coefficients. In such an embodiment, when the inverse transform unit operates on only small blocks, a traditional wavelet decode would generate full-size video at reduced resolution due to the absence of the high frequency coefficients. In one embodiment, the decoder may re-size the full-size video to a correspondingly smaller size (e.g., down to 25% of the original).
As illustrated in Table 1 below, run length coded data is represented as series of run level pairs. A run value represents a number of consecutive coefficient scan positions at which zero valued coefficients are detected. A run value may have any value between zero and the maximum number of coefficient positions in the data unit (e.g., 64 for an 8×8 block or 32 for a coded pair of 4×4 blocks). A level value represents the value of the next non-zero coefficient encountered along the scan direction. Thus, to code coefficients of a single block or a block pair, a run length encoder will generate at least one run and perhaps a series of levels and runs as dictated by the information content of the block. Coding of a block may conclude at a run or a level value.
Typically, it is convenient to consider the run and level values as associated pairs:
The pairs may be VLC coded as a number of symbols. If a run value of the final pair consumes the remainder of a given block, then a unique end-of-block character may be inserted in a final level position to complete the final symbol and permit the VLC coding to conclude. For good compression, however, unless the symbols (the run/level pairs) exhibit some pattern, an arbitrary code word table must be used which requires a table lookup during decoding. Table lookups are slow processes, which can impair decoder performance.
According to an embodiment of the present invention, efficient decoding of the data of Table 1 may be achieved by coding each run value and each level value as individual symbols (instead of the run, level pairs described above). Such an embodiment provides opportunities to optimize VLC consumption algorithms. According to an embodiment, the consumption method may consider a “pattern” of coded run and level values as shown in Table 2.
The consumption operation set forth in
Thus, as shown above, the coding schemes of the present embodiments organize coded video data according to a protocol that provide for very fast decoding of reduced-sized images, which is particularly suitable for video editing applications. The foregoing description provides examples of 4×4 blocks, which lead to a quarter-sized display when decoded. Of course, the principles of the present invention are not so limited. Operation of the decoding system may be tailored to provide any ratio of small display vs. full sized display that is desired. For the size ratios shown in Table 3, the splitter 130 may assemble sub-blocks directly from source 8×8 blocks having the dimensions shown in the table.
If other size ratios are desired, for example 50%, additional spatial resizing techniques may be employed on decoded video data once it is output from the decoder (
Additionally, to provide additional flexibility, video coders and decoders may be provided with three or more coding/decoding chains, each of which is devoted to processing video data associated with a predetermined frame size. Using a video coder as an example, a first coding chain may process 3×3 arrays of extracted DCT coefficients a second coding chain may process remaining coefficients up to a 5×5 coefficient array (a 5×5 array having the coefficients of the 3×3 array removes) and a third coding chain may process coefficients that remain following extraction by the first two coding chains. Similarly, video decoders may possess multiple coding chains in an analogous manner.
The systems and techniques described in the foregoing embodiments may be integrated into larger video coding systems to provide full coding services. One such system codes video frames as a plurality of ‘tiles.’ The spatial area of a frame is organized into discrete sections, called tiles, and certain coding decisions for blocks that occur within the tiles may be made on a tile-by-tile basis rather than a block-by-block basis. For example, the selection of a VLC table (
The foregoing embodiments may be provided a software-implemented system. As such, these embodiments may be represented by program instructions that are to be executed by a server or other common computing platform. One such platform 800 is illustrated in the simplified block diagram of
Several embodiments of the present invention are specifically illustrated and described herein. However, it will be appreciated that modifications and variations of the present invention are covered by the above teachings and within the purview of the appended claims without departing from the spirit and intended scope of the invention.
Number | Name | Date | Kind |
---|---|---|---|
2905756 | Graham | Sep 1959 | A |
4245248 | Netravali et al. | Jan 1981 | A |
4399461 | Powell | Aug 1983 | A |
4717956 | Morehead et al. | Jan 1988 | A |
4853775 | Rouvrais et al. | Aug 1989 | A |
5001559 | Gonzales et al. | Mar 1991 | A |
5060064 | Lamnabhi et al. | Oct 1991 | A |
5081532 | Rabii | Jan 1992 | A |
5116287 | Hironaka et al. | May 1992 | A |
5196933 | Henot | Mar 1993 | A |
5225904 | Golin et al. | Jul 1993 | A |
5473376 | Auyeung | Dec 1995 | A |
5561477 | Polit | Oct 1996 | A |
5600375 | Wickstrom | Feb 1997 | A |
5699119 | Chung et al. | Dec 1997 | A |
5737022 | Yamaguchi et al. | Apr 1998 | A |
5764296 | Shin | Jun 1998 | A |
5764374 | Seroussi et al. | Jun 1998 | A |
5812197 | Chan et al. | Sep 1998 | A |
5825935 | Murakoshi | Oct 1998 | A |
5974197 | Lee et al. | Oct 1999 | A |
5990963 | Mishima et al. | Nov 1999 | A |
6005622 | Haskell et al. | Dec 1999 | A |
6078617 | Nakagawa et al. | Jun 2000 | A |
6341144 | Haskell et al. | Jan 2002 | B1 |
6556625 | Haskell et al. | Apr 2003 | B2 |
20060062309 | Hoshi | Mar 2006 | A1 |
Number | Date | Country |
---|---|---|
0422404 | Apr 1991 | EP |
0283715 | Sep 1998 | EP |
Number | Date | Country | |
---|---|---|---|
20050226513 A1 | Oct 2005 | US |