Merge remote-tracking branch 'origin/1.8' into 1.8
This commit is contained in:
@@ -297,7 +297,11 @@ Task* StreamingTexture::UpdateAllocation(int32 residency)
|
||||
if (texture->Init(desc))
|
||||
{
|
||||
Streaming.Error = true;
|
||||
LOG(Error, "Cannot allocate texture {0}.", texture->GetName());
|
||||
#if GPU_ENABLE_RESOURCE_NAMING
|
||||
LOG(Error, "Cannot allocate texture {0}", texture->GetName());
|
||||
#else
|
||||
LOG(Error, "Cannot allocate texture");
|
||||
#endif
|
||||
}
|
||||
if (allocatedResidency != 0)
|
||||
{
|
||||
|
||||
@@ -58,7 +58,7 @@ public class TextureTool : EngineModule
|
||||
options.PrivateDependencies.Add("bc7enc16");
|
||||
}
|
||||
}
|
||||
if (options.Target.IsEditor && options.Platform.Target != TargetPlatform.Linux) // TODO: add ASTC for Editor on Linux
|
||||
if (options.Target.IsEditor && astc.IsSupported(options))
|
||||
{
|
||||
// ASTC for mobile (iOS and Android)
|
||||
options.SourceFiles.Add(Path.Combine(FolderPath, "TextureTool.astc.cpp"));
|
||||
|
||||
16
Source/ThirdParty/astc/astc.Build.cs
vendored
16
Source/ThirdParty/astc/astc.Build.cs
vendored
@@ -8,6 +8,22 @@ using Flax.Build.NativeCpp;
|
||||
/// </summary>
|
||||
public class astc : DepsModule
|
||||
{
|
||||
/// <summary>
|
||||
/// Returns true if can use astc lib for a given build setup.
|
||||
/// </summary>
|
||||
public static bool IsSupported(BuildOptions options)
|
||||
{
|
||||
switch (options.Platform.Target)
|
||||
{
|
||||
case TargetPlatform.Windows:
|
||||
return true;
|
||||
case TargetPlatform.Mac:
|
||||
return options.Architecture == TargetArchitecture.ARM64;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public override void Init()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user