Announcement

Collapse
No announcement yet.

Handheld AR World Origin

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

    Handheld AR World Origin

    For the new Handheld AR template in 4.19, what drives the world origin when the app is run on the device. I can't seem to figure it out. Sometimes it seems that the origin is placed at the device's location when the app is started. Is there any way to reset the origin to a location after the app has run? Like click on a location and reset the origin to that location? Or click a button the origin is reset to where the device is currently located?

    #2
    Hi, DMHokie!
    Take a look at this video https://youtu.be/wOuzD-Darms?t=2556
    Last edited by plastik21; 03-23-2018, 05:26 PM.

    Comment


      #3
      Now I'm experimenting with world alignment, but can't figure out what transform should I provide to SetAlignmentTransform node. I've tried to provide inverse transform of a point (TraceResult) on tracked plane. This works for the first time. But then if I click at the different location on the same plane then world origin flies far away. And all the rest clicks move world origin into incorrect spots. The same problem occurs if I provide non-inverse transform.

      Also I've noticed that GetLocalToTrackingTransform and GetLocalToWorldTransform nodes of a TraceResult object always return identical transforms whatever alignment transform is set.
      Is it bug or did I miss something? Where the tracking space origin is located and how it relates to unreal world space?
      Last edited by plastik21; 03-23-2018, 05:30 PM.

      Comment


        #4
        Finally, I've managed to set world alignment correctly: https://youtu.be/LPw-Von1r2g
        You need to keep current world alignment transform somewhere like in pawn's variable (it is strange there is no GetAlignmentTransform node). It's identity by default.
        If you want to move your world origin to some spot, you should get inverse transform of that spot and compose it with current world alignment transform. See attached screenshot.

        And as I said in the post above GetLocalToTrackingTransform and GetLocalToWorldTransform nodes of a TraceResult object always return identical transforms. I think this is bug. Because why do we need these two identical spaces?
        Last edited by plastik21; 03-25-2018, 04:41 PM.

        Comment


          #5
          Awesome. I haven’t had a chance to look into what you sent, but it seems like what I am trying to do is exactly what you showed. I’ll take a look and see if I can recreate it.

          Comment


            #6
            Thanks a load for the solution, you’re a star.

            Is that first Branch coming from the World Hit Test and Input Touch?
            Last edited by CGough; 04-05-2018, 12:24 PM.
            Modeller and many other things at Visualisation One

            Comment


              #7
              CGough, sorry, do not remember. I guess it comes from Touch Pressed.

              Btw, check out my progress in AR 4.19: https://youtu.be/Fvq6QnEFYkc

              Comment


                #8
                plastik21 It's Fine, It was, I just asked to cover any doubt but it seems to work just fine.

                Your work looks great too, lovely helicopter and particle effects. It's a wonder how much work goes into the blueprints and code before you can really make use of your good 3D work.
                Modeller and many other things at Visualisation One

                Comment


                  #9
                  CGough, It took me about 2 weeks to achieve the scene like helicopter's landing (the helicopter model was made by outsource artist and animated by me). I've started with no knowledge how to build iOS application on Windows platform, what are the limits of graphics on mobile devices, how AR works in general. But I have experience about a year in developing UE4 applications. Mostly blueprint projects. And yeah - google is the most valuable tool!

                  Comment


                    #10
                    plastik21 that's looking great ! The plane visualization looks nice, along with way to manipulate it's transform. Do you mind sharing the setup for the visualization perhaps ? Would save me the effort to actually look into it myself and I could return the favor by sending you out some beers
                    VR/AR Development [Portfolio | YouTube | LinkedIn]

                    Comment


                      #11
                      Shin_ji, what part of visualization are you interested in exactly?

                      Comment


                        #12
                        Are you able to scale the world origin to scale the scene?

                        Comment


                          #13
                          Lutherbrian, Unfortunately, I couldn't find the proper way out of the box to scale the level except manually go over all actors and scale each of them individually. In my project I only spawn a single actor in level which basically is a mesh with sounds and particles. And then just scale the actor (SetWorldScale3D). It's suitable for my project purposes. Indeed not fully - particles are scaled incorrectly - the size is scaled, but velocities are left the same. I guess I have to scale velocities as well and probably some other particle system parameters. So much headache

                          Comment


                            #14
                            I've seen that Unity has this feature fully integrated, it doesn't scale the scene but rather manipulates the camera actor to make it appear smaller so that the issues you are having with particles is non existent. Seems something that should be coming in future updates as it would be fundamental in creating an AR game.

                            Comment


                              #15
                              plastik21 your ar project looks cool. In your video it looks like you are also rotating the scene alignment. How do you do that? I tried it but is doesn't work properly.

                              Comment

                              Working...
                              X