Announcement

Collapse
No announcement yet.

Special "nodraw" material to prevent triangles to be rendered - possible ?

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

    Special "nodraw" material to prevent triangles to be rendered - possible ?

    While there are a lot of talks about BSP tools and better CSG workflow, no one seem to remember that all older engines that use BSP/CSG have special "nodraw" material which tells map compiler or renderer to discard or not to render triangles with "nodraw" material. This effectively discards all the back faces in any geometry reducing rendering overhead.

    Here is a mock-up showing such approach:

    Click image for larger version

Name:	ue4_special_nodraw_material.png
Views:	1
Size:	61.7 KB
ID:	1181447
    Full: http://s32.postimg.org/3rbnq4x5v/ue4...w_material.png

    Does UE4 have something like that? (perhaps default material with some option checked to tell renderer not to render those triangles)

    P.S. Note that it's not an "invisible" material, where triangles you processed, but you don't see them in the scene (invisible material would still have triangles in wireframe mode, while "nodraw" material wouldn't have any)
    Last edited by motorsep; 05-01-2016, 01:51 PM.

    #2
    Meep meep. I am guessing it doesn't exist :/

    Comment


      #3
      you can make a masked material with 0 opacity, it will effectively do what you're wanting to do
      Follow me on Twitter!
      Developer of Elium - Prison Escape
      Local Image-Based Lighting for UE4

      Comment


        #4
        Originally posted by Chosker View Post
        you can make a masked material with 0 opacity, it will effectively do what you're wanting to do
        It's more expensive to render masked material than the way I am talking about. In the old engine I worked with, it was literally a few lines of code where renderer would skip triangles with "nodraw" material. There was no overhead.

        Comment


          #5
          with the method I propose the triangle geometry will be processed yes, but then no depth and no pixel shader will be processed for it. with nowadays GPUs that's quite significant, and triangles not so much anymore
          besides that, I don't think you'll find an option in UE4 that skips the triangle itself
          Follow me on Twitter!
          Developer of Elium - Prison Escape
          Local Image-Based Lighting for UE4

          Comment


            #6
            Since I am going for mobile VR, processing triangles that aren't visible to camera would create significant overhead

            If UE4 doesn't have such option, yeah, I am out of luck and probably have to remove those manually in 3D app before exporting meshes to FBX

            Comment

            Working...
            X