Passing Transformation from the Unreal Scene - default position not working

 

I have some problems with passing transformation from Unreal to Axi - everything is working correctly and I have control of transformation but Axi repositions my stuff right in the middle of the level (in 0,0,0). I tried to set the default value (by adding a variable node) in node "Get Aximetry Transformation" but it didn't work. How to solve this? I want to have control over my meseches but I need them to be exactly where I put them in Unreal.

   KGH.EC

 
Profile Image
Eifert@Aximmetry
  -  

Hi,

Get Aximmetry Transform passes Transformation from Aximmetry to Unreal and not the other way around.
Get Aximmetry Transform exposes the Transform in Aximmetry once you import the Unreal project into an Aximmetry compound/project. The exposed new pin will have the (0,0,0) value, which is why it was always at the (0,0,0) position.

Warmest regards,

 
Profile Image
chinzillafilms
  -  

Hi Eifert! I had the same question and you did not answer it or understood it correctly. When I have an object placed in my UE scene AND want to control it in Unreal, BUT I need to have the object positioned right where I did in Unreal (not 0.0.0.), what do I do? Thank you :)

 
Profile Image
TwentyStudios
  -  

@chinzillafilms: Aximmetry doesn’t receive the position of the object from UE4, so it’s expected that it defaults to the 0.0.0 position since that’s the position it gets from Aximmetry. You could just copy/paste the transform manually from the UE4 scene. What I usually do if I want to control the object position relative to the UE4 position is that I parent the object(s) to a Null object placed at 0.0.0 in the UE4 scene. I then do GetAximmetryTransform on the Null object instead. That way everything stays in place in the UE4 scene while still being controllable from Aximmetry.

 
Profile Image
Eifert@Aximmetry
  -  

Hi Chinzillafilms,

Yes, I misunderstood the original post a bit.

So connecting anything to the Default Value won't work.
However, you can change the Default Value in the node using the Split Struct Pin option when right-clicking on the Default Value text:
->
If you add the Unreal project to a new Aximmetry project with an edited Get Aximmetry Transform Default Value, then in Aximmetry the pin of the Unreal module will have the same value as the Default Value. However, it won't change back to this Default Value once you edit it in Aximmetry.

All this probably won't help with your workflow and you should probably follow TwentyStudios suggestion.
Also, note that distances in Unreal are in centimeters, so if you copy-paste position values from Unreal to Aximmetry, you will have to divide it by 100.
The Default Value in the Get Aximmetry Transform uses Aximmetry's meter-based unit of length.

Warmest regards,

 
Profile Image
anzaaximm
  -  

@TwentyStudios please show me how you do this with an example

 
Profile Image
TwentyStudios
  -  

@anzaaxim: Instead of me spending an hour creating a custom tutorial just for you, wouldn’t it be more efficient if you spent a couple of minutes searching for a tutorial on how to parent an object to another object in Unreal? This isn’t something specific to Aximmetry, so you’ll find plenty of material if you just search for it. 

 
Profile Image
RikvdReijen
  -  

Hey anzaaximm, have you figured out how to do this? I would like to automatically get the positions of the ArUco markers I have placed in the 3D environment and have standardized names to be able to quickly jump from location to location. I would like to stay in Unreal as much as possible to avoid rework on edits.

My LLM suggest I should communicate the Unreal transform data based on UDP or OSC. I have no idea how that would be done or if it is possible.

 
Profile Image
alan.shi
  -  

@TwentyStudios Hello, I followed your method and used a 0.0.0 parent object to indirectly manipulate the position rotation of child objects. However, there is a huge issue that the pivot point is still located at 0.0.0 instead of the axis of the object I placed in UE4. This rotation is incorrect. Is there any way to modify the pivot point in aximmetry without changing the position of the object

 
Profile Image
Eifert@Aximmetry
  -  

Hi RikvdReijen,

Could you provide more details on what you intend to achieve with the ArUco markers? Specifically, how would the position jump from one location to another?

In any case, you should use the Get Aximmetry Transformation node in Unreal as described here: https://aximmetry.com/learn/virtual-production-workflow/obtaining-graphics-and-virtual-assets/creating-content-for-aximmetry-de/additional-control-with-blueprints/#get-aximmetry-transformation

In Aximmetry, you can detect ArUco markers by using the Marker Detector module as follows:

Where the modules named CAMERA TRANSFORMATION, CAMERA ZOOM FACTOR, and LENS DISTORTION are Transmit Transformation, Transmit Scalar, and Transmit modules. These modules will change their names based on the From Tunnel pin's value, which you'll need to specify accordingly.

Warmest regards,

 
Profile Image
Eifert@Aximmetry
  -  

Hi Alan.shi,

It seems like you might be modifying a parent object's location that is connected to your model in a way that affects it directly. You could try creating a new actor in Unreal, placing your object under it in the Outliner panel, and then modifying only the new actor's position from the blueprint.

Warmest regards,

 
Profile Image
RikvdReijen
  -  

Hi Eifel, I am trying to achieve the automatic obtainment of the ArUco marker as placed in Unreal and the automatic adjustment of my tracked camera. I had some trouble understanding finding the Lens distortion compound, is it the same as the camera out size. I previously had used the camera tracking compound which has the same outputs, I never got that to work and assume that would only work for the tracked camera. I assume yours would apply to both the tracked and virtual camera (which can be great).

Passing Transformation from the Unreal Scene - default position not working

I did not get it to work yet since I don't know what the cube object in your Unreal scene is? Is that the ArUco marker? Ideally I would like that to be bi-directionally driven by Unreal Engine and Aximmetry (preference towards Unreal Engine at least as initial transform value)

 
Profile Image
Eifert@Aximmetry
  -  

Hi,

It seems you are rendering an ArUco marker in Unreal and intend to place the camera there, which is definitely more complex than necessary.

The picture in the above posts will not work, as the Video Input is connected to the Marker Detector module instead of Unreal's rendered image.
Also, note that for it to work, the camera would need to point at the virtual ArUco code.

The Lens Distortion transmit tunnel is only present if you're using a tracked camera compound:
Passing Transformation from the Unreal Scene - default position not working
If you are using Unreal's rendered image in the Marker Detector, there's no need to connect anything to the Marker Detector's Lens Data pin, since Unreal will render without any distortion.

The Cube object was just an example to demonstrate placing a virtual object, such as a virtual cube, where an ArUco marker is located in the real-world studio.


Currently, there isn't a built-in method to send data from Unreal code to Aximmetry. As your LLM suggested, using the OSC protocol might be a solution for sending data from Unreal to Aximmetry. Once Aximmetry receives the Unreal transformation, you'll need to convert it into Aximmetry's coordinate system. This can be done by editing the
[Common_Studio]:Compounds\Tools\Unreal_Transformation.xcomp compound, which includes logic for such conversions.

If you don't require this functionality to be dynamic, you can manually copy and paste the transformation data from Unreal into the
[Common_Studio]:Compounds\Tools\Unreal_Transformation.xcomp compound without using OSC.  I recommend trying this at first.

Warmest regards,

;