sysgpu: fix Texture.getWidth()

Authored by @hordurj in https://github.com/hexops/mach/pull/1220/commits/235decb4aa5736f4f25643e960c74ae41088ad4e

Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
Stephen Gutekanst 2024-07-06 11:18:30 -07:00
parent d9e11a8296
commit 2f0415a603

View file

@ -1317,7 +1317,7 @@ pub const Impl = sysgpu.Interface(struct {
pub inline fn textureGetWidth(texture_raw: *sysgpu.Texture) u32 { pub inline fn textureGetWidth(texture_raw: *sysgpu.Texture) u32 {
const texture: *impl.Texture = @ptrCast(@alignCast(texture_raw)); const texture: *impl.Texture = @ptrCast(@alignCast(texture_raw));
return texture.getHeight(); return texture.getWidth();
} }
pub inline fn textureSetLabel(texture: *sysgpu.Texture, label: [*:0]const u8) void { pub inline fn textureSetLabel(texture: *sysgpu.Texture, label: [*:0]const u8) void {