Table of Contents

NAME

QccIMGImageComponentFilterSeparable, QccIMGImageFilterSeparable, QccIMGImageComponentFilter2D, QccIMGImageFilter2D - image and image-component filtering

SYNOPSIS

#include "libQccPack.h"

int QccIMGImageComponentFilterSeparable(const QccIMGImageComponent *input_image, QccIMGImageComponent *output_image, const QccFilter *horizontal_filter, const QccFilter *vertical_filter, int boundary_extension);
int QccIMGImageFilterSeparable(const QccIMGImage *input_image, QccIMGImage *output_image, const QccFilter *horizontal_filter, const QccFilter *vertical_filter, int boundary_extension);

int QccIMGImageComponentFilter2D(const QccIMGImageComponent *input_image, QccIMGImageComponent *output_image, const QccIMGImageComponent *filter);
int QccIMGImageFilter2D(const QccIMGImage *input_image, QccIMGImage *output_image, const QccIMGImageComponent *filter);

DESCRIPTION

QccIMGImageComponentFilterSeparable() implements the separable two-dimensional FIR filtering of an image component. horizontal_filter gives the one-dimensional FIR filter for filtering along the rows (i.e., in the horizontal direction); vertical_filter gives the one-dimensional FIR filter for filtering along the columns (i.e., in the vertical direction). input_image is the image component to be filtered, and output_image is the resulting filtered image component. output_image must be allocated to the same size as input_image prior to calling QccIMGImageComponentMatrixSeparable(). The FIR filtering operation is implemented by time-domain convolutions, one for each row and column in input_image. These convolutions are implemented via a call to QccFilterMatrixSeparable(3) . boundary_extension specifies the method for handling the left and right signal boundaries in the 1D FIR convolutions. See QccFilterVector(3) for the possible values of boundary_extension.

QccIMGImageFilterSeparable() filters input_image, producing filtered output_image. In effect, QccIMGImageFilterSeparable() simply calls QccIMGImageComponentFilterSeparable() for each of the Y, U, and V components of the images.

QccIMGImageComponentFilter2D() implements non-separable filtering of input_image using the 2D filter kernel given by filter. filter must have an odd number of rows and an odd number of columns; the center of the filter kernel is assumed to be at (floor(filter->num_rows / 2), floor(filter->num_cols / 2)). output_image is then the result of a 2D convolution of filter and input_image. output_image must be allocated to the same size as input_image prior to calling QccIMGImageComponentFilter2D().

QccIMGImageFilter2D() filters input_image, producing filtered output_image. In effect, QccIMGImageFilter2D() simply calls QccIMGImageComponentFilter2D() for each of the Y, U, and V components of the images.

RETURN VALUE

These routines return 0 on success, 1 on failure.

SEE ALSO

QccFilterMatrixSeparable(3) , QccFilterVector(3) , QccIMGImageComponent(3) , QccIMGImage(3) , QccPackIMG(3) , QccPack(3)

AUTHOR

Copyright (C) 1997-2021 James E. Fowler


Table of Contents



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