Unity-Technologies / arfoundation-samples

Example content for Unity projects based on AR Foundation
Other
3.04k stars 1.14k forks source link

Image Tracking: Using four Images to scale a Plane #996

Closed gentlejohnny closed 2 years ago

gentlejohnny commented 2 years ago

I started building an Android and iOS AR application with image tracking. The goal is to build a plane with a material on it based on the space between 4 trackable images. So my system should detect and store four image trackers and create Emptys at their locations. With these GameObjects, a custom written Mesh Pipeline should triangulate a plane scaled to these four trackers.

Now I have the Problem that all my created GameObjects have the same location and I realy don't know why. Do your guys know maby why. In the following are my codes for this procedure.

Also I think that based on my triangulation the order of the GameObjects in the Array has to be the same. My Idea was to make the coordinated from the GameObjects comparable with the help of the own created list.

This first class defines the List which is used to have an overview about all the tracked Images and related GameObjects.

gentlejohnny commented 2 years ago

I was able to find out that all my GameObjects are getting the location from my Session Origin when tracked but I don't know how to fix it

ankur-unity commented 2 years ago

There is an ongoing discussion in our forum for a similar issue: https://forum.unity.com/threads/unity-ar-app-android-and-ios-image-tracking-using-four-images-to-scale-a-plane.1310606/

gentlejohnny commented 2 years ago

There is an ongoing discussion in our forum for a similar issue: https://forum.unity.com/threads/unity-ar-app-android-and-ios-image-tracking-using-four-images-to-scale-a-plane.1310606/

Hey, the other discussion is also from me and can't help me that far right now. I hoped to have a diffrent range on this side to get to people...thanks for closing my topic without futher notice. As you can see is the topic on the other site still not finished/closed so why should thone?

tdmowrer commented 2 years ago

As a frequent lurker on this GitHub, it does stand out to me that issues are often marked as "closed" as soon as they are responded to. It would be nice to clarify (perhaps in the README) what that means exactly. For example, "closed" could mean

  1. Unity considers the matter resolved, and no further action will be taken to address it.
  2. The issue is not resolved, but it is being handled elsewhere / this isn't the right forum for it.
  3. Responded; back to you! In this case, should OP reopen the issue to put it back into the queue?

Lurking on this thread as I do, I see a lot of interpretations like (1) above, where "closed by Unity" feels a bit premature. If the intent is closer to (3), it would be good to clarify that to avoid (pardon the phrasing) pissing off the community :)

gentlejohnny commented 2 years ago

Hello again, I coudn't solve my problem by now but I found out that if I put a prefab (in my case an empty GameObject) in the AR Tracked Image Managers TrackedImagePrefab I got diffrent Vector3 for the position of the images. Does anyone know why this makes such an impact