Ensure fast text rendering for VR textures |
||||||||
Issue descriptionRendering performance of natively-rendered HTTP warnings could be improved with a font cache. The goal is to minimize delay when entering VR. This is follow-on work to crbug/713779.
,
Apr 26 2017
,
Apr 26 2017
The font cache will certainly help, but may not be sufficient. We should do a perf audit.
,
Apr 27 2017
,
Apr 28 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/255a2914d4d023ca040c250e2ce129e1e5370a05 commit 255a2914d4d023ca040c250e2ce129e1e5370a05 Author: mthiesse <mthiesse@chromium.org> Date: Fri Apr 28 18:39:49 2017 VR: Get fallback fonts for set of characters rather than full string. This shaves ~6ms off of our total skia render time for English. Similar numbers for other languages. BUG= 715591 Review-Url: https://codereview.chromium.org/2846023002 Cr-Commit-Position: refs/heads/master@{#468070} [modify] https://crrev.com/255a2914d4d023ca040c250e2ce129e1e5370a05/chrome/browser/android/vr_shell/textures/ui_texture.cc
,
May 8 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/f6d4d348d9ebd6a7efeaf289c1c696d433c278ca commit f6d4d348d9ebd6a7efeaf289c1c696d433c278ca Author: vollick <vollick@chromium.org> Date: Mon May 08 15:43:08 2017 Add tracing to TexturedElement BUG= 715591 Review-Url: https://codereview.chromium.org/2864903002 Cr-Commit-Position: refs/heads/master@{#469992} [modify] https://crrev.com/f6d4d348d9ebd6a7efeaf289c1c696d433c278ca/chrome/browser/android/vr_shell/ui_elements/textured_element.cc
,
May 10 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/03c0b57bb3900cb5f1f481163a40a038e2498f39 commit 03c0b57bb3900cb5f1f481163a40a038e2498f39 Author: acondor <acondor@google.com> Date: Wed May 10 21:09:25 2017 Fallback Font Cache and Character Hinting for VRShell - An Android-only font cache was implemented, mimiking Linux's. - In order to increase cache hits, we use ICU scripts and only query one character per script. - Only get a fallback font if the main font is not able to render the character. And always check if previous fallback fonts already support the character. This change solves the issue of extra line spacing that was being introduced by including extra (unnecessary) fallback fonts. BUG= 715591 Review-Url: https://codereview.chromium.org/2863693002 Cr-Commit-Position: refs/heads/master@{#470706} [modify] https://crrev.com/03c0b57bb3900cb5f1f481163a40a038e2498f39/chrome/browser/android/vr_shell/BUILD.gn [add] https://crrev.com/03c0b57bb3900cb5f1f481163a40a038e2498f39/chrome/browser/android/vr_shell/font_fallback.cc [add] https://crrev.com/03c0b57bb3900cb5f1f481163a40a038e2498f39/chrome/browser/android/vr_shell/font_fallback.h [modify] https://crrev.com/03c0b57bb3900cb5f1f481163a40a038e2498f39/chrome/browser/android/vr_shell/textures/ui_texture.cc [modify] https://crrev.com/03c0b57bb3900cb5f1f481163a40a038e2498f39/ui/gfx/platform_font_linux.cc [modify] https://crrev.com/03c0b57bb3900cb5f1f481163a40a038e2498f39/ui/gfx/platform_font_linux.h
,
May 11 2017
Since our perf is now passable, I've changed the priority. Don't want to close this, of course, because there's still ongoing work.
,
May 13 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/b40dc0c1f2fea886a3184e9c3265c9d9f8d7275f commit b40dc0c1f2fea886a3184e9c3265c9d9f8d7275f Author: acondor <acondor@google.com> Date: Sat May 13 00:14:24 2017 VR: Avoiding regeneration of RenderText objects for texture rendering - Code is based in gfx::Canvas::DrawStringRectWithFlags, but tailored for VR needs and instead of drawing, it returns a list of RenderText. - For textures that require text measurement, both the measurement and drawing is done in a single pass. - Being the text layout the most expensive operation for texture rendering, times are reduced to almost half. BUG= 715591 Review-Url: https://codereview.chromium.org/2877673005 Cr-Commit-Position: refs/heads/master@{#471503} [modify] https://crrev.com/b40dc0c1f2fea886a3184e9c3265c9d9f8d7275f/chrome/browser/android/vr_shell/textures/insecure_content_permanent_texture.cc [modify] https://crrev.com/b40dc0c1f2fea886a3184e9c3265c9d9f8d7275f/chrome/browser/android/vr_shell/textures/insecure_content_transient_texture.cc [modify] https://crrev.com/b40dc0c1f2fea886a3184e9c3265c9d9f8d7275f/chrome/browser/android/vr_shell/textures/ui_texture.cc [modify] https://crrev.com/b40dc0c1f2fea886a3184e9c3265c9d9f8d7275f/chrome/browser/android/vr_shell/textures/ui_texture.h [modify] https://crrev.com/b40dc0c1f2fea886a3184e9c3265c9d9f8d7275f/chrome/browser/android/vr_shell/textures/url_bar_texture.cc [modify] https://crrev.com/b40dc0c1f2fea886a3184e9c3265c9d9f8d7275f/chrome/browser/android/vr_shell/textures/url_bar_texture.h
,
May 15 2017
Currently, our longest rendering time texture is the Transient Security Warning for WebVR, which renders in ~6ms.
,
Jun 1 2017
Passing the ownership before leaving.
,
Jun 8 2017
Text rendering speed is acceptable. Closing. We can add a separate bug for GPU accelerated text rendering if it becomes important later. |
||||||||
►
Sign in to add a comment |
||||||||
Comment 1 by vollick@chromium.org
, Apr 26 2017