GetConceptualFaceEx

This function returns a handle to the conceptual face. Be aware that different instances can return the same handles (however with possible different startIndices and noTriangles).
Argument index should be at least zero and smaller then return value of GetConceptualFaceCnt().

Syntax

public const string EngineDLL = @"engine.dll";[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, out Int64 startIndexTriangles, out Int64 noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, out Int64 startIndexLines, out Int64 noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, out Int64 startIndexPoints, out Int64 noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, out Int64 startIndexFacePolygons, out Int64 noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, out Int64 startIndexConceptualFacePolygons, out Int64 noIndicesConceptualFacePolygons);

[DllImport(EngineDLL, EntryPoint = "GetConceptualFaceEx")]
public static extern Int64 GetConceptualFaceEx(Int64 owlInstance, Int64 index, IntPtr startIndexTriangles, IntPtr noIndicesTriangles, IntPtr startIndexLines, IntPtr noIndicesLines, IntPtr startIndexPoints, IntPtr noIndicesPoints, IntPtr startIndexFacePolygons, IntPtr noIndicesFacePolygons, IntPtr startIndexConceptualFacePolygons, IntPtr noIndicesConceptualFacePolygons);    

Property owlInstance

Size: 64 bit / 8 byte (value)
The handle to the specific instance in the design tree. The instance handle is static within one open model but is most probably different when the same instance is opened in another model. The instance is always exactly of one unique class.

Property index

Size: 64 bit / 8 byte (value)
This is the index (0 based) of the face in the set of conceptual faces available.

Property startIndexTriangles

Size: 64 bit / 8 byte (reference)
The first index in the indices array representing a Triangle by a reference in the vertices array.

Property noIndicesTriangles

Size: 64 bit / 8 byte (reference)
The number of lines within this conceptual face has exactly one third of the number in this noIndicesTriangles, each individual index from startIndexTriangles references a vertex element in the vertices array, the references could be duplicated. Each triple of references represents one triangle.

Property startIndexLines

Size: 64 bit / 8 byte (reference)
The first index in the indices array representing a Line by a reference in the vertices array.

Property noIndicesLines

Size: 64 bit / 8 byte (reference)
The number of lines within this conceptual face has exactly half of the number in this noIndicesLines, each individual index from startIndexLines references a vertex element in the vertices array, the references could be duplicated. Each tuple of references represents one line.

Property startIndexPoints

Size: 64 bit / 8 byte (reference)
The first index in the indices array representing a Point by a reference in the vertices array.

Property noIndicesPoints

Size: 64 bit / 8 byte (reference)
The number of points within this conceptual face exactly matched this noIndicesPoints, each individual index from startIndexPoints references a vertex element in the vertices array, the references could be duplicated.

Property startIndexFacePolygons

Size: 64 bit / 8 byte (reference)
The first index in the indices array representing the polygon for that specific face (a face is always placed / defined in exactly 1 plane). SetFormat(..) has several options to structure how these polygons are exported with / without repeating line segments, line segments per line segment or list of vertex references ending with -1 (outer polygon) or -2 (inner polygon) [default]. For example by default a Cylinder has 38 faces, top and bottom have each one polygon with 37 points (first and last point the same) and surrounding face polygons represent rectangles (i.e. 6 elements including the last / first point being the same and -1 as ending).

Property noIndicesFacePolygons

Size: 64 bit / 8 byte (reference)
The number of indices in the indices array for the face polygons. For example in default SetFormat(..) setting a square polygon represented by 6 indices, for example [0, 1, 2, 3, 0, -1] where the vertices array has at least 4 vertex elements.

Property startIndexConceptualFacePolygons

Size: 64 bit / 8 byte (reference)
The first index in the indices array representing the polygon for that specific conceptual face. SetFormat(..) has several options to structure how these polygons are exported with / without repeating line segments, line segments per line segment or list of vertex references ending with -1 (outer polygon) or -2 (inner polygon) [default]. For example by default a Cylinder has three conceptual faces, top and bottom have each one polygon and surrounding polygon has two polygons.

Property noIndicesConceptualFacePolygons

Size: 64 bit / 8 byte (reference)
The number of indices in the indices array for the conceptual face polgyons. For example in default SetFormat(..) setting a square polygon represented by 6 indices, for example [0, 1, 2, 3, 0, -1] where the vertices array has at least 4 vertex elements.

Example

Here you can find code snippits that show how the API call GetConceptualFaceEx can be used.

using Engine;

const Int64 flagbit0 = 1;                           // 2^^0                          0000.0000..0000.0001
const Int64 flagbit1 = 2;                           // 2^^1                          0000.0000..0000.0010
const Int64 flagbit2 = 4;                           // 2^^2                          0000.0000..0000.0100
const Int64 flagbit3 = 8;                           // 2^^3                          0000.0000..0000.1000

