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

地図画面の動作が遅い #370

Closed
ssig33 opened this issue Mar 2, 2021 · 7 comments · Fixed by #437
Closed

地図画面の動作が遅い #370

ssig33 opened this issue Mar 2, 2021 · 7 comments · Fixed by #437

Comments

@ssig33
Copy link
Contributor

ssig33 commented Mar 2, 2021

地図をドラッグ&ドロップした時の挙動がとにかく遅くて、印刷したい地図の状態を得るのが困難であると思う

@smellman
Copy link
Contributor

smellman commented Mar 3, 2021

ちなみに、2019年台風19号のマップを見ているならば、そもそもデータ量が多すぎるので、重くて当然というのはある。

これ?

@takano32
Copy link
Contributor

takano32 commented Mar 3, 2021

補足。

Slack

Image from Gyazo

つまり

Image from Gyazo

@yuiseki
Copy link
Collaborator

yuiseki commented Mar 4, 2021

smellman added a commit that referenced this issue Apr 24, 2021
smellman added a commit to smellman/mapprint that referenced this issue Apr 24, 2021
@halsk halsk unassigned ssig33 and smellman Jan 4, 2024
@halsk
Copy link
Member

halsk commented Jan 4, 2024

この問題は引き続き解消されていないので、なんとかしたいところ

@smellman
Copy link
Contributor

smellman commented Jan 4, 2024

markerではなくSpriteを表示するようにすると高速に動くはずだが、Spriteを動的に作る仕組みなどを考える必要がある。

@Kanahiro
Copy link
Contributor

Kanahiro commented Jan 4, 2024

この件、気になったのでみてみましたが

inBoundsMarkers() {

①地図移動のたびにcomputedプロパティのinboundMarkersが再計算され、②この値に依存する別のcomputedが再計算され…と重たいようです。GeoJSONのループ自体が重たいのかも?

たとえば常に全件表示するようにすると、地図操作のパフォーマンスは改善するような気がします。それでもフレームレートは遅いですが。なので地図の描画速度がボトルネックではない気がしました。

@Kanahiro
Copy link
Contributor

Kanahiro commented Jan 4, 2024

概要はPRに書いてありますが、毎回markerを全てループしていて、かつコストの高い処理が入っていたのが、パフォーマンス低下の原因と思われます。

@halsk halsk closed this as completed in #437 Jan 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
6 participants