3DStreet / 3dstreet

🚲🚢🚌 Web-based 3D visualization of streets using A-Frame
https://3dstreet.app
Other
256 stars 33 forks source link

can't change the parameters of the street component for a scene loaded from JSON #459

Closed Algorush closed 3 months ago

Algorush commented 8 months ago

After loading the scene from JSON, the #default-street element does not have a street component, meaning we cannot change its properties such as showAnimation, sowGround, ...

kfarr commented 7 months ago

As a user, I wish to change street and streetmix-loader parameters upon reloading a saved scene. Including the option to regenerate the street from streetmix or change the URL to another street

Algorush commented 5 months ago

I propose the following solution to make it possible to change the parameters of the street and streetmix-loader components after loading a scene from a JSON file.

  1. avoid renaming street to not-street and streetmix-loader to not-streetmix-loader.
  2. Don't call init/update methods of the street and streetmix-loader when loading scene with these components from JSON. To do this I will add a global variable: STREET.sourceType = jsonFile/streetmix/streetplan.

And then make ability to change street component parameters without scene reloading: https://github.com/3DStreet/3dstreet/issues/511