Open RustyRaptor opened 10 months ago
Well going back and starting over has fixed the issue. So I guess this isn't really a bug with APS but just my implementation is broken. I'll try to figure out why that is.
Ok so turns out that the reason this was happening was because the images used for the sprites were taking too long to load because they are too big (600 by 600)ish. I noticed this when I started changing the images around the issue started again. Reducing the size of the images to 32 by 32 fixed the issue. I'm sure bigger sizes would work but I decided to match the size I was using for the sprites options.
I am wondering if maybe the implementation needs to be different to avoid this issue entirely. Maybe something with the order in which things are being done is causing the sprites to refresh way sooner than the images loading? Or does this have something to do with the 3D viewer rendering too fast? I feel like I am in way over my head trying to figure this out now.
I realize this could be the wrong place to report this. Let me know if I need to move this to another repo or a support channel.
https://github.com/autodesk-platform-services/aps-iot-extensions-demo/assets/7911442/608d5cbb-8714-415a-85f4-a92192f3aa73
Here is some of the output I get if I log the ViewableData
_spritesMap:
_viewablesMap:
Some parts of my code:
_refreshSprites()
_process_sensor()
_set_sensor_style_and_map_issues()
create_viewable()
_create_visual_style()
update() and constructor