Regular API function

simGetShapeGeomInfo

Description Retrieves geometric information related to a shape. See also simGetShapeMesh.
C synopsis simInt simGetShapeGeomInfo(simInt shapeHandle,simInt* intData,simFloat* floatData,simVoid* reserved)
C parameters
shapeHandle: handle of the shape. See also simGetObjectHandle.
intData (output): pointer to 5 integer values:
intData[0]: the pure type of the shape. Undefined if the shape is a compound shape.
floatData (output): pointer to 5 float values:
floatData[0]: X-size or diameter of the pure shape. Undefined if the shape is a compound shape or not pure.
floatData[1]: Y-size of the pure shape. Undefined if the shape is a compound shape or not pure.
floatData[2]: Z-size or height of the pure shape. Undefined if the shape is a compound shape or not pure.
floatData[3]: Inside scaling. Undefined if the shape is a compound shape or not pure.
reserved: reserved for future extensions. Set to NULL.
C return value
-1 in case of an error, otherwise bit-coded:
bit0 set (1): shape is a compound shape
bit1 set (2): shape is pure
bit2 set (4): shape is convex
Lua synopsis number result,number pureType,table_4 dimensions=simGetShapeGeomInfo(number shapeHandle)
Lua parameters
shapeHandle: handle of the shape. See also simGetObjectHandle.
Lua return values
result: -1 in case of an error, otherwise bit-coded:
bit0 set (1): shape is a compound shape
bit1 set (2): shape is pure
bit2 set (4): shape is convex
pureType: the pure type of the shape. Undefined if the shape is a compound shape.
dimensions: table to 4 values giving information about the shape's dimensions:
dimensions[1]: X-size or diameter of the pure shape. Undefined if the shape is a compound shape or not pure.
dimensions[2]: Y-size of the pure shape. Undefined if the shape is a compound shape or not pure.
dimensions[3]: Z-size or height of the pure shape. Undefined if the shape is a compound shape or not pure.
dimensions[4]: Inside scaling. Undefined if the shape is a compound shape or not pure.

All regular API functions on one page