mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 11:48:09 +02:00
fix force of BC3 instead of BC1a compression
This commit is contained in:
parent
84901ba94b
commit
07440e325f
1 changed files with 3 additions and 5 deletions
|
@ -493,10 +493,6 @@ gpu::TexturePointer TextureUsage::process2DTextureColorFromImage(const QImage& s
|
||||||
|
|
||||||
if (validAlpha) {
|
if (validAlpha) {
|
||||||
processTextureAlpha(image, validAlpha, alphaAsMask);
|
processTextureAlpha(image, validAlpha, alphaAsMask);
|
||||||
|
|
||||||
// NOTE: This disables BC1a compression because it was producing odd artifacts on text textures
|
|
||||||
// for the tutorial. Instead we use BC3 (which is larger) but doesn't produce the same artifacts).
|
|
||||||
alphaAsMask = false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
gpu::TexturePointer theTexture = nullptr;
|
gpu::TexturePointer theTexture = nullptr;
|
||||||
|
@ -506,7 +502,9 @@ gpu::TexturePointer TextureUsage::process2DTextureColorFromImage(const QImage& s
|
||||||
gpu::Element formatGPU;
|
gpu::Element formatGPU;
|
||||||
if (isColorTexturesCompressionEnabled()) {
|
if (isColorTexturesCompressionEnabled()) {
|
||||||
if (validAlpha) {
|
if (validAlpha) {
|
||||||
formatGPU = alphaAsMask ? gpu::Element::COLOR_COMPRESSED_SRGBA_MASK : gpu::Element::COLOR_COMPRESSED_SRGBA;
|
// NOTE: This disables BC1a compression because it was producing odd artifacts on text textures
|
||||||
|
// for the tutorial. Instead we use BC3 (which is larger) but doesn't produce the same artifacts).
|
||||||
|
formatGPU = gpu::Element::COLOR_COMPRESSED_SRGBA;
|
||||||
} else {
|
} else {
|
||||||
formatGPU = gpu::Element::COLOR_COMPRESSED_SRGB;
|
formatGPU = gpu::Element::COLOR_COMPRESSED_SRGB;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue