mirror of
https://github.com/simple64/simple64.git
synced 2026-11-14 21:38:42 +01:00
update parallel rdp
This commit is contained in:
1 parent
a9929dcdff
commit
84d05dd02d
89 files changed
+47413
-52063
No files matched your search
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2017-2022 Hans-Kristian Arntzen
|
||||
/* Copyright (c) 2017-2023 Hans-Kristian Arntzen
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files (the
|
||||
@@ -52,6 +52,28 @@ void SamplerDeleter::operator()(Sampler *sampler)
|
||||
sampler->device->handle_pool.samplers.free(sampler);
|
||||
}
|
||||
|
||||
SamplerCreateInfo Sampler::fill_sampler_info(const VkSamplerCreateInfo &info)
|
||||
{
|
||||
SamplerCreateInfo sampler_info = {};
|
||||
|
||||
sampler_info.mag_filter = info.magFilter;
|
||||
sampler_info.min_filter = info.minFilter;
|
||||
sampler_info.mipmap_mode = info.mipmapMode;
|
||||
sampler_info.address_mode_u = info.addressModeU;
|
||||
sampler_info.address_mode_v = info.addressModeV;
|
||||
sampler_info.address_mode_w = info.addressModeW;
|
||||
sampler_info.mip_lod_bias = info.mipLodBias;
|
||||
sampler_info.anisotropy_enable = info.anisotropyEnable;
|
||||
sampler_info.max_anisotropy = info.maxAnisotropy;
|
||||
sampler_info.compare_enable = info.compareEnable;
|
||||
sampler_info.compare_op = info.compareOp;
|
||||
sampler_info.min_lod = info.minLod;
|
||||
sampler_info.max_lod = info.maxLod;
|
||||
sampler_info.border_color = info.borderColor;
|
||||
sampler_info.unnormalized_coordinates = info.unnormalizedCoordinates;
|
||||
return sampler_info;
|
||||
}
|
||||
|
||||
VkSamplerCreateInfo Sampler::fill_vk_sampler_info(const SamplerCreateInfo &sampler_info)
|
||||
{
|
||||
VkSamplerCreateInfo info = { VK_STRUCTURE_TYPE_SAMPLER_CREATE_INFO };
|
||||
@@ -96,7 +118,7 @@ ImmutableSampler::ImmutableSampler(Util::Hash hash, Device *device_, const Sampl
|
||||
LOGE("Failed to create sampler.\n");
|
||||
|
||||
#ifdef GRANITE_VULKAN_FOSSILIZE
|
||||
//device->register_sampler(vk_sampler, hash, info);
|
||||
device->register_sampler(vk_sampler, hash, info);
|
||||
#endif
|
||||
|
||||
sampler = SamplerHandle(device->handle_pool.samplers.allocate(device, vk_sampler, sampler_info, true));
|
||||
@@ -113,6 +135,12 @@ ImmutableYcbcrConversion::ImmutableYcbcrConversion(Util::Hash hash, Device *devi
|
||||
{
|
||||
LOGE("Failed to create YCbCr conversion.\n");
|
||||
}
|
||||
else
|
||||
{
|
||||
#ifdef GRANITE_VULKAN_FOSSILIZE
|
||||
device->register_sampler_ycbcr_conversion(conversion, info);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
else
|
||||
LOGE("Ycbcr conversion is not supported on this device.\n");
|
||||
|
||||
Reference in new issue
Block a user