A Unity ID allows you to buy and/or subscribe to Unity products and services, shop in the Asset Store and participate
in the Unity community.
Discussion in 'Assets and Asset Store' started by eagle555, Oct 24, 2017.
Thanks for reporting this. I will take a look now and try to fix this issue asap
Sweet, I'm happy to hear that and can't wait for the fix!
So basically the issue was missing tangents on one mesh, and MCS put black values there instead of default 1, like reported before. I forgot to implement this fix. I will fix it and make MCS automatically refresh it's mesh cache when changing import settings on a mesh and put a log warning if one of the meshes is missing e.g. tangents or vertex colors compared to the rest.
Thanks for the fantastic support @eagle555 ! Amazing asset, keep up the great work!
Hi @eagle555 - Thnks 4 the update too.
Is this already implemented in this update?
I also read this in the MCS Ratings. Has this ever been addressed or is it a User Error?
Any plans to improve runtime adding and removal of objects to the combined mesh? Would like to test it as an alternative for trees and compare to gpu instancing.
Geometry removal without colliders is not in the update yet. As for runtime giving different search results. It always worked on my side and I need to know how to reproduce it. The message just means that MCS didn't find anything to combine according to the search rules selected.
Unlike rocks, mesh combining is not good for trees like SpeedTrees, GPU instancing is the way to go. Unless the trees are lower poly meshes that are static (no wind).
Re-combining in runtime is very useful for editors where players can build their own levels out of modular objects. It's something that is on the roadmap to be able to add and remove from a cell and re-combine at runtime only the cells that changed.
@eagle555 I imported the new version and I get the following error on Unity 2017.1.5f1:
Assets/MeshCombineStudio/Editor/MeshCombinerEditor.cs(846,78): error CS0117: `UnityEditor.EditorGUILayout' does not contain a definition for `EnumFlagsField'
outputLayer.intValue = EditorGUILayout.LayerField(new GUIContent("Layer", "The combined GameObjects will be on this layer."), outputLayer.intValue);
#if UNITY_5 || UNITY_2017_1 || UNITY_2017_2
outputStatic.intValue = (int)(StaticEditorFlags)(EditorGUILayout.EnumMaskField(new GUIContent("Static", "The combined GameObjects will have these static settings."), (StaticEditorFlags)outputStatic.intValue));
outputStatic.intValue = (int)(StaticEditorFlags)(EditorGUILayout.EnumFlagsField(new GUIContent("Static", "The combined GameObjects will have these static settings."), (StaticEditorFlags)outputStatic.intValue));
#if UNITY_5 || UNITY_2017_1 || UNITY_2017_2
Seems that Unity changed it since +U2017.3
I will have it fixed in the update, but currently I'm in the middle of it.
Thanks. That worked.
Are we supposed to turn off Unity's Static and Dynamic Batching?
If you with MCS combine in runtime static objects that are marked with `Batching Static` and Unity's static batching is enabled, it will combine those before MCS can do and it will go wrong. So in that case you need to turn it off or disable the Batch Static flag on those GameObjects. Dynamic Batching can be turned on.
I can't get any kind of decent performance from this. I tried out on the Cathedral scene from 3DForge Village Interiors and my frame rate drops to about 12-18 fps from 25-35 fps. My platform is the Wii U so I'm trying to get steady 30 fps , but this actually made it worse.
I think it's a matter of setup, I DM'ed you a message to look into this together.
I think your site is down -- not getting to the documentation page. Was looking into using this for a project but needed a refresher.
Do you have any videos showing how to set this asset up properly?
The site and documentation link works on my side. Does anybody else has this issue?
I don't have any tutorial videos yet, but I'm working on a major update (overlapping geometry removal on e.g. rocks to be able to make performant caves and overhangs) and once I finish that I will make tutorial videos.
I'm making good progress with the new MCS update which will have a free extension called `MCS Caves & Overhangs`, basically has the feature to remove overlapping geometry to optimize rocks to the max. There's other use cases for it but this is the most obvious one I can think of.
I opened a new thread for it here and made a video showcasing it
I submitted a new MCS 1.4 update to the Asset Store:
Displays amount of materials found
Displays combine time
Destroying MCS GameObject will restore original meshes
Added progress bar for combining per frame mode
Cells pivot are at cell center instead of Scene origin
Automatically unpack MCS prefab in +U2018.3 to make inspector more responsive.
Hang on combine jobs
Loosing reference to original objects when Unity re-serializes
Loosing combine specs when Unity re-serializes
First click "Search Button", then make a change on the original objects and then click "Combine" button wouldn't include the change.
A LODGroup was added to cells with only 1 lod level.
Fixed Combine ready event being called multiple times if combined mesh exceeded 65k verts
Canceling combining in per frame mode didn't work correctly.
Multi-threaded combining per frame sometimes didn't execute.
LOD objects sometimes didn't get combined because their individual bounds were taken into account which could lead to being in another cell.
Also the free extension MCS Caves & Overhangs is ready and works now with LODs, and will submit that as well.
Hello eagle555 !
Is it possible to "un-combine" an object by name ?
For instance if I would like to animate a 3D object wich is combined.
Is the API allow to find a combined sub-object by name and "un-combined it" ?
What MCS does is uncombine all submeshes and recombine everything that has the same material. Otherwise they will be separate GameObjects. So yes you can use MCS to uncombine a submesh by putting another material (in the Mesh Renderer component) on it then the rest of the sub meshes (which is most likely already the case, as submeshes are meant for different materials).
Yesterday I submitted MCS Caves & Overhangs to the Asset Store. Also I submitted new version of MCS which I decided to name version 2, because I think the overlap removal feature is a major feature that as far as I know hasn't been done before. And it makes things possible that were not easily possible before.
Remove overlapping geometry (in form of free extension)
Automatically disables original colliders if "Add MeshColliders" option in enabled.
Also I will add more major features next week:
* Splitting a mesh into cells, if you have e.g. like one big 32 bit mesh. So instead of cell combining based on objects position it will just add all triangles of the same materials to it's proper cell, this can lead to better culling. We need this feature for our pre-made arena buildings and terrain which are currently one mesh.
* Optimizing the shadows with being able to combine different materials into 1 mesh with the above mesh splitting feature, as shadow casting only needs 1 shader.
* Leaving original meshes on shadow cast only in the case of point light and spot light shadows. As mesh combining is good for normal drawing and directional light shadows, but it's not good for point/spot light shadows, which can lead to an explosion in vert / triangle count to draw (because the bigger meshes are not good for point/spot light shadow culling). This is probably the major reason why some report performance drops instead of increasing after combining. I will also go in depth in the documentation about this. With real-time point/spot lights in forward rendering it has the same issue and this cannot be solved with combining. So either all lights would need to be baked or switching to deferred rendering would be needed.
* Improve the GUI a bit.
After that I will start make tutorial videos and update the documentation to go more in detail where combining is good and gotchas to take into account.
P.s. our artist made a new cave arena, think it looks stunning. I exchanged the screenshots on the MCS Caves & Overhangs thread:
Awesome, thanks for the update. Glad to see you are back. : D
I tried to change the material at the Run Time but it didn't uncombine the object.
Maybe there is a function to launch in order to update ?
You need to do it in the Editor. MCS creates new GameObjects with meshes that are children of the MCS prefab. So can use these as replacement.
Thanks for your answer !
I tried the following steps :
1 => Config :
2 => Play the scene
3=> Select in the viewport the object I want to unCombine (which is indeed a child of MeshCombineStudio/LODGroup 1/Cell (0,0, 0,0, 0,0))
4 => Apply a new material to its MeshRender component.
5=> The material changes but the object is still combined.
Thanks for your help.
Subsidiary question :
Are instances well handled by MCS ?
Do it like this in Unity Editor (not Play the Scene):
Can see the buildings has 3 sub-meshes.
Use these settings. Disable where I put the X. Then click "Combine" button and you will see that the sub-meshes get uncombined and they are inside the MeshCombineStudio GameObject.
Whenever I combine on runtime (default settings) it seems to successfully combine but also spawns these errors which stop the game from working;
- Unity 2018.3.4f1
- Default settings for mesh combiner, except for "on runtime" enabled
- No objects are static, static batching is disabled
Thanks for reporting. It's a debug message for testing I overlooked to comment out (it's only triggered in certain cases). You can comment out the Debug message and it should be fine. I will remove it for the next update.
Since the last update, I can't use the Mesh Combiner without crashing Unity =(
Can you show me a screenshot of your settings in MCS? Also does it hang Unity or Unity crashes?
MCS Caves & Overhangs just got accepted on the Asset Store!
@eagle555 - Awesome news!
I'm just playing around with the demo Scene and it seems to be a huge boost. Now there is only one thing I'd love to see in MCS: Automagic Texture Atlasing - any chance you will add this feature in the (near) future?
Thanks for the great update and keep up the good work!
Yes the performance gain is unbeatable, GPU Instancing is magnitudes slower.
Seems that free doesn't get good ranking on the Asset Store which I wasn't aware of, since I never tried it before.
I'm trying to recover my sales / reputation a bit, so I'm able to put more time into the Asset Store again to continue with major updates with new features, improvement and fixes for my Assets as I have many cool ideas.
Normally when releasing a new Asset with this amount of downloads I would reach top ranking. So I decided to ask 12.50 for the MCS Caves & Overhangs extension. It's still is under-selling to what can be adhieved with it. I submitted the change to the Asset Store and you can still download it for free for another 3.5 hours.
I (and probably many others) would be glad to support asset creators through something like Patreon.
I think that it could be a good way to make sustainable the assets we already own.
Have you considered it?
Interesting idea, will think about it.
I don't have patrion. I will stick with the assetstore, even with its downsides
@eagle555 - Please, can you add texture atlasing for our combined meshes?
Could you please elaborate why?
It's something that would be cool to add, will look into this.
4000 rocks instanced with Graphics.DrawInstancedIndirect (fastest way of doing it):
GPU instancing is always slower than combining (it has some additional overhead), it can be a bit more efficient with culling so it would need to disregard less triangles out of the camera frustum, but that doesn't help that much also culling itself costs, that's why e.g. Vegation Studio uses cells for culling, basically the same as MCS does. So if MCS reduces the rock geometry to only one third (so 33% of the original), then it will give at least 3x the fps that you would get with GPU instancing. As with instancing you can't remove individual triangles from each rock.
Interesting. Thanks for the insight!
MCS Caves & Overhangs is available again on the Asset Store.
Hi, thanks for the great tool, it greatly simplifies and speeds up the process. The only thing that is still missing is texture atlasting. Really looking forward to.
I have a simple demand for the next release
In the MeshCombiner script, is it possible to add a "Use Component Filter" with the condition "not" inside the Search Option area.
Because I have some animated gameObjects with an "Animation" component. As far as I understand, these objects can't be properly animated when combined. Si I decided to combine all the static objects without the animated ones.
Thank you and have a nice day,
Good request, will add that in the next update
Now i have a silly question: When making prefabs from saved combined meshes, do we make it from the MCS parent game object (with the MCS Script) or create it from the child object (named: "cells") ?
Make it from a child. There's not need to include the MCS script for it.
Got another demotivating review today...Luckily I was able to contact and he removed it.
If you haven't made a review yet, maybe you can help to put MCS in more positive day light.
P.s. I'm currently working on adding the features I promised to MCS 2 which will take it to the next level.