Full screen shader introduction

Поделиться
HTML-код
  • Опубликовано: 25 дек 2024

Комментарии • 33

  • @whitpan
    @whitpan 3 месяца назад

    Thank you so much for going into how to actually get your new shader into the render pipeline! I had shaders from other tutorials that may have been older versions or just didn't cover it and my shaders weren't being applied you've finally helped me fix this issue!!

  • @CCosmicCreator
    @CCosmicCreator Год назад

    You're the best for this one.

  • @미셸-s7j
    @미셸-s7j 10 месяцев назад

    thanck you !! You save me

  • @PRodi_
    @PRodi_ Год назад +2

    No, you’re breathtaking! With your shaders tutorials♥ keep it up.
    Btw. Do you know how to make distortion on the edges in the position of this vignette?

    • @iDigvijaysinhG
      @iDigvijaysinhG  Год назад +2

      Thanks, and for the distortion effect, to go for a super simple effect, we can multiply power node with some simple noise.
      However that still depends on what kind of distortion we are going for.
      i. e. to replicate screen flickering in some of the horror movies or games we need to tinker our graph a lot with "scene color" and "refraction" to actually distort what we see on the screen.

  • @nutellaj1778
    @nutellaj1778 Месяц назад

    hi, thx for the tutorial! How can I animate this effect to appear and disappear whenever i need?

    • @iDigvijaysinhG
      @iDigvijaysinhG  Месяц назад +1

      Hey,
      You could use a Time node. Multiply it with some number to control the speed. Feed the output to Sin node, you will have value that will ping pong between -1 to 1, now we need to remap it to only go from 0 to 1.
      There are bunch of waves to do that like just feed it to Fraction node. Multiply it with Power node at 5:56 and feed that output instead to alpha.

  • @theapein
    @theapein Год назад +1

    That's nice, how would you go about adding a way to exclude some object from specific Layer from being affected by this Vignette?

    • @iDigvijaysinhG
      @iDigvijaysinhG  Год назад

      That's tough maybe, I don't think we can exclude some objectives using layers, maybe can use stencil but I don't know how at the moment, need to look into it.

    • @theapein
      @theapein Год назад

      ​@@iDigvijaysinhGcool, I use camera stacking for it and pp but I'd prefer a different approach to avoid multiple camera setup

    • @iDigvijaysinhG
      @iDigvijaysinhG  Год назад

      That's one way to do it, I am just curious however, why do you want to avoid multiple cameras? Any particular problem?

    • @theapein
      @theapein Год назад

      @@iDigvijaysinhG well I am worried there will be performance hit because of multiple camera setup, plus it requires specific project structure with layers to make sure you are culling on each camera specific layers. So I'm researching if there's alternative solution where you just select layers you want to exclude on the effect like vignette itself.

  • @martinakutalkova4647
    @martinakutalkova4647 Год назад

    Hi, thank you for this tutorial! I'd like to ask if there's a way how to achieve same effect but in older versions of Unity (2021.3.31f1) where there is not possible to create Fullscreen Shader Graph. I'd like to add a full screen effect for a mobile game but I'm struggling a bit how to perform this correctly. Thank you in advance for your help/answer/tip.

    • @iDigvijaysinhG
      @iDigvijaysinhG  Год назад

      Thank you!
      We could always write custom shaders, I wrote a screen distortion effect shader back in version 2018.x but that was before the introduction of multiple render pipelines. They are not interchangeable so.
      However If you want vignette (effect in video) you could simply use post processing if you are on URP.
      If you want a different effect, look into how to write full screen shaders. There are great resources out there.
      However I will advise against upgrading the project in higher Unity version. It often breaks things and introduces more headaches.

  • @kemaldogan8185
    @kemaldogan8185 Год назад +1

    Hi im using unity 2022.3.4f1 and when i create and go to fullscreen shader graph on editor it directly gives error "Shader error in 'Shader Graphs/Master': Unexpected directive '
    ' at line 41" could you help me

    • @iDigvijaysinhG
      @iDigvijaysinhG  Год назад

      Seems like Unity's internal error, could you tell me which version of Shader graph you are using from the package manager? Also does it occur for all shader graph or just full screen shader?
      Also try to downgrade it one version and see if the problem persists. Keep in mind, you also need to match it for the Render pipeline as well.

    • @kemaldogan8185
      @kemaldogan8185 Год назад

      @@iDigvijaysinhG Thanks for your response, I handled the situation by changing my OS language and regional format to US English.

  • @cb3ezy
    @cb3ezy 7 месяцев назад

    How did you get full screen shader? I cant get it!

    • @iDigvijaysinhG
      @iDigvijaysinhG  7 месяцев назад

      Hey,
      I am sorry, I didn't get what you are saying. Are you asking how I get the option to create a full screen shader?

  • @HK-jv4wc
    @HK-jv4wc Год назад

    Hey is there a way to call this shader effect to play let's say with an onclick event?

    • @iDigvijaysinhG
      @iDigvijaysinhG  Год назад

      If you want vignette then just use post processing. Turn it on off in OnClick().
      You could also watch my "Hit indicator" video for some other reference.

    • @HK-jv4wc
      @HK-jv4wc Год назад

      @@iDigvijaysinhG Thanks for the reply, I will have a look basically the idea is that when the player moves in the world (AR game) and enters a portal they will experience a full screen effect as they go through it!

    • @LeafesMan
      @LeafesMan Год назад

      ​@@HK-jv4wcHi, I know it's been a minute but did you ever find a solution to this?
      I'm in your shoes right now looking all over and I just can't quite get an hlsl shader working with the full screen renderer

  • @Mourdraug
    @Mourdraug Год назад

    Can you actually use normal shaders instead of graphs with Full Screen Renderer Feature? I'm pulling out my hair trying to figure it out but to no avail

    • @iDigvijaysinhG
      @iDigvijaysinhG  Год назад

      Hi Mourdraug,
      I haven't tried it personally, but can you tell me a bit more about what is the problem that you are facing?
      Because as far as I know, technically we can feed any material in our "Renderer feature" material slot, provided that our actual shader does not have any error.
      Also we can create our own custom renderer feature or even our own custom render pipeline but that topic is very overwhelming for me as well.

    • @Mourdraug
      @Mourdraug Год назад

      @@iDigvijaysinhG My guess is I'm missing some Tag in my shader, because when I make a material with the shader graph the way you presented the preview is just a rectangle of sort while making a material with the shaderlab shader I get the regular sphere preview, and when I use it as renderer feature it does nothing.

  • @davidvpi
    @davidvpi Год назад

    I have no "Add new feature" button, Unity version 2022.3.2f1

    • @iDigvijaysinhG
      @iDigvijaysinhG  Год назад

      Hey David, I have checked in tech stream release 2023.1.2f and "add renderer feature" button is still there.
      However just to be double sure, I have downloaded the exact version you have mentioned and it's still working for me.
      Are you sure you are looking in the renderer asset and not the pipeline asset?
      Are there any errors, which may prevent that button to show up?
      Lastly try some other render pipeline version and see if that does the trick.

    • @davidvpi
      @davidvpi Год назад

      @@iDigvijaysinhG I have an error " _renderer_ is missing RendererFeatures"

    • @iDigvijaysinhG
      @iDigvijaysinhG  Год назад

      There should be a feature with error then, you would instead have a button "Try fixing" or similar.
      Now the solution depends on the particular error to fix it but if you are just following my tutorial then first try to remove that feature with an error and you will be able to see the "add renderer feature" button.

  • @nyan12
    @nyan12 Год назад

    can u make a rain drop effect on screen with it?

    • @iDigvijaysinhG
      @iDigvijaysinhG  Год назад

      You could follow the same approach with perlin noise for uv distortion (gradient noise node), and add Y panning to it.
      It will be a "convincing" look.