Warnings when use PBR branch

Hi guys :slight_smile:
When I merged current 3.1 branch to PBR branch, I got warnings with PBR shader. For example:
WARNING: In technique 'PreShadow': Define 'COLOR_MAP' mapped to non-existent material parameter 'ColorMap', ignoring. июн 05, 2016 12:09:17 PM com.jme3.material.plugins.J3MLoader readDefine.
Is it normal behavior?

The defines are used to set compile time constraints in the shaders. That warning is saying that there is no param ColorMap set in the .j3md. It will just treat it as if that conditional is never set to true and should not cause any problems in people’s code, however it does mean that there is redundant code in the shader (possibly, I haven’t looked I’m just going on what you wrote).

It’s not ideal but it isn’t going to kill anything AFAIK; I suspect it is a copy-paste issue.

1 Like

I understand it, but I think that we need to update the PBRLighting.j3md :slight_smile:

What @Neilos said.
You can always make a PR if you want, it’s probably just a matter of removing the define in the material definition.

I think if these defines will be removed by author of this definition, it will be better :slight_smile:

Well… then you’ll have to wait, and cope with those warnings, for now.

Ok :slight_smile: