3dstreet icon indicating copy to clipboard operation
3dstreet copied to clipboard

ensure auto-striping works after type change / delete / add

Open kfarr opened this issue 1 year ago β€’ 1 comments

  • where is existing striping logic? streetmix-parsers? https://github.com/3DStreet/3dstreet/blob/main/src/aframe-streetmix-parsers.js#L51
  • what are the key variables needed to infer striping? current type / previous type / direction for each -- infer from object? or infer from segment dom metadata?
  • can this be run for only 1 segment at a time? (ie when adding / removing?)
  • how to convert to output a component street-generated-striping

instead, consider

  • in managed street when parsing by object, for each segment, determine left striping based on current segment and its previous segment
  • need to have access to the current segment and the previous

kfarr avatar Dec 20 '24 18:12 kfarr

works when loading from start

next considerations:

  • how should striping behave when a segment is deleted? recalc
  • how should striping behave when a segment is inserted or moved? recalc
  • how should striping behave when a segment is changed -- change type or direction? (recalc)

--> need a function that is evaluating striping in place instead of generating at the object level

  • recalculate striping

  • for each segment evaluate -- need access to "previous" segment type and direction

  • as a user doing rapid prototyping, I would expect the striping to change automatically, similar to justification / alignment updating

  • however at some point I may wish to change this value manually and then I don't want those values to update

kfarr avatar Dec 29 '24 22:12 kfarr