Hi,
I’m a newbie and tried the PathExtruder. I have made a pipe and want to close the ends so that you can’t see inside. I didn’t found code for that and now i want to create a face at start and end. I filled a face with vertex data and want to apply it ti a mesh. But the AddFace-Method
is not available in Version 4. Does someone have experience with that?
Thank you .
Here is an example code:
var profile:Vector.<Vector3D> = new Vector.<Vector3D>();
// profile of pipe
profile.push(new Vector3D(0,0,0));
profile.push(new Vector3D(50,0,0));
profile.push(new Vector3D(50, 50, 0));
profile.push(new Vector3D(0, 50, 0));
//create pipe
//....
// Now create start and end
var shape:Face = new Face();
var i:Number;
var mesh:Mesh;
for (i = 0; i < profile.length; i++)
{
shape.setVertexAt(i, profile.x, profile.y, profile.z);
}
mesh = new Mesh(area, m_DefaultMaterial);
// not available in version 4
//mesh.AddFace