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

Support for canvas elements on quads. #634

Merged
merged 2 commits into from
Oct 27, 2016
Merged

Support for canvas elements on quads. #634

merged 2 commits into from
Oct 27, 2016

Conversation

manthey
Copy link
Contributor

@manthey manthey commented Oct 24, 2016

Rather than using an image, a canvas can be rendered on a quad. On the canvas renderer, after changing the canvas quad, a draw call is sufficient to update it. On the vgl renderer, the texture is cached, so it will take more work to update the texture.

Rather than using an image, a canvas can be rendered on a quad.  On the canvas renderer, after changing the canvas quad, a draw call is sufficient to update it.  On the vgl renderer, the texture is cached, so it will take more work to update the texture.
@codecov-io
Copy link

codecov-io commented Oct 24, 2016

Current coverage is 86.50% (diff: 100%)

Merging #634 into master will increase coverage by <.01%

@@             master       #634   diff @@
==========================================
  Files            85         85          
  Lines          8325       8328     +3   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
+ Hits           7201       7204     +3   
  Misses         1124       1124          
  Partials          0          0          

Powered by Codecov. Last update cf6aeb5...76c5cc1

@manthey manthey mentioned this pull request Oct 27, 2016
@@ -423,6 +423,7 @@ capabilities[quadFeature.capabilities.image] = true;
capabilities[quadFeature.capabilities.imageCrop] = true;
capabilities[quadFeature.capabilities.imageFixedScale] = false;
capabilities[quadFeature.capabilities.imageFull] = true;
capabilities[quadFeature.capabilities.canvas] = false;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need this? Can't we state missing key as false?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't need it, but I want to explicitly document what capabilities different renderers have rather than implicitly document them.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My only concern is that now we need something similar in canvas version? my slight preference would be not to list canvas in gl and gl in canvas (and what about d3).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is if we can render a canvas on a quad, not if we can use the canvas renderer.

For instance, we could do this in gl by regenerating the texture whenever the canvas changes, and thus using gl to render the feature. Similarly, for d3, we can convert a canvas to an Image, then render that (super inefficient, but possible).

@aashish24
Copy link
Member

This is if we can render a canvas on a quad, not if we can use the canvas renderer.

ah, makes sense. The name was bit confusing. LGTM then.

@manthey manthey merged commit 6861609 into master Oct 27, 2016
@manthey manthey deleted the canvas-quad-content branch October 27, 2016 17:03
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.

3 participants