# Loading multiple texture uniforms in RawShaderMaterial

**URL:** <https://discourse.threejs.org/t/loading-multiple-texture-uniforms-in-rawshadermaterial/32309>\
**Category:** Questions\
**Tags:** materials\
**Created:** [December 2, 2021, 2:16pm UTC](https://discourse.threejs.org/t/loading-multiple-texture-uniforms-in-rawshadermaterial/32309 "2021-12-02T14:16:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![marwie](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/marwie/32/22424_2.png) [@marwie](https://discourse.threejs.org/u/marwie)\
**Post date:** [December 2, 2021, 2:16pm UTC](https://discourse.threejs.org/t/loading-multiple-texture-uniforms-in-rawshadermaterial/32309/1 "2021-12-02T14:16:00Z")

</div>

Hello,

I’m currently having problems rendering a custom shader using RawShaderMaterial.

I’m trying to render a shader with a diffuse texture and an additive emission texture. I’m loading the textures using a THREE.TextureLoader and set \_BaseMap and \_EmissionMap as uniform { value { THREE.Texture(.image) }}

I stripped my frag shader down to these few lines:

```javascript
#version 300 es
precision highp float;
precision highp int;

uniform mediump sampler2D _BaseMap;
uniform mediump sampler2D _EmissionMap;

in highp vec2 vs_TEXCOORD0;
out highp vec4 SV_Target0;
vec4 u_xlat1;

void main()
{
    SV_Target0.xyz = texture(_EmissionMap, vs_TEXCOORD0.xy).xyz;
    SV_Target0.w = 1.0;
    return;
}

```

When i run it like this it is just black. Running it with texture(\_BaseMap it works correctly.  
I’m not sure what I’m missing, maybe someone could point me in the right direction! Thanks a lot 🙂

Current version of threejs: 0.134.0  
Just in case it is useful here are the uniforms that are currently set - maybe there is a problem as well?

 ![image](https://canada1.discourse-cdn.com/flex035/uploads/threejs/original/3X/b/a/bacd5efb77a60158b89569fac39d8406e90baab2.png)

---

<div class="post-metadata">

**Author:** ![marwie](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/marwie/32/22424_2.png) [@marwie](https://discourse.threejs.org/u/marwie)\
**Post date:** [December 2, 2021, 2:52pm UTC](https://discourse.threejs.org/t/loading-multiple-texture-uniforms-in-rawshadermaterial/32309/2 "2021-12-02T14:52:47Z")

</div>

The loading issue seems to be solved (not sure what I changed that fixed it right now to be honest)
