I want to add frame markers to my Unity game at runtime. I made a prefab which is basically the same as the FrameMarker prefab provided by QCAR but with some additional graphics and logic scripts added.
I create the frame markers by calling:
frameObject = Instantiate(FrameMarker, Vector3(0,0,0), Quaternion.identity);
Where the FrameMarker variable is the prefab (dropped onto the inspector window).
When a frame marker is created by calling Instantiate, it creates a game object called "FrameMarker(clone)". No marker is visible in the game scene on the PC. When the frame marker clone is clicked on in the Hierarchy window, it's name changes to "FrameMarker0" (and FrameMarker1, etc.. for additional markers if clicked). Only when the name changes does the frame become visible in the game scene.
The tracking does not work on Android. I cannot "click the game object in the Hierarchy view" on Android, so trying that won't work.
I can't add the frames manually in the Hierarchy. Adding all of them will be too much work.
Any idea how to solve this?