Merge remote-tracking branch 'origin/master' into gi

# Conflicts:
#	Flax.flaxproj
#	Source/Engine/Core/Math/Vector3.h
#	Source/Engine/Graphics/Textures/GPUTexture.cpp
#	Source/Engine/GraphicsDevice/DirectX/DX11/GPUContextDX11.cpp
#	Source/Engine/Terrain/Terrain.cpp
#	Source/Engine/Tools/ModelTool/ModelTool.Build.cs
#	Source/FlaxEngine.Gen.cs
#	Source/FlaxEngine.Gen.h
This commit is contained in:
Wojciech Figat
2022-03-22 13:00:21 +01:00
49 changed files with 647 additions and 163 deletions

View File

@@ -837,8 +837,8 @@ DragDropEffect MacWindow::DoDragDrop(const StringView& data)
void MacWindow::SetCursor(CursorType type)
{
WindowBase::SetCursor(type);
if (!_isMouseOver)
return;
//if (!_isMouseOver)
// return;
NSCursor* cursor = nullptr;
switch (type)
{
@@ -875,6 +875,7 @@ void MacWindow::SetCursor(CursorType type)
if (cursor)
{
[cursor set];
[NSCursor unhide];
}
}

View File

@@ -25,7 +25,11 @@ public:
static void MemoryBarrier();
static int64 InterlockedExchange(int64 volatile* dst, int64 exchange)
{
#if WIN64
return _InterlockedExchange64(dst, exchange);
#else
return _interlockedexchange64(dst, exchange);
#endif
}
static int32 InterlockedCompareExchange(int32 volatile* dst, int32 exchange, int32 comperand)
{
@@ -37,15 +41,27 @@ public:
}
static int64 InterlockedIncrement(int64 volatile* dst)
{
#if WIN64
return _InterlockedExchangeAdd64(dst, 1) + 1;
#else
return _interlockedexchange64(dst, 1) + 1;
#endif
}
static int64 InterlockedDecrement(int64 volatile* dst)
{
#if WIN64
return _InterlockedExchangeAdd64(dst, -1) - 1;
#else
return _interlockedexchangeadd64(dst, -1) - 1;
#endif
}
static int64 InterlockedAdd(int64 volatile* dst, int64 value)
{
#if WIN64
return _InterlockedExchangeAdd64(dst, value);
#else
return _interlockedexchangeadd64(dst, value);
#endif
}
static int32 AtomicRead(int32 volatile* dst)
{
@@ -61,7 +77,11 @@ public:
}
static void AtomicStore(int64 volatile* dst, int64 value)
{
#if WIN64
_InterlockedExchange64(dst, value);
#else
_interlockedexchange64(dst, value);
#endif
}
static void Prefetch(void const* ptr);
static void* Allocate(uint64 size, uint64 alignment);