octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #61760] [octave forge] (image) imresize - anti


From: Christof Kaufmann
Subject: [Octave-bug-tracker] [bug #61760] [octave forge] (image) imresize - antialiasing is not implemented
Date: Fri, 7 Jan 2022 10:54:52 -0500 (EST)
User-agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:95.0) Gecko/20100101 Firefox/95.0

Follow-up Comment #3, bug #61760 (project octave):

Sounds like a good idea at first glance, but when looking deeper into this, it
is independent of this issue. The only functions that are using imremap are
imresize and imperspectivewarp.

imresize would be the only function supporting anti-aliasing. It seems, that
it needs an own implementation of interpolation based on convolution. Even for
bilinear interpolation and maybe nearest neighbor as well to support
anti-aliasing.

imperspectivewarp and imresize are both octave specific. Maybe they could be
merged into imwarp. imperspectivewarp is quite similar to imwarp
<https://www.mathworks.com/help/images/ref/imwarp.html> when using tform. The
Matlab version of imwarp does not support anti-aliasing and also not "box",
"lanczos2" and "lanczos3" interpolation methods. So it seems, they also have
two implementations.

It is also not straightforward to implement anti-aliasing for imwarp, since
the scale factor is required. imresize directly gives the scale factor, but
for imwarp it is not that easy (but should be possible for linear transforms,
I guess). With imremap it is possible to specify the interpolation points
directly and then its impossible to define the scale in general.

Overall I think the convolutional based interpolation can be implemented in
imresize directly (in this issue here). imremap can stay as it is for now, but
in future the bicubic interpolation from bug #60322 should be moved into
interp2 (bug #61754) and imremap might be merged with imperspectivewarp into
imwarp.

    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?61760>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]