- Home /
Issue using a single-mesh with multiple-seperate-components and alphaBlended transparency.
I am using a single mesh, imported as FBX, that is a collection of Z facing facades and planes with a perspective camera translating along the x axis to create a nifty parallaxing effect. The idea is to create a layered environment, kind of like something you would see from a platformer. I thought I ran into this issue here, since it fairly accurately describes my issue. Also, to improve iPhone performance, I'm keeping to an unlit alpha-blended shader. So I followed the lead answer of incorporting this into my camera:
camera.transparencySortMode = TransparencySortMode.Orthographic
No dice. I discovered next, however, that my issue was completely solved by using an alpha-test/cutout shader of any kind, but not the unlit blended shader.
My best guess at the problem may be connected to how I constructed my model. The model is several separate components of polygons, with no geometry connecting them inbetween. My goal is to avoid splitting this model up into separate meshes (since it's fairly heavy in unconnected geometry), so I'm trying to figure out why Unity is having issues sorting these layers according to how I see fit.
Any insight or solutions, anyone? I'll comment with updates as I progress on the issue.
Can you not export them as multiple objects?
A single mesh is not internally Z sorted and so cannot use blended transparency.
I'm simply trying to avoid it for ease-of-use. But why the problem is happening makes sense, thanks.
I'm no expert on modelling packages, but can't you get it to output each of the planes as a sub mesh so that it gets its own renderer? (That's whay would happen with skinned meshes anyway I believe). In that way you would have the layering and still have a single FBX.
Easily. The only reason for not doing so thus far was not believing it to have a different effect on how it was rendered. I'm being told by some colleagues the same thing you are mentioning here, so I'm quickly reconstructing the mesh this way to give it a shot.
Answer by beeeeeepboop · Mar 19, 2013 at 06:28 PM
The solution is to split the facades into individual meshes instead of combined components inside of the exported FBX. Now that this is the case, Camera.transparencySortMode has to be adjusted to render properly.
Your answer
Follow this Question
Related Questions
CustomAxis sort not working between objects placed at different layers rendered by multiple cameras 0 Answers
Transparencies with overlapping bounding boxes (Glass Interior/Exterior) 0 Answers
Transparent objects sorting 6 Answers
Sorting Issue with Alpha Blended and UI 0 Answers
Looking for a transparent shader 0 Answers