Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GLTFLineString 用map.toJSON() 导出为json后 data里面不是原来的3个点位置信息 生成了 很多个点 (36个) #799

Closed
lzp0070007 opened this issue Nov 29, 2024 · 1 comment · Fixed by fuzhenn/gl-layers#32
Assignees
Labels
gltf 与@maptalks/gltf-layer有关的issue

Comments

@lzp0070007
Copy link

GLTFLineString 用map.toJSON() 导出为json后 data里面不是原来的3个点位置信息 生成了 很多个点 (36个) 然后把这个json用new maptalks.Map.fromJSON(this.id, mapJson); 初始化 也会报错
604fe4bc45c19de8a2ac728e97d6640f
75962934113163cba9ae8dfaa2c214ad

@fuzhenn fuzhenn assigned fuzhenn and liubgithub and unassigned fuzhenn Dec 4, 2024
@fuzhenn fuzhenn added the gltf 与@maptalks/gltf-layer有关的issue label Dec 4, 2024
@liubgithub
Copy link
Collaborator

@lzp0070007 GLTFLineString会根据线条在中间插值模型,所以生成36个模型是正常,比如沿着路线种树。如果不希望插值,可以直接用GLTFMarker或者MultiGLTFMarker。另外Map.fromJSON报错是个bug,这个会在下个版本改过来

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
gltf 与@maptalks/gltf-layer有关的issue
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants