7
Metric Rectification for Perspective Images of Planes David Liebowitz and Andrew Zisserman Robotics Research Group Department of Engineering Science University of Oxford Oxford OX1 3PJ, UK. We describe the geometry, constraints and algorithmic implementation for metric rectification of planes. The recti- fication allows metric properties, such as angles and length ratios, to be measured on the world plane from a perspect- ive image. The novel contributions are: first, that in a stratified context the various forms of providing metric information, which include a known angle, two equal though unknown angles, and a known length ratio; can all be represented as circular constraints on the parameters of an affine trans- formation of the plane — this provides a simple and uniform framework for integrating constraints; second, direct recti- fication from right angles in the plane; third, it is shown that metric rectification enables calibration of the internal camera parameters; fourth, vanishing points are estimated using a Maximum Likelihood estimator; fifth, an algorithm for automatic rectification. Examples are given for a num- ber of images, and applications demonstrated for texture map acquisition and metric measurements. 1 Introduction It is well known that under perspective imaging a plane is mapped to the image by a plane projective transformation (a homography) [13]. This transformation is used in many areas of computer vision including planar object recogni- tion [12], mosaicing [15], and photogrammetry [14]. The projective transformation is determined uniquely if the Eu- clidean world coordinates of four or more image points are known. Once the transformation is determined, Euclidean measurements, such as lengths and angles, can be made on the world plane directly from image measurements. Fur- thermore, the image can be rectified by a projective warping to one that would have been obtained from a fronto-parallel view of the plane (i.e. parallel to the image plane). In this paper we show that it is not necessary to provide the Euclidean coordinates of four points; instead metric properties on the world plane, such as a length ratio and an angle, can be used directly to partially determine the pro- jective transformation up to a particular (metric) ambigu- ity. This partial determination requires far less information about the world plane to be known, but is neverless suffi- cient to enable metric measurements of entities on the world plane to be made from their images. Collins and Beveridge [2] made a significant step in this direction by showing that once the vanishing line of the plane is identified, the transformation from world to image plane can be reduced to an affinity. They used this result to reduce the dimension of the search, from eight to six, in re- gistering satellite images. We improve on this result in four ways. First, it is shown that by using known metric informa- tion the affinity can be reduced to a similarity. Section 2.2 describes three cases of providing this metric information from an image: a known angle, two equal though unknown angles, and a known length ratio. Each of these constraints can be represented simply as a circular constraint on two unknown parameters, and a closed form solution obtained by intersecting circles. This means that the problem of im- age registration considered in [2] can be reduced to a four dimensional search. Unlike the method of [2] no know- ledge of the internal parameters of the camera is required. Faugeras et al. [7] used similar constraints in a 3D context, but only an iterative solution was given. Second, in section 3, it is shown that an imaged plane can be rectified directly from metric information, without first identifying the vanishing line. This is illustrated for the metric constraints arising from right angles on the plane. Third, section 4, describes how the camera internal calibra- tion parameters are constrained by the metric rectification of a plane. Fourth, vanishing points are estimated using a Maximum Likelihood Estimator (MLE) described in sec- tion 5.1. This substantially improves the accuracy of the results. In man made scenes there are often two dominant ortho- gonal directions, for example aerial views of streets, interior

Metric Rectification for Perspective Images of Planesvgg/publications/papers/liebowitz98.pdf · Metric Rectification for Perspective Images of Planes David Liebowitz and Andrew

  • Upload
    buidung

  • View
    223

  • Download
    0

Embed Size (px)

Citation preview

Metric Rectification for Perspective Imagesof Planes

David Liebowitz andAndrew ZissermanRoboticsResearchGroup

Departmentof EngineeringScienceUniversityof OxfordOxfordOX1 3PJ,UK.

����������� �We describethe geometry, constraints and algorithmic

implementationfor metricrectificationof planes.Therecti-ficationallowsmetricproperties,such asanglesandlengthratios,to bemeasuredon theworld planefroma perspect-ive image.

The novel contributions are: first, that in a stratifiedcontext thevariousformsof providing metric information,which includea knownangle, two equalthoughunknownangles,and a knownlength ratio; can all be representedascircular constraintsontheparametersof anaffinetrans-formationof theplane—thisprovidesa simpleanduniformframework for integratingconstraints; second,directrecti-fication from right anglesin the plane; third, it is shownthat metric rectificationenablescalibration of the internalcamera parameters; fourth, vanishingpointsare estimatedusinga MaximumLikelihoodestimator;fifth, an algorithmfor automaticrectification.Examplesare givenfor a num-ber of images, and applicationsdemonstrated for texturemapacquisitionandmetricmeasurements.

