Strip Unused LOD

Going over how to get rid of unused LOD when your UE4 project is cooked.

Windows
MacOS
Linux
On this page

Reducing the size of your cooked Unreal Engine 4 (UE4) project to be as small can be a challenging task to complete. In the following How - To we will take a look at how unused Level of Detail (LOD) meshes can be automatically removed when your UE4 project is cooked for PC, Consoles and Mobile devices.

Steps

In the following section we will take a look at how to remove unused LOD meshes from your final cooked UE4 project.

  1. First, locate your UE4 projects DefaultEngine.INI file by going to YourProjectName\Config.

    StripUnUsedLOD_01.png

  2. Once your project's DefaultEngine.INI file is located, open it up in any text editor.

    StripUnUsedLOD_02.png

  3. In your DefaultEngine.INI file, look for a section called [Console Variables]. If you do not find a section called [Console Variables] you will need to add one by typing the following text anywhere in your DefaultEngine.INI file.
    [Console Variables]

    StripUnUsedLOD_03.png

  4. Under the newly added  [Console Variables] section add the following items:

    [ConsoleVariables]
    ; Strip render data for LODs below the MinLOD for the target platform during cooking.
    r.StaticMesh.StripMinLodDataDuringCooking=1
    r.SkeletalMesh.StripMinLodDataDuringCooking=1

Remember that r.StaticMesh.StripMinLodDataDuringCooking=1 will strip Static Mesh LOD's while r.SkeletalMesh.StripMinLodDataDuringCooking=1 will strip Skeletal Mesh LOD's. You do not have to use both commands and can use either Static or Skeletal depending on the needs of your project.

  1. Once the Console Variables have been added, save and then close your DefaultEngine.INI file. 

  2. Now, make sure you have set up Per Platform LOD's for your project's meshes and then try to cook your UE4 project.

End Results

With the stripping commands now added to the Console Variables section of your DefaultEngine.INI file, the next time you go to package your UE4 project for release you should notice a reduction in the size of your packaged project. Depending on how your projects content is setup using this could help reduce the size of your UE4 project by 25% - 50%.

Welcome to the new Unreal Engine 4 Documentation site!

We're working on lots of new features including a feedback system so you can tell us how we are doing. It's not quite ready for use in the wild yet, so head over to the Documentation Feedback forum to tell us about this page or call out any issues you are encountering in the meantime.

We'll be sure to let you know when the new system is up and running.

Post Feedback