CPLplotinout

by Tim C. Lueth, SG-Lib Toolbox: SolidGeometry 5.6 - CPL/Closed Polygon Lists
Introduced first in SolidGeometry 4.4, Creation date: 2018-12-23, Last change: 2025-09-14

plots the CPLs in colors depending in the enclosure level

Description

plots the enclosing level using the colorstring 'rbgymcwk'



See Also: CPLplot , CPLplotcolors , CPLplotregions , CPLplotcwccw

Example Illustration

 missing image of CPLplotinout(CPL,col)

Syntax

h=CPLplotinout(CPL,[col])

Input Parameter

CPL: Closed Polygon line
col: line type; first char (color) is ignored

Output Parameter

h: handle to plot

Examples


SGfigure; CPLplotinout(CPLsample(14))
SGfigure; CPLplotinout(CPLsample(14),'?-.')
SGfigure; CPLplotinout(CPLsample(14),'?-.',4)




Copyright 2018-2025 Tim C. Lueth. All rights reserved. The code is the property of Tim C. Lueth and may not be redistributed or modified without explicit written permission. This software may be used free of charge for academic research and teaching purposes only. Commercial use, redistribution, modification, or reverse engineering is strictly prohibited. Access to source code is restricted and granted only under specific agreements. For licensing inquiries or commercial use, please contact: Tim C. Lueth

Algorithm (Workflow)

This function, CPLplotinout, is designed to plot closed polygon lines (CPLs) with colors that depend on the enclosure level. It is part of the SolidGeometry library and was introduced in version 4.4.

Input Parameters

Output

Algorithm Steps

  1. The function begins by determining the color and line type using the getfuncparams function. If no specific line type is provided, it defaults to 'r-'.
  2. Additional parameters are extracted from varargin starting from the second element onward.
  3. The function CPLsortinout is called with the CPL input to determine the enclosure levels of the polygons.
  4. An array h is initialized to store plot handles, with its size based on the number of elements in the sorted enclosure levels.
  5. A loop iterates over each element in the sorted enclosure levels:

The function is designed to work with other related functions such as CPLplot, CPLplotcolors, CPLplotregions, and CPLplotcwccw, which provide additional plotting capabilities for closed polygon lines.

Algorithm explaination created using ChatGPT on 2025-08-19 00:07. (Please note: No guarantee for the correctness of this explanation)

Last html export of this page out of FM database by TL: 2025-09-21