Thank you for your reply.
I understand the matter of cash.
As
a result of the verification from that, it was found that an error
occurs when loading AR.Model instantaneously in repeat processing.
If we put drawables.addCamDrawable in onEnterFieldOfVision function and load AR.Model gradually, it did not result in error.
The following is a sample code when an error occurs.
var World = { initiallyLoadedData: false, renderingARObjects: function(poi) { var perRotate = 30; var perTranslate = 10; var location = new AR.GeoLocation(poi.latitude, poi.longitude, poi.altitude); for (var i = 1; i <= 5; i++) { var relative = new AR.RelativeLocation(location, perTranslate * i, 0, -10); var model = new AR.Model('assets/car.wt3', { rotate: perRotate * i }); var tracker = new AR.GeoObject(relative, { drawables: { cam: [model] } }); } }, locationChanged: function(lat, lon, alt, acc) { if (!World.initiallyLoadedData) { World.renderingARObjects({ 'latitude': lat, 'longitude': lon, 'altitude': alt }); World.initiallyLoadedData = true; } } }
Unfortunately, due to corporate confidentiality, I can not provide wt3 files.
Instead, I will show the spec.
Terminal: ASUS MeMO Pad HD 7
OS: Android 4.2.2
Wikitude SDK: 6.1
Wikitude3DEncoder: 1.7
Hello,
from what I can see, you had the right idea the first time around; you actually need to instantiate separate AR.Model objects. The question of why that is not working for you remains.
Internally, we only load any given wt3 file once and cache it. So there should be no need to worry about re-loading your model.
I'd like you to provide a minimal sample code on how I can reproduce the errors you have outlined. Ideally I'd like to use your wt3 file as well.
Kind regards
Daniel
忠 村上
Hello.
First of all, I apologize that I am not good at English.
I would like to render multiple AR.Models with heavy file size (many meshes).
The file has a configuration of 9.24 MB in capacity, 52970 in Vertices, 1 in Meshes (texture size is 2048 × 2048).
If I try to load this file in iterative processing, it will result in errors with the following message.
The reason why multiple AR.Models are loaded multiple times is because the ModelMatrix is different (scale, rotate, translate).
Why is such an error going out?
Both SDK and encoder version are latest.
Therefore, I will load AR.Model only once (new Instance) in order to improve processing speed, and change ModelMatrix in iteration.
Here is the sample code.
If you execute this code, all cars will have the same rotation.
Can not render with each ModelMatrix?