Home Products Download Order Contacts

comp.graphics.algorithms

Subject: Re: Zoom / Scale



"suntribe" wrote in message
news:1s05op73iuf11$.1e7u20jxgx42w$.dlg@40tude.net...
> Hi every1..
>
> i'm trying to implement zoom capability in my app so i know how to do it,
> but i ran into some problems :)
>
> For zoom i use simple pixel replication (if it's called like that) :)
>
> newsize = x * oldsize..
>
> when i zoom out the picture, everything is ok.. but when i zoom in the
> picture, and if i zoom very large pictures (1280x1024) then i run out of
> memory :) i know why i get that message.. but how to do the zoom and not
> to
> run out of memory...
>
> one thought i came with is not to zoom entire picture, but to zoom only
> the
> part that is currently visible on the screen..
>
> Is there a better way to do a zoom on a picture?

This IS the better way. Try your own idea first!
For simplicity, constrain the zooming to 'whole' pixels -- clipping edge
pixels properly is slightly more difficult, and you may not need that
anyway.

[Jongware]



Reply


View All Messages in comp.graphics.algorithms

path:
Zoom / Scale =>

Replies:

Copyright 2006 WatermarkFactory.com. All Rights Reserved.