Documentation Center

  • Trials
  • Product Updates

cpstruct2pairs

Convert CPSTRUCT to valid pairs of control points

Syntax

[movingPoints,fixedPoints] = cpstruct2pairs(CPSTRUCT)

Description

[movingPoints,fixedPoints] = cpstruct2pairs(CPSTRUCT) takes a CPSTRUCT (produced by cpselect) and returns the arrays of coordinates of valid control point pairs in movingPoints and fixedPoints. cpstruct2pairs eliminates unmatched points and predicted points.

Examples

Start the Control Point Selection Tool, cpselect.

aerial = imread('westconcordaerial.png');
cpselect(aerial(:,:,1),'westconcordorthophoto.png')

Using cpselect, pick control points in the images. Select Export Points to Workspace from the File menu to save the points to the workspace. On the Export Points to Workspace dialog box, check the Structure with all points check box and clear Input points of valid pairs and Base points of valid pairs. Click OK. Use cpstruct2pairs to extract the input and base points from the CPSTRUCT.

[movingPoints,fixedPoints] = cpstruct2pairs(cpstruct);

See Also

| |

Was this topic helpful?