You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
========================== MAJOR FEATURES + CHANGES ========================== Change 2719147 on 2015/10/07 by Mark.Satterthwaite Allow the shader cache to perform some precompilation synchronously on load before falling back to asynchronous compilation to balance load times against total time spent precompiling. Added a stat to the group that reports how long the precompile has been running until it completes so it is easier to track. Change 2719182 on 2015/10/07 by Mark.Satterthwaite Refactor the ShaderCache's internal data structures and change the way we handle recording whether a particular predraw state has been submitted to try and make it more efficient. Change 2719185 on 2015/10/07 by Mark.Satterthwaite Merging CL #2717701: Try and fix random crashes on Mac when manipulating bound-shader-states caused by ShaderCache potentially providing a bogus shader state pointer on exit from predraw. Change 2719434 on 2015/10/07 by Mark.Satterthwaite Make sure that Mac ensures reports have a source context and a sane callstack when sent to the crash-reports server. Change 2724764 on 2015/10/12 by Josh.Adams [Initial AppleTV support] Merging //depot/YakBranch/... to //UE4/Dev-Platform/... Change 2726266 on 2015/10/13 by Lee.Clark PS4 - Calc reserve size required for DMA copy when using unsafe command buffers Change 2726401 on 2015/10/13 by Mark.Satterthwaite Merging CL #2716418: Fix UE-15228 'Crash Report Client doesn't restart into project editor on Mac' by reporting the original command line supplied by LaunchMac, not the modified one that strips the project name. The CRC can then relaunch as expected. #jira UE-15228 Change 2726421 on 2015/10/13 by Lee.Clark PS4 - Don't try to clear invalid targets Change 2727040 on 2015/10/13 by Michael.Trepka Merging CL 2724777 - Fixed splash screen rendering for images with DPI different than 72 Change 2729783 on 2015/10/15 by Keith.Judge Fix huge memory leak in Test/Shipping configurations, caused because I am a numpty. Change 2729847 on 2015/10/15 by Mark.Satterthwaite Merging CL #2729846: On OS X unconstrain windows from the dimension of the parent display when in Windowed mode - it is OK for them to be larger in this case. They do need to be repositioned if on the Primary display so that they don't creep under the menu bar and become unmovable/unclosable and Fullscreen windows still need to be constrained to a single display. We can now take screenshots of windows that are larger than the display & not get grey bars beyond the cutoff. #jira UE-21992 Change 2729865 on 2015/10/15 by Keith.Judge Fast semantics - Finish up resource transitions, adding resource decompression where appropriate and using non-fast clears where we can't determine the resource transition. Change 2729897 on 2015/10/15 by Keith.Judge Fast Semantics - Make sure all GetData() calls are made safe with GPU fences. Change 2729972 on 2015/10/15 by Keith.Judge Removed the last vestiges of ID3D11DeviceContext/ID3D11DeviceContext1 from the Xbox RHI. Everything now uses ID3D11DeviceContextX directly. This should be marginally quicker as it stops a double call to ClearState(). Change 2731503 on 2015/10/16 by Keith.Judge Added _XDK_VERSION to the DDC key for textures, which should solve the issue of the tiling mode changing in August XDK (and future changes Microsoft may inflict). Change 2731596 on 2015/10/16 by Keith.Judge Fast Semantics - Add deferred resource deletion queue to make deleted resources be actually deleted a number of frames later so that the GPU is definitely finished with them. Hooked up the temporary SRVs for dynamic VBs as a first step. Change 2731928 on 2015/10/16 by Michael.Trepka PR #1659: Mac/Build.sh handles additional arguments (Contributed by judgeaxl) Change 2731934 on 2015/10/16 by Michael.Trepka PR #1618: added clang 3.7.0 -Wshift-negative-value ignore in JpegImageWrapper.cpp (Contributed by bsekura) Change 2732018 on 2015/10/16 by Mark.Satterthwaite Emit a shader code cache for each platforms requested shader formats, this is separate to the targeted formats as not all can or need to be cached. - The implementation extends the ShaderCache's hooks in FShaderResource's serialisation function to capture the required shaders. - Each target platform has its own list of cached shader formats, analogous to the list of targeted RHIs. Presently only the Mac implements this. - Code cached shaders are now compressed (for size) to reduce the overhead associated with keeping all the shader code around - this works esp. well for text-based formats like GLSL. Change 2732365 on 2015/10/16 by Josh.Adams - Packaging a TVOS .ipa now works (still haven't tried any of the Editor integration like Launch On) Change 2733170 on 2015/10/18 by Terence.Burns Fix for Android IAP query not returning entire inventory. Change 2733174 on 2015/10/18 by Terence.Burns Fix Movie player issue where wait for movie to finish isnt being respected. Seems a stray bUserCanceled event flag was causing this not to be observed. Added some verbose logging to apple movie player. Change 2733488 on 2015/10/19 by Mark.Satterthwaite Added the ability to merge the .ushadercache files used by the ShaderCache to store shader & draw state information. - Fixed a bug that would cause invalid shader membership and draw state information to be logged. - Added a separate command-line tool to merge shader cache files, currently Mac-only but in theory should work on other platforms too. Change 2735226 on 2015/10/20 by Mark.Satterthwaite Fix temporal AA rendering on GL/Mac OS X - you can't rely on EyeAdaptation values unless SM5 is available so only perform that code on SM5 & we must correctly clamp saturate(NaN) to 0 as the current hlslcc won't do that for us (& is required by the HLSL spec). The latter used to be clamped in the AA_ALPHA && AA_VELOCITY_WEIGHTING code block that was removed recently. #jira UE-21214 #jira UE-19913 Change 2736722 on 2015/10/21 by Daniel.Lamb Improved performance of cooking stats system. Change 2737172 on 2015/10/21 by Daniel.Lamb Improved cooking stats performance for ddc stats.
243 lines
7.3 KiB
C++
243 lines
7.3 KiB
C++
// Copyright 1998-2015 Epic Games, Inc. All Rights Reserved.
|
|
|
|
/*=============================================================================
|
|
AndroidTargetPlatform.h: Declares the FAndroidTargetPlatform class.
|
|
=============================================================================*/
|
|
|
|
#pragma once
|
|
|
|
#include "Ticker.h"
|
|
|
|
#if WITH_ENGINE
|
|
#include "StaticMeshResources.h"
|
|
#endif // WITH_ENGINE
|
|
|
|
/**
|
|
* Defines supported texture format names.
|
|
*/
|
|
namespace AndroidTexFormat
|
|
{
|
|
// Compressed Texture Formats
|
|
static FName NamePVRTC2(TEXT("PVRTC2"));
|
|
static FName NamePVRTC4(TEXT("PVRTC4"));
|
|
static FName NameAutoPVRTC(TEXT("AutoPVRTC"));
|
|
static FName NameDXT1(TEXT("DXT1"));
|
|
static FName NameDXT5(TEXT("DXT5"));
|
|
static FName NameAutoDXT(TEXT("AutoDXT"));
|
|
static FName NameATC_RGB(TEXT("ATC_RGB"));
|
|
static FName NameATC_RGBA_E(TEXT("ATC_RGBA_E")); // explicit alpha
|
|
static FName NameATC_RGBA_I(TEXT("ATC_RGBA_I")); // interpolated alpha
|
|
static FName NameAutoATC(TEXT("AutoATC"));
|
|
static FName NameETC1(TEXT("ETC1"));
|
|
static FName NameAutoETC1(TEXT("AutoETC1")); // ETC1 or uncompressed RGBA, if alpha channel required
|
|
static FName NameETC2_RGB(TEXT("ETC2_RGB"));
|
|
static FName NameETC2_RGBA(TEXT("ETC2_RGBA"));
|
|
static FName NameAutoETC2(TEXT("AutoETC2"));
|
|
static FName NameASTC_4x4(TEXT("ASTC_4x4"));
|
|
static FName NameASTC_6x6(TEXT("ASTC_6x6"));
|
|
static FName NameASTC_8x8(TEXT("ASTC_8x8"));
|
|
static FName NameASTC_10x10(TEXT("ASTC_10x10"));
|
|
static FName NameASTC_12x12(TEXT("ASTC_12x12"));
|
|
static FName NameAutoASTC(TEXT("AutoASTC"));
|
|
|
|
// Uncompressed Texture Formats
|
|
static FName NameBGRA8(TEXT("BGRA8"));
|
|
static FName NameG8(TEXT("G8"));
|
|
static FName NameVU8(TEXT("VU8"));
|
|
static FName NameRGBA16F(TEXT("RGBA16F"));
|
|
|
|
// Error "formats" (uncompressed)
|
|
static FName NamePOTERROR(TEXT("POTERROR"));
|
|
}
|
|
|
|
|
|
/**
|
|
* FAndroidTargetPlatform, abstraction for cooking Android platforms
|
|
*/
|
|
template<class TPlatformProperties>
|
|
class FAndroidTargetPlatform
|
|
: public TTargetPlatformBase< TPlatformProperties >
|
|
{
|
|
public:
|
|
|
|
/**
|
|
* Default constructor.
|
|
*/
|
|
FAndroidTargetPlatform( );
|
|
|
|
/**
|
|
* Destructor
|
|
*/
|
|
~FAndroidTargetPlatform();
|
|
|
|
public:
|
|
|
|
/**
|
|
* Gets the name of the Android platform variant, i.e. ATC, DXT, PVRTC, etc.
|
|
*
|
|
* @param Variant name.
|
|
*/
|
|
virtual FString GetAndroidVariantName( )
|
|
{
|
|
return FString();
|
|
}
|
|
|
|
public:
|
|
|
|
//~ Begin ITargetPlatform Interface
|
|
|
|
virtual void EnableDeviceCheck(bool OnOff) override {}
|
|
|
|
virtual bool AddDevice( const FString& DeviceName, bool bDefault ) override
|
|
{
|
|
return false;
|
|
}
|
|
|
|
virtual void GetAllDevices( TArray<ITargetDevicePtr>& OutDevices ) const override;
|
|
|
|
virtual ECompressionFlags GetBaseCompressionMethod( ) const override;
|
|
|
|
virtual bool GenerateStreamingInstallManifest(const TMultiMap<FString, int32>& ChunkMap, const TSet<int32>& ChunkIDsInUse) const override
|
|
{
|
|
return true;
|
|
}
|
|
|
|
virtual ITargetDevicePtr GetDefaultDevice( ) const override;
|
|
|
|
virtual ITargetDevicePtr GetDevice( const FTargetDeviceId& DeviceId ) override;
|
|
|
|
virtual bool IsRunningPlatform( ) const override;
|
|
|
|
virtual bool IsServerOnly( ) const override
|
|
{
|
|
return false;
|
|
}
|
|
|
|
virtual bool IsSdkInstalled(bool bProjectHasCode, FString& OutDocumentationPath) const override;
|
|
|
|
virtual bool SupportsFeature( ETargetPlatformFeatures Feature ) const override;
|
|
|
|
virtual bool SupportsTextureFormat( FName Format ) const
|
|
{
|
|
// By default we support all texture formats.
|
|
return true;
|
|
}
|
|
|
|
virtual bool SupportsCompressedNonPOT( ) const
|
|
{
|
|
// most formats do support non-POT compressed textures
|
|
return true;
|
|
}
|
|
|
|
#if WITH_ENGINE
|
|
virtual void GetReflectionCaptureFormats( TArray<FName>& OutFormats ) const override;
|
|
|
|
virtual void GetAllPossibleShaderFormats( TArray<FName>& OutFormats ) const override;
|
|
|
|
virtual void GetAllTargetedShaderFormats(TArray<FName>& OutFormats) const override;
|
|
|
|
virtual void GetAllCachedShaderFormats( TArray<FName>& OutFormats ) const override {}
|
|
|
|
virtual const class FStaticMeshLODSettings& GetStaticMeshLODSettings() const override;
|
|
|
|
virtual void GetTextureFormats( const UTexture* InTexture, TArray<FName>& OutFormats ) const override;
|
|
|
|
virtual const UTextureLODSettings& GetTextureLODSettings() const override;
|
|
|
|
virtual void RegisterTextureLODSettings(const UTextureLODSettings* InTextureLODSettings) override
|
|
{
|
|
TextureLODSettings = InTextureLODSettings;
|
|
}
|
|
|
|
virtual FName GetWaveFormat( const class USoundWave* Wave ) const override;
|
|
#endif //WITH_ENGINE
|
|
|
|
virtual bool SupportsVariants() const override;
|
|
|
|
virtual FText GetVariantTitle() const override;
|
|
|
|
virtual void GetBuildProjectSettingKeys(FString& OutSection, TArray<FString>& InBoolKeys, TArray<FString>& InIntKeys, TArray<FString>& InStringKeys) const override
|
|
{
|
|
OutSection = TEXT("/Script/AndroidRuntimeSettings.AndroidRuntimeSettings");
|
|
InBoolKeys.Add(TEXT("bBuildForArmV7")); InBoolKeys.Add(TEXT("bBuildForArm64")); InBoolKeys.Add(TEXT("bBuildForX86"));
|
|
InBoolKeys.Add(TEXT("bBuildForX8664")); InBoolKeys.Add(TEXT("bBuildForES2")); InBoolKeys.Add(TEXT("bBuildForES31"));
|
|
}
|
|
|
|
DECLARE_DERIVED_EVENT(FAndroidTargetPlatform, ITargetPlatform::FOnTargetDeviceDiscovered, FOnTargetDeviceDiscovered);
|
|
virtual FOnTargetDeviceDiscovered& OnDeviceDiscovered( ) override
|
|
{
|
|
return DeviceDiscoveredEvent;
|
|
}
|
|
|
|
DECLARE_DERIVED_EVENT(FAndroidTargetPlatform, ITargetPlatform::FOnTargetDeviceLost, FOnTargetDeviceLost);
|
|
virtual FOnTargetDeviceLost& OnDeviceLost( ) override
|
|
{
|
|
return DeviceLostEvent;
|
|
}
|
|
|
|
//~ End ITargetPlatform Interface
|
|
|
|
protected:
|
|
|
|
/**
|
|
* Adds the specified texture format to the OutFormats if this android target platforms supports it.
|
|
*
|
|
* @param Format - The format to add.
|
|
* @param OutFormats - The collection of formats to add to.
|
|
* @param bIsCompressedNonPOT - If this is true, the texture wants to be compressed but is not a power of 2
|
|
*/
|
|
void AddTextureFormatIfSupports( FName Format, TArray<FName>& OutFormats, bool bIsCompressedNonPOT=false ) const;
|
|
|
|
/**
|
|
* Return true if this device has a supported set of extensions for this platform.
|
|
*
|
|
* @param Extensions - The GL extensions string.
|
|
* @param GLESVersion - The GLES version reported by this device.
|
|
*/
|
|
virtual bool SupportedByExtensionsString( const FString& ExtensionsString, const int GLESVersion ) const
|
|
{
|
|
return true;
|
|
}
|
|
|
|
#if WITH_ENGINE
|
|
// Holds the Engine INI settings (for quick access).
|
|
FConfigFile EngineSettings;
|
|
#endif //WITH_ENGINE
|
|
|
|
private:
|
|
|
|
// Handles when the ticker fires.
|
|
bool HandleTicker( float DeltaTime );
|
|
|
|
// Holds a map of valid devices.
|
|
TMap<FString, FAndroidTargetDevicePtr> Devices;
|
|
|
|
// Holds a delegate to be invoked when the widget ticks.
|
|
FTickerDelegate TickDelegate;
|
|
|
|
// Handle to the registered TickDelegate.
|
|
FDelegateHandle TickDelegateHandle;
|
|
|
|
// Pointer to the device detection handler that grabs device ids in another thread
|
|
IAndroidDeviceDetection* DeviceDetection;
|
|
|
|
#if WITH_ENGINE
|
|
// Holds a cache of the target LOD settings.
|
|
const UTextureLODSettings* TextureLODSettings;
|
|
|
|
// Holds the static mesh LOD settings.
|
|
FStaticMeshLODSettings StaticMeshLODSettings;
|
|
|
|
ITargetDevicePtr DefaultDevice;
|
|
#endif //WITH_ENGINE
|
|
|
|
// Holds an event delegate that is executed when a new target device has been discovered.
|
|
FOnTargetDeviceDiscovered DeviceDiscoveredEvent;
|
|
|
|
// Holds an event delegate that is executed when a target device has been lost, i.e. disconnected or timed out.
|
|
FOnTargetDeviceLost DeviceLostEvent;
|
|
};
|
|
|
|
|
|
#include "AndroidTargetPlatform.inl"
|