std-getpts


Synopsis

(std-getpts <ele>) => pts

(std-get-getpts-vertexmask) => actual mask

(std-set-getpts-vertexmask <mask>) => new mask

Description

STD-GETPTS returns the list of WCS points defined by the entity ele.

3D-points in the same order as defined in the entity dxf group list are returned.

Some polyline vertices may be rejected depending on the value of STD-GET-GETPTS-VERTEXMASK. The R14/VLISP z-value bug is fixed, ie. the correct z-value is returned.

Text entities return always one point (group 10), even if a second fitting point is defined.

Arc entities return a list of the start- and the endpoint.

STD-GET-GETPTS-VERTEXMASK and STD-SET-GETPTS-VERTEXMASK get and set a bitmask used with flag 70 of any subentity, for leaving out vertices or attributes with the function STD-GETPTS.

The default value returned by STD-GET-GETPTS-VERTEXMASK is 0.

For polylines a bitmask 16 would reject all spline frame points, bitmask 9 reject every computer-added vertices, bitmask 0 rejects none.

This is useful to change between the vertices without any spline frames (the visible points), or the defined points only (without the calculated fit points).

Instead of the sum of integers a list of integers is valid as well. Then the bitwise sum of these numbers is used. (using LOGIOR)

Ie. A mask of '(1 8) == mask 9

mask '(1 9) == mask 9

Examples:

;;; unordered list of all points of the selected entities
(apply 'std-union (mapcar 'std-getpts (std-sslist (ssget))))

;;; Initialize vertex bitmask used for rejecting vertices.
(std-set-getpts-vertexmask 0)        ;return all vertices
(std-set-getpts-vertexmask '(1 8))   ;reject spline-fit and
                         ;curve-fit vertices with std-getpts
(std-set-getpts-vertexmask 16)       ;reject spline frame vertices

Arguments

ele: Either an entity type, entget-list, entsel picklist or nentsel picklist of any entity.

mask: a positive integer or a list of integers or nil

Return Value

STD-GETPTS returns a list of 3D-points.

STD-GET-GETPTS-VERTEXMASK and STD-SET-GETPTS-VERTEXMASK return the actual value of the current vertexmask.

Side Effects

STD-SET GETPTS-VERTEXMASK controls the behaviour of STD-GETPTS and
STD-%CPLX-LIST by changing the global variable *STD:GETPTS-VERTEXMASK*

Module

(std-require 'STDPOINT)

Defined in STDPOINT

Note: Before version 0.4001 it was in STDENT!