Nayera-mohamed / andar

Automatically exported from code.google.com/p/andar
0 stars 0 forks source link

How can I disable other marker detection when one model is already visible on a marker #45

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Keep 2 markers in close proximity. Register 2 different models to these 2 
markers. 
2. Now point to one of the marker. The correct model shows up.
3. Now position the mobile camera in such a way that both the markers are 
visible. Now both the models show up, but in my app I want to show only one 
model at a time.

What is the expected output? What do you see instead?
I want to show only one model at a time. I see both the model. I tried add 
visibility listener to unregister the other models but it does not get called 
in latest AndAR code.

What version of the product are you using? On what operating system?
Latest AndAR library.

Please provide any additional information below.

Original issue reported on code.google.com by rupam.bh...@gmail.com on 25 Nov 2010 at 8:33

GoogleCodeExporter commented 8 years ago
I fixed this by using the name in the ARObject as an unique ID. 
Then I made a controller which has the IDs of the markers I want to draw on. 
Inside the draw function of the ARObject you must check if that object needs to 
be drawn.

You also can turn it around.
When using the name of the ARObject you can let the controller decide what to 
draw.
With this method you only have to implement one kind of ARObject.

Original comment by D.J.Span...@gmail.com on 15 Dec 2010 at 6:58

GoogleCodeExporter commented 8 years ago

Original comment by raghavsood on 8 Jul 2012 at 10:40