Table of Contents

NAME

QccWAVWaveletShapeAdaptiveDWT2D, QccWAVWaveletInverseShapeAdaptiveDWT2D - separable 2D shape-adaptive discrete wavelet transform and inverse transform for a 2D signal

SYNOPSIS

#include "libQccPack.h"

int QccWAVWaveletShapeAdaptiveDWT2D(QccMatrix signal, QccMatrix mask, int num_rows, int num_cols, int num_scales, const QccWAVWavelet *wavelet);

int QccWAVWaveletInverseShapeAdaptiveDWT2D(QccMatrix signal, QccMatrix mask, int num_rows, int num_cols, int num_scales, const QccWAVWavelet *wavelet);

DESCRIPTION

QccWAVWaveletShapeAdaptiveDWT2D() performs a separable 2D shape-adaptive discrete wavelet transform (SA-DWT) of a two-dimensional signal, signal, which is represented as a matrix of num_rows rows and num_cols columns. num_scales gives the number of scales, or levels, of the decomposition. QccWAVWaveletShapeAdaptiveDWT2D() implements a dyadic decomposition of signal; that is, the low-low subband (baseband) is recursively decomposed into a lowpass and three highpass bands for each level of decomposition. The output of the DWT is returned in signal, overwriting the original input signal. The output subbands reside in signal with the baseband in the upper-left corner, with highpass subbands successively "nested" from the upper-left corner to lower-right corner.

mask indicates where the original input signal exists. That is, mask indicates the regions of support in the original input signal. Where mask is less than or equal to QCCALPHA_TRANSPARENT, there is no signal, and where mask is greater than QCCALPHA_TRANSPARENT, signal exists and is transformed (see QccAlpha(3) ).

Essentially, the 2D SA-DWT is implemented by doing one scale of a 1D SA-DWT for each row, and then for each column. See QccWAVWaveletShapeAdaptiveDWT1D(3) for specific details on how this 1D SA-DWT is calculated.

The transparency mask is transformed (with a 2D Lazy wavelet transform) alongside the signal so that mask indicates where valid coefficients, i.e., coefficients resulting from non-transparent regions in the original input signal, reside in the output signal. The transformed mask is returned in mask, overwriting the original input mask.

Currently, QccWAVWaveletShapeAdaptiveDWT1D() supports only biorthogonal wavelets. These may be used with symmetric extension (lifting or filter-bank implementations) or boundary-wavelet extension (lifting implementations only).

QccWAVWaveletInverseShapeAdaptiveDWT2D() performs the corresponding separable 2D inverse SA-DWT of signal which is assumed to have been produced by QccWAVWaveletShapeAdaptiveDWT2D(). mask should be the corresponding Lazy-wavelet transformed mask also produced by QccWAVWaveletShapeAdaptiveDWT2D(). num_scales gives the number of levels of decomposition that exist in signal.

Use QccWAVSubbandPyramidShapeAdaptiveDWT(3) and QccWAVSubbandPyramidInverseShapeAdaptiveDWT(3) to perform a 2D separable SA-DWT or inverse SA-DWT on a QccWAVSubbandPyramid data structure (which is the recommended way to do it, since the QccWAVSubbandPyramid structure stores the number of levels of decomposition along with the transform coefficients).

RETURN VALUES

These routines return 0 on success and 1 on error.

NOTES

SA-DWTs have been recently included in Version 2 of the MPEG-4 standard, wherein they are used for texture coding of arbitrarily shaped still objects. Li and Li (see below) elaborate at length on the shape-adaptive DWT used in MPEG-4, and also consider some variants not included in the MPEG-4 standard. See QccWAVWaveletShapeAdaptiveDWT1D(3) for details on the differences between the QccPack SA-DWT implementation, the MPEG-4 specification, and Li and Li's descriptions.

SEE ALSO

QccWAVWaveletShapeAdaptiveDWT1D(3) , QccWAVWaveletInverseShapeAdaptiveDWT1D(3) , QccWAVSubbandPyramidShapeAdaptiveDWT(3) , QccWAVSubbandPyramidInverseShapeAdaptiveDWT(3) , QccWAVWavelet(3) , QccPackWAV(3) , QccPack(3)

S. Li and W. Li, "Shape-Adaptive Discrete Wavelet Transforms for Arbitrarily Shaped Visual Object Coding," IEEE Transactions on Circuits and Systems for Video Coding, vol. 10, pp. 725-743, August 2000.

ISO/IEC 14496-2, "Information Technology -- Coding of audio-visual objects -- Part 2: Visual," MPEG-4 Standard, Amendment 1, July 2000.

AUTHOR

Copyright (C) 1997-2021 James E. Fowler


Table of Contents



Get QccPack at SourceForge.net. Fast, secure and Free Open Source software downloads