# Is it possible to retrieve the \`WebGLTexture\` from a \`THREE.WebGLRenderTarget\`?

**URL:** <https://discourse.threejs.org/t/is-it-possible-to-retrieve-the-webgltexture-from-a-three-webglrendertarget/38187>\
**Category:** Questions\
**Created:** [May 16, 2022, 11:38am UTC](https://discourse.threejs.org/t/is-it-possible-to-retrieve-the-webgltexture-from-a-three-webglrendertarget/38187 "2022-05-16T11:38:02Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![alecmce](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/alecmce/32/3074_2.png) [@alecmce](https://discourse.threejs.org/u/alecmce)\
**Post date:** [May 16, 2022, 11:38am UTC](https://discourse.threejs.org/t/is-it-possible-to-retrieve-the-webgltexture-from-a-three-webglrendertarget/38187/1 "2022-05-16T11:38:02Z")

</div>

I want to build a mixed system that uses a non-threejs program to do some processing with textures that were rendered by threejs. To do that, I want to render to a `THREE.WebGLRenderTarget`, then later use the underlying texture in a non-threejs program. But I can’t find any way of extracting the `(gl.)WebGLTexture`. Can anyone help?

---

<div class="post-metadata">

**Author:** ![makc3d](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/makc3d/32/10452_2.png) [@makc3d](https://discourse.threejs.org/u/makc3d)\
**Post date:** [May 16, 2022, 11:42am UTC](https://discourse.threejs.org/t/is-it-possible-to-retrieve-the-webgltexture-from-a-three-webglrendertarget/38187/2 "2022-05-16T11:42:49Z")

</div>

> <https://stackoverflow.com/questions/13626606/read-pixels-from-a-webgl-texture/13640310#13640310>

---

<div class="post-metadata">

**Author:** ![alecmce](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/alecmce/32/3074_2.png) [@alecmce](https://discourse.threejs.org/u/alecmce)\
**Post date:** [May 16, 2022, 11:53am UTC](https://discourse.threejs.org/t/is-it-possible-to-retrieve-the-webgltexture-from-a-three-webglrendertarget/38187/3 "2022-05-16T11:53:40Z")

</div>

That’s reading pixels out of a buffer, but not getting access to the underlying texture. I would then have to copy the pixels back into another texture to use in my non-three program.

---

<div class="post-metadata">

**Author:** ![makc3d](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/makc3d/32/10452_2.png) [@makc3d](https://discourse.threejs.org/u/makc3d)\
**Post date:** [May 16, 2022, 1:02pm UTC](https://discourse.threejs.org/t/is-it-possible-to-retrieve-the-webgltexture-from-a-three-webglrendertarget/38187/4 "2022-05-16T13:02:45Z")

</div>

so you mean non-three-but-still-webgl program, okay, then inspect `renderer.properties.get( renderTarget )` and see if what you want is there