const Int64 flagbit4 = 16;                          // 2^^4                          0000.0000..0001.0000
const Int64 flagbit5 = 32;                          // 2^^5                          0000.0000..0010.0000
const Int64 flagbit6 = 64;                          // 2^^6                          0000.0000..0100.0000
const Int64 flagbit7 = 128;                         // 2^^7                          0000.0000..1000.0000

const Int64 flagbit8 = 256;                         // 2^^8                          0000.0001..0000.0000
const Int64 flagbit9 = 512;                         // 2^^9                          0000.0010..0000.0000
const Int64 flagbit10 = 1024;                       // 2^^10                         0000.0100..0000.0000
const Int64 flagbit11 = 2048;                       // 2^^11                         0000.1000..0000.0000

const Int64 flagbit12 = 4096;                       // 2^^12                         0001.0000..0000.0000
const Int64 flagbit13 = 8192;                       // 2^^13                         0010.0000..0000.0000
const Int64 flagbit14 = 16384;                      // 2^^14                         0100.0000..0000.0000
const Int64 flagbit15 = 32768;                      // 2^^15                         1000.0000..0000.0000

static void Main(string[] args)
{
    Int64   model = Engine.x86_64.CreateModel();

    if (model != 0)
    {
        //
        //  Classes
        //
        Int64   classCollection = Engine.x86_64.GetClassByName(model, "Collection"),
                classCylinder = Engine.x86_64.GetClassByName(model, "Cylinder"),
                classLine3D = Engine.x86_64.GetClassByName(model, "Line3D"),
                classPoint3D = Engine.x86_64.GetClassByName(model, "Point3D");

        //
        //  Object Properties (relations)
        //
        Int64   propertyObjects = Engine.x86_64.GetPropertyByName(model, "objects");

        //
        //  Datatype Properties (attributes)
        //
        Int64   propertyCoordinates = Engine.x86_64.GetPropertyByName(model, "coordinates"),
                propertyLength = Engine.x86_64.GetPropertyByName(model, "length"),
                propertyPoints = Engine.x86_64.GetPropertyByName(model, "points"),
                propertyRadius = Engine.x86_64.GetPropertyByName(model, "radius"),
                propertySegmentationParts = Engine.x86_64.GetPropertyByName(model, "segmentationParts");

        //
        //  Instances (creating)
        //
        Int64   instanceCollection = Engine.x86_64.CreateInstance(classCollection, (string) null),
                instanceCylinder = Engine.x86_64.CreateInstance(classCylinder, (string) null),
                instanceLine3D = Engine.x86_64.CreateInstance(classLine3D, (string) null),
                instancePoint3D_I = Engine.x86_64.CreateInstance(classPoint3D, (string) null),
                instancePoint3D_II = Engine.x86_64.CreateInstance(classPoint3D, (string) null);

        Int64[] objects = { instancePoint3D_I, instanceLine3D, instanceLine3D, instancePoint3D_II, instanceCylinder, instancePoint3D_I };
        Engine.x86_64.SetObjectProperty(instanceCollection, propertyObjects, ref objects[0], 6);

        double[]    coordinates_I = { 1.0, 2.0, 3.0 },
                    coordinates_II = { 4.0, 5.0, 6.0 },
                    points = { 0.0, 0.0, -1.0, 5.0, 3.0, 0.0 };
        double      length = 4.0,
                    radius = 2.0;
        Int64       segmentationParts = 36;

        Engine.x86_64.SetDatatypeProperty(instanceCylinder, propertyLength, ref length, 1);
        Engine.x86_64.SetDatatypeProperty(instanceCylinder, propertyRadius, ref radius, 1);
        Engine.x86_64.SetDatatypeProperty(instanceCylinder, propertySegmentationParts, ref segmentationParts, 1);
        Engine.x86_64.SetDatatypeProperty(instanceLine3D, propertyPoints, ref points[0], 6);
        Engine.x86_64.SetDatatypeProperty(instancePoint3D_I, propertyCoordinates, ref coordinates_I[0], 3);
        Engine.x86_64.SetDatatypeProperty(instancePoint3D_II, propertyCoordinates, ref coordinates_II[0], 3);

        Int64   myInstance = instanceCollection;

        ...
        ...     //  create, load or edit myInstance, in this case a simple Collection is used as input
        ...

        //
        //  Initializing the mask with all possible options
        //
        Int64   setting = 0,
                mask = Engine.x86_64.GetFormat(0, 0);

        setting += 0 * flagbit2;        //    SINGLE / DOUBLE PRECISION (float / double)
        setting += 0 * flagbit3;        //    32 / 63 BIT INDEX ARRAY (int32_t / int64_t)

        setting += 1 * flagbit4;        //    OFF / ON VECTORS (x, y, z) 
        setting += 1 * flagbit5;        //    OFF / ON NORMALS (Nx, Ny, Nz)

        setting += 1 * flagbit8;        //    OFF / ON TRIANGLES
        setting += 1 * flagbit9;        //    OFF / ON LINES
        setting += 1 * flagbit10;       //    OFF / ON POINTS

        setting += 0 * flagbit12;       //    OFF / ON WIREFRAME FACES
        setting += 0 * flagbit13;       //    OFF / ON WIREFRAME CONCEPTUAL FACES

        Int64   vertexElementSizeInBytes = Engine.x86_64.SetFormat(model, setting, mask);
        System.Diagnostics.Debug.Assert(vertexElementSizeInBytes == (3 + 3) * sizeof(float));

        ...

        Int64   vertexBufferSize = 0, indexBufferSize = 0;
        Engine.x86_64.CalculateInstance(myInstance, out vertexBufferSize, out indexBufferSize, (IntPtr) 0);

        if (vertexBufferSize != 0 && indexBufferSize != 0)
        {
            float[] vertices = new float[vertexBufferSize * (vertexElementSizeInBytes / sizeof(float))];
            Int32[] indices = new Int32[indexBufferSize];

            Engine.x86_64.UpdateInstanceVertexBuffer(myInstance, ref vertices[0]);
            Engine.x86_64.UpdateInstanceIndexBuffer(myInstance, ref indices[0]);

            Int64   triangleCnt = 0, lineCnt = 0, pointCnt = 0,
                    conceptualFaceCnt = Engine.x86_64.GetConceptualFaceCnt(myInstance);
            for (Int64 index = 0; index < conceptualFaceCnt; index++)
            {
                Int64   startIndexTriangles = 0, noIndicesTrangles = 0,
                        startIndexLines = 0, noIndicesLines = 0,
                        startIndexPoints = 0, noIndicesPoints = 0;

                Engine.x86_64.GetConceptualFaceEx(
                        myInstance, index,
                        out startIndexTriangles, out noIndicesTrangles,
                        out startIndexLines, out noIndicesLines,
                        out startIndexPoints, out noIndicesPoints,
                        (IntPtr) 0, (IntPtr) 0,
                        (IntPtr) 0, (IntPtr) 0
                    );

                //  
                //  Calculate space required for arrays
                //
                triangleCnt += noIndicesTrangles / 3;
                lineCnt += noIndicesLines / 2;
                pointCnt += noIndicesPoints;
            }

            Int32[] triangleIndices = (triangleCnt != 0) ? new Int32[3 * triangleCnt] : null,
                    lineIndices = (lineCnt != 0) ? new Int32[2 * lineCnt] : null,
                    pointIndices = (pointCnt != 0) ? new Int32[pointCnt] : null;

            Int64   triangleIndicesOffset = 0, lineIndicesOffset = 0, pointIndicesOffset = 0;
            for (Int64 index = 0; index < conceptualFaceCnt; index++)
            {
                Int64   startIndexTriangles = 0, noIndicesTrangles = 0,
                        startIndexLines = 0, noIndicesLines = 0,
                        startIndexPoints = 0, noIndicesPoints = 0;

                Engine.x86_64.GetConceptualFaceEx(
                        myInstance, index,
                        out startIndexTriangles, out noIndicesTrangles,
                        out startIndexLines, out noIndicesLines,
                        out startIndexPoints, out noIndicesPoints,
                        (IntPtr) 0, (IntPtr) 0,
                        (IntPtr) 0, (IntPtr) 0
                    );

                if (noIndicesTrangles != 0)
                {
                    Array.Copy(indices, startIndexTriangles, triangleIndices, triangleIndicesOffset, noIndicesTrangles);
                    triangleIndicesOffset += noIndicesTrangles;
                }

                if (noIndicesLines != 0)
                {
                    Array.Copy(indices, startIndexLines, lineIndices, lineIndicesOffset, noIndicesLines);
                    lineIndicesOffset += noIndicesLines;
                }

                if (noIndicesPoints != 0)
                {
                    Array.Copy(indices, startIndexPoints, pointIndices, pointIndicesOffset, noIndicesPoints);
                    pointIndicesOffset += noIndicesPoints;
                }
            }
            System.Diagnostics.Debug.Assert(triangleIndicesOffset == triangleCnt * 3 && lineIndicesOffset == lineCnt * 2 && pointIndicesOffset == pointCnt);

            //
            //  Now the index arrays for triagles, lines and points are ready
            //      triangleIndices
            //      lineIndices
            //      pointIndices
            //  all three are using the same vertex array
            //      vertices
            //

            //
            //  Based on the Collection we should find
            //      
            //
            System.Diagnostics.Debug.Assert(triangleCnt == 36 * 2 + 2 * (36 - 2));  //  The collection contained 1 cylinder (with segmentation parts 36)
            System.Diagnostics.Debug.Assert(lineCnt == 2);                          //  The collection contained 2 lines
            System.Diagnostics.Debug.Assert(pointCnt == 3);                         //  The collection contained 3 points

            ...
            ...     //  use the vertex and index array for visualization, QTO, conversion etc.
            ...
        }

        //
        //  The resulting model can be viewed in 3D-Editor.exe
        //
        Engine.x86_64.SaveModel(model, "c:\\created\\myFile.bin");
        Engine.x86_64.CloseModel(model);
    }
}