This came into my sentry feed after adding cascade shadow.
Affects only MacOS Chrome.
I can’t reproduce this on my machine.
BJS - [13:16:57]: Error: Internal error compiling shader with Metal backend.
Compilation failed:
program_source:51:39: error: no matching member function for call to 'sample_compare'
return static_cast<T>(texture.sample_compare(sampler, coord.xy, coord.z, metal::level(level)));
~~~~~~~~^~~~~~~~~~~~~~
program_source:498:23: note: in instantiation of function template specialization 'ANGLE_textureLod_impl<float>' requested here
float ANGLE__81 = ANGLE_textureLod(_ushadowSampler, ANGLE__80, 0.0f);
^
program_source:40:36: note: expanded from macro 'ANGLE_textureLod'
#define ANGLE_textureLod(env, ...) ANGLE_textureLod_impl(*env.texture, *env.sampler, __VA_ARGS__)
^
/System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/3902/Libraries/lib/clang/902.14/include/metal/metal_texture:5108:16: note: candidate function not viable: no known conversion from 'metal::level' to 'metal::int2' (aka 'int2') for 4th argument
METAL_FUNC T sample_compare(sampler s, float2 coord, float compare_value, int2 offset = int2(0)) const thread
...
This is what I have found so far:
But it seems Babylonjs uses SPIRV on WebGpuEngine.
I’m only using webgl.
Unfortunately, the error you’re reporting is inside ANGLE, so there’s nothing we can do about it. You should report it to Chromium (you can also search for similar issues, maybe it has already been reported).