New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 715591 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: Jun 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Feature
Proj-VR
Proj-XR
Proj-XR-VR



Sign in to add a comment

Ensure fast text rendering for VR textures

Project Member Reported by cjgrant@chromium.org, Apr 26 2017

Issue description

Rendering 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.

 
Labels: hotlist-initial-vr-browser
Labels: -hotlist-initial-vr-browser
Cc: acondor@google.com mthiesse@chromium.org
Status: Available (was: Untriaged)
Summary: Ensure fast text rendering for VR textures (was: Implement font cache to improve rendering speed of text-based VR textures)
The font cache will certainly help, but may not be sufficient. We should do a perf audit.

Comment 4 by acondor@google.com, Apr 27 2017

Owner: acondor@google.com
Project Member

Comment 5 by bugdroid1@chromium.org, 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

Project Member

Comment 6 by bugdroid1@chromium.org, 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

Project Member

Comment 7 by bugdroid1@chromium.org, 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

Labels: -Pri-1 Pri-2
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.
Project Member

Comment 9 by bugdroid1@chromium.org, 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

Comment 10 by acondor@google.com, May 15 2017

Labels: -Pri-2 Pri-3
Currently, our longest rendering time texture is the Transient Security Warning for WebVR, which renders in ~6ms.
Owner: vollick@chromium.org
Passing the ownership before leaving.
Status: Fixed (was: Available)
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