Skip to content

Fontrendering#40

Draft
FabianWildgrube wants to merge 33 commits into
maplibre:mainfrom
FabianWildgrube:fontrendering
Draft

Fontrendering#40
FabianWildgrube wants to merge 33 commits into
maplibre:mainfrom
FabianWildgrube:fontrendering

Conversation

@FabianWildgrube

@FabianWildgrube FabianWildgrube commented Apr 25, 2022

Copy link
Copy Markdown
Contributor

Adds an experiments folder with a standalone native app that tests rendering of text on the GPU.

See detailed explanation and a first benchmark here.

This PR is not finished, rather opened as a draft for visibility purposes.

Open Issues include:

  • overlapping text "cancels" each other out, due to trick in fragment shader
  • Glyphs are "tesselated" and drawn naively (i.e. each gets their own buffer, each gets a single draw call)
  • Only tesselate each glyph once
  • Draw instanced
  • Enable styling (e.g. colors for a start)

This experiment could also be refactored to abstract the boilerplate code for the standalone winit/wgpu application away, so that that can be reused for other experiments (if we don't want to always work with the full maplibre-rs project as the basis)

@FabianWildgrube FabianWildgrube mentioned this pull request Apr 25, 2022
@FabianWildgrube

Copy link
Copy Markdown
Contributor Author

Current status: Instances Rendering with support for per-word colors
Screenshot 2022-05-15 at 10 27 29
(This frame took 8ms rendering time on M1 Macbook Pro)

@maxammann

Copy link
Copy Markdown
Collaborator

Worth checking out: https://github.com/yeslogic/allsorts

@maxammann maxammann force-pushed the main branch 3 times, most recently from 8c5d8ee to 4dbd47b Compare June 3, 2022 09:54
@maxammann

Copy link
Copy Markdown
Collaborator

@FabianWildgrube Hi! Are you still interested in pushing this forward? I think this approach is still very nice, though there were some limitations I don't remember right now.

@FabianWildgrube

Copy link
Copy Markdown
Contributor Author

Hi @maxammann - I still think it's an interesting and fun problem to look at. But realistically I'm not going to get to it because of work and other obligations 😞

@maxammann

Copy link
Copy Markdown
Collaborator

Hi @maxammann - I still think it's an interesting and fun problem to look at. But realistically I'm not going to get to it because of work and other obligations 😞

Yeah same here :) no worries!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants