Skip to content

LoD1 terrain #79

Answered by liberostelios
AdrianKriger asked this question in Q&A
Jul 12, 2021 · 1 comments · 6 replies
Discussion options

You must be logged in to vote

Hi Adrian. Glad to see you are interested in CityJSON.

I think your issue is in add_terrain_v, where there seems to be one extra square bracket wrapped around the vertex coordinates. The right code should be:

def add_terrain_v(pts, cm):
    for p in pts:
        cm['vertices'].append([p[0], p[1], p[2]]) # <- There was an extra square bracket here

Haven't checked thoroughly the rest of the code, but this for sure is an issue.

PS: It's very nice to see that you have some nice metadata in your model! 👏

Replies: 1 comment 6 replies

Comment options

You must be logged in to vote
6 replies
@liberostelios
Comment options

@AdrianKriger
Comment options

@liberostelios
Comment options

@AdrianKriger
Comment options

@hugoledoux
Comment options

Answer selected by AdrianKriger
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants
Converted from issue

This discussion was converted from issue #77 on July 13, 2021 09:25.