Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by DEtH_MoroZ · Mar 19, 2011 at 05:09 PM · meshcombinecalculatetrisverts

Decombine script or recalculate part of mesh?

hi there. im looking for solution for pretty complicated problem, this tool may rly help me. so, the question is:

is there some kind of "decombine" script? (for example get a part of mesh and assign it to another mesh filter)

i need it cos i want to add some triangles to pretty huge model via runtime, and may be "decombine" will be nice solution. (get part of mesh, change ammount of triangles, combine it back)

tyvm for all responds :)

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
0
Best Answer

Answer by Peter G · Mar 19, 2011 at 05:23 PM

Creating a new mesh from part of another mesh provides some interesting difficulties:

  1. Creating a new mesh is as easy as var mesh = new Mesh();.

  2. Another task is getting the vertex arrays from the first mesh. If you are simply doing a distance check, then it isn't very hard. If you want complex shapes, then you will have to to find an algorithm that isolates only the vertices you want- maybe use vertex color.

  3. Recreating the triangle arrays is probably going to be the hardest part. If you are lucky and removing a submesh, that will save you some time. Otherwise. Same as above. You will need to procedurally recreate the triangle indices.

Decombining a mesh won't come easily. Your best option would be to store the vertex and triangle indices before you combine the mesh so that you can take it apart more easily.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image DEtH_MoroZ · Mar 19, 2011 at 05:34 PM 0
Share

tyvm :) im getting triangles i want to use by spherecastall, but problem is that im creating new triangles and assign them back, its takes alot of time.

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

No one has followed this question yet.

Related Questions

Bunch of Cubes. How to reduce tris/verts? 0 Answers

add verts and tris to interactive cloth 1 Answer

On combining two objects to reduce draw calls ... 3 Answers

In my game, the tris count is 70k and verts count is 130k and with 120 draw calls... how to optimize it. to make to run on low end android devices 1 Answer

Combining Meshes, mesh combine a simple working example 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges