Re: Scaling images
- Posted by Jonas Temple <jtemple at yhti.net> Nov 22, 2004
- 2309 views
Brian Broker wrote: > > > It's a bit more complicated than that if you want an antialiasing effect. > You can do something like this: > }}} <eucode> > -- for antialiasing effect > hdc = getDC( Win ) > w32Proc(xSetStretchBltMode,{hdc,HALFTONE}) -- HALFTONE = 4 > w32Proc(xSetBrushOrgEx,{hdc,0,0,NULL}) > releaseDC( hdc ) > </eucode> {{{ > > Now your stretchBlt should look better (with antialiasing effect). > > Unfortunately, the HALFTONE option is not supported on Windows 95/98/Me. > > Declarations for the above functions are: > }}} <eucode> > constant > xSetStretchBltMode = > registerw32Procedure(gdi32,"SetStretchBltMode",{C_POINTER,C_INT}), > xSetBrushOrgEx = > registerw32Procedure(gdi32,"SetBrushOrgEx",{C_POINTER,C_INT,C_INT,C_POINTER}), > HALFTONE = 4 > </eucode> {{{ > Brian, Perfect! Exactly what I needed. Thanks a bunch! Jonas Temple http://www.yhti.net/~jktemple