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

Fontrendering #40

Draft
wants to merge 33 commits into
base: main
Choose a base branch
from
Draft

Conversation

FabianWildgrube
Copy link
Collaborator

@FabianWildgrube FabianWildgrube commented Apr 25, 2022

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
Collaborator 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
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
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
Collaborator 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
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