# WebGPU Mode PBRCustomMaterial add sampler uniform error

**URL:** <https://forum.babylonjs.com/t/webgpu-mode-pbrcustommaterial-add-sampler-uniform-error/48235>\
**Category:** Bugs\
**Tags:** webgpu, pbrcustommaterial\
**Created:** [February 23, 2024, 5:57am UTC](https://forum.babylonjs.com/t/webgpu-mode-pbrcustommaterial-add-sampler-uniform-error/48235 "2024-02-23T05:57:38Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![zhangyahan](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/zhangyahan/32/31789_2.png) [@zhangyahan](https://forum.babylonjs.com/u/zhangyahan)\
**Post date:** [February 23, 2024, 5:57am UTC](https://forum.babylonjs.com/t/webgpu-mode-pbrcustommaterial-add-sampler-uniform-error/48235/1 "2024-02-23T05:57:38Z")

</div>

Adding a sampler uniform to PBRCustomMaterial in WebGL mode works fine, but trying to do the same in WebGPU mode gives the console an error.

> **[Babylon.js Playground](https://playground.babylonjs.com/?webgpu#BVJCJC%231)**
>
> Babylon.js playground is a live editor for Babylon.js WebGL 3D scenes

---

<div class="post-metadata">

**Author:** ![qq2315137135](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/qq2315137135/32/32219_2.png) [@qq2315137135](https://forum.babylonjs.com/u/qq2315137135)\
**Post date:** [February 23, 2024, 9:03am UTC](https://forum.babylonjs.com/t/webgpu-mode-pbrcustommaterial-add-sampler-uniform-error/48235/2 "2024-02-23T09:03:44Z")

</div>

> **[Babylon.js Playground](https://playground.babylonjs.com/?webgpu#BVJCJC%233)**
>
> Babylon.js playground is a live editor for Babylon.js WebGL 3D scenes
