adding base for intel backend
Test / build_and_test (push) Successful in 25s
Build / build (push) Successful in 36s

This commit is contained in:
2026-06-16 05:06:20 +02:00
parent c9961ea346
commit 38f802b294
27 changed files with 2570 additions and 0 deletions
+26
View File
@@ -0,0 +1,26 @@
const std = @import("std");
const vk = @import("vulkan");
const base = @import("base");
const VkError = base.VkError;
const Self = @This();
pub const Interface = base.Sampler;
interface: Interface,
pub fn create(device: *base.Device, allocator: std.mem.Allocator, info: *const vk.SamplerCreateInfo) VkError!*Self {
const self = allocator.create(Self) catch return VkError.OutOfHostMemory;
errdefer allocator.destroy(self);
var interface = try Interface.init(device, allocator, info);
interface.vtable = &.{ .destroy = destroy };
self.* = .{ .interface = interface };
return self;
}
pub fn destroy(interface: *Interface, allocator: std.mem.Allocator) void {
const self: *Self = @alignCast(@fieldParentPtr("interface", interface));
allocator.destroy(self);
}