Buffer resources from swap chain were not being released.
This commit is contained in:
parent
2f0415a603
commit
9e4611d5d6
1 changed files with 2 additions and 0 deletions
|
|
@ -1498,6 +1498,8 @@ pub const Resource = struct {
|
||||||
pub fn deinit(resource: *Resource) void {
|
pub fn deinit(resource: *Resource) void {
|
||||||
if (resource.mem_allocator) |mem_allocator| {
|
if (resource.mem_allocator) |mem_allocator| {
|
||||||
mem_allocator.destroyResource(resource.*) catch {};
|
mem_allocator.destroyResource(resource.*) catch {};
|
||||||
|
} else {
|
||||||
|
_ = resource.d3d_resource.lpVtbl.*.Release.?(resource.d3d_resource);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue