gpu: throw error if texture data is not slice #289
No reviewers
Labels
No labels
CI
all
basisu
blog
bug
build
contributor-friendly
core
correctness
deferred
dev
direct3d-headers
docs
driver-os-issue
duplicate
dxcompiler
editor
examples
experiment
feature-idea
feedback
flac
freetype
gamemode
gkurve
glfw
gpu
gpu-dawn
harfbuzz
help welcome
in-progress
infrastructure
invalid
libmach
linux-audio-headers
long-term
mach
mach.gfx
mach.math
mach.physics
mach.testing
model3d
needs-triage
object
opengl-headers
opus
os/linux
os/macos
os/wasm
os/windows
package-manager
priority
proposal
proposal-accepted
question
roadmap
slipped
stability
sysaudio
sysgpu
sysjs
validating-fix
vulkan-zig-generated
wayland-headers
website
wontfix
wrench
www
x11-headers
xcode-frameworks
zig-update
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
hexops/mach!289
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "main"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@ -65,4 +65,3 @@destination: *const ImageCopyTexture,data: anytype,data_layout: *const Texture.DataLayout,write_size: *const Extent3D,Nice! I think there are more places than just here that we need to update - though.
Queue.zigfn writeBufferCommandEncoder.zigfn writeBuffer@ -65,4 +65,3 @@destination: *const ImageCopyTexture,data: anytype,data_layout: *const Texture.DataLayout,write_size: *const Extent3D,yeah im aware. will update this soon
@ -65,4 +65,3 @@destination: *const ImageCopyTexture,data: anytype,data_layout: *const Texture.DataLayout,write_size: *const Extent3D,also this seems wrong (check CI log)
@ -65,4 +65,3 @@destination: *const ImageCopyTexture,data: anytype,data_layout: *const Texture.DataLayout,write_size: *const Extent3D,It looks like
std.meta.isSliceOf(T)might do what we want https://sourcegraph.com/github.com/ziglang/zig/-/blob/lib/std/meta/trait.zig?L142:7@ -65,4 +65,3 @@destination: *const ImageCopyTexture,data: anytype,data_layout: *const Texture.DataLayout,write_size: *const Extent3D,about
writeBuffer, you mean removecomptime T: typeand just take data slice asanytypeand check it?@ -65,4 +65,3 @@destination: *const ImageCopyTexture,data: anytype,data_layout: *const Texture.DataLayout,write_size: *const Extent3D,Oh, dang - It's confusing we ended up with different APIs here. I looked around, and actually it seems like
comptime T: type, data: []const Tis pretty reasonable. Maybe we should just change thiswriteTexturefunction signature to that instead ofdata: anytype?@ -65,4 +65,3 @@destination: *const ImageCopyTexture,data: anytype,data_layout: *const Texture.DataLayout,write_size: *const Extent3D,yeah make sense 👍
Even better, thank you for doing this!