Automatic Image Resizing Checked In
Sunday January 19th, 2003
David Illsley writes: "Yesterday saw the checkin of automatic image resizing (bug 73322) to the Mozilla trunk. When turned on (it's disabled by default) it shrinks any image that is bigger than the window to make the whole image visible. When this is done, the cursor over the image changes to tell you that if you click, the image is restored to full size. You get the best of both worlds! This currently doesn't have a prefs UI in Phoenix but if you put the appropriate pref in you user.js file, it works just fine. This is one of the few features in IE that I have seen and liked and it's great that Moz now has it too. Thanks guys."
To enable this feature in Mozilla, go to Edit > Preferences > Appearance and check the 'Enable automatic image resizing' box. If you're using Phoenix, add the following line to your prefs.js or user.js file:
#52 Re: Performance/other problems analysis
Monday January 20th, 2003 3:39 PM
You are replying to this message
Not to get too picky... but nearest neighbour is a resampling technique, albeit the simplest and least effective one (of course, this is image dependent). In any case, It's been a while since I did significant image resampling using low level graphics card capabilities... It used to be that graphics cards hardware capabilities only included integer factor resizing (i.e. hardware zoom). I believe this has changed in these days of on board GPU's (and I may be showing my age here) but I think that it is mainly using the Texture engines (which has some limitations as a general purpose image manipulation engine). If the cards dont have the capabilities then OpenGl (e.g. using glPixelTransformParameterEXT() ) or DirectX (using whatever function call) will still be performing the interpolation in software.
Of interest as well, the cross-platform nature of Mozilla sometimes stands in the way of certain optimizations... For example, these type of operations could be optimizable using Intel's SSE or AMD 3DNow instruction sets. Of course, this would only be useful to a subset of the Mozilla platform target base and would require additional maintenance as CPU's changed.
The web browser has not been not typically used (I mean for the masses) as a high fidelity image viewing/manipulation tool and images tend to fit nicely in a 1 to 1 ratio from source to target. Having said that, if we are going to head down the path of substantial arbitrary scale factor image resampling, it might be nice to have some configurable options...I cant quite see this as a high priority yet, but perhaps it is another case of the old (Field of Dreams) adage, "if you build it, they will come".