# Failed: FMath::IsFinite(TexelFactor) | Vertex Painting?

**URL:** <https://forums.unrealengine.com/t/failed-fmath-isfinite-texelfactor-vertex-painting/466306>\
**Category:** World Creation\
**Tags:** paint, unreal-engine, question\
**Created:** [June 5, 2020, 10:07pm UTC](https://forums.unrealengine.com/t/failed-fmath-isfinite-texelfactor-vertex-painting/466306 "2020-06-05T22:07:45Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sarlack](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/sarlack/32/1194542_2.png) [@Sarlack](https://forums.unrealengine.com/u/Sarlack)\
**Post date:** [June 5, 2020, 10:07pm UTC](https://forums.unrealengine.com/t/failed-fmath-isfinite-texelfactor-vertex-painting/466306/1 "2020-06-05T22:07:45Z")

</div>

When I load one of my levels I get this error…  
LogOutputDevice: Error: Ensure condition failed: FMath::IsFinite(TexelFactor)

It only happens once per start of the engine, if I load another level and reload the level that caused the error the first time, it doesn’t error again. But if I restart the editor it will happen once again. And I’m pretty sure it only happens in 4.25

I’m wonder if it has something to do with Vertex Painting.

I also get this warning above the call stack when I load the level…  
Warning: Spent 0.0s repairing painted vertex colors due to static mesh re-imports! This will happen every load until the maps are resaved.

I re-save like the warning says, but it will still do the same thing the next time I start the editor and load the level.

This level has some buildings made with static meshes that were painted. I selected all the meshes for a house and clicked “Convert selection to Blueprint class”. In the blueprint, the static mesh components are painted like they were in the level. I tried to clear the mesh and reload it, but the paint remains.

Is there a way to paint vertex of a static mesh component in a blueprint or at least clear the paint?  
There is a Remove Painted Verticies function in the actor blueprint which i tried in the construction script, but it does nothing.

---

<div class="post-metadata">

**Author:** ![herb64](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@herb64](https://forums.unrealengine.com/u/herb64)\
**Post date:** [June 6, 2020, 5:51am UTC](https://forums.unrealengine.com/t/failed-fmath-isfinite-texelfactor-vertex-painting/466306/2 "2020-06-06T05:51:53Z")

</div>

I get the same Ensure Condition - but have no vertex painting in my project. So it looks like it might not have to do with the Vertex Painting at all.  
From source code: TexelFactor is “the world size a texture square holding with unit UVs” - so my guess is, that there’s some UV scaling issue with some object. I did not find the mesh causing this in my case yet.  
Just my 2ct…

---

<div class="post-metadata">

**Author:** ![krisgoku2\_Dev](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@krisgoku2\_Dev](https://forums.unrealengine.com/u/krisgoku2_Dev)\
**Post date:** [June 20, 2020, 7:55pm UTC](https://forums.unrealengine.com/t/failed-fmath-isfinite-texelfactor-vertex-painting/466306/3 "2020-06-20T19:55:56Z")

</div>

I had the same issue also,re-import seems to fix but will randomly go haywire after so many times.Must be a ue4 saving error.Test rei-mport package and hurry and finish it before it goes haywire again…and the return of the 10 second load… I noticed the more I worked in the level the slower the load then boom…This only applies in 4.25… I should see will it do the same on a packaged game…like over 50 opens

---

<div class="post-metadata">

**Author:** ![Ukkoprkl](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Ukkoprkl](https://forums.unrealengine.com/u/Ukkoprkl)\
**Post date:** [August 10, 2020, 8:52pm UTC](https://forums.unrealengine.com/t/failed-fmath-isfinite-texelfactor-vertex-painting/466306/4 "2020-08-10T20:52:10Z")

</div>

I have this issue in landscape. Checked with the debugger and when it checks for landscape materials there are 2 default material references from which 1 has TexelFactor is infinity. The problem is that the materials seems to be generated from landscape material, height and weight maps somehow. If I could somehow reset one component’s material it would be great…

---

<div class="post-metadata">

**Author:** ![simpill](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@simpill](https://forums.unrealengine.com/u/simpill)\
**Post date:** [September 20, 2020, 5:11am UTC](https://forums.unrealengine.com/t/failed-fmath-isfinite-texelfactor-vertex-painting/466306/5 "2020-09-20T05:11:58Z")

</div>

Anyone figured this out? I cant package my project

---

<div class="post-metadata">

**Author:** ![B3b3L](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/b3b3l/32/577413_2.png) [@B3b3L](https://forums.unrealengine.com/u/B3b3L)\
**Post date:** [September 23, 2020, 7:15am UTC](https://forums.unrealengine.com/t/failed-fmath-isfinite-texelfactor-vertex-painting/466306/6 "2020-09-23T07:15:52Z")

</div>

For me it help the answer from @buscas31 from this forum post → [https://answers.unrealengine.com/questions/364985/texture-streaming-pool-over-43032619-mb.html](https://answers.unrealengine.com/questions/364985/texture-streaming-pool-over-43032619-mb.html)

---

<div class="post-metadata">

**Author:** ![Sarlack](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/sarlack/32/1194542_2.png) [@Sarlack](https://forums.unrealengine.com/u/Sarlack)\
**Post date:** [November 7, 2020, 12:40am UTC](https://forums.unrealengine.com/t/failed-fmath-isfinite-texelfactor-vertex-painting/466306/7 "2020-11-07T00:40:42Z")

</div>

@buscas31 solution from the link, I turned off Texture Streaming in Project Settings \> Rendering and the **Error: Ensure condition failed** stopped happening. But I would prefer to have Texture Streaming turned on.

I was able to make the error stop by just re-saving the level as a new level. I got saving errors, but I just hit continue. The level now doesn’t trigger the error when loading.

---

<div class="post-metadata">

**Author:** ![Creator\_135](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Creator\_135](https://forums.unrealengine.com/u/Creator_135)\
**Post date:** [February 12, 2021, 2:35am UTC](https://forums.unrealengine.com/t/failed-fmath-isfinite-texelfactor-vertex-painting/466306/8 "2021-02-12T02:35:30Z")

</div>

Thank Sarlack, It works. They should fix this bug, all of a sudden my code does not compile for no reason.

---

<div class="post-metadata">

**Author:** ![StBlueFire](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/stbluefire/32/641418_2.png) [@StBlueFire](https://forums.unrealengine.com/u/StBlueFire)\
**Post date:** [September 30, 2021, 1:01pm UTC](https://forums.unrealengine.com/t/failed-fmath-isfinite-texelfactor-vertex-painting/466306/9 "2021-09-30T13:01:30Z")

</div>

In case you don’t want to turn off Texture Streaming. I solved this error by changing my Landscape material to something simple and then swapping it back. This appeared to resolve the issue.

I found this out by going into debug mode since I have a CPP project and seeing that LandscapeComponent63 was the culprit.
