Announcement

Collapse
No announcement yet.

Material Editor 2.0

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

    Material Editor 2.0

    Hi everyone!

    On the Roadmap it states there will be a Material Editor 2.0, but I could not find any details on it, so I thought it would be nice to start a thread here with everything we might be expecting from it.

    Let me start off by showing a Photoshopped image of what I personally have in mind.

    Click image for larger version

Name:	MaterialEditorFragmentGraph.jpg
Views:	1
Size:	338.4 KB
ID:	1148791


    So the ideas are simple:
    -Make it feel more like Blueprint.
    -Give the user more control over the available shader programs.

    The main elements to notice are the differences in showing the different programs. The vertex and fragment program are separated graphs.
    The fragment graph does not have that many differences from the old one, but there is an extra output show here, the "reflection" output.
    The reflection output is for overriding the default reflection probe setup. The "Reflection Texture" node show in the image above is the actual
    reflection data made by the reflection probes. if you want to replace it with a simple cube map for mobile, or a mirror reflection you can, while
    still maintaining the PBR setup.

    On the left we see the standard Blueprint window showing the graphs, functions and the possibility to add local variables. There is one default
    function for the shading model. It would be cool if all shading models were made node based, and nothing was hidden in the background. It also
    give the user the possibility to make his own shading models. Currently you have to put it on Unlit and abuse the Emissive Color input.


    Now let's take a look at the vertex graph:

    Click image for larger version

