# Showing a captured video sequence with annotations

**URL:** <https://discourse.julialang.org/t/showing-a-captured-video-sequence-with-annotations/2625>\
**Category:** Visualization\
**Tags:** question, images, glvisualize, plotting\
**Created:** [March 12, 2017, 5:36pm UTC](https://discourse.julialang.org/t/showing-a-captured-video-sequence-with-annotations/2625 "2017-03-12T17:36:30Z")\
**Posts on this page:** 1\
**Showing post:** 20

<div class="post-metadata">

**Author:** ![TsurHerman](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tsurherman/32/1234_2.png) [@TsurHerman](https://discourse.julialang.org/u/TsurHerman)\
**Post date:** [March 14, 2017, 11:46am UTC](https://discourse.julialang.org/t/showing-a-captured-video-sequence-with-annotations/2625/20 "2017-03-14T11:46:58Z")

</div>

[Shaders](https://gist.github.com/TsurHerman/a2126a640388c3456e9672635e9067ef)  
Usage is roughly as follows: you need an active openGL context (glfw window)

```julia
S = [("glass.vert",GL_VERTEX_SHADER),("glass.frag",GL_FRAGMENT_SHADER)]
prog = GLprogram("directoryOfShaders",S)

prog["Vpos"] = rand(4,100) #set a vertex attribute(vec4) within the shader .. implicitly create a buffer and transfer data
prog["uniformVar"] = 1 #set a uniform variable inside that program
prog["_indices"] = rand(0:99,3,100) #create indices for 100 triangles randomly for indexed drawing

```

if you are using Atom/Juno examine the structure of prog (structure(prog)) to see a list of uniform variables and vertex attribute variables

This is the first thing I used Julia for … so it is supplied as is, in the hope that you may benefit from it.

---

_[View the full topic](https://discourse.julialang.org/t/showing-a-captured-video-sequence-with-annotations/2625)._
