Hello,
I’m trying to create a Mesh with the new NURBSGeometry class, but it won’t appear. Did anybody work with this before and point me in the right direction?
I’ve looked into the Away3D NURBS & NURBS Explorer and have used the vectordata of one of the examples. This example is build with an older away3d version though and some of the classes seem to have changed.
My code looks like this at the moment.
var controlNet:Vector.<NURBSVertex> = new Vector.<NURBSVertex>( [
new NURBSVertex( -300, -100, -300, 1),
new NURBSVertex( -300, -100, -150, 1),
new NURBSVertex( -300, -100, 0, 1),
new NURBSVertex( -300, -100, 150, 1),
new NURBSVertex( -150, -100, -300, 1),
new NURBSVertex( -150, -100, -150, 1),
new NURBSVertex( -150, -100, 0, 1),
new NURBSVertex( -150, -100, 150, 1),
new NURBSVertex( 0, -100, -300, 1),
new NURBSVertex( 0, -100, -150, 1),
new NURBSVertex( 0, -100, 0, 1),
new NURBSVertex( 0, -100, 150, 1),
new NURBSVertex( 150, -100, -300, 1),
new NURBSVertex( 150, -100, -150, 1),
new NURBSVertex( 150, -100, 0, 1),
new NURBSVertex( 150, -100, 150, 1)] );
var nurb:NURBSGeometry = new NURBSGeometry( controlNet, 4, 4, 4, 4, 15, 15 );
meshObject = new Mesh(nurb, planeMaterial);
nurb.refreshNURBS();
view.scene.addChild(meshObject);