Jump to content

Optimization scene help (thousands of cubes)


valx76
 Share

Recommended Posts

Hey everyone,

 

I'm trying to create a warehouse viewer app.

I need to display A LOT OF meshes (I'm using only deformed cubes). I tried the optimization processes I saw in the tutorials, but I'm probably missing something, because my scene is slow (5 fps)..

I'm currently using instances, I saw it was normally the best idea in my case (all the mesh will stay in their position, no move, no transform, no material change).

Is it the right choice ? I tried with cloned objects too but the result was worse in my case (or I was doing something wrong?)..

 

NOTE : I'm using "scene.pick()" which is using apparently a lot of CPU (or GPU), because in the app I will use the mouse lock API (and use the screen's center as the cursor).

 

Here is the playground : http://www.babylonjs-playground.com/#KDCLN#3

I also have a bug on the floor, the shadow-like things, I don't know what it is, if someone has an idea..

 

Thank you guys :)

Link to comment
Share on other sites

Hey guys,

 

I really need to know if I can achieve that with BabylonJS with a reasonable FPS count or if I should try something else (like a desktop app).

Basically, I just need to be able to display like 100.000 cubes of 4 different types (1 type = 1 color) with LOD and picking on like 50.000 cubes.

NOTE: I don't need textures, PostProcess effects, animations, etc. Just to display colored/transformed cubes I can hover/click on and move around without too much lag.

 

Thanks for your help

 

EDIT: Sorry for the double post, I wanted to edit, and I can't remove the post ; Sorry for that..

Edited by valx76
Link to comment
Share on other sites

well, 100K cubes is quite a big number of 3D shapes for any webGL engine

but, althought it's near the reasonable limit, maybe could you have a look at these feature : http://doc.babylonjs.com/overviews/Solid_Particle_System

after have read thses posts where someone had the same goal than you :

Remember also that if 100K is a high value for the CPU, 80 or 75K instead make a real difference in term of FPS... whereas the user eyes won't probably see the difference because we can't really "see" 100K objects at once in the same screen.

Well, the idea is to lower the total number is the performance doesn't fit your need to fake the big number of instances, knowing that the user can't see everything in the same time.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...