Anti-Aliasing Filter for matlab imresize
Afficher commentaires plus anciens
Hi, I am doing a project on computer graphics and have been asked to implement the matlab's imresize function in C++, using bicubic interpolation.
As you know, if the scale factor is less than one,we need a anti-aliasing filter while interpolation. However I have no experience in filter design and at the moment I'm still relatively new to matlab and the image processing toolbox. I've tried using the fspecial gaussian filter but it doesnt seem to have muxh effect. Can you give me any tips on how to produce an appropriate filter in matlab, or point me to relevant information.
Any help is appeciated,
many thanks,
Xifei WU 2011.6.14
3 commentaires
David Young
le 14 Juin 2011
I've often observed people using the fspecial Gaussian option incorrectly. Note that you need to set the SIGMA parameter to an appropriate value for the spatial smoothing scale (this would be related to the scale factor for resizing) and to set the HSIZE argument to be large enough to cover most of the support for the filter. Usually making HSIZE 5 or 6 times SIGMA is plenty. Perhaps you should check this first.
Wu
le 14 Juin 2011
David Young
le 14 Juin 2011
I'm sorry, but I don't know about the internal operation of imresize. I guess with some effort it would be possible to work out the anitaliasing method by applying imresize to simple examples.
Réponses (2)
Catégories
En savoir plus sur Multirate Signal Processing dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!