question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Implement a canvas renderer

See original GitHub issue

A work in progress is already well under way. The performance benefits seem to far outweigh anything that can be accomplished in the DOM.

The main drawbacks of using canvas over the DOM:

  • We lose functionality provided by text and node in the DOM, namely:
    • Selection & context menus, this doesn’t matter as we already reimplemented them to work around then DOM getting in the way
    • Links just work in the DOM; create an <a> and just put it somewhere. This needs more handling code to work in a canvas.
  • Zooming in will blur the text, so it’s best used at 100% page scale

I’ll list most of the improvements and bug fixes that canvas provided in the PR which should be out soon 😄

Marking as breaking as we need new API around colors and font styles which will be managed in TS.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:2
  • Comments:16 (14 by maintainers)

github_iconTop GitHub Comments

4reactions
mofuxcommented, Sep 2, 2017

♥️♥️♥️♥️

0reactions
Tyriarcommented, May 18, 2018

@jerch that’s how it was, and yeah it was a lot faster. The reason it switched back is because characters need to overlap in order for parts of characters not to be cut off. I plan on getting to minimizing draws eventually.

@odrzutowiec that does seem a bit slow, what browser/version/os are you on? Let’s create a separate issue to discuss. Also only ascii is optimized currently, there’s a lot of opportunity to speed up for non-ascii characters.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Scripting API: CanvasRenderer - Unity - Manual
Description. A component that will render to the screen after all normal rendering has completed when attached to a Canvas. Designed for GUI...
Read more >
Canvas Renderer component - Mastering UI Development ...
For a UI element to render, it must have a Canvas Renderer component on it. All of renderable UI elements that you create...
Read more >
Getting started with the Canvas renderer | Three.js Cookbook
If your system doesn't support WebGL, there is an alternative renderer that you can use to render your scenes: the CanvasRenderer object.
Read more >
dmester/canvas-renderer - GitHub
HTML5 inspired canvas implemented in Node.js for rendering PNG images. Render simple polygons as PNG with no native dependencies like PhantomJS. The library ......
Read more >
Minecraft Java 1.17.1 Canvas Renderer Shaders ... - YouTube
With Canvas Renderer Mod we can use shaders and increase our FPS performance. I use the example of Lumi Lights shaders in this...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found