Jump to content

Material parameter limit


photo

Recommended Posts

Posted

Hi,

 

It appears that I have reached the (undocumented and unchecked) material parameter limit (64) while working on an ocean shader. Random things in the material start breaking, and the log is spammed with seemingly unrelated material warnings and errors. I can't double the material limit because it appears that there may be more constants and/or enums that are interdependent. 

 

Thus this post is both a bug report (no checking on reaching limit) and a call for help how to temporarily raise the material parameter limit until this is fixed.

 

Steps to reproduce: 

Add at least 65 parameters to a material.

 

Thanks in advance.

Posted

Hello Michel,

 

I looked at the source code and noticed that we you're limited to 256 parameters per material, not 64. It could be a limitation of rendering API (I mean shader uniform limit in case of OpenGL).

 

Could you please provide your material so we'll be able to see the effect?

  • 2 weeks later...
Posted

Hello Michel,

 

I looked at the source code and noticed that we you're limited to 256 parameters per material, not 64. It could be a limitation of rendering API (I mean shader uniform limit in case of OpenGL).

 

Could you please provide your material so we'll be able to see the effect?

 

Hi,

 

The parameter limit for custom shader parameters is 64, I'm pretty sure you can see that when reproducing the problem by pasting any 65 parameters in any material. Technically speaking, I think this could easily be doubled as the minimum requirement for modern hardware is to support uniforms / shader constants double this amount.

 

Regards,

 

Michel

Posted

Hi Michel,

 

We currently investigating this issue. Could you please provide your problematic *.mat file to make sure that we on the right way?

 

One thing you can try - if you are using a lot of float parameters is to pass them as vec4() and then parse inside the Editor.

 

Thanks!

How to submit a good bug report
---
FTP server for test scenes and user uploads:

×
×
  • Create New...