How to remove border on creating (rectangle) custom mesh/

(imageWidth/


        const width = scalingFactor * 
1000)
        const height = scalingFactor *  (imageHeight/1000)

        // Setup the box mesh info
        // prettier-ignore
        const boxVertices = [ 0, 0, 0,      width , 0, 0,       0, -height, 0,
                              width, 0, 0,  width, -height, 0,  0, -height, 0 ];

        const boxUvs = [ 0, 1,        1, 1,           0, 0,                     // Bottom-left
                         1, 1,        1, 0,           0, 0 ];
        
        let boxCreationFlags =
            Communicator.MeshInstanceCreationFlags.Invisible |
            Communicator.MeshInstanceCreationFlags.DoNotLight |
            Communicator.MeshInstanceCreationFlags.ExcludeBounding

        const scaleMatrix = new Communicator.Matrix()
        const textWorldHeight = await this._calculateTextBoxHeight()
        scaleMatrix.setScaleComponent(textWorldHeight, textWorldHeight, 1.0)
        
        // Let the system continually rotate the text for us
        boxCreationFlags |= Communicator.MeshInstanceCreationFlags.ScreenOriented
        boxMatrix = scaleMatrix
      

        // Setup the mesh instance data now. No color required since we're going to
        // place a texture over the entire face
        const boxMeshData = new Communicator.MeshData()
        boxMeshData.setFaceWinding(Communicator.FaceWinding.Clockwise)
        boxMeshData.setBackfacesEnabled(false)
        boxMeshData.addFaces(boxVertices, undefined, undefined, null)

        const boxMeshId = await this._viewer.model.createMesh(boxMeshData)
        const boxMeshInstanceData = new Communicator.MeshInstanceData(
            boxMeshId,
            boxMatrix,
            "box",
            null,
            null,
            null,
            boxCreationFlags
        )
        const boxNodeId = await this._viewer.model.createMeshInstance(
            boxMeshInstanceData
        )

Hello @raja.r,

It looks like the code snippet you referenced is similar to the 3D Text Insertion example included in the quickstart module. Does your code also include the function:

boxMeshData.addPolyline(lineVertices, void 0);

Thanks,
Tino

no this function not included. what is the lineVertices? for rectangle

The 3D Text Insertion example is the same as I had referenced in your previous post. Are you not able to view this example? The entire code for this example is provided in HOOPS_Communicator_2024.X.0\web_viewer\examples\scripts\examples\text_insertion.js.

A meshData object does not have a polyline by default. So somewhere in your code, you are calling the addPolyline function.