Closed antoniohof closed 6 years ago
Thx! This is really welcome!
I checked and it's luckily only the download domain that changed from https://poly.google.com/downloads/*
to https://poly.googleusercontent.com/downloads/*
. It's still working without API key after fixing this: https://github.com/archilogic-com/aframe-gblock/commit/356b922c9caf8e2339952684f731f8a6d330c1f5
If you don't mind: I will merge your code in such a way that the user can decide whether he prefers the official API using the API key (recommended) or the unofficial way without API key (for backward compatibility, keeping old implementations working). Would you be OK with that?
Sure! No problem :)
I just realized it's not working with GLTF2 models, change line 100 to
var format = info.formats.find( format => { return format.formatType === 'GLTF' || format.formatType === 'GLTF2'; } );
to fix it.
wondering how to extend the current a-frame component while keeping backward compatibility. what do you think about:
Using a Google Poly API key: (Recommended)
<a-entity gblock="https://poly.google.com/objects/dVG0XJrpRJC?key=xxxxxxxxxxxx"></a-entity>
Using unofficial API without key: (Legacy mode: Might be discontinued in the future.)
<a-entity gblock="https://poly.google.com/objects/dVG0XJrpRJC"></a-entity>
Demo was not working. Fixed by using official google poly API. Now it's necessary to setup your API_KEY