# A question about THREE.DataArrayTexture

**URL:** <https://discourse.threejs.org/t/a-question-about-three-dataarraytexture/51333>\
**Category:** Questions\
**Tags:** textures, shaders\
**Created:** [May 8, 2023, 1:18pm UTC](https://discourse.threejs.org/t/a-question-about-three-dataarraytexture/51333 "2023-05-08T13:18:08Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Attila\_Schroeder](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/attila_schroeder/32/36097_2.png) [@Attila\_Schroeder](https://discourse.threejs.org/u/Attila_Schroeder)\
**Post date:** [May 8, 2023, 1:18pm UTC](https://discourse.threejs.org/t/a-question-about-three-dataarraytexture/51333/1 "2023-05-08T13:18:08Z")

</div>

I have a question about the THREE.DataArrayTexture.  
If I pass huge arrays to shader and then process them in the shader, it doesn’t cause any problems. However, if I pass such an array to a THREE.DataArrayTexture, this leads to brief stutters.  
I only use linear min and mag filters. What arithmetic operations does the THREE.DataArrayTexture perform?  
I had the idea of ​​doing without the THREE.DataArrayTexture and then reading and processing the array manually in the shader. Because I know exactly which array element has which color value and to which coordinates it belongs.  
To what extent can the bottleneck between CPU and GPU lead to stuttering?

---

<div class="post-metadata">

**Author:** ![donmccurdy](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/donmccurdy/32/33209_2.png) [@donmccurdy](https://discourse.threejs.org/u/donmccurdy)\
**Post date:** [May 8, 2023, 1:40pm UTC](https://discourse.threejs.org/t/a-question-about-three-dataarraytexture/51333/2 "2023-05-08T13:40:27Z")

</div>

How are you passing large arrays to the shader, if not with a texture? Could you share a code excerpt or a demo? Also note that if you just have a single array, you probably want THREE.DataTexture, not THREE.DataArrayTexture.

---

<div class="post-metadata">

**Author:** ![Attila\_Schroeder](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/attila_schroeder/32/36097_2.png) [@Attila\_Schroeder](https://discourse.threejs.org/u/Attila_Schroeder)\
**Post date:** [May 8, 2023, 2:05pm UTC](https://discourse.threejs.org/t/a-question-about-three-dataarraytexture/51333/3 "2023-05-08T14:05:53Z")

</div>

I pass large arrays to a geometry via attributes and the shader can access them.

```javascript
geometry.setAttribute('coords', new THREE.Float32BufferAttribute(data.coords, 3));     
geometry.attributes.coords.needsUpdate = true;

```

But your objection is justified because I only pass an array initially when I create a geometry object and no longer while it exists. I didn’t have that in mind when I first thought about it.  
My software is very big. I would have to create a small example
