Lumen & Nanite on MacOS

I’m on a 14" M1 Macbook Pro and lumen works great. This is a completely dynamic scene with no baked lighting with lumen dynamic global illumination. This scene is a red cube in a white room with a single point light.

8 Likes

how? are you sure its Lumen? How can you be sure?

yes, it is lumen, i can use the lumen debug visualization modes and see clearly it’s enabled. i can also toggle lumen on and off and the global illumination also disappears/appears accordingly. I am using UE5 Preview 2 and MacOS 12.3. This is what also appears when i type “show VisualizeLumen” in a packaged build:

lumen reflection is also working:

4 Likes

This is great news.
Does hardware raytracing work too? Lumen looks best when usint hw raytracing but I don’t know if that works on m1.

No, it does not. M1 Macs don’t have Raytracing Hardware on Chip. The Metal Graphics API however, does have a Raytracing API that runs on Compute shaders on the GPU but does not run at interactive rates. At this time, It’s meant to aid in offline renders in software such as Blender and others. I personally believe that apple will eventually add specific Raytracing Hardware on Chip but who knows exactly when that will happen.

5 Likes

What I want to know is when Nanite will be supported on MacOS. It’s one of the main features of UE5, so it really sux that UE5 shipped without implementing it on MacOS. The documentation states it even works on PS4 and Xbox One (though not very well), and I know that Nanite is largely software rasterised. Given how fast the M1 processors are and that Nanite can even work on old GCN GPUs, it should be more than possible getting it working on M1-based MacBooks. Has anyone heard anything?

10 Likes

Hi, does it still work? It worked for me even on an intel mac on preview2. Now it doesnt work anymore.

I’m not sure what you mean by ‘it’, but I assume you mean either Lumen or Nanite. Short version, Lumen works, Nanite does not. I’m pretty sure preview 2 didn’t support either of those features, the final release does support Lumen though.

Around Nanite support: no one has been able to provide me with a solid technical reason why Nanite couldn’t work on the Mac. I’ve heard various reasons thrown around like M1 GPU not supporting tessellation, but that’s false, it does, but even if it didn’t, Nanite is mostly software rasterised anyway, so it wouldn’t explain why it couldn’t work on the Mac.

Meanwhile, Epic has been dead silent on the topic, the documentation doesn’t even mention if it’s supported on the Mac or not and they seemingly refuse to make any sort of statements or respond to any comments involving Nanite support on Mac. Meanwhile you have people like myself that don’t know how to proceed as we just don’t know whether Epic intends to implement Nanite support for the Mac or not.

I’m extremely disappointed that Unreal Engine 5 launched in the state that it did, with the Mac version completely missing one of the most important features that the new engine has to offer.

4 Likes

Hey, thanks for your answer. I meant lumen. And it did work for me on intel Mac on preview 2. And it stopped working after that. I have no idea why. :confused:

The only other thing I can suggest trying is to create a new project in UE5, and in the Project Settings, under Platforms->Mac, make sure that you’ve got the latest version of Metal selected and that everything looks like it’s on desktop-based settings.

Thank you! I will try that!

Also make sure when you create the project it’s set to high end desktop, not one of the mobile settings since that will obviously disable Lumen.

I’m not talking about M1 support, I’m talking about Nanite support on Mac.

1 Like

How is that safe to say? M1 support simply means that the editor/engine is compiled as an ARM binary instead of an Intel one. That has nothing to do with Nanite.

while that is 100% true, i think that when epic decides to buckle down and fully support the apple silicon, they will be in a mindstate that they start to implement everything else they intended to at some point

3 Likes

It will be nice to put together hardware info for MacOS users, which Macs work with Lumen and Nanite.
I have a 5k retina, and Lumen, Nanite, and Backinglight don’t work.
Screenshot 2022-05-05 at 17.09.53
… and I have a MacAir 2020 M1 and Lumen and Baked Light, work. Ninate didn’t check yet.
Screenshot 2022-05-08 at 11.10.11

Also the question for me if it is related to the hardware that the M1 is not supported, or just the Metal API that is not fully integrated / not supporting it.

e.g. if i see the screenshot above, the Radeon Pro 570X seems like it does not work in the Mac, but should on windows?

It might take some rendering engine developer who can share some insights what it is lacking off, time to integrate, hardware support or software api support

Lumen Works (Software Tracing). Nanite NOT Working

3 Likes

So I did some testing and I didn’t investigate too much, BUT… I forced Nanite to be supported on MacOS by adding:

[ShaderPlatform METAL_SM5]
bSupportsNanite=true

to:

Engine/Config/Mac/DataDrivenPlatformInfo.ini

and this resulted in a bunch of shaders recompiling on engine launch. Nanite still didn’t appear to work even though i forced it on. Turns out the engine was checking for support for Atomics for the UInt64 type which the Metal RHI reports that it does not suppport. I forced support with:

GRHISupportsAtomicUInt64 = true;

This causes the engine to crash due to threads not being created because

GRHIPersistentThreadGroupCount < =0;

So i forced it with:

GRHIPersistentThreadGroupCount = 1;

this causes the engine to crash because it cant find a particular compute shader. So it appears that nanite is not supported due to the hardware not being physically supported (GRHISupportsAtomicUInt64). This could be because the M1 is using Rosetta x86 emulation or the M1 could actually not support it period. i have no clue, it’s not something i’ve studdied at length. So, It appears as though the M1 does not contain the proper hardware required to run nanite in it’s current state. I’m sure that the nanite algorithm could be modified slightly to allow support. This is all a shot in the dark from only 20 minutes of investigation.

4 Likes

That is excellent info and i was very excited to hear that i could package my game in native m1 mode. However, i’ve tried every which way and it doesn’t actually work. This could be project specific so it may work for others. If i use -architecture=arm64 like it says , it just complains that arm64(M1) is not supported and it’s going to build in x86(Intel) mode anyways. however, if i use -specifiedarchitecture=arm64 it will complain that MyGameEditor arm64(M1) is not supported but it will compile MyGame (No Editor) in arm64(M1) mode. Everything compiles appropriately but it still fails to package because it can’t find all of the .dSYM files (debug info files) for my project and the engine. Even in shipping builds it still tries to find them and it fails due to not being able to find them. If i change my Target.cs files to manually override the including of debug info, it won’t complain about not finding debug info but it will actually say the infamous “Launch was not setup to be included in binary build. please mark it as PrecompileForTargets.Any” and it fails to package. So, unless i’m not doing something correct (I’m litterally following that documentation page to the letter) M1 is not supported in any build of your game. If someone can get it to package for arm64(M1) please do let me know, i’m interested in testing the performance between the two builds of my game. Thank you all.

EDIT: It appears that it might work for source builds of the engine.

EDIT 2: I can confirm that it also does not work for source builds (6 hours to build the engine for nothing lol). Well, i guess just hope for proper M1 support soon

EDIT 3: Ok…So, Using visual studio code, i am able to compile UnrealGame to apple silicon (M1). Doing the same for my project, also works. So yes, with the Source version of the engine, you can indeed compile the engine and your game to native apple silicon, just not the Editor.

2 Likes