State Query Funcs

class lwsdk.LWStateQueryFuncs(self)

Bases: object

Proxy of C++ PCore::LWStateQueryFuncs class

 bbox(EltOpLayer layermask) → unsigned int, int[6]

Returns a Python typle that contains the total number of points in the first element, and a sequence containing the (x0, x1, y0, y1, z0, z1) values of the bounding box for the points the current layermask selection in the second element.

 layerList(EltOpLayer oplayer, char objname) → char

Returns a string containing layer numbers for the given layermask and objname. The layer numbers in the returned string are separated by spaces, with the highest numbered layer listed first. The object name is its filename, or None for the current object.

 layerMask(EltOpLayer oplayer) → unsigned int

Returns bits for the data layers included in the layermask selection. If bit i of the mask is set, then layer i + 1 of the current object belongs to the set defined by the arg1. This function is provided primarily for backward compatibility. New code should use the LWStateQueryFuncs::layerList() function, which is designed for multiple objects and an unlimited number of layers.

 mode(int setting) → int

Returns the state of a user interface setting. The setting codes are:

  Returns the selection mode (points, polygons, volume) as an integer.
  Returns the state of the symmetry toggle.

 numLayers() → int

Returns the number of data layers for the current object.

 object() → char

Returns the filename of the current object. If the geometry in the current layers hasn't been saved to a file yet, this returns the reference name (the name that would be returned by LWObjectFuncs::refName() method). If no object has been loaded into Modeler, this returns None.

 surface() → char

Returns the name of the current default surface.

 vmap(int index) → char

Returns the name of the currently selected vertex map, and returns the LWID of the vmap. index can be one of the following:


Previous topic

Object Funcs

Next topic

Font List Funcs

This Page