# Package Fail: CompressedFormat == PF\_Unknown || CompressedFormat == CompressedMip\[0\].PixelFormat

**URL:** <https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806>\
**Category:** XR Development\
**Tags:** unreal-engine, UE5-0, Android, question\
**Created:** [July 15, 2021, 9:49pm UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806 "2021-07-15T21:49:07Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kingofftheknomes](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Kingofftheknomes](https://forums.unrealengine.com/u/Kingofftheknomes)\
**Post date:** [July 15, 2021, 9:49pm UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/1 "2021-07-15T21:49:07Z")

</div>

Hi Everyone

I am trying to package a VR game for the quest 2 that I have built to android vulkan. The game packages successfully BEFORE I build the lighting. AFTER I build lighting I get a error during cooking That says:

“LogWindows: Error: Error reentered: Assertion failed: CompressedFormat == PF\_Unknown || CompressedFormat == CompressedMip[0].PixelFormat [File:D:/build/++UE5/Sync/Engine/Source/Runtime/Engine/Private/VT/VirtualTextureDataBuilder.cpp] [Line: 673]”

(See full output log atttached).

I am on Unreal engine 5 early access but the error is happening on 4.26 as well.

I can’t find any help on this particular error, any advice appreciated.

[Changelog.txt](https://forums.unrealengine.com/uploads/short-url/5dxSeZx1VMVsVKw85T3cecqrKgZ.txt) (95.9 KB)

---

<div class="post-metadata">

**Author:** ![motorsep](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/motorsep/32/918698_2.png) [@motorsep](https://forums.unrealengine.com/u/motorsep)\
**Post date:** [August 10, 2021, 3:17pm UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/3 "2021-08-10T15:17:36Z")

</div>

You are not alone in this [Unreal Engine 4.27 Preview - #193 by motorsep](https://forums.unrealengine.com/t/unreal-engine-4-27-preview/234295/193)

I reported the bug, pinged Epic and @VictorLerp on Discord, but haven’t heard anything back. Let’s hope it will be fixed (preferably in 4.27 hotfix or something).

---

<div class="post-metadata">

**Author:** ![Rishi\_Jayanthan](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Rishi\_Jayanthan](https://forums.unrealengine.com/u/Rishi_Jayanthan)\
**Post date:** [January 14, 2022, 2:22am UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/4 "2022-01-14T02:22:14Z")

</div>

Hey Is there any solution for this now?

---

<div class="post-metadata">

**Author:** ![Abs22x2](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/abs22x2/32/471665_2.png) [@Abs22x2](https://forums.unrealengine.com/u/Abs22x2)\
**Post date:** [April 12, 2022, 10:10am UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/5 "2022-04-12T10:10:04Z")

</div>

Hello,  
I am having the same issue with UE v4.27.2  
I am trying to package for the ASTC platform (for Oculus Quest 2) using Virtual Textures (but no Runtime Virtual Textures) and the package always fails with:

> Assertion failed: CompressedFormat == PF\_Unknown || CompressedFormat == CompressedMip[0].PixelFormat [File:D:/Build/++UE4/Sync/Engine/Source/Runtime/Engine/Private/VT/VirtualTextureDataBuilder.cpp] [Line: 676]

I am using OpenGL and not Vulkan.  
It is kinda annoying since I really need to use VT because of the very large textures I am using (importing UDIM textures).  
I don’t really understand why this error occurs since the compression format of my textures seems to be OK (DXT1 for color maps and BC5 for normal maps) and works fine when I am not using Virtual Textures.

Did you solve this problem by any chance ?

EDIT: This failure happens when the “Enable virtual texture support on mobile” option is enabled

---

<div class="post-metadata">

**Author:** ![motorsep](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/motorsep/32/918698_2.png) [@motorsep](https://forums.unrealengine.com/u/motorsep)\
**Post date:** [April 12, 2022, 1:44pm UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/6 "2022-04-12T13:44:28Z")

</div>

> [@Abs22x2](#):
>
> EDIT: This failure happens when the “Enable virtual texture support on mobile” option is enabled

Do you have an option for VTs for Lightmaps turned on? That created issue for me.

Another thing is that all your VTs need to have power of two padding on in the Texture Editor. Sadly, there is no way to set this for lightmaps, therefor you need to turn off VT for lightmaps.

---

<div class="post-metadata">

**Author:** ![Abs22x2](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/abs22x2/32/471665_2.png) [@Abs22x2](https://forums.unrealengine.com/u/Abs22x2)\
**Post date:** [April 12, 2022, 2:48pm UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/7 "2022-04-12T14:48:22Z")

</div>

First of all, thank you very much for answering so fast!

Sadly I have not enbaled the VTs for lightmaps  
But my textures didn’t have the power of two padding on in the texture settings  
I have tried to rebuild with the power of two padding turned on (even if all my textures are already in power of two since those are UDIM imported textures and UE4 only interprets UDIM as VTs when they are in power of two resolutions - my textures are 256x256)

I still have the same failure both with ASTC and ETC2

Here are screenshots of my current project and texture settings:

_Project settings_  
 ![VTSettings](https://d3kjluh73b9h9o.cloudfront.net/original/4X/1/b/3/1b35e4d3d9408e2d2373832fa3f3300537f96d30.png)

_Texture settings_

 ![VTTextureSettings](https://d3kjluh73b9h9o.cloudfront.net/original/4X/e/a/3/ea33410688c269b49111556d82622c1bac2490e1.png)

I am a bit deseperate  
I tried to build with UE4.26 with the same result  
I am planning to upgrade a copy of the project to UE5 and see if the issue is still there

Thank you for your help

---

<div class="post-metadata">

**Author:** ![motorsep](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/motorsep/32/918698_2.png) [@motorsep](https://forums.unrealengine.com/u/motorsep)\
**Post date:** [April 12, 2022, 3:17pm UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/8 "2022-04-12T15:17:27Z")

</div>

Sorry mate, can’t help you with that. I jumped through many hoops to get it working and I still get occasional crash here and there.

Btw, it’s not worth using VTs on mobile though - too expensive, performance wise.

---

<div class="post-metadata">

**Author:** ![Abs22x2](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/abs22x2/32/471665_2.png) [@Abs22x2](https://forums.unrealengine.com/u/Abs22x2)\
**Post date:** [April 12, 2022, 3:19pm UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/9 "2022-04-12T15:19:35Z")

</div>

Alright

Well I am trying to use VTs for a very specific usage and I don’t have many other choices since UDIMs work this way with UE4

I will keep digging and try to fix this

Thank you for your help though

EDIT: Doesn’t work on UE5 either

---

<div class="post-metadata">

**Author:** ![motorsep](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/motorsep/32/918698_2.png) [@motorsep](https://forums.unrealengine.com/u/motorsep)\
**Post date:** [April 12, 2022, 8:13pm UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/10 "2022-04-12T20:13:16Z")

</div>

> [@Abs22x2](#):
>
> EDIT: Doesn’t work on UE5 either

Since UE4 is pretty much done being supported at this point, I recommend making a blank project in UE5 with whatever settings you need and if it crashes, upload this project to be shared with Epic and submit bug report.

---

<div class="post-metadata">

**Author:** ![Abs22x2](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/abs22x2/32/471665_2.png) [@Abs22x2](https://forums.unrealengine.com/u/Abs22x2)\
**Post date:** [April 25, 2022, 8:50am UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/11 "2022-04-25T08:50:51Z")

</div>

I have submitted the issue to Epic.  
As I said the engine doesn’t really crash, it just won’t package with mobile virtual textures support enabled.

I also tried to modify the engine source code (4.27) and I managed to package my apk, but the textures are not present when I launch my apk on my Oculus Quest 2.  
However I think that I am close to some kind of workaround.  
It seems that UE4 (the VirtualTextureDataBuilder to be more specific) doesn’t like virtual textures and misinterprets the Pixel Format of the textures… (is this meant by Epic or is this an oversight?)

Anyway, if I make any progress I’ll keep posting here

Have a good day

---

<div class="post-metadata">

**Author:** ![Fat\_Scout](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/fat_scout/32/482168_2.png) [@Fat\_Scout](https://forums.unrealengine.com/u/Fat_Scout)\
**Post date:** [April 28, 2022, 2:48am UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/12 "2022-04-28T02:48:12Z")

</div>

Howdy Abs, thank you for working on this what did you do to modify the source code? As I write this I commented out the line that throws the exception and am waiting for the VS build to complete.

I also have an issue with just testing my code using livelink VR preview - this also causes the engine to crash with no Crash report. I think it’s crashing again because of VTs.

---

<div class="post-metadata">

**Author:** ![Abs22x2](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/abs22x2/32/471665_2.png) [@Abs22x2](https://forums.unrealengine.com/u/Abs22x2)\
**Post date:** [April 28, 2022, 8:59am UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/13 "2022-04-28T08:59:06Z")

</div>

Hello  
I also commented the line that throws the exception and I forced the compression format of my VTs, and added some logs to determine what condition triggered the assertion

> // Added logs  
> UE\_LOG(LogTemp, Warning, TEXT(“Compression Debug Output”));  
> UE\_LOG(LogTemp, Warning, TEXT(“Unknown Compressed Format?: %s”), CompressedFormat == PF\_Unknown);  
> UE\_LOG(LogTemp, Warning, TEXT(“Compressed Mip Pixel Format: %d”), (int)CompressedMip[0].PixelFormat);  
> UE\_LOG(LogTemp, Warning, TEXT(“Compressed Pixel Format: %d”));  
> UE\_LOG(LogTemp, Warning, TEXT(“Compression Debug Output: %d”), (int)CompressedFormat);  
> // Line Causing Assertion  
> check(CompressedFormat == PF\_Unknown || CompressedFormat == CompressedMip[0].PixelFormat);
> 
> CompressedFormat = (EPixelFormat)CompressedMip[0];// Tried to replace with = PF\_ETC2\_RGBA; but textures are broken

This led me to a successful package but the textures didn’t show up in the packaged apk…  
I didn’t take the time to dig deeper into the engine but I will eventually

Good luck!

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_517caca7](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_517caca7](https://forums.unrealengine.com/u/anonymous_user_517caca7)\
**Post date:** [May 17, 2022, 9:23pm UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/14 "2022-05-17T21:23:34Z")

</div>

Running into this problem also. Abs22x2, mind sharing where you added the commented line? Debugging this currently on my end but thought I would start where you added that log.

---

<div class="post-metadata">

**Author:** ![Abs22x2](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/abs22x2/32/471665_2.png) [@Abs22x2](https://forums.unrealengine.com/u/Abs22x2)\
**Post date:** [May 18, 2022, 10:14am UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/15 "2022-05-18T10:14:27Z")

</div>

Hello  
My bad I didn’t precise where I added those lines.  
I directly modified the VirtualTextureDataBuilder.cpp (you can find where this file is located into the engine sources with the assertion message) line 676

> [@Abs22x2](#):
>
> [File:D:/Build/++UE4/Sync/Engine/Source/Runtime/Engine/Private/VT/VirtualTextureDataBuilder.cpp] [Line: 676]

---

<div class="post-metadata">

**Author:** ![mixer76](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@mixer76](https://forums.unrealengine.com/u/mixer76)\
**Post date:** [June 13, 2022, 6:41am UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/16 "2022-06-13T06:41:45Z")

</div>

I encountered this problem when I painted too much grass with the foliage tool on my RVT enabled landscape. After decreasing the number of grass, the packaging is successful.

---

<div class="post-metadata">

**Author:** ![Abs22x2](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/abs22x2/32/471665_2.png) [@Abs22x2](https://forums.unrealengine.com/u/Abs22x2)\
**Post date:** [July 12, 2022, 2:41pm UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/17 "2022-07-12T14:41:02Z")

</div>

I don’t have any foliage in my project 😕

---

<div class="post-metadata">

**Author:** ![christuusgnosis](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@christuusgnosis](https://forums.unrealengine.com/u/christuusgnosis)\
**Post date:** [July 17, 2022, 1:19am UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/18 "2022-07-17T01:19:52Z")

</div>

quest does not like open gl  
you should disable open gl and only have vulkan, its optimized for vulkan.

---

<div class="post-metadata">

**Author:** ![Abs22x2](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/abs22x2/32/471665_2.png) [@Abs22x2](https://forums.unrealengine.com/u/Abs22x2)\
**Post date:** [July 21, 2022, 8:12am UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/19 "2022-07-21T08:12:58Z")

</div>

Hello,

I will try this then, thank you for the tip.  
Why the Quest doesn’t like OpenGL by the way?

---

<div class="post-metadata">

**Author:** ![motorsep](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/motorsep/32/918698_2.png) [@motorsep](https://forums.unrealengine.com/u/motorsep)\
**Post date:** [July 21, 2022, 2:37pm UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/20 "2022-07-21T14:37:05Z")

</div>

I think this issue only happens with unpadded VT textures and/or when you turn on VTs for Lightmaps on mobile. I haven’t seen this error when NOT using VTs.

---

<div class="post-metadata">

**Author:** ![christuusgnosis](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@christuusgnosis](https://forums.unrealengine.com/u/christuusgnosis)\
**Post date:** [July 21, 2022, 3:59pm UTC](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806/21 "2022-07-21T15:59:34Z")

</div>

IDK  
it doesn’t make sense to me  
vulkan is the “new” thing  
but Carmack is TD for Meta  
so I do not know why his ogl baby was cast aside for vulkan  
IMHO that’s why quest games look like crap  
ogl is cleaner and brighter  
but  
what do I know

[Next page](https://forums.unrealengine.com/t/package-fail-compressedformat-pf-unknown-compressedformat-compressedmip-0-pixelformat/240806.md?page=2)
