Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

kainino0x
Copy link
Contributor

@kainino0x kainino0x commented Nov 20, 2021

And add a note on how to read/write depth/stencil formats which are not copyable.

Fixes #652 (remaining open questions there are being split out to separate issues decided not to do that, just added notes in the spec).
CC #2328


Preview | Diff

@kainino0x kainino0x requested review from kvark and toji November 20, 2021 01:14
@github-actions
Copy link
Contributor

Previews, as seen when this build job started (189c73a):
WebGPU | IDL
WGSL
Explainer

@github-actions
Copy link
Contributor

Previews, as seen when this build job started (0b22936):
WebGPU | IDL
WGSL
Explainer

@github-actions
Copy link
Contributor

Previews, as seen when this build job started (4d49c7c):
WebGPU | IDL
WGSL
Explainer

spec/index.bs Outdated
WebGPU provides {{GPUCommandEncoder/copyBufferToTexture()}} for buffer-to-texture copies and
{{GPUCommandEncoder/copyTextureToBuffer()}} for texture-to-buffer copies.

Pixels are tightly-packed in the linear-memory layout of each row of an image copy.
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe worth explaining what this is, then adding a note saying "this is often referred to as linear memory layout"?
I.e. say that texel (i+1, j) follows (i, j), and row (, j+1) follows row (, j).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I tried to sidestep this by only explaining the layout of each individual row, not the whole image, but we do need this somewhere eventually. GPUImageDataLayout has TODOs to describe linear memory layouts.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Moved this to that section (which makes more sense) and rewrote it in terms of texel blocks.

@github-actions
Copy link
Contributor

Previews, as seen when this build job started (b0bc35f):
WebGPU | IDL
WGSL
Explainer

@kvark kvark merged commit 03c2345 into gpuweb:main Nov 24, 2021
github-actions bot added a commit that referenced this pull request Nov 24, 2021
)

SHA: 03c2345
Reason: push, by @kvark

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
github-actions bot added a commit that referenced this pull request Nov 24, 2021
)

SHA: 03c2345
Reason: push, by @kvark

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
github-actions bot added a commit that referenced this pull request Nov 24, 2021
)

SHA: 03c2345
Reason: push, by @kvark

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@kainino0x kainino0x deleted the image-copy-tight branch November 24, 2021 21:00
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.

Copying of depth24plus formats
3 participants