Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Why does Compiling Shaders show Huge Numbers?

So this seamed to have started after the 4.1 update

I have a shader which when i made a change in the previous version of the engine would count down from around 350 when compiling only after i hit Apply.

Now when i edit the shader or any other shader it counts down from 1,000-1,700 as soon as i make any chhange, assuming this was a bug i tried reconnecting a node that was already connected over and over and each time i did the shader compiling count would jump by 1,000...

Is this a known bug or am i the first one to encounter this?

A fix would be greatly appreciated.

Product Version: Not Selected
more ▼

asked Apr 26 '14 at 11:57 AM in Everything Else

avatar image

31 1 3 5

avatar image Hyroncore Apr 26 '14 at 12:06 PM

Could you please post a screenshot of the portion of your texture that you changed the node in? I am still personally learning as well but had encountered a similar issue when I was creating materials with alot of textures.

Also I have noticed as an example using premade demo maps like the Elemental and Shooter Game maps where that happens if you up the build quality. I am unsure as to why that might happen mind.

Also while this might not be directly relevant to your question I did find this particular question here that might offer insight as to why your experiencing this situation. Check out this link here: https://answers.unrealengine.com/questions/9999/compiling-shaders-takes-a-long-time.html

avatar image AH_Rob Apr 27 '14 at 01:22 PM

I am having something very similar.

I have just upgraded to 4.1 and now when I make a change to a material I have around 300 shaders compiling. My project has two materials in it, and 6 textures, so hardly anything particularly taxing. I get approximately 300 shaders compiling when I do anything in the material. Add a constant, add a texture sample. Currently my material just has 2 textures plugged straight into it.

Prior to 4.1 I never even noticed it compiling shaders when I made a change!

avatar image Surfur Apr 30 '14 at 07:15 PM

I have the same thing happening. Even making a material with a single constant plugged into the Diffuse will require around 100 shaders to compile. And any small change to anything within the material, even changing the constant from 1 to 2 will require 100 shaders to compile. Eventually all the small changes you do will add up and start going to the 400's and 800's if you're making a lot of small changes in a rapid succession. This didn't happen in the previous version and I hope there's a fix soon!

avatar image Adam Davis STAFF Apr 30 '14 at 09:23 PM

Hi everyone,

Can you please post your dxdiags here so we can have a look at what might be going on? Thank you!

avatar image CharlestonS Apr 30 '14 at 11:34 PM

Here you are sir. FYI - Since posting this i have seen a lot of people in the forums and such having the same problem since the 4.1 update.link text

dxdiag.txt (64.5 kB)
avatar image lackthereof0 May 01 '14 at 04:04 AM

I've found that the number of shaders compiling goes up by a few hundred every time I make a change to the material (example, the default value of a scalar parameter). Oddly, it doesn't "start over" at zero when I make a change, it appends more. [1]: /storage/temp/5280-dxdiag.txt

dxdiag.txt (71.1 kB)
avatar image CharlestonS May 01 '14 at 04:39 AM

Yeah, it's the same for me, as soon as i even open a shader it starts compiling at the actual shader count then EVERY change i makes multiplies that number then if i hit Apply while its compiling it multiplies again. It makes shader creation a very tedious process since the 4.1 update

avatar image Surfur Apr 30 '14 at 09:35 PM

Attached is my Dxdiag

dxdiag.txt (38.1 kB)
avatar image AH_Rob May 01 '14 at 07:58 AM

dxdiag for you

dxdiag.txt (45.8 kB)
dxdiag.txt (45.8 kB)
avatar image KnightTechDev May 17 '14 at 08:03 AM

The Version 4.1 and 4.1.1 feels like it takes a bit longer to load on some things and compiling shaders does seem to take a bit longer, early load one of mine took 15 minutes when before it was about 30 seconds to 1 minute. When you Compile it does seem to compile multiple vs targeted in the graph too. it has improved in other areas though no doubt.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

2 answers: sort voted first

Hi everyone,

We have released a preview version of the 4.1.1 update. This contains a fix for the shader compile issue. You can find more information here: https://forums.unrealengine.com/showthread.php?4406-4-1-1-hotfix-update-Preview-now-available

If you do not wish to try the preview version, we do expect to have an update for everyone within a week. Thank you and have a great day!

more ▼

answered May 07 '14 at 07:19 PM

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

Hi everyone,

Our lead rendering programmer, Nick Penwarden posted a response on another thread. Here is what he said:

When we added support for async shader compiling it significantly reduced the amount of time the editor blocks when updating the preview material. It was a great workflow change for our artists but I can see how it would be frustrating on some hardware, especially CPUs without many cores.

We have made some changes for the next release to reduce the number of preview shaders we compile which will decrease the time it is taking. I hope that helps. I also appreciate the feedback, we'll take it in to account and consider whether we should add an option for disabling live preview. https://forums.unrealengine.com/showthread.php?4026-Epic-can-you-PLEASE-KILL-the-material-autocompile-feature-for-good

-Nick P.

more ▼

answered May 01 '14 at 06:25 PM

avatar image CharlestonS May 01 '14 at 06:40 PM

I have 6 cores with 12 threads though and this doesn't really answer the questions as to why it multiplies the shader compile count every time there is a change. I mean a 100 instruction shader can turn into a 20,000 plus shader compile after making changes.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question