renderer/metal: fix compilation issues

This commit is contained in:
Mitchell Hashimoto
2024-09-18 09:10:12 -07:00
parent 9c897e29a4
commit e811ea859d

View File

@ -360,7 +360,7 @@ pub const DerivedConfig = struct {
const alloc = arena.allocator(); const alloc = arena.allocator();
// Copy our shaders // Copy our shaders
const custom_shaders = try config.@"custom-shader".value.clone(alloc); const custom_shaders = try config.@"custom-shader".clone(alloc);
// Copy our font features // Copy our font features
const font_features = try config.@"font-feature".list.clone(alloc); const font_features = try config.@"font-feature".list.clone(alloc);
@ -549,7 +549,7 @@ pub fn init(alloc: Allocator, options: renderer.Options) !Metal {
// If we have custom shaders then setup our state // If we have custom shaders then setup our state
var custom_shader_state: ?CustomShaderState = state: { var custom_shader_state: ?CustomShaderState = state: {
if (custom_shaders.value.items.len == 0) break :state null; if (custom_shaders.len == 0) break :state null;
// Build our sampler for our texture // Build our sampler for our texture
var sampler = try mtl_sampler.Sampler.init(gpu_state.device); var sampler = try mtl_sampler.Sampler.init(gpu_state.device);