In several of our vso software products we are processing images and video ( which is a simple set of several images ), one of the biggest and most intensive part is the rescale of pictures.
A image / bitmap is a big array of "square" dot , when you have a resolution of 640x480, it means you have 640 columns of 480 lines of square.. so it makes a total of 307200 pixels. ( or 0.3 MPixels )
Today, most of digital camera are around 10 Mb / 12 M pixels ! it makes resolution has big as 4000 x 3000
for video resolution for DVD for example there is the PAL and NTSC standard which means resolution of 720x576 or 720x480 pixels.
Everytime we need to convert a video, it is necessary to adapt / resize the video from the source resolution to the DVD.
A typical video frequency is 25 fps or 30 fps , it means there is 25 singles images to read per seconde x the lenght of the video...
for 1 minute you have 720x576x25x60 = 6.2 milliards of pixel to read and reencode.
all this, to explain it is a very important subject and part of software like PhotoDVD , VSO Image Resizer, PhotoOnWeb and .. ConvertXtoDVD
there are 2 cases, either you have a big pictures and you need it at a lower resolution ( for example a picture from the digital camera which is 4000x3000 but you display is only 1024x768 ), or you have a small picture and you need to a larger resolutio. these 2 operations are named : upscale ( enlarge ) and downscale ( reduce )
Let's start with downscale ( the most interesting and frequent case )
When you need a different resolution you need to arrange severals pixel to make only one...
Imagine you have a array of 12x12 pixels, but you want to make a final resolution of 3x3 , you can pick a single pixel each 4 pixel, and ignore some other pixel, or you can compute an average between the sub array of 4x4 pixels .. it starts to be complex ? .. yes, it is.. so let's see some samples :
the 3 top pictures are different filter methods, and the last one is the original pictures ( but you will see it already resized by the browser so you should save it to your local hard drive )
Article to be continued.

