The efficacy of radiation treatment depends strongly on the accuracy of the treatment field set up. On-line portal imaging provides the possibility of detecting and correcting field placement errors before a significant radiation dose is delivered. A heuristic algorithm is described for fast field contour delineation based on the properties of the portal images, and its accuracy and reproducibility are tested on a number of artificial and real images. Its speed depends on the size of the field and varies between 0.1 s and 0.3 s for 480 X 512 pixel images for implementation on a PC-386 computer. A correction is proposed for local distortions in the contour line based on an estimation of the oriented curvature. Experimental results with real portal images demonstrate the reliability of the approach and its suitability for clinical implementation.