Комментарии:
I'm using an overlay camera for my weapon which is added to my main camera's stack and for some reason it is rendering the lines through my weapon. Making it feel transparent. Any idea why this would be happening?
ОтветитьAny to make it so that it doesn't place the outline on where the model gets shaded? Thanks!
Okay, it's probably due to the low poly count, but please answer my question still. Thank you!
P.S. Let me clarify: I don't want the outline separating colors of different brightness values if they have the same hue and saturation values. Let me know if that's possible!
Hi, Do you know If I can somehow get shadow information into the shader graph as well? I want to add outlines to all the shadows as well, if you know of any resources please let me know. Also Thank you for making this tutorial it still works in the 2022.2 version with some changes:)
ОтветитьHi, I'm using Unity 2022.2.21, I followed the tutorial, and the outlines are showing, but now there is no color except white and black outlines. Any idea on why this is happening? Great tutorial btw :D
Ответитьunfortunatly doesnt work now :/
ОтветитьI've been fighting with this shader for a while now, and I have an issue I just can't seem to figure out a solution to. Specifically, this sobel implementation has a minimum outline thickness of two pixels, which is annoying when you're attempting to use it in pixel art applications. Is there a way to make the sobel filter not generate an outline when the depth texture at a given pixel is higher than its neighbors (Such that outlines only generate "behind" objects).
ОтветитьHi there! First of all i wanted to thank you for this amazing tutorial, I know its a bit late but I have a question! How can I exclude certain gameObjects so they dont have this render feature? I really want to use this method but i keep getting some weirds outlines on certain objects! Thanks again :)
ОтветитьThis doesn't work with 2021.3? Followed the tutorial to the T, but no outlines show up.
ОтветитьI made the sobel function a bit more general so that I could feed it my own textures. But I was struggeling a while to get it working and I thought if the docs tell me UVs need to be normalized why are we using whole integers to offset it... So turns out I needed to use a screen node and use those values to normalize the offsets by dividing them. Maybe this will help someone who stumbled on to the same problem
ОтветитьThis tutorial helped me a lot in my game development.
ОтветитьNice video, really informative. I'm currently stuck in 2021.2.10f1 with trying to apply it to the entire scene. The outlines are working fine, as they are present as a lighter color of the base color when placing the material on a object, but outlines aren't visible in screen view. I have no errors on the project so I'm imagining I'm missing something somewhere, the material is in the blit material for the render pipeline and post processing is checked on my main game camera. I'm writing this as I'm about to go to bed so sorry if this question isn't written well. Also thanks for answering a lot of these questions in the comments! it's helped troubleshooting a lot here. if you or anyone else could help me here I would greatly appreciate it!
Ответитьi dont get it.... exactly how are you actually getting the unity depth texture? I understand you made a boolean, and i did that too but its not working i just get pure black color everywhere, please advise, thanks in advance.
ОтветитьWorks in 2021.3.11f1
Thank you so much !
It works very well with any low poly models.
Using Unity 2021.3.11f1, the shader keywords text box cant be found in the debug window :(
ОтветитьHey there! I am new to the renderer side of Unity, so I probably did something wrong in the setup - I can't even get the effect to show up in the frame debugger (which I believe it should?). I tried your blit feature as well as the cyanilux one you recommended somewhere. There are no errors, only in your renderpass, there is a warning about the RenderTargetHandle being obsolete. How would I go about debugging this further? The project is in Unity 2022.1
ОтветитьHey man All I have is a black screen when my thickness is zero or less and no outlines with anything above 0. I also did not have the Feature definition option for the DepthTexture Boolean
ОтветитьHello, I am in Unity 2021.3 and I don't have any outline. :/
Also, I can't put any kewords on the materials but the DepthTexture checkbox shows up on the inspector.
Thx in advance for help!
Hello, sir! I'm using a different version of Unity (2022.2) and was wondering if this could be used for unity's Fullscreen Material on Custom Passes? I can't seem to get it working for it.
ОтветитьIf you have black vertical lines going across your screen like i did make sure the input UV in the custom function is a vector2 not a float or vector1
ОтветитьThis method works with models with rigidbody component? Others outline shaders that i have tested don't work on models with rigidbody component
Ответитьhi i did everything you said to do and the outlines are there but the color of my whole map is gone. Where is the problem ?
ОтветитьOMG, so cool! Going to try this
ОтветитьFor anyone trying this in newer Unity Versions: You have to replace the "UV" Node in the shader graph with the "Screen Position" Node.
ОтветитьSo how would I avoid the color effect on the skybox?
ОтветитьNote: Blend node needs to be in overwrite
ОтветитьHey, in the urpasset_renderer inspector there is no option to add the render feature blit material feature. Am I using the wrong version or doing something wrong? On a URP template for 2020.3.2.
Ответитьit doesnt work for me. it just shows big black vertical lines across the screen
ОтветитьHi, I work in Unity 2020.3.30 urp, and followed everything from beginning to end (with the changes in the comments). But the thickness doesn't seem to change no matter how much I change any settings. I checked debug mode and all multiple times, but don't see any difference in thickness. I'm not certain if have to make any changes for Unity 2020.3.30. Does anyone know what could be wrong? Would be a great help.
ОтветитьIt's a shame they've overcomplicated image effect shaders so much. All you used to have to do was pass an image effect shader material to Graphics.Blit().
ОтветитьGreat tutorial and explanation! But has anyone had any luck with Unity 2021.2.13? I should say I get no errors and I've triple checked my keywords.
ОтветитьHey! For those who are using 2020.3, use a "screen position" node instead of a "UV" node for the input on the Custom Function!
The reason is that unity is feeding a render of the UV output of the scene (don't ask me why), instead of what is expected, an UV that goes from (0, 0) to (1, 1) for the screen.
Half the reason I liked was because there were 665 likes. I've been using shader graph for 2d, so most of this tutorial didn't apply to me, but I skimmed it anyway.
Ответитьfinally !! ty ive beeen looking for something like this 4 ever
ОтветитьGreat tutorial! Thanks so much!
Ответитьhi, I believe I followed every step perfectly but While the material is changing in preview, nothing changes in the game view. Also my material has strange lines going up and down it, almost like a tennis ball texture. Any help is really appreciated!
Ответитьin the .HLSL file, shouldn't the sixth float2 of sobelSamplePoints[9] be (1,0) instead of (1,1)? As it stands the cell that should be the middle-right is sampling the top-right instead.
ОтветитьIs this possible to replicate for the built in render pipeline and for unity 2019.
ОтветитьThank you so much for these tutorials! I am completely new to shaders, and was expecting that everything would go over my head. But you explain it really well, looking forward for more content! :)
ОтветитьI have black screen
can anyone help??
I'm using this in a game, and I've noticed that my reflection probs stopped working when using the Blit material in the Forward Renderer. The baked ones are fine, but the realtime ones are all black. Is there a fix or a way around this?
ОтветитьGreat Tutorial Ned!
ОтветитьAye there, fantastic tutorial, really helpful for my present project. Had a question though, how can I get the shader to work for both my base camera and overlay camera? Its an FPS with the overlay camera rendering the held weapon while the base camera renders everything else.
ОтветитьMine just comes out solid white...
ОтветитьHi, first thanks for this video really informative. However I think I have set it up wrong as if I say set this for one of my prefabs so say trees use this material I thought only those would be outlined but it seems it just renders the enter texture on the screen over what should be displayed. So say I pick a texture of a sword, set that on the blit material, run my project then instead of seeing all the trees for example in the view I just see the sword texture. Any ideas? Thanks
ОтветитьI get the outlines showing up in the material preview, however not in the scene itself, any idea what the reason for this is? I'm using 2020.3
Ответить