Is it possible to update already visible and displayed POI? I want to respont to some events, e. g. additional data about POI becomes available, which I want to display near POI/ update POI icon etc. Additinaly, is it possible to display some "raw text" near POI icon?
and it works fine. How can I access first property in X? If I manage to edit it, how can I notify ARchitect engine to refresh view on device?
I hope you got what I meant to say :)
Kind regards,
Branimir
A
Andreas Fötschl
said
over 10 years ago
Hi Branimir!
You can change AR.Label's attributes by direct access using e.g. myLabel.text = "my new label text"
Hope that helps.
Kind regards, Andreas
B
Branimir Pervan
said
over 10 years ago
Andreas,
thanks again for your answer and effort. With your guidance, I managed to solve my problem :)
Best regards,
Branimir
L
Leandro
said
over 10 years ago
Hi, everyone. Sorry for bringing up this issue again.
I can't figure out how to update already displayed POIs. Assuming the SimpleARBrowser example that comes with Wikitude SDK, if I create a method called "updateData()" in the ARchitectBrowser.html similar to "newData()", how can I access and modify all the POIs being displayed? I read in one of the comments inside ARchitectBrowser.html that the jsonObject array "keeps jsonData received from the native app" but I can't update the changes made inside it.
Thanks in advance. Best regards.
Leandro
A
Andreas Fötschl
said
over 10 years ago
Hi Leandro,
When reloading POI data you may either update lablels and information of existin places in case you e.g. just want to update POI title or destroy existing placemarks and recreate new ones.
There is documentation in how to properly destroy GeoObjects, you can afterwards simply recreate them. I recommend you to define a clear-function that wipes all AR content and call it as first line in your newData-function, that way you can easily update your data.
Please also keep in mind, that radar-component will also be destroyed when calling AR.context.destroyAll(), so you may need to redefine the radar.
Branimir Pervan