Announcement

Collapse
No announcement yet.

point light and shadow casting

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

    point light and shadow casting

    Hi. I am new to UE, but so far I love it. I have used other game making software, but UE so far seems to be what I have been looking for.
    However, I am running into a few snags. I am working on a 3rd person project and learning how to add meshes and materials of my own making, but I am having an issue with the point lights doing weird things. In the first picture, the point light is doing basically what I want it to do, but in the second pic, it seems almost to be projecting light in a particular direction and not in all directions like it should, and it is not lighting the mesh right. The "ceiling" and the point lights in both of these areas are in exactly the same Z position, and the meshes are basically the same, just simple cube meshes with the normal facing inward. I have four different meshes for my walls, and they all use the same material. They all are made of a floor, ceiling and whatever wall parts I need to make the parts for the level - a line (floor, ceiling, left wall and right wall), a corner (floor, ceiling, left wall, front wall), a "T" (floor, ceiling, and only one wall), and an "open" which is only a floor and ceiling with no walls. I can pretty much make the whole level with these 4 pieces simply by placing them and rotating them as needed. I noticed that the point light only does this on the "T" mesh and the "open" mesh. I have rechecked and reimported them more than once (I'm using Blender 2.56), but always the same result.

    Click image for larger version

Name:	s1.png
Views:	1
Size:	85.3 KB
ID:	1528186Click image for larger version

Name:	s2.png
Views:	1
Size:	89.8 KB
ID:	1528187


    Next issue: The floor looks seamless everywhere till I get to a turn, whether at a corner or a T, then it looks very un-seamless (see 3rd pic). I made the floor texture completely tileable so that no matter how it is positioned or rotated it appears seamless against adjacent floor parts, and again, I have shadow-casting disabled for all of the meshes. They look fine till I get to a spot where a mesh was rotated. What's up with that?

    Lastly, I notice as I run through the level in play mode, that when I round a corner, I see flashes of light that disappear as I continue running. Is light leaking through my meshes where they are joined because there is a gap between them? I could not take a screen shot of this because it only lasts for 1 frame and I am not quite that quick,

    Click image for larger version

Name:	s3.png
Views:	1
Size:	75.7 KB
ID:	1528188

    Any help or suggestions will be greatly appreciated.

    #2
    Can no one offer any possible tips or solutions to this?

    Comment


      #3
      REALLY?????????? After nearly 50 views no one has ANYTHING AT ALL to say about this topic? Is this such an uncommon and baffling problem in UE? I have looked through the docs and read several threads related to this. So...........
      I see a few different types of lights, but none of them are called ambient... is there a way to set up ambient lighting for use inside a cave type level? Directional lights and skylights do not seem to accomplish this. I'm really discouraged here. I have spent lots of time modelling and making textures for this, but I must find a solution to this ugly lighting problem.

      Hello?

      Comment


        #4
        Are those lights baked or dynamic? Stationary/Movable lights tend to have this issue if your normals are incorrect, whether that's broken vertex normals, incorrect normal maps, or an incorrect value used in the normal input. World-Space normals usually have this issue too depending on the blend quality.

        If you're just looking for an ambient light source, without actual lights, try the Sky Light set to Stationary or Movable with shadows off. You'll probably have to use a very specific cubemap or use a really low strength. You can also try the Ambient Cubemap option in the Post-Process Volume, but that's a deprecated feature and has some minor issues with newer features in the engine.

        The 1 frame flash might be due to your mesh setup and occlusion culling. Modularity at a small scale has a problem with culling objects very quickly based on the small bounding boxes. If you rotate your camera really fast horizontally, do you see it still?
        Lighting Artist II @ Crystal Dynamics
        Former Lighting Artist @ Obsidian Entertainment
        ArtStation

        Comment


          #5
          OK I'll take a shot at it.

          First off is generally one is supplied with some very basic tools built to produce a result at a very basic level with the ideal of keeping the lighting build time as low as possible as giving you the best of the best out of the box would turn the lighting build that would only take seconds into hours even for a very simple environment. This is typical with any high end rending system as it's a bad idea in general to default the rendered output to the highest possible settings

          This would be my first impression as to what I would expect a build based on out of the box settings would produce and I expect that most looking at the result would think the same way as to what it would take to make it better as to the need to focus on the tress and not the entire forest as to the number of individual problems that prevents you from achieving a predictable result..

          Predictability is the very root of success and is the problem with most tutorials that it is assumed that the "basic" requirements is understood but where the root of the problem is first establishing the required setup that will allow what is being demonstrated to work as to expectations.

          So

          Looking at the sample the one thing that stands out is the single point light source is not behaving as expected as to a material lacking any kind of reflective quality.

          What might help you out I did this as to going back to basic set up requirements

          https://www.youtube.com/watch?v=OS7NM2IkQcw

          A bit long but the purpose to be served was to point out the basics and how in a lot of cases it's the build of the material that determines lighting behavior as to how lights need to bounce off a surface creating indirect light.
          . .
          .
          Last edited by FrankieV; 09-20-2018, 02:09 PM.
          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


            #6
            Thanks to both of you very much! You guys are great.

            To Rosegoldslugs: Actually I am not sure of the difference between baked lights and dynamic. Much of this stuff is all new to me. All of my normasl are flipped correctly and I use Crazybump to make my normal maps and spec and occlusion maps. I find turning the specular way up does help a little, but I don't want that much sheen - the ceiling is supposed to be concrete. Also, too high on the normal map makes it appear as a much more "bumpy" surface, and that is not what I am trying to achieve either. I really appreciate both of you answering this post. I do read docs and watch tutorials, but my question has always been, why waste hours and hours and still not find the answers you are looking for when probably someone on the forums can very quickly guide you toward some possible solutions. After all, is that not what the forums are for? Gotta help the noobies. Anyway. I am not sure about worldspace normals (what is that?) or blend quality or normal input values. Where do I find that stuff? I am not at all against experimentation/hit & miss but I don't know where to even begin. I DO want ambient light, but I also would like a few point lights here and there as accents. Don't really want to start compromising. Lastly, I thought perhaps that "one frame flash" was due to the not quite 100% preciseness of the location of the vertices as exported from Blender (I LOVE Blender, used 3ds Max for a while but it seems very awkward to me), and so I went about making all new models for my wall cells with additional faces to overlap adjacent meshes, but when that also did not work, I though maybe it had something to do with camera distance.... (?). And to answer your question, yes, when I am running through the level and turn a corner (really fast horizontal camera movement) it does it. Where do I adjust occlusion culling?

            To FrankieV: Agreed. To understand many tutorials I have seen (here and elsewhere) one would have to already know how to do everything the tutorial is supposed to teach in order to benefit from the tutorial. It's like "Oh, your drowning? Well swim to the boat and I'll throw you a life-jacket once your back inside." I have not yet looked at the links you provided, but I surely will as soon as I get done jabbering here.

            Again, THANK YOU guys so much for taking the time to help. I am great at modeling and excellent and texturing, also pretty good at scripting, but all this UE4 stuff is new to me. I'll tinker with it some more now that I have somewhere to start and let you know how it goes.

            Comment

            Working...
            X