1 Intr oduction

It is well known thatunderperspective imaginga planeis mappedto theimageby aplaneprojectivetransformation(a homography)[13]. This transformationis usedin manyareasof computervision including planarobject recogni-tion [12], mosaicing[15], andphotogrammetry[14]. Theprojective transformationis determineduniquelyif theEu-clideanworld coordinatesof four or moreimagepointsareknown. Oncethe transformationis determined,Euclideanmeasurements,suchaslengthsandangles,canbemadeonthe world planedirectly from imagemeasurements.Fur-thermore,theimagecanberectifiedby aprojectivewarpingto onethatwouldhavebeenobtainedfrom afronto-parallelview of theplane(i.e.parallelto theimageplane).

In this paperwe show that it is not necessaryto providethe Euclideancoordinatesof four points; insteadmetric

propertieson theworld plane,suchasa lengthratio andanangle,canbe useddirectly to partially determinethe pro-jective transformationup to a particular(metric) ambigu-ity. This partialdeterminationrequiresfar lessinformationaboutthe world planeto be known, but is neverlesssuffi-cientto enablemetricmeasurementsof entitiesontheworldplaneto bemadefrom their images.

Collins andBeveridge[2] madea significantstepin thisdirection by showing that once the vanishingline of theplaneis identified,thetransformationfrom world to imageplanecanbereducedto anaffinity. They usedthis resulttoreducethedimensionof thesearch,from eightto six, in re-gisteringsatelliteimages.We improveonthis resultin fourways.

First, it is shown that by usingknown metric informa-tion theaffinity canbereducedto a similarity. Section2.2describesthreecasesof providing this metric informationfrom animage:a known angle,two equalthoughunknownangles,anda known lengthratio. Eachof theseconstraintscanbe representedsimply as a circular constrainton twounknown parameters,anda closedform solutionobtainedby intersectingcircles.This meansthat theproblemof im-ageregistrationconsideredin [2] canbe reducedto a fourdimensionalsearch. Unlike the methodof [2] no know-ledgeof the internalparametersof thecamerais required.Faugeraset al. [7] usedsimilar constraintsin a 3D context,but only aniterativesolutionwasgiven.

Second,in section3, it is shown that an imagedplanecanbe rectifieddirectly from metric information,withoutfirst identifyingthevanishingline. This is illustratedfor themetric constraintsarising from right angleson the plane.Third, section4, describeshow thecamerainternalcalibra-tion parametersareconstrainedby the metric rectificationof a plane. Fourth, vanishingpointsareestimatedusingaMaximum LikelihoodEstimator(MLE) describedin sec-tion 5.1. This substantiallyimprovesthe accuracy of theresults.

In manmadescenesthereareoftentwo dominantortho-gonaldirections,for exampleaerialviewsof streets,interior

andexteriorsof buildings. In this situationthe vanishingpointscanbe obtainedautomatically, andmetric rectifica-tion is obtainedup to a onedimensionalambiguity. This isdescribedin section5.3. Themethodsaredemonstratedinsection6.

2 Stratification of projective rectification

As describedby Koenderink[9] andFaugeras[6] metricstructurerecovery can be stratifiedso that first affine andthenmetric propertiesaredetermined.In this sectionwefollow theirapproach.

Pointson theimageplane,� , arerelatedto pointson theworld plane, ��� , as �������� , where � and ��� arehomo-geneous3-vectors.Theprojective transformationmatrix �canbedecomposed(uniquely)into aconcatenationof threematrices,� , � and� , representingsimilarity, affineand‘pureprojective’ transformationrespectively:���������where ��� �� � ! !! � !"$#%"'&("') *+and,.-/�10 "$#324"'&�25"')7698 is thevanishinglineof theplane.Thevector ,.- is homogeneousandhastwo degreesof freedom.

