fz_objt_fact_create_face

Description

Creates a new, closed face by connecting the points in a given array.
This array holds the indices to the coordinate points of the object. Most likely, the coordinates of the object were previously created with ().
The index of the new face is optionally returned in the findx parameter.

Plugin Prototype

fzrt_error_td fz_objt_fact_create_face(

fzrt_int

windex,

fz_objt_ptr

obj,

fzrt_int *

pindx,

fzrt_int

npindx,

fzrt_int *

findx )

Parameters

windex [Input]

project window index

obj [Input]

object

pindx [Input]

array of point indices to connect

npindx [Input]

number of point indices in array

findx [Result, Optional]

index of new face

Returns

Error codes

Availability

5.0.0.0

Plugin Example

fz_xyz_td pts[4]; fzrt_int pindx[4]; fz_objt_ptr new_obj;
fz_objt_cnstr_objt_new(windex,&new_obj); pts[0] = { 0.0, 0.0, 0.0}; pts[1] = {100.0, 0.0, 0.0}; pts[2] = {100.0,100.0, 0.0}; pts[3] = { 0.0,100.0, 0.0}; pindx[0] = 0; pindx[1] = 1; pindx[2] = 2; pindx[3] = 3; fz_objt_fact_add_pnts(windex,new_obj,pts,4); fz_objt_fact_create_face(windex,new_obj,pindx,4,NULL);
The sample code above creates a new object and adds 4 points, which are connected to form a square face. The face connects points number 0,1,2 and 3 in this order.

Example Files

util_objt_cnstr_lowlevel.fsl

See Also

,

Function Set

fz_model_fset


Defined in

fz_objt_api.h