Home > other >  Grid model is decomposed into a cube
Grid model is decomposed into a cube

Time:09-28

Is there anyone can be a grid model all broken down into small cubes, or sphere method,

CodePudding user response:

Yes, obtain model data, according to the vertex coordinates of the information such as surface, according to your needs, generated a cube or a small sphere, generated by the method is to instantiate an empty object, add a MeshFilter components, obtaining the components, data access model, add vertex for the model, surface, normals, texture,,,, add a Render components, this model shows, the advantage is you can create lifelike dissolution effect, even after the collapse is not necessarily a bunch of little cubes, but various random shape of an object, even after the collapse of local appearance, can maintain the original object, but, but efficiency is not high!!

You can advance the small cube precast body, when it comes to an object, the disintegration of the destroyed or hidden to the dissolution of the object first, then according to the need to instantiate a certain number of small cube precast body to go,,

CodePudding user response:

reference 1st floor sdhexu response:
yes, obtain model data, according to the vertex coordinates of the information such as surface, according to your needs, generated a cube or a small sphere, generating method is to instantiate an empty object, add a MeshFilter components, obtaining the components, data access model, add vertex for the model, surface, normals, texture,,,, add a Render components, this model shows, the advantage is you can create lifelike dissolution effect, even after the collapse is not necessarily a bunch of little cubes, but various random shape of an object, even after the collapse of local appearance, can maintain the original object, but, but efficiency is not high!!

You can advance the small cube precast body, when it comes to an object, the disintegration of the destroyed or hidden to the dissolution of the object first, then according to the need to instantiate a certain number of small cube precast body went,,
ok, thank you for your answer, my foundation is bad, feel or need a related project or case tutorial under reference, if you have any case teaching link to share, or even better, thank you very much for your reply!
  • Related