Groups > Corel > Corel Paint Shop Pro older versions > Re: Diagonal Stripes in Resizes




Re: Diagonal Stripes in Resizes

Re: Diagonal Stripes in Resizes
Fri, 02 Feb 2007 11:05:26 -060
Jess Fertudei wrote:

> Whenever I resize a photo (usually 50% to make it 1024x768) and it has
power
> lines or, more importantly railroad tracks... whatever the long straight
> object is... it distorts from perfectly sharp to having a 'candy cane' or
> 'barbers pole' type of diagonal stripe effect all along it.

Your image is made of colored dots called pixels. Pixels are
what represent the information in an image. When you make your
image 50% smaller in each dimension you throw away 75% of the
pixels. In other words you throw away 75% of the image information.
This naturally leads to problems. As an extreme example, imagine
trying to represent the entire scene using only one pixel. In
original large image you can represent the original abrupt edge
of a straight object (e.g. a rail) using several pixels to make
a smooth transition. After resizing smaller there aren't enough
pixels to do this and your edges get an aliasing artifact called
stair-stepping or jaggies. You call this a barber pole effect.
Technically, aliasing results from sampling theory which has
some rules about the number of samples (pixels) you must have
to represent a particular spatial frequency (fineness of detail).
The way to suppress aliasing effects is to remove the high
spatial frequencies (abrupt edges) that cannot be represented
by the smaller number of pixels in the new image prior to doing
the resizing.

> I could blur it,
> but that would defeat the entire projects (I need to do this often).

I'm not sure what the first sentence above means. Doing something
often is not a problem if you do it right. (Upgrading to a version
of PSP that supports scripting automation wouldn't hurt either
but is not critical for something as simple as this.)

> I have tried to resize and resample in Irfanview also, and get the same
> effect.

This tells you that the problem is with what you are doing and
not with the software.

> Rails and power lines are very common in rail photography, and I see this
> happen a lot, so any suggestions as to how to avoid this would be
> appreciated.

What you do is this. First you blur your image slightly to remove
high spatial frequency detail that is too fine to represent in
the resized image. The proper amount of blurring depends on how
much you are going to resize. The smaller you want, the more you
would blur. To a certain degree the best level of blurring also
depends on the content of the image. There is no need to panic
about blurring the image because you are just removing stuff from
it that you can't represent properly and see adequately in a
smaller image with a lower information content. You probably need
to experiment a little with the best level of blurring. You should
apply the smallest amount of blur that is sufficient to remove
the jaggies you get after resizing. After blurring the image
resize it using the Smart Size setting. Optionally, you can
sharpen the image slightly after the resize to emphasize fine
detail. This won't bring back the jaggies. For this sharpening
try Unsharp Mask, Radius 1.0 to 2.0, Strength 20 to 100, Clipping
around 5 to 15. I've attached a simple image to illustrate what
happens under various conditions and why anti-aliasing (also a
kind of blurring) is related to the advice I've given you.
Post Reply
View Original Image
about | contact