mirror of
https://github.com/doitsujin/dxvk.git
synced 2025-02-20 19:54:19 +01:00
[dxvk] Allow non seamless samplers.
This commit is contained in:
parent
e9ac543627
commit
f2b1805d7e
@ -38,6 +38,7 @@ namespace dxvk {
|
||||
info.borderColor.float32[i] = desc.BorderColor[i];
|
||||
|
||||
info.usePixelCoord = VK_FALSE; // Not supported in D3D11
|
||||
info.nonSeamless = VK_FALSE;
|
||||
|
||||
// Make sure to use a valid anisotropy value
|
||||
if (desc.MaxAnisotropy < 1) info.maxAnisotropy = 1.0f;
|
||||
|
@ -365,6 +365,7 @@ namespace dxvk {
|
||||
samplerInfo.compareOp = VK_COMPARE_OP_ALWAYS;
|
||||
samplerInfo.borderColor = VkClearColorValue();
|
||||
samplerInfo.usePixelCoord = VK_FALSE;
|
||||
samplerInfo.nonSeamless = VK_FALSE;
|
||||
m_sampler = Device->createSampler(samplerInfo);
|
||||
|
||||
DxvkBufferCreateInfo bufferInfo;
|
||||
|
@ -5961,6 +5961,7 @@ namespace dxvk {
|
||||
info.mipmapLodMin = mipFilter.MipsEnabled ? float(cKey.MaxMipLevel) : 0;
|
||||
info.mipmapLodMax = mipFilter.MipsEnabled ? FLT_MAX : 0;
|
||||
info.usePixelCoord = VK_FALSE;
|
||||
info.nonSeamless = VK_FALSE;
|
||||
|
||||
DecodeD3DCOLOR(cKey.BorderColor, info.borderColor.float32);
|
||||
|
||||
|
@ -16,7 +16,7 @@ namespace dxvk {
|
||||
VkSamplerCreateInfo samplerInfo;
|
||||
samplerInfo.sType = VK_STRUCTURE_TYPE_SAMPLER_CREATE_INFO;
|
||||
samplerInfo.pNext = nullptr;
|
||||
samplerInfo.flags = 0;
|
||||
samplerInfo.flags = info.nonSeamless ? VK_SAMPLER_CREATE_NON_SEAMLESS_CUBE_MAP_BIT_EXT : 0;
|
||||
samplerInfo.magFilter = info.magFilter;
|
||||
samplerInfo.minFilter = info.minFilter;
|
||||
samplerInfo.mipmapMode = info.mipmapMode;
|
||||
|
@ -38,6 +38,9 @@ namespace dxvk {
|
||||
|
||||
/// Enables unnormalized coordinates
|
||||
VkBool32 usePixelCoord;
|
||||
|
||||
/// Enables non seamless cube map filtering
|
||||
VkBool32 nonSeamless;
|
||||
};
|
||||
|
||||
|
||||
|
@ -304,6 +304,7 @@ namespace dxvk {
|
||||
samplerInfo.compareOp = VK_COMPARE_OP_ALWAYS;
|
||||
samplerInfo.borderColor = VkClearColorValue();
|
||||
samplerInfo.usePixelCoord = VK_TRUE;
|
||||
samplerInfo.nonSeamless = VK_FALSE;
|
||||
m_samplerPresent = m_device->createSampler(samplerInfo);
|
||||
|
||||
samplerInfo.addressModeU = VK_SAMPLER_ADDRESS_MODE_CLAMP_TO_EDGE;
|
||||
|
@ -53,6 +53,7 @@ namespace dxvk {
|
||||
info.compareOp = VK_COMPARE_OP_NEVER;
|
||||
info.borderColor = VkClearColorValue();
|
||||
info.usePixelCoord = VK_FALSE;
|
||||
info.nonSeamless = VK_FALSE;
|
||||
|
||||
return dev->createSampler(info);
|
||||
}
|
||||
|
@ -311,6 +311,7 @@ namespace dxvk::hud {
|
||||
info.compareOp = VK_COMPARE_OP_NEVER;
|
||||
info.borderColor = VkClearColorValue();
|
||||
info.usePixelCoord = VK_TRUE;
|
||||
info.nonSeamless = VK_FALSE;
|
||||
|
||||
return m_device->createSampler(info);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user