Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

What exactly does a rendering pipeline do?

Discussion in 'Editor & General Support' started by Marscaleb, May 7, 2021.

  1. Marscaleb

    Marscaleb

    Joined:
    Jan 7, 2014
    Posts:
    987
    So I recall when I was starting my project that I looked up this "URP" and "HDRP" thing, and it basically boiled down to "You use HDRP if you want to target high-end devices, and you use URP if you want to target all platforms including mobile."
    And I thought, okay then, so I'd want a URP project since I'm not anywhere near making visuals that require high-end devices (even though I may not actually release the game for mobile.) I didn't change any of my settings but I always figured that's what I was using; I figured that was the default. A number of assets I'm using were promoted as being for mobile or mobile-ready, and I've got materials using mobile shaders.

    But recently I found out that I'm not actually using URP, but also I'm not actually using HDRP. The Render Pipeline Asset in my project's graphics settings is "none."
    And I found that since I don't have URP on here I can't use Shader Graph, which today I thought I would try out.
    I went to the package manager ans installed Universal RP. The system was busy for very long time while it re-imported all of my assets. When it was finished I added the UniversalPipelineAsset to the render pipeline asset in my graphics settings. This caused every material in my project to turn to a solid magenta.

    Now I suppose at this point I could ask "how to I properly set all these assets to properly use URP?" but in all honesty, what I'm really left to ask is "what do these render pipelines even DO?"
    I mean my game was running fine without any pipeline set at all. I figured setting URP would make things run smoother under-the-hood so final performance would be better optimized, but that is 100% just guessing.

    What do I actually gain to actually set the render pipeline to URP? Should I just remove the Universal RP package if I'm not using it?
     
    Last edited: May 7, 2021
  2. Mauri

    Mauri

    Joined:
    Dec 9, 2010
    Posts:
    2,657
    You may want to read the Manual pages to understand what they do:

    By default (that is: if you don't use any of the new render pipelines), Unity relies solely on the so-called
    Built-in Render Pipeline
    - a general-purpose render pipeline that has limited options for customization. Because of that, Unity eventually introduced the Scriptable Render Pipeline (SRP). Both
    HDRP
    and
    URP
    are built on top of this technology and you can even make your own custom render pipeline with it.

    The HDRP has the latest cutting-edge, high-fidelity graphics and is mainly intended for high-end platforms, whereas the URP has optimized graphics and is meant to be used across a wide range of platforms (e.g. from mobile to high-end consoles and PCs).

    Materials turning magenta is to be expected because shaders from the Built-in Render Pipeline aren't compatible with SRP, but you can upgrade your materials.
     
    Last edited: May 7, 2021
    Kurt-Dekker likes this.
  3. Marscaleb

    Marscaleb

    Joined:
    Jan 7, 2014
    Posts:
    987
    Right, I got that part.
    But nobody seems to be explaining what the difference is between these and nothing at all, or I guess the Built-in Render pipeline you mentioned.

    I'm looking through that manual you shared a link to, but I'm not really seeing much that I understand.
    What do I actually gain from using it?
    Honestly it looks like extra work just to convert all the materials, and most of those conversions are going to the same shader. (No difference between standard and specular? All my old specular-based materials won't look right.)
    What benefit does that actually provide?
     
  4. kdgalla

    kdgalla

    Joined:
    Mar 15, 2013
    Posts:
    4,355
    Basically, Unity started off with (and still has) a built-in process to render all of your 3D stuff into a 2D image on the screen. This takes in all of your meshes/materials/shaders as input and spits-out a screenful of graphics at the end.

    It worked fine, but people didn't like how it was built-in and they couldn't edit it and make changes or optimizations for their own requirements. Unity introduced the pipelines as an editable alternative to the built-in renderer. As you noticed, however, shaders are not necessarily compatible between one renderer and the other. Switching from the built-in to URP is going to require refactoring. Anything using the standard shader should have been converted through some built-in editor process, but any other shader I think you'll need to recreate using shader graph.

    It sounds like you might have been under the impression that URP and HDRP were add-ons that you could apply to your existing project, but that's not the case. Really it's an either/or situation where if you chose to use URP or HDRP then you no-longer have access to the regular Unity graphics features that you're familiar with.
     
    Kurt-Dekker likes this.
  5. Marscaleb

    Marscaleb

    Joined:
    Jan 7, 2014
    Posts:
    987
    Well more correctly: I was under the assumption that one HAD to use either URP or HDRP, like there wasn't any other choice, and I kind of figured that URP was default, so it was already something I had enabled.

    I really wish these people explaining URP and HDRP would bother to explain that not having either was an option.

    So, it's a set of tools that lets me make changes to the renderer? Well I don't see any reason I would want that; I really have no intent to make such low-level changes. It sounds like a cool feature, and if I had a team working for me I could imagine using it to tweak my visuals to make my dream visual style. But I'm a solo developer buying most of my assets from the asset store. It doesn't sound like I actually gain anything from using URP unless I was going to make some tweaks to best suit my game.

    Is there anything wrong with my not using URP? Could this result in a loss of performance from using the older renderer? Or am I only losing the option to tweak things for the best result (which would probably not be something I would do)?

    EDIT: Also, would I just want to click the remove button for Universal RP from the package manager? I haven't done anything else, but I know it spend some time re-importing assets. I don't want to screw something up since I'm playing with things I don't understand.
     
    Last edited: May 7, 2021
  6. PutridEx

    PutridEx

    Joined:
    Feb 3, 2021
    Posts:
    1,120
    Built-in pipeline was the only RP for a long time, until unity decided it's too old, too much debt holds them back to improve upon it, etc etc -- so they created SRP. Although you can create your own RP, most people aren't graphic programmers. You choose one of the two unity offers.

    URP is a RP that unity releases updates for, improvements, and is more similar to built-in (legacy) pipeline, which is the one you are(were?) using.

    https://docs.unity3d.com/Packages/c...l/universalrp-builtin-feature-comparison.html

    That's a comparasion of features between URP and Built-in.

    Built-in now is considered legacy, no new features are coming, and unity is focusing on SRP(URP + HDRP)
    They still support built-in though, bug fixes and so on.
    (The majority of all games in the world made with unity use built-in) for the simple reason it was the only render pipeline.


    Many people decide to stay on built-in, complaining about URP, missing features or late features and so on,
    others move to URP since it's what unity now supports. Some are waiting for a feature to land, or their project was already using built-in so upgrading to urp is too much work and not worth it.


    URP, on PC at least, is usually faster then built-in based on my tests. And the unity developers consider it a regression if URP is slower than built-in.
    Although -- built-in supports more features. URP is trying to catch up, while having unique features of it's own.


    One of the biggest problems is, If you buy something in the asset store, there's a good chance it doesn't support all these render pipelines. Maybe it supports URP only, built-in only, HDRP, or multiple.
     
  7. kdgalla

    kdgalla

    Joined:
    Mar 15, 2013
    Posts:
    4,355
    I think that's the ultimate plan, but for now the old renderer is still available and there's no date set for it to be deprecated yet.
     
  8. vertexx

    vertexx

    Joined:
    Mar 18, 2014
    Posts:
    347
    Best thing is to look at something rendered in these formats and judge/compare for yourself if it's worth the teeth gnashing to change from what you have. Most "higher level" rendering formats that Unity offers are of doubtful use and reliability, unfortunately.
     
  9. MikeBastien

    MikeBastien

    Joined:
    Apr 24, 2009
    Posts:
    139
    Breakneck breakdown:

    Slower-paced version: