-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Move ScatterplotLayer & BitmapLayer to UBOs #8875
Conversation
modules/layers/src/scatterplot-layer/scatterplot-layer-inputs.ts
Outdated
Show resolved
Hide resolved
modules/layers/src/scatterplot-layer/scatterplot-layer-inputs.ts
Outdated
Show resolved
Hide resolved
@@ -6,6 +6,11 @@ import * as FIXTURES from 'deck.gl-test/data'; | |||
|
|||
const SIZE = 1; | |||
|
|||
function getUniforms(layer: Layer) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thought: Maybe should be part of the layer test utils at some point?
modules/layers/src/scatterplot-layer/scatterplot-layer-inputs.ts
Outdated
Show resolved
Hide resolved
@@ -6,6 +6,11 @@ import * as FIXTURES from 'deck.gl-test/data'; | |||
|
|||
const SIZE = 1; | |||
|
|||
function getUniforms(layer: Layer) { | |||
// @ts-ignore | |||
return layer.getModels()[0]._uniformStore.uniformBlocks.get('scatterplot').uniforms; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe you can do model.shaderInputs.getUniformValues()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I figured it was better to check if the uniformStore
as this is closer to the GPU
Follow up to #8782, trying out moving
ScatterplotLayer
&BitmapLayer
to use UBO.Change List
ShaderModule
for bindingscatterplot
/bitmap
uniformsshaderInputs
rather thanuniforms
indraw()
layerUniforms
module for setting layer opacity (allows removal ofsetUniforms()
)setUniforms
temporarily kept to let tests pass (DataFilterExtension
and others still need this), will address in follow-up PRsMaskExtension
to use UBOs