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 larsbertram1, Aug 19, 2014.
Works perfectly now with the include, no fluttering bark weirdness.
Hi Lars, small update. I'm not sure what changed but I no longer have the light limit problem with URP. I had to reimport CTI and apply all the proper updates but it's performing fantastically.
I was wondering, is there any way to add a shader option to fade out leaf geometry as it becomes perpendicular to the camera view? I'm generally happy with the stylized look I've got, but that would be the last piece of the puzzle. Thanks.
Can anyone suggest any tips or a tutorial on creating normal maps that will work in CTI? I think I am having issues packing the different channels. All I really want is normals but I am getting a very shiny surface in addition to the texture that the normal provides. I have photoshop but I'm not clear on how to get the right values in the right channels.
it is straight forward:
take a regular normal map.
copy its red channel into alpha.
set the red channel to a constant value like 51. this defines the specular!
set the blue channel to 255. this is ambient occlusion.
important: make sure the texture is imported with sRGB texture unchecked.
Thank you Lars. That helped but my issue turned out to be with the albedo for the bark. I had an alpha that was 100% and the bark was smooth. I'm still figuring out the topic of packing obviously. Thanks again!
Now that the HDRP is out of preview I finally started to experiment with it. I found out that with the latest Unity 2019.30f6 with HDRP 7.2 the shaders seem to work but the scene view flickers to black if the post processing is on in that scene view. In game view it seems to work fine. BTW are you planning to update the bark array shader too? Oh and I'm talking about the demo HDRP scene.
this should be fixed soon. or do it yourself:
open the bark shader and find:
normalOut.z = sqrt( 1 - dot(normalOut.xy , normalOut.xy ) );
repalce it with:
normalOut.z = sqrt( saturate( 1 - dot(normalOut.xy , normalOut.xy )) );
Thanks! That did the trick!
I have been experiencing some very weird behavior with latest version of cti in unity 2017.1.
Firstly, it seems that enabling instancing on cti materials actually makes the performance a lot *worse* on some occasions, secondly, some of my plants move in unison when instancing on the materials is *disabled*.
Basically, all the plants sway across the terrain as if they are part of a large chunk, with the pivot of the swaying being an arbitrary point in the middle of the plant cluster.
If it helps, this happens with the LOD1 in plants imported as terrain trees, but not with LOD0 or when the plants are placed by hand.
It also happens only during play, not in the scene view.
Have you experienced anything like this?
In any case, it's not a real issue, since instancing seems to work fine in most other occasions, it's just weird that it happens with some plants but not others, which have seemingly the same tags and LOD structure.
nope, anybody else?
Very strange. Been a while since I used 2017 so can not do any in depth testing. Would say round up the usual suspects.
Make sure no static batching, try disabling dynamic batching in Player Settings.
Check if LOD/wind fade is enabled on the shader. Maybe an error on that in 2017? Disable if it is enabled.
Can not think of much more than that for this issue.
So it's gotta be something to do with the buggyness of Unity 2017?! I didn't have this issue either but 2017 have been doing some weird stuff for me two but they work in other version.
Never figured out the issue.
Nevertheless, I can't imagine why I would need to disable instancing for now, so it's fine.
This is what I'm working on.
CTI looks great, as always!
Wow! Very beautiful scene man
looks great – but i will never understand why the top branches of fir trees should point downwards
Hah, admittedly, they shouldn't.
But I frankly don't like the look of sparse, sad Christmas tree-looking treetops of large/old conifer trees, and I liked what they did with their trees in Days Gone, so I went with something similar.
I try many way but Blenedr export doesn't work. The CTI do not create the CTI file from fbx that export from Blender 2.8
i am not a blender user... do you get any errors in the console?
No error . I just drag and drop fbx in Unity asset folder . THe unity just download it.
Btw which software do you use to make a 3d model?
have you named the fbx properly? like "MyTest_afsTREE.fbx"?
then you should get a prompt in the console that the importer has been triggered.
I try to put _afsTREE infront or behind or _afsTREE alone but it does't work. I used to make it work long time ago but in Blender 2.8 may have the problem with exporting
I wil try again soon with older version of blender. Is it automatic convert if I put the name afsTree like this?
the importer looks for assets containing "_afsTREE".
Yes I follow the guide . But it still doesn't work.
Can you test my fbx file? I have a simple object.
Oh thank you so much
This is my tree from blender 2.80 and 2.81
i justed checked the first model.
and i got the following error in the console:
Your Model contains too many/too little materials or bark and leaf materials are not named properly.
checking the tree in maya showed that the leaf and bark materials aren't named properly.
so rename your materials and try again
My tree is work now but got a problem. Why when main wind intensity value is higher. the leaf and the branch move separate too far from the trunk? I use Unity 2019.3
here is my tree
sorry, but i do not have to time to look into your files, but you may have to freeze the transforms to get it working properly.
oh thank you.
Hello. I work in Maya the tree is work great with the Importer even I don't freeze the transformation of child.
But in Blender . The child don't link with parent. When the wind blow. Leave and brach will separate from trunk even I freeze all transform.
Any idea to solve this?
Probably a rotation issue. Blender is fun to get the rotation right in Unity. What I do and it works most of the time is have the empty gameobject 'root' rotated x90 y00 z00 and the rest of the tree reset rotation and scale reset to 0,0,0(CTRL+A). If doing the rotation to the root make sure to unparent the trunk and then reparent after the gameobject is rotated.
Rotation issues tend to be the biggest problem I come across with Blender to CTI
tahnk you so much. I will try it soon
And can you share your fbx export setting?
Hi @larsbertram1, have you had a chance to try out the tree shaders with URP and 2020.1? I'm noticing some weird visuals particularly where the shadow cascades transition. Thanks.
Perhaps related to this? https://forum.unity.com/threads/shadow-cascades-weird-since-7-2-0.828453/
It work perfectly!! Thank you for share your experience and tip.
Glad it worked!
Sorry did not see this question. I just use the default settings with Selected Only enabled. Just in case you have lights or additional objects in the file.
Hi @larsbertram1 , sorry to bump this but I'm still having issues with URP shadow cascades and the CTI shaders. I was wondering if it's related to this issue here: https://forum.unity.com/threads/shadow-cascades-weird-since-7-2-0.828453/
Or possibly here: https://forum.unity.com/threads/shadow-artifact-on-grass-with-urp-fix-included.844777/#post-5709928
Visually it looks like a non-shaded blocky strip where a shadow cascade transition occurs. This is with the latest versions of URP, and unfortunately isn't being resolved with subsequent iterations. Thanks.
i will have to look if i ever updated ctito urp 7.2. and above. i doubt...
Hi, im having issues with bark normals... having the normal strength above 0 causes vissible seams and wierd lighting.
i suspect its down to how im generating the UV map for the bark. im currently modeling my trunk then marking seams and unwrapping in bits. i guess i should be starting with a simple cylinder that is unwrapped to use a tilable texture, is this correct?
Any guidance on proper workflow for bark UVs would be great
hmm, creating several uv shells should be fine. but you have to make sure that your tangents are fine in case you use normals. do oyu let unity create proper mikkt space tangents on import?
Yes tangents are set to calculate mikktspace
how do the normals look in the frame debugger?
I may have fixed it. had some issues with my initial normal bake, so fixed this in blender.
Now if i import as a standard normal map it seems to work correctly.
using non srgb or Normal Map (GA) Occlusion (B) maps causes issues tho. is this expected in HDRP?
All working as far as i can tell anyway so im happy, thanks for the help
And I must say it's a really cool trick to not add any more keywords and I wish more developers would do that. Keyword limit has been my problem for a few years now. Introducing local_shader_features may be a scalable solution but it's also a very bad solution as it doesn't change much; part of asset developers don't know about it, another part doesn't care, yet another part doesn't update their assets anymore. And converting shader featurs to local manually after every asset update is a pain in the ass. I don't really know how maximum shader limit affects performance, but I would rather see it set to some very large value that's little likely to hit (like i.e. 2048 or smth).
Anyway back to CTI:
I have added "use wind from script" feature to CTI tree creator shaders and it seems to work. So unless there is some limitation I'm not aware of, I propose adding it to the next update of CTI.
Is anyone else seeing these types of shader errors with Universal RP 7.3.1? I've tried deleting my Library folder and reopening my project, but that didn't work.
I figured out that I need to replace "com.unity.render-pipelines.lightweight" with "com.unity.render-pipelines.universal" in all the files in the Shaders folder. Well I did that but I get another strange shader message in my bark shader, so somethings still not right. Has anyone seen this error before? Now I'm really stuck.
With our CTI trees set up with Vegetation Studio Pro, I'd like to use VSP billboard tree wind, but those billboards move out of sync with the CTI mesh tree wind, so the mesh<>billboard transition is jarring. I asked Lennart and he said: "The wind on the billboards are based on the HD wind algorithm found in the HD.Lit shader. The same as NatureManufacture uses for their trees. If the tree uses another wind math it will not be synced." What does CTI use? I see in the CTIShaderController for VSP, there is a line: BillboardHDWind = true,...so I thought it would work... any insight on how to make the mesh and billboards in sync with the wind movement?
cti does not use the hd wind.
so you will have to hack the vsp billboard shaders to sync mesh and billboard trees based on the wind implementation in the original cti billboard shaders.