PLui

by Tim C. Lueth, SG-Lib Toolbox: SolidGeometry 5.6 - PL/Point Lists
Introduced first in SolidGeometry 4.7, Creation date: 2019-06-20, Last change: 2025-09-14

interactive fnct to create and modify CPLS (Only one Contur)

Description

Left Mouse button => Set remove and shift points by
Right Mouse button => Shift at edges, Rotate at corners
Middle Mouse Button => exit
More or less: CPL=VLui(CPL,'','',col,'',linw);

See Also: VLui , CPSlineui , CPLui , CPSui , PLsquareui , PLcircleui , VLFLui , SGui , CPLsplitui , Poseofimageui , Poseui , SGTui

Example Illustration

 missing image of PLui(PL,col,linw)

Syntax

PL=PLui([PL,col,linw])

Input Parameter

PL: Optional PL; default is [];
col: Optional color; default is 'r-'
linw: optional line width; default is 2

Output Parameter

PL: Final Point List

Examples


cla; PLui()
cla; PLui(CPLsample(3))
cla; PLui(CPLsample(3),'b-',3)




Copyright 2019-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, PLui, is an interactive tool for creating and modifying closed polygon lists (CPLs). It is part of the SolidGeometry library and was introduced in version 4.7. The function allows users to interactively set, remove, and shift points using mouse buttons.

Input Parameters

Output

Function Workflow

  1. The function begins by retrieving the input parameters using the getfuncparams function. This function extracts the specified parameter or assigns a default value if the parameter is not provided.
  2. The VLui function is called with the parameters PL, col, and linw. This function handles the interactive user interface for modifying the polygon.
  3. The resulting point list PL is reduced to its first two columns, which likely represent the x and y coordinates of the points.
  4. The circshift function is used to circularly shift the points in the list by one position. This operation might be used to reorder the points for a specific purpose.

Mouse Button Interactions

The function is designed to be used in a graphical environment where users can visually manipulate the shape of a polygon by interacting with its points and edges.

Algorithm explaination created using ChatGPT on 2025-08-19 01:05. (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