- Home /
Other
How to make a Line Renderer thin out only near the ends? Alternatively, how to apply 3-way slicing?
So I'm using a Line Renderer to make a dynamically changing floating jungle vine in a jungle scene in a 2D game. I want the vine to thin out near both ends for x length until it reaches y thickness, while being y think in the middle and everywhere else. Currently I am using a very long image where the vine thins out near the end, however as the length of the vine increase or shortens so does the shortening length (x).
Is there any way to apply a "sliced" method to the Line Renderer's image material, such as what we can do in UI Image?: https://www.youtube.com/watch?v=WFQcc1GUe7U#t=1m15s
Or, is there a way to determine the Line's image coordinates?
Don't ask multiple questions in one.
Other than that, I agree with Fattie.
Heh right ...
say OP you may consider using Vectrosity
which is used by pretty much every Unity engineer,
https://www.assetstore.unity3d.com/en/#!/content/82
I'm not sure if it solves your particular need
finally you should add a screen-shot of your scene to give people an idea
Answer by Fattie · Jan 15, 2016 at 02:22 AM
LineRenderer is little more than a tool useful for debugging and "hello world" test apps by learners. I would really just forget about it and find a way to do it properly.
Thanks Fattie, yeah I'll just make my own line renderer for 2D since I'll have a lot more control especially with UV coordinates.
Follow this Question
Related Questions
GIT seems to be losing some scene data 1 Answer
Image vs Sprites performance 1 Answer
When I load image it dissapears 2 Answers
Possible to use sprite mesh for UI.Image GraphicRaycaster culling? 1 Answer
Sprite behavior in Image component 0 Answers