Skip to content

Commit a93bc55

Browse files
committed
bump: tsover v6.0.1
1 parent cce851a commit a93bc55

4 files changed

Lines changed: 305 additions & 1626 deletions

File tree

packages/typegpu/src/core/texture/texture.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@ class TgpuTextureImpl<TProps extends TextureProps> implements TgpuTexture<TProps
243243
this.#texture = branch.device.createTexture({
244244
label: getName(this) ?? '<unnamed>',
245245
format: props.format,
246-
size: props.size,
246+
size: props.size as GPUExtent3D,
247247
usage: this.#flags,
248248
dimension: props.dimension ?? '2d',
249249
viewFormats: props.viewFormats ?? [],

packages/typegpu/src/data/numeric.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ const boolCast = callableSchema({
1616
}
1717
return !!v;
1818
},
19-
codegenImpl: (ctx, args) => ctx.gen.typeInstantiation(bool, args),
19+
codegenImpl: (ctx, [v]) => ctx.gen.typeInstantiation(bool, v ? [v] : []),
2020
});
2121

2222
/**
@@ -65,7 +65,7 @@ const u32Cast = callableSchema({
6565
// Integer input: treat as bit reinterpretation (i32 -> u32)
6666
return (v & 0xffffffff) >>> 0;
6767
},
68-
codegenImpl: (ctx, args) => ctx.gen.typeInstantiation(u32, args),
68+
codegenImpl: (ctx, [v]) => ctx.gen.typeInstantiation(u32, v ? [v] : []),
6969
});
7070

7171
/**
@@ -105,7 +105,7 @@ const i32Cast = callableSchema({
105105
}
106106
return v | 0;
107107
},
108-
codegenImpl: (ctx, args) => ctx.gen.typeInstantiation(i32, args),
108+
codegenImpl: (ctx, [v]) => ctx.gen.typeInstantiation(i32, v ? [v] : []),
109109
});
110110

111111
export const u16: U16 = {
@@ -148,7 +148,7 @@ const f32Cast = callableSchema({
148148
}
149149
return Math.fround(v);
150150
},
151-
codegenImpl: (ctx, args) => ctx.gen.typeInstantiation(f32, args),
151+
codegenImpl: (ctx, [v]) => ctx.gen.typeInstantiation(f32, v ? [v] : []),
152152
});
153153

154154
/**
@@ -275,7 +275,7 @@ const f16Cast = callableSchema({
275275
return roundToF16(v);
276276
},
277277
// TODO: make usage of f16() in GPU mode check for feature availability and throw if not available
278-
codegenImpl: (ctx, args) => ctx.gen.typeInstantiation(f16, args),
278+
codegenImpl: (ctx, [v]) => ctx.gen.typeInstantiation(f16, v ? [v] : []),
279279
});
280280

281281
/**

0 commit comments

Comments
 (0)