Git Product home page Git Product logo

Comments (4)

Algorush avatar Algorush commented on May 29, 2024

I suggest to change once in one place of the code all the width values ​​in the object with the data received from the streetmix API. So as not to convert to meters everywhere where necessary. @kfarr what do you think about this?
Because, the processSegments function in aframe-streetmix-parser recieve only part of recieved JSON with segments data. But the schemaVersion, as well as units, are at a higher level in recieved JSON.
That is, there will be no need to change the structure of existing code. And remove the conversion of feet to meters everywhere. And moving it to the moment the JSON response is received from the API in streetmix-loader component

from 3dstreet.

Algorush avatar Algorush commented on May 29, 2024

More notes and sample API responses for new metric responses:

PR #486. Tested with all cases from here streetmix/streetmix#2900

from 3dstreet.

Algorush avatar Algorush commented on May 29, 2024

I'll change tests also

from 3dstreet.

kfarr avatar kfarr commented on May 29, 2024

Just sharing notes testing with a streetmix staging server providing metric responses

Testing technique, load the 3dstreet app and type the following in console:

newEl = document.createElement('a-entity')
newEl.setAttribute('streetmix-loader', 'streetmixAPIURL: https://streetmix-staging.herokuapp.com/api/v1/streets?namespacedId=295')
parentEl = document.querySelector('#street-container')
parentEl.appendChild(newEl)

Behavior on 3dstreet.app (production) using OLD parser, parsing the NEW streetmix metric API response. This is using old parser that does not support metric, therefore we expect this to look incorrect, and it does!
image

Behavior on github.3dstreet.org with NEW streetmix metric API response which supports the new metric api is correct:
image

Behavior on github.3dstreet.org with OLD streetmix imperial API response:
image

Therefore both imperial and metric responses work as expected on the new release. I think we're good!

from 3dstreet.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.