Announcement

Collapse
No announcement yet.

Spotlight moving in Side-Scroller Template

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

    Spotlight moving in Side-Scroller Template

    Hi!

    I've been trying to setup a Spotlight in the Side-Scroller Template, but the light moves whenever i move camera - in editor and in play-mode. I wonder if it has something to do with the Camera being fixed?


    Thanks,
    Nuutia
    When the Spotlight is viewed from center When the Spotlight is viewed from left

    #2
    Well if your camera is fixed and you are moving the scene, then logically the light placed in the scene would move along with the scene?
    obvious solution. Attach the light to the camera.

    Comment


      #3
      I'm talking about the the Side-Scroller template, which has the camera fixed if you go to Play Mode. And i specifically don't want the light to move with the camera.

      In the screenshots i try to demonstrate the problem:
      - In the first image the light is centered into an object and it is as i want it to be.
      - In the second image i've moved the camera bit to left side and the light is no longer illuminating the object, but instead bleeds into the wall.

      Comment


        #4
        In side scroller default the camera is not fixed. It follows the character around as any other camera in any other sample project.

        Still, if you attach the light to the object you want illuminated by Parenting it or adding it in as one of the object's components you might be able to prevent any movement or limit possible parallax effect.

        Comment


          #5
          My terminology seems to be off. I meant that the camera is restricted to certain axes. I can see how 'fixed' would mean it being totally still.

          I attached the Spotlight to the Object in World Outliner, but still had the same effect. I then experimented with 'Soft Source Radius' -slider and was able to lessen the effect with it - but the problem still existed.
          I then set another Spotlight and set a different Object with a different Material in front of it and the problem was gone. I applied a different Material to my first object and the problem was gone.

          I experimented and found that the problem seems to exist with metallic Materials.

          Thank your for your replies, MostHost LA!

          Comment


            #6
            Originally posted by Nuutia View Post
            My terminology seems to be off. I meant that the camera is restricted to certain axes. I can see how 'fixed' would mean it being totally still.

            I attached the Spotlight to the Object in World Outliner, but still had the same effect. I then experimented with 'Soft Source Radius' -slider and was able to lessen the effect with it - but the problem still existed.
            I then set another Spotlight and set a different Object with a different Material in front of it and the problem was gone. I applied a different Material to my first object and the problem was gone.

            I experimented and found that the problem seems to exist with metallic Materials.

            Thank your for your replies, MostHost LA!
            Good to know!

            Comment


              #7
              Can you give steps to reproduce?

              it seems wierd that - even if what you are seeing is actually just a Parallax effect and expected to happen - it would only occur on a metallic materials.
              also I guess engine version in use matters should this be a bug...

              Comment


                #8
                Here are the steps to reproduce:

                01. Make a new project with Side-Scroller Template and Starter Content.
                02. Place an empty cylinder shape to against a wall, rotate it and scale it so it resembles a 'thick coin'.
                03. Take a spotlight and adjust it's cones about two times the size of the cylinder. I removed all other lights from the scene.
                04. Apply material - M_Metal_Burnished_Steel - to both, the wall and the cylinder.
                05. Watch the spotlight's "burning point" move as you move your view in editor.

                Now that i did this new project, i realized that M_Brick_Clay_New -material also has this phenomenon - it is just not as easy to see. So i guess it's something every material has.

                Comment


                  #9
                  That's normal behavior though. you are looking sideways so you see a parallax effect happening. If you were looking at the door/coin from the exact same point as the light, you'd see no distortions. the moment the camera moves off to the side of the light, you experience a varying degree of parallax effect.

                  now is this accurate to the IRL amount you get? that's up for debate.

                  One thing is for sure however, the center of the spotlight is not behaving as it should be, that's too much of an offset. This could be due to the reflection capture. IS there one on the scene?
                  maybe the engine just doesn't really know what to do with the light reflection and it's incorrectly interpolating the parallax for it.
                  BTW, the material does need a normal map for the light to work right too, so make sure you have one applied.

                  If after checking the reflection and the different rendering layers the center of the spotlight remains so far to the left compered to the center, then
                  You should consider filing a bug report with the steps to see what the UE4 team says.
                  https://www.unrealengine.com/en-US/s...validated=true

                  Comment


                    #10
                    There is a Reflection Capture in the scene. It's the default one in the Side-Scroller Template.

                    I tried with different materials from the Starter Content and they all have the same effect: the burning point of the Spotlight has that offset, no matter if the material has Normal Map or not. I've also build Reflections and tried having the Spotlight as Stationery and Movable, but no change.

                    I file a report on this and let's see what their answer is.

                    Thank you again, MostHost LA, for taking your time and interest on this matter!

                    Comment

                    Working...
                    X