# Send different uniform values to a single shader

**URL:** <https://discourse.processing.org/t/send-different-uniform-values-to-a-single-shader/568>\
**Category:** Coding Questions\
**Created:** [May 31, 2018, 3:53pm UTC](https://discourse.processing.org/t/send-different-uniform-values-to-a-single-shader/568 "2018-05-31T15:53:19Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![WakeMeAtThree](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/wakemeatthree/32/38_2.png) [@WakeMeAtThree](https://discourse.processing.org/u/WakeMeAtThree)\
**Post date:** [June 2, 2018, 7:34am UTC](https://discourse.processing.org/t/send-different-uniform-values-to-a-single-shader/568/2 "2018-06-02T07:34:20Z")

</div>

You can access the attribute positions from the vertex shader and have a varying variable that’s shared between fragment and vertex. Maybe post your glsl code so we can have a look? Also, [this thread](https://discourse.processing.org/t/depth-of-field-effect-with-a-shader/265) might be of interest to you.

---

_[View the full topic](https://discourse.processing.org/t/send-different-uniform-values-to-a-single-shader/568)._
