fix alignment for shader binary

This commit is contained in:
Robin Voetter
2022-09-24 00:40:17 +02:00
committed by ashpil
parent 33a137a0dd
commit c42f540ce3
2 changed files with 4 additions and 4 deletions

View File

@@ -59,9 +59,9 @@ pub const ResourceGenStep = struct {
const shader_out_path = self.shader_step.add(source, .{});
var writer = self.resources.writer();
writer.print("pub const {s} = @embedFile(\"", .{name}) catch unreachable;
writer.print("pub const {s} align(@alignOf(u32)) = @embedFile(\"", .{name}) catch unreachable;
renderPath(shader_out_path, writer);
writer.writeAll("\");\n") catch unreachable;
writer.writeAll("\").*;\n") catch unreachable;
}
fn make(step: *Step) !void {