ImageEn, unit imageenproc

TImageEnProc.Lens

TImageEnProc.Lens


Declaration

procedure Lens(cx, cy, Width, Height: Integer; Refraction: Double);


Description

Applies a lens effect to the current image.

Note: This function is also available to the user in the Image Processing dialog

Parameter Description
cx Horizontal lens position (center)
cy Vertical lens position (center)
Width Lens width
Height Lens height
Refraction Lens refraction (from 1)


Demo

Demo  Demos\ImageEditing\Lens\LensTest.dpr


Example

ImageEnView1.Proc.Lens( ImageEnView1.IEBitmap.Width div 2,
                        ImageEnView1.IEBitmap.Height div 2,
                        ImageEnView1.IEBitmap.Width,
                        ImageEnView1.IEBitmap.Height,
                        6 );