adding base image
Build / build (push) Successful in 2m5s
Test / build (push) Successful in 10m33s

This commit is contained in:
2026-04-06 22:49:23 +02:00
parent 85e0fe4362
commit b051c71f02
3 changed files with 44 additions and 1 deletions
+22
View File
@@ -144,6 +144,7 @@ pub const SetupDispatcher = block: {
.IAdd = autoSetupConstant,
.IAddCarry = autoSetupConstant,
.IEqual = autoSetupConstant,
.ImageRead = autoSetupConstant,
.IMul = autoSetupConstant,
.INotEqual = autoSetupConstant,
.ISub = autoSetupConstant,
@@ -190,6 +191,7 @@ pub const SetupDispatcher = block: {
.TypeBool = opTypeBool,
.TypeFloat = opTypeFloat,
.TypeFunction = opTypeFunction,
.TypeImage = opTypeImage,
.TypeInt = opTypeInt,
.TypeMatrix = opTypeMatrix,
.TypePointer = opTypePointer,
@@ -2371,6 +2373,26 @@ fn opTypeFunction(allocator: std.mem.Allocator, word_count: SpvWord, rt: *Runtim
};
}
fn opTypeImage(_: std.mem.Allocator, word_count: SpvWord, rt: *Runtime) RuntimeError!void {
const id = try rt.it.next();
rt.results[id].variant = .{
.Type = .{
.Image = .{
.dim = try rt.it.nextAs(spv.SpvDim),
.depth = @truncate(try rt.it.next()),
.arrayed = @truncate(try rt.it.next()),
.ms = @truncate(try rt.it.next()),
.sampled = @truncate(try rt.it.next()),
.format = try rt.it.nextAs(spv.SpvImageFormat),
.access = null,
},
},
};
if (word_count > 8) {
rt.results[id].variant.?.Type.Image.access = try rt.it.nextAs(spv.SpvAccessQualifier);
}
}
fn opTypeInt(_: std.mem.Allocator, _: SpvWord, rt: *Runtime) RuntimeError!void {
const id = try rt.it.next();
rt.results[id].variant = .{