Added VK_MAKE_VERSION equivalent helper (MakeVersion) to VulkanHelpers.cs

This commit is contained in:
sGo7-Dev 2026-10-16 20:22:46 -06:00
commit 96c6832c2c
No known key found for this signature in database
GPG key ID: 1461C18AAD65D459

View file

@ -10,6 +10,14 @@ namespace Brutal.VulkanApi.Abstractions;
public static partial class VulkanHelpers
{
/// <summary>
/// Returns a packed version created from major, minor and patch components
/// </summary>
public static int MakeVersion(int major, int minor, int patch)
{
return (major << 22) | (minor << 12) | patch;
}
/// <summary>
/// The number of mip levels in a full chain for the given 2D dimensions: floor(log2(max(width, height))) + 1.
/// </summary>