1

I'm creating about 12,000 + BoxHelpers and the loading and, specially, the navigating is very slow. I want to know if there is a better approach

this is what I have

    var c=[];
c.push([    -100,15,285 ]);
c.push([    0,25.5,285  ]);
c.push([    0,51,285    ]);
c.push([    0,76.5,285  ]);
c.push([    0,0,297 ]);
c.push([    0,25.5,297  ]);
c.push([    0,51,297    ]);

.... this is for example only. actual data comes from json.

var cubeGeometry = new THREE.CubeGeometry(10, 24.5, 12);


  for (var i in c)
        var cube = new THREE.BoxHelper();
    cube.material.color.set( 0x6666FF    );
    cube.scale.set( 5, 12, 6 );
    cube.position.set(c[i][0], c[i][1],c[i][2] );
    scene.add( cube );
    }

May be creating the whole building then just add the building to the scene? but I dont even know how to do start.

1 Answer 1

1

You wanna create a Building out of thousands of objects?

If I get it correctly: - Create the Building in Blender and import it, or - Create the Building out of ONE Geometry with thousands of vertices and faces

Can you upload an example Code in jsfiddle?

Sign up to request clarification or add additional context in comments.

1 Comment

Thanks. I use the merge function in Three.js to accomplish what I wanted.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.