Dont use astc on windows/limux yet
This commit is contained in:
@@ -58,8 +58,9 @@ public class TextureTool : EngineModule
|
||||
options.PrivateDependencies.Add("bc7enc16");
|
||||
}
|
||||
}
|
||||
if (options.Target.IsEditor)
|
||||
if (options.Target.IsEditor && options.Platform.Target == TargetPlatform.Mac) // TODO: add ASTC for Editor on Linux and Windows
|
||||
{
|
||||
// ASTC for mobile (iOS and Android)
|
||||
options.SourceFiles.Add(Path.Combine(FolderPath, "TextureTool.astc.cpp"));
|
||||
options.PrivateDependencies.Add("astc");
|
||||
}
|
||||
|
||||
@@ -834,6 +834,16 @@ bool TextureTool::ImportTextureDirectXTex(ImageType type, const StringView& path
|
||||
|
||||
bool TextureTool::ConvertDirectXTex(TextureData& dst, const TextureData& src, const PixelFormat dstFormat)
|
||||
{
|
||||
if (PixelFormatExtensions::IsCompressedASTC(dstFormat))
|
||||
{
|
||||
// TODO: decompress if need to
|
||||
#if COMPILE_WITH_ASTC
|
||||
return ConvertAstc(dst, *textureData, dstFormat);
|
||||
#else
|
||||
return true;
|
||||
#endif
|
||||
}
|
||||
|
||||
HRESULT result;
|
||||
DirectX::ScratchImage dstImage;
|
||||
DirectX::ScratchImage tmpImage;
|
||||
@@ -919,10 +929,6 @@ bool TextureTool::ConvertDirectXTex(TextureData& dst, const TextureData& src, co
|
||||
return true;
|
||||
}
|
||||
}
|
||||
else if (PixelFormatExtensions::IsCompressedASTC(dstFormat))
|
||||
{
|
||||
todo_astc_compression_on_windows;
|
||||
}
|
||||
// Check if convert data
|
||||
else if (inImage->GetMetadata().format != dstFormatDxgi)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user