��� �� #: ;=<: !! � !! ! � *+Again, this matrix hastwo degreesof freedomrepresentedby theparameters> and ? . Thegeometricinterpretationoftheseparametersis that they specify the imageof the cir-cularpoints[13]. Thecircularpoints @ and A area pair ofcomplex conjugatepointson the line at infinity which aretransformedfrom co-ordinates0 � 2CBEDF2 ! 658 on the metricplaneto 0.>HG D ? 2 � 2 ! 698 on theaffine plane. Their signi-ficancelies in the fact that they areinvariantto Euclideantransformations.Oncethey areidentifiedmetricpropertiesof the planeareavailable. The final matrix in the decom-positionis a similarity transformation�I�KJKLNM OP 8 ��QwhereM is a rotationmatrix, O a translationvector, and L anisotropicscaling.Therearefour degreesof freedom.RTSVU W �YX[Z]\��X_^�`a�b�Yc.de`f��X�hgjik`

Thefirst stageis to determine� , which requiresidenti-fying thevanishingline ,.- of theplane.Thevanishingline

is theimageof theline at infinity on theworld plane.Paral-lel lineson theworld planeintersectat vanishingpointsintheimage,andthevanishingpointslie on , - . Two or moresuchpointsdetermine, - . Once� is determinedtheimagecanbe affine rectified(seefigure 3), andaffine propertiessuchaslengthratiosonparallelline segmentsmeasured.RTS$R W �XlZmhgnio`p��X�Z�`a���cq�

It is assumedin thefollowing thatthegeometryhasbeenrecoveredup to an affine transformationby applying thematrix � . Recovery of metric geometryrequiresan affinetransformationof theplane, � , thatwill restoreanglesandlength ratios for non-parallelsegments. In the followingthreemethodsof providingconstraintson > and? aregiven.Theseare:

1. A known anglebetweenlines;

2. Equalityof two (unknown) angles;and,

3. A known lengthratio.

In eachcaseit shown that the constraintis a circle. Thisis in fact a circle in the complex planesince > and ? areoriginally real and imaginarycomponents,andthe circlesmay be plottedon the planewith > asthe real axis and ?theimaginary. However, since> and? arereal,thecomplexinterpretationis notsignificantin seekinga solution.Known angle:Supposer is the angle on the world plane betweenthelines imagedas ,.s and ,.t (herelines , arehomogeneous3-vectors).Thenit canbeshown that > and ? lie on thecirclewith centre0$u < 2 u : 6 �n0 0.vxwpy 6z 2 0$v ; y 6z {}|�~ r 6andradius � ��� 0.v ; y 6z��9��� r �where v�� ; " s &7��" s # and y�� ; " t &N��" t # arethe line direc-tions.Note,if rI��� � z thecirclecentreis on the > axis.Equal (unknown) angles:Supposetheangleontheworld planebetweentwo linesim-agedwith directionsv #�2 y # is thesameasthatbetweentwolines imagedwith directionsv &Y2 y & . Thenit canbe shownthat > and ? lie on thecirclewith centreon the > axis0$u < 2 u : 6 ��0 v # y & ; y # v &v # ; y # ; v & wpy & 2 ! 6andsquaredradius� & � 0 v # y & ; y # v &v # ; y # ; v & wpy & 6 &w 0.v # ; y #}6 0.v # y # ; v & y &76v # ; y # ; v & wpy & ; v # y #

Known length ratio:Supposethelengthratio of two non-parallelline segments

2222x , y

1111x , y

(

)

)

)

)