Name:	MaterialEditorVertexGraph.jpg
Views:	1
Size:	349.6 KB
ID:	1148792

    This is the default setup, so when a new material is created, it will have all the nodes and variables hooked up. Currently you can only do world
    space offsets, and have to do extra calculations to do it locally. With this setup it will be more clear what is happening. There is also the possibility
    of giving custom normals in case you do extreme deformations.

    You can see on the left side the local variables automatically provided by the engine. Any unused variables should of course be removed when compiling.
    The TexCoord options could also be optimized based on what the user hooks up (float, float2, float3, float4).

    Shader Model 4+
    When the user turns tessellation on, an extra graph is added, the Tessellation Graph.
    The user should also have the possibility to turn on the Geometry Graph. We should look into the best way to set this up. This should make it easy to implement hair.

    Multi-pass
    It would be cool to have multi-pass shaders, but currently I don't know how that would be set up. Maybe the user is allowed to make multiple graphs and order them,
    or maybe it is just a seperate object in your project called "Multi-pass Material" where the artist can assign regular materials as being a pass.


    NEW FEATURES SUMMARY

    Material
    Layout
    -Separate graphs for vertex, fragment and tessellation program.
    -Access to all the vertex data and changeable vertex attributes in vertex graph.
    -Geometry program graph.

    Settings
    -Parent material for material inheritance.
    -Render queue
    -Buffer masking, defines to which ones it is writing. (R, G, B, Depth)

    Variables
    -Matrices.
    -Arrays.

    Output
    -New reflection output to replace the reflection probing technology.

    Nodes
    -For loops
    -Sine & Cosine should have default period of 2pi.
    -Reroute nodes.
    -Collapse nodes.
    -Extra texture sampler output for complete vec4.

    Miscellaneous
    -Better context sensitive search menu.
    -Layered materials should work with materials instead of functions.
    -Separate short key for duplicating nodes together with the nodes it is connected to.
    -Local functions.
    -Variables support and local variables for functions.
    -Multi-pass support.
    -Quicker compile time when inside the material editor, only compile for current system.

    Material Instance
    -Parameter tool tips.

    Material Struct
    -Same as the Blueprint version, but usable in Materials.

    Material Function Library
    -For all your global functions, instead of having it all separated in your project per function.

    Material Parameter Collection
    -Support all parameter types.
    Last edited by Roel; 05-03-2015, 07:43 AM.

    #2
    I also wrapped my head around some improvements to the material system.

    Some of the things you are proposing can already be achieved:

    -Collapse nodes.
    That is exactly what a material function does.

    Material Function library for less chaos in your project
    I use the folder structure to organize my functions.


    What I would personally like to see is:

    - material parameter tooltips that show in the material instance editor.
    Sometimes the parameter name alone is just not descriptive enough

    - Currently, a bool param node pullout to create a switch connects to true, it should connect to value....
    Its not really a bug, but an improvement if corrected

    - Texture samplers should be context sensitive of the type of texture. If I alsign a "normal map" compressed texture, the sampler should change to normal. Its a real hassle to change all sampler types that use a texture after the compression was changed.

    -sub materials
    It would be nice to be able to drag a material from the content browser into aonother material. Ther it would show up as a broken up "material attributes" node with all the output pins.
    Sure I can do that at the moment wrapping every material in a function. But it would be much more convieniently if that is done behind the scene.

    - material element naming
    Ok, thisone affects the static meshes, but is material related. It would be nice to have an option to assign a name to the material elements of a mesh.
    On it would be so much easier to handle than Element0,Elemen1,Element2...
    A possible solution that I like would be a field in the mesh that says "Element descriptor" and you assign an Enum type to it which´s members map to the element order of the mesh.

    -structures/enums in materials and functions
    Being able to use structures and enums in materials and material functions. It would be handy to be able to make changes to a material instance by selecting an enum (which connects to a switch).
    This way the level artist can choose one of serveral "looks" of a mesh without even the need to know what a texture or a material is...

    -Bulk import settings for textures
    Also material related as materials use textures. When I have created 50 textures that I wish to import with the compression settimng "Masks", the engine of course imports them with the "default" settings.
    For normal maps it works like a charm that the engine auto detects the texture type. I have to go into each texture and change the compresison settings manually.. Thats tedious.

    Function params as local variables
    If I want to use an input parameter of a material function deep down in the function graph, I have to drag a wire from the function entry node which doesnt help the readability at all.
    It would be nice to have some sort of "get" node for input parameters inside functions. I have functions with a dozen parameters and not all get adressed within the first handfull of nodes....

    -Material inheritance
    It would be nice to make a material with some parameters for specular and Diffuse and then being able to make a material that inherits these. In the inherited the input pins for these material atrributes can be garyed out (marked as inherited) and from there I can add more stuff to the otther outputs (refraction, etc) for different materials that all share the specular and diffuse paramteres from the parent material.

    ..So thats my two cents added
    Last edited by KVogler; 04-27-2015, 08:08 AM.

    Comment


      #3
      That is exactly what a material function does.
      Collapsing nodes is not the same as making a function. A function is for re-usability.

      I use the folder structure to organize my functions.
      I do this too, but the suggestion for material function libraries is just to have more consistency between the different tools.

      Thanks for all the suggestions, I will merge them in my post later today so we will eventually get one big pile of suggestions

      Comment


        #4
        Collapsing nodes is not the same as making a function. A function is for re-usability.
        But also effectively collapses the nodes. Reusability is an added bonus

        PS: Maybe this post would draw attention more effectively if placed in the "Feedback for Epic" subsection...
        Last edited by KVogler; 04-27-2015, 08:19 AM.

        Comment


          #5
          Moved this thread to feedback.
          Tim Hobson | Learning Resources | Epic Games
          UE4 Documentation
          Wiki Troubleshooting Guides: Lighting | Swarm Agent | Destructibles |
          _____________________________________________
          Follow me on Twitter @TimHobsonUE4 | My Personal Website
          Photons Be Free: Mini-Tutorials and other Curiosities

          Comment


            #6
            I would love for it to work a bit more fluid like substance designer or the Ghost Town plugin for 3ds. I often work over Teamvewer when I can't be home at my computer, and because it requires a bit more precision when pulling connections and such it's a pain over remote. Also I would love to be able to duplicate something with it's connections intact (don't think it's available).

            Comment


              #7
              duplicate something with it's connections intact (don't think it's available).
              What do you mean?
              If I select a connected set of nodes and duplicate it, the connections among the selected nodes are there...

              Comment


                #8
                Originally posted by KVogler View Post
                What do you mean?
                If I select a connected set of nodes and duplicate it, the connections among the selected nodes are there...
                Yes, but not if you duplicate just one node without it's connecting nodes. In Substance Designer for example you can duplicate with or without connections using different shortcuts.
                Saves lots of time.

                Comment


                  #9
                  Oh havent seen anyone bring this up but it would be really nice to have re-route nodes in the material editor like in the bluprint editor. Helps to keep things a lot cleaner.
                  James Brad Barnette
                  Senior Creative Artist
                  3Dmotif LLC

                  Comment


                    #10
                    I wanted to make a post about this for quite some time.

                    It's been over a year now since UE4 became available to the general public.. many things have changed since then, almost every part of the editor has been improved in some way..

                    The material editor however has been stuck pretty much exactly the same!

                    Lets just start from the very basics:

                    -How come there are no for loops yet? (a concept that predates computing which every programming language ever has? ) someone please explain to me why!
                    -Vector arrays (and arrays in general)?
                    -Matrices?
                    -Structs?

                    Sure, we can use the custom node to write hlsl code but that comes with its own set of problems and it's less optimized.. plus it kinda defeats the purpose of having a node-based editor

                    Then there are other general usability features that are missing (compared to blueprints at least).

                    -Variables list! this is a huge one.. let's say you want a scalar parameter that need to use all over the place right?
                    Well.. you can't! you either gonna have to connect everything to one scalar (and have a spaghetti mess) or copy the node a bunch of times but then have to change every single one of those nodes if you need to change the value of that scalar.

                    -Local material functions (currently material functions are global and less useful compared to BP).
                    -Re-route nodes.
                    -Collapsed graphs.
                    etc. etc.

                    In conclusion.. Epic, the material editor needs some love too!

                    4.10 Update! -> [Community Project] WIP Weather & Ocean Water Shader
                    WIP Interactive Water Shader, WIP 2D Water Sim
                    WIP FFT Ocean w/ Foam, Quad-tree Infinite Ocean LOD

                    Comment


                      #11
                      The material editor however has been stuck pretty much exactly the same!
                      Absolutely. There were just some nodes added regarding landscape materials, the rest is still as in 4.2

                      I hope the guys at Epic catch some of my/our ideas here..

                      Comment


                        #12
                        Well as much as I would like to see more features add to the material editor I would love to “see a what you see is what you get” compositor along the same line as Illustrator or After Effects.

                        Maybe not in app, as in a past Twitch it was mentioned that there has been improvements in the plug-in path way, but as a plug-in life would be good to be able to use materials as a material layer and map the texture as to scale and position directly on to the geometry.
                        Clarke's third law: Any sufficiently advanced technology is indistinguishable from magic.
                        Custom Map Maker Discord
                        https://discord.gg/t48GHkA
                        Urban Terror https://www.urbanterror.info/home/

                        Comment


                          #13
                          Thanks everyone for the feedback, I made a list at the bottom with all the current ideas, I will update it when more feedback comes in. Note: I only incorporated everything related to the Material Editor.

                          Originally posted by FrankieV View Post
                          Well as much as I would like to see more features add to the material editor I would love to “see a what you see is what you get” compositor along the same line as Illustrator or After Effects.
                          Could you elaborate on what you want to see as a feature exactly? I don't know illustrator and after effects that well.

                          Comment


                            #14
                            Anothr nice thing to have:

                            An option to temporarily disable shader compilation.

                            Sometimes I have a really broken material graph. Currently Im fixing one for this guy. This is a good example where I would need it.
                            https://forums.unrealengine.com/show...scape-material
                            It is easy to see that this graph will not be fixed by pulling a node or two. It needs extensive surgery and until then it will keep being broken. But still, everytime I (dis)connect a wire, rename a parameter, change its sort order, etc, the engine tries to recompile all the shaders.

                            I would love to be able to place ten nodes, connect a dozen wires and place/rename parameters without the engine even trying to compile after every mouseclick.
                            I disabled all realtime node previews etc. Still the engine is doing it. Or is this already possible?

                            How can I make the engine not be such a compilomaniac

                            Comment


                              #15
                              That doesn't sound right, it shouldn't compile until you either click the save or the apply button (?)

                              4.10 Update! -> [Community Project] WIP Weather & Ocean Water Shader
                              WIP Interactive Water Shader, WIP 2D Water Sim
                              WIP FFT Ocean w/ Foam, Quad-tree Infinite Ocean LOD

                              Comment

                              Working...
                              X