<?xml version="1.0" encoding="UTF-8"?>
<!--
 * Scilab Computer Vision Module
 * Copyright (C) 2017 - Scilab Enterprises
 *
 -->
<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg"  xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" version="5.0-subset Scilab"
  xml:lang="fr" xml:id="PtList">
  <info>
    <pubdate>$LastChangedDate$</pubdate>
  </info>
  <refnamediv>
    <refname>PtList</refname>
    <refpurpose>Type for a list of points</refpurpose>
  </refnamediv>
  <refsection>
    <title>Description</title>
    <para><literal>PtList</literal> is the type used to store a list of points.</para>
    <para>This type is taken as input parameter of several functions, such as as <literal>contourArea</literal> for example.</para>

    <para><literal>PtList</literal> supports the extraction operator <literal>(n:step:m)</literal>, returning a matrix containing the point coordinates.</para>
  </refsection>
  <refsection>
    <title>Examples</title>
    <programlisting role="example"><![CDATA[
    scicv_Init();

    img_gray = imread(getSampleImage("shapes.png"), CV_LOAD_IMAGE_GRAYSCALE);
    canny_img = Canny(img_gray, 100, 100*2, 3);

    [img_out, contours] = findContours(canny_img, CV_RETR_TREE, CV_CHAIN_APPROX_SIMPLE, [0, 0]);

    // First contour
    cnt = contours(1);
    disp(typeof(cnt));

    // Contour point coordinates
    disp(cnt(:));
 ]]></programlisting>
  </refsection>
  <refsection>
    <title>See also</title>
    <simplelist type="inline">
      <member>
        <link linkend="PtLists">PtLists</link>
      </member>
    </simplelist>
  </refsection>
</refentry>