(

(

( 12

l 2

12x , y

2121x , y

l 1

Figure 1. Notation for line segments in thekno wn length ratio constraint.

is L on theworld plane, andtheseline segmentsareimagedasshown in figure1. Writing ����� for ��� # ; �a� & andsim-ilarly for � , it canbe shown that > and ? lie on the circlewith centreon the > axis0.u < 2 u : 6 ��0 0.�I� # �I� # ; L & �I� & �I� &��� # & ; L & �I� & & 2 ! 6andradius � ��� L 0.�I� & �I� # ; �I� # �I� & 6�I� # & ; L & �I� & & �RTS�� � Xlik������cVil�H�aXlZ���cVioh�c.X[i

Two (independent)constraintsarealwaysrequiredto de-termine> and? , andvariouscombinationsareillustratedinfigures4 and5. It shouldbenotedthat the constraintsaredependenton line orientation(in the affine rectified geo-metry),andthesameconstraintcircle resultsfrom any par-allel line sets.

Most of the examplesemploy right angles,sincethesearethemostpervasiveandusefulanglesin manmadestruc-tures.For right anglestheknown angleconstraintgeneratescircles with centreson the > axis. Similarly, the knownlengthratioandequal(arbitrary)angleconstraintsalsogen-eratecircleswith centreson the > axis.Having all thecon-straintcircleswith centreson the sameaxis simplifiesob-tainingsolutionsbecausetheconstraintcirclesaresymmet-ric with respectto this axis, andonly intersectionsin theupperhalf planeneedbeconsidered.

3 Unstratified rectification

The previous sectiondescribeda two steprectificationprocessapplyingconstraintssequentiallyon the projectiveandaffine componentsof the rectificationhomography. It

is possible,however, to determinetheparametersof �� dir-ectly from metric information,without first usingaffine in-formation,suchasparallelism,to determine� from thevan-ishingline. In generaldirectapplicationof themetriccon-straintsgeneratesnon-linearconstraintson theparameters.However, for orthogonallinestheconstraintonthefour rec-tificationparametersis linear.

To obtaina linear constraintthe parametersarerepres-entedby the conic � which is dual to the circular points.This conic is definedas ����@FA 8 wfA�@ 8 [16], andis rep-resentedby a rank two �=��� matrix. Oncethe imageof �is determined,the imagedcircular pointsarealsodeterm-ined. Fromsection2, thecircularpointsareimagedon thevanishingline at 090$>�G D ? 6�" ) 2e" ) 2 ; > " # ; " & G D ? " # 698 Con-sequently, oncethecircularpointsaredeterminedtherecti-ficationparameters,$- andand > 2 ? canbecomputed.

It canbeshown thatorthogonallinesareconjugatewrt � ,i.e. satisfy , s 8 ��, t � ! for orthogonallines , s and , t . Eachpair of orthogonallines thusplacesa linear constrainton� . Five orthogonalline pairs,i.e. five right angles,aresuf-ficient to determine� linearly, providedlinesof morethantwo orientationsare included. Alternatively, � is determ-ined by four orthogonalline pairs togetherwith the ranktwo constraint,but thesolutionis non-linear.

4 Application to cameracalibration

Caprile and Torre [1] have shown that threevanishingpointsfor orthogonaldirectionsallowspartialcalibrationofa camerafrom a singleview. The calibrationmethodfol-lows a constructionshowing that theprincipalpoint of thecamerais at the orthocentreof the trianglewhich hasthevanishingpointsasits vertices.This relieson prior meas-urementof theaspectratio andtheassumptionthattheim-ageskew is zero.

Metric rectificationof a planealsopartially determinescameracalibration.Thefive internalcalibrationparameterscanbecomputedfrom theimageof theabsoluteconic [5],andhencearedeterminedoncethe imagedabsoluteconicis determined.Theimagedcircularpointslie on theimageof theabsoluteconic,andthesepointsareknown for a rec-tified plane.Eachrectifiedplanethenprovides2 pointsontheconicandthus2 linearconstraintson theconic. In theabsenceof additionalconstraints,5 points,thatis threenon-parallelplanesarerequiredfor cameracalibration.If priorinformationaboutthecamerais available,suchastheaspectratioor skew, only two non-parallelplanesarerequired.

5 Implementation Details TSVU ¡ eikcq��¢�cVio£n\¤X[cVil�¥`����YcVZ¦��YcqXliA vanishingpoint is determinedby the intersectionof

two imagedparallel lines. The intersectionof the lines , #and , & is simply ���§, # ��, & . Generally, therearemorethantwo imagedparallellinesavailableandthevanishingpointis thusoverconstrained.

The presenceof measurementerror (‘noise’) resultsina setof line segmentswhich do not intersectpreciselyina point. A numberof approachesto estimatingthevanish-ing point have beenproposed. A simple approachis thecalculationof a weightedmeanof all pairwiseline inter-sections[1]. More elaboratehasbeenthe applicationofBayesianstatisticsto errorin projectivespaces.AssumingaBinghamprobabilitydensityfunctionandmappingclustersof line intersectionpoints to the unit sphere,a vanishingpoint is estimatedas the point that minimisesthe sumofweightedorthogonaldistancesto theobservedcluster[3].

In contrastto this,wedefineandimplementaML estim-ateof the vanishingpoint in order to minimize the errorswherethey occur: in the image. We have found empiric-ally that this estimatorsignificantlyimprovestheaccuracyof themetricrectification.

Supposethereare ¨n© z line segments,$ª andwe seekto estimatethevanishingpoint « . TheML estimateof thevanishingpoint ¬« involvesfinding alsoan estimateof theline segments¬ , ª suchthat ¬« lies oneachline ¬ , ª andthelineset ­ ¬ , ª¯® minimizestheMalhanobisdistancefrom ­7, ª�® .

It is assumedthattheerrorin thefittedline segmentscanbemodelledby isotropicmeanzeroGaussiannoiseon theendpoints. If theendpointsof , are � s and � t , (figure2),thentheMLE minimizes° ��± ª§² &³ 0 ¬ , ª 2 � sª 6 w ² & ³ 0 ¬ , ª 2 � tª 6subjectto the constraints ¬«o´ ¬ ,�ª=� ! 2¯µ�D , where ² ³ 0$� 2 , 6 isthe perpendicularimagedistancebetweenthe point � andline , . An alternative cost function underdifferent noiseassumptionsis givenby Kanatani[8].

Thecostfunctionisminimizedasfollows: Given ¬« it canbeshown thatthecost

° 0 ¬« 6 canbeobtainedin closedform.° 0 ¬« 6 canthenbe minimizedover ¬« usingthe Levenberg-Marquartnumericalalgorithm[11]. An initial solutionfor ¬«is obtainedfrom thenull vectorof thematrix 0$, #�2 , &�2 ´N´¶´9,.� 6via singularvaluedecomposition. TS$R · Z��£l`¹¸º��\�cVik£

Imagesarewarpedby applyingtheinversehomographyto eachpixel in thetargetimage.Theintensityat thesource

xb

a

^va l^

bd

dl

x

Figure 2. Geometr y of the ML cost function.

point in theoriginal imageis determiningby bilinearinter-polation. In orderto automatethewarpingandensurethatthe convex hull of the original imageis correctlymappedinto therectangleof thetargetimage,it is necessaryto useorientedprojectivegeometry[10]. TS�� ��»o��X[Z¦��Ycq� ¼�`a��`a�b�YcqXli Xe½ dh�i�c.�Y¢kcVik£\¤XlcVil���H�ik¼�Xl���¢oXl£eX[ik�¾C¼�cq�`a�b�YcqXlik�

Automationof thecorrectionprocessis achievedby de-tectingthe two dominantdirectionsof lines in the image,and assumingthat thesedirectionsare orthogonalin theplane. The dominantdirectionsare obtainedfrom a fre-quency histogramon line direction(orientation),with thefrequency weightedby segmentlength. Typically the his-togramis bimodal,andis readilysegmented.The lines ineachdominantdirectionareassumedto be parallel andavanishingpoint determined.The resultingaffine imageislikewisesearchedfor dominantdirections,andlines in thetwo directionsconstrainedto beat right angles.Sincethisonly providesoneconstrainton theaffineparameters,thereis an ambiguityin relative scale. Examplehistogramsaregiven in figure 7. Note that while the histogramapproachlendsitself well to the detectionof dominantdirectionsofparallellines in affine images,it is lesswell suitedto van-ishing point detection. The projective distortionof paral-lel linesresultsin distributedhistogrammaxima,suchasadoublepeakin thepresenceof two widelyspacedclustersoflines.Morerobustvanishingpointdetectionmaybeaccom-plishedwith applicationof techniquessuchas the HoughTransform,asfor examplein [2] and[17].

Any point on the circle constraintchosenfor the affineparameterswill make thoselinesorthogonal,thechoiceofpoint determiningthe relative scalingin the two dominantdirections.In theabsenceof any affinedistortion,thepara-meterswould have value 0 ! 2 � 698 , so thepoint on thecon-straintcircle closestto thepoint 0 ! 2 � 698 is chosenfor thecorrection.

6 Examplesand applications

Texture map acquisition. This example illustrates thevarietyof constraintsavailablefor metricrectificationin the

caseof atexturewith rich geometry. Figure3 showsthefirststagewhereparallellinesareselected(manually)andusedto determinetheimageof theline at infinity.

Thethreetypesof constraintandtheresultingcirclesareillustratedin figure 4. Application of the direct (unstrati-fied)methodof section3 usingthreeof thelight squaresasconstraintsresultsin a metricimagevisually indistinguish-ablefrom figure4(c). Theanglebetweenlines labelled1aand1b, for example,differs by 0.44¿ betweenthe metricimagesobtainedusingthe stratifiedapproach(shown) anda metric imageobtainedby thedirectapproach.Note thattheorthogonalityof theselineswasusedasa constraintinbothcases.Therectifiedlinesarenot preciselyorthogonalsincebothrectificationsareoverconstrained.

Using repeated elements. Repeatedplanar structure,wherea featureappearsatdifferentorientations,allowsuseof thelengthratio andequalangleconstraintsfor unknownlengthsandangles.Figure5 (a) is an imageof a rosewin-dow with twelve repetitionsof thewindow segments.Theline at infinity is found from parallel lines in the overallstructure.Theaffine parametersarefound, for demonstra-tion purposes,only from aminimalsetof constraintstakingtheindicatedpairsof anglesto beof equalmagnitude.Theresultingconstraintcirclesandrectifiedimageappearin fig-ure5 (b) and(c).

Euclidean measurements. Figure 6 demonstratesthatEuclideanmeasurementsmaybemadefrom animageoncethehomographyis knownupto aEuclideanambiguity. Thehomography( ��� ) in thiscaseis obtainedfromtheorthogon-ality andlengthratioof theinnergoalarea.Overall scaling( L ), allowing trueworld measurementfrom the image,fol-lows from settingthescalingfor oneof theknown lengthsin theimage.

Automatic metric rectification. Figure 7 is rectifiedautomatically using dominant line orientation in histo-grams.Thehistogramsfor bothstagesareshown,with clearseparationof dominantdirectionpeaks.Line orientationiscomputedover therange; � � z to � � z and‘wrapsaround’,i.e. ; � � z and � � z identify thesameorientation.

7 Extensions

1. Lensdistortionhasbeenignoredthroughoutthis paper.Wherenecessarythe approachof DevernayandFaugeras[4] maybeappliedto removeradialdistortion.2. Thesymmetryof planarobjectsandcirclescanalsobeusedto constrainrectification.3. The MLE hasso far beenimplementedfor vanishingpointsfrom a setof line segmentsonly. In caseswherethe

vanishingline is over constrained,i.e. therearemorethantwo vanishingpointsavailable,the line itself canbeestim-atedusingMLE.4. Similarly, a ML estimatorcanbeappliedto thesolutionfor 0.> 2 ? 6 whenmorethantwo constraintsareavailable.5. The ideasdevelopedin this papercan be extendedtothreedimensionalstructure,wheremetricrectificationis of3D projectivestructureobtainedfrom uncalibratedimages.���À�ikX_¸H¾q`�¼k£l`�Z�`_il���

Theauthorswould like to thankDr Andrew Fitzgibbonfor his invaluableassistancewith softwareandmany help-ful discussions.We aregrateful to EU Esprit ProjectIm-proofsandtheUniversityof theWitwatersrandPostgradu-ateScholarshipandAppealFundfor financialsupport.

References

[1] B. CaprileandV. Torre. Usingvanishingpointsfor cameracalibra-tion. IJCV, pages127–140,1990.

[2] R. T. Collins andJ. R. Beveridge. Matchingperspective views ofcoplanarstructuresusingprojective unwarpingandsimilarity match-ing. In Proc.CVPR, 1993.

[3] R.T. Collins. A Bayesiananlysisof projective incidence. In J.L.MundyandA. Zisserman,editors,Proc.2ndEuropean-USWorkshopon Invariance, Azores, pages151–163,1993.

[4] F. DevernayandO. Faugeras.Automaticcalibrationandremoval ofdistortionfrom scenesof structuredenvironments.In SPIE, volume2567,SanDiego,CA, July 1995.

[5] O. Faugeras,Q. Luong,andS. Maybank. Cameraself-calibration:Theoryandexperiments. In Proc. ECCV, LNCS 588, pages321–334.Springer-Verlag,1992.

[6] O. D. Faugeras.Stratificationof three-dimensionalvision: project-ive,affine,andmetricrepresentation.J. Opt.Soc.Am., A12:465–484,1995.

[7] O.D. Faugeras,S. Laveau,L. Robert,G. Csurka,andC. Zeller. 3-D reconstructionof urbanscenesfrom sequencesof images. Tech.report,INRIA, 1995.

[8] K. Kanatani.Statisticaloptimizationfor geometriccomputation:the-ory andpractice. Technicalreport,AI Lab, Deptof ComputerSci-ence,GunmaUniversity, 1995.

[9] J.J.KoenderinkandA. J.vanDoorn. Affine structurefrom motion.J. Opt.Soc.Am.A, 8(2):377–385,1991.

[10] S.Laveau.Geometrie d’un systemede Á cameras.Theorie, estima-tion et applications. PhDthesis,INRIA, 1996.

[11] W. Press,B. Flannery, S. Teukolsky, andW. Vetterling. NumericalRecipesin C. CambridgeUniversityPress,1988.

[12] C. Rothwell, A. Zisserman,J. Mundy, and D. Forsyth. Efficientmodellibrary accessby projectively invariantindexing functions.InProc.CVPR, pages109–114,1992.

[13] J.SempleandG.Kneebone.Algebraic ProjectiveGeometry. OxfordUniversityPress,1979.

[14] C. Slama.Manualof Photogrammetry. AmericanSocietyof Photo-grammetry, FallsChurch,VA, USA, 4th edition,1980.

[15] R. Szeliski. Imagemosaicingfor tele-realityapplications.Technicalreport,Digital EquipmentCorporation,Cambridge,USA, 1994.

[16] W. Triggs.Autocalibrationfromplanarscenes.In Proc.ECCV, 1998.

[17] T. Tuytelaars,L. VanGool,M. Proesmans,andT. Moons. Thecas-cadedHoughtransformasan aid in aerial imageinterpretation.InProc.ICCV, pages67–72,January1998.

(a) (b) (c)

Figure 3. Affine rectification of a patterned floor . (a) The original image. (b) Line segments detectedby Canny edge detection at sub-pix el accurac y; worm segmentation; and, fitting by or thogonalregression. Two parallel line sets (in white) inter sect in two vanishing points, and determine theimaged line at infinity . The vanishing points are found by MLE. (c) The rectified affine image.

−10 0 10 20 30 40

−15

−10

−5

0

5

10

15

20

25

right angle (2a, 2b)

right angle(1a, 1b)(3a, 3b)(4a, 4b)

equal angle(1ab, 2ab)

length ratio(1a, 1b) and (4a, 4b)

alpha

beta

(a) (b) (c)

Figure 4. Metric rectification follo wing figure 3(c). (a) Lines segments used to provide constraints.The lines sho wn in white are kno wn to be in pair s at right angles. (b) Constraint cir cles in the > ; ?plane . The or thogonality of line pair s (1a, 1b), (3a, 3b) and (4a, 4b) gives the same cir cle (up to noise).The or thogonality of pair (2a, 2b) (whic h are not parallel to the fir st three) generates a diff erent cir cle.The constraint of equal angle between pair s (1a, 1b) and (2a,2b) also generates a diff erent cir cle. Theconstraint from unity length ratio of the sides of the squares bounded by (1a, 1b) and (4a, 4b) is alsogiven. (c) The rectified metric image. Note that accurac y of the squares and cir cles demonstrate thata good estimation of the metric plane is achieved.

−10 −8 −6 −4 −2 0 2−5

0

5

pair 1

pair 2

alpha

beta

(a) (b) (c)

Figure 5. Rectification using repeated elements in a rose windo w. (a) The repetition of structure inthe windo w allo ws application of the equal angles constraint for pair s 1 and 2. The true angle neednot be kno wn. (b) Constraint cir cles for the equal angle pair s. (c) The metric image.

(a) (b)

Figure 6. Measurement of Euclidean quantities follo wing perspective rectification. (a) Scene froman infamous England World Cup victor y. Perspective correction using the parallel lines and kno wnlength ratio of the goal area, allo ws measurement in the plane from the perspective image. (b)Measurements of the goal area, a shado w and the approximate height of a fallen defender.

−2 −1 0 1 20

100

200

300

400

500

600

700

800

angle (radians)

freq

uenc

y

−2 −1 0 1 20

5

10

15

20

25

30

35

angle (radians)

freq

uenc

y

(a) (b) (c)

Figure 7. Bimodal histogram dominant direction detection. (a) Original image. (b) Orientation histo-gram of fitted lines in the original image. (c) Orientation histogram of fitted lines in the affine image(without edge length scaling). Note the sharpening around the modes.

(a) (b)

Figure 8. (a) Automated rectification. (b) Rectification with the correct relative scaling using ameasured ratio of lengths of one of the windo ws. Note the slight diff erence in scaling.