NME swizzle bug introduced in recent commit?

I’ve been working on a node material, but this morning when I reload my work in progress I’m getting the following error:
8:30:50: TypeError: (this.rSwizzle + this.gSwizzle + this.bSwizzle + this.aSwizzle).substr is not a function

Could this be related to this recently merged PR change?

Or is the change to support swizzling on the blocks going to need an update in my materials?

pinging @Deltakosh

nope my bad, the fix was merged, (@sebavan did it make the cut for the nightly?)

@Prodigal: Any way this will be fixed in a couple of hours max

1 Like

I checked and it is in the new nightly
@Prodigal: Simply refresh your cache and you should be good to go :slight_smile:
Sorry for the inconvenience

2 Likes

@Deltakosh Upon refresh the console error is indeed gone, but the output for the material is still not rendering.

I had the serialized swizzle value issue, but it looks like you’ve already fixed that this morning.

After fixing that in my block, I’m still getting an error any time I use the ColorMerger block (goes away if I bypass just that block:

9:37:33: Shader compilation error: FRAGMENT SHADER ERROR: 0:274: 'und' : illegal vector field selection ERROR: 0:274: '=' : dimension mismatch ERROR: 0:274: '=' : cannot convert from 'highp float' to 'highp 3-component vector of float'

The error doesn’t show on load, which is curious, but if I disconnect, reconnect or change a block value the error is emitted.

For reference, here is the material I’m working with: https://nme.babylonjs.com/#LP47ZD#1

If you connect the DrawGrid ColorMerger block’s rgb output directly to the FragmentOutput you’ll still see the issue so I’m relatively sure it’s an issue with the ColorMerger. Connecting other rgb values from other parts of the material that bypass ColorMerger seem to render correctly and eliminate the error.

On it!

1 Like

Ok this is “Expected”
There was a second fix that did not make it to the nightly
I’ll make sure to build one in the next couple hours

1 Like

Thanks so much for the quick response. I’ll hold tight.

2 Likes