distribute_particles   xtlang


Defined in:  https://github.com/digego/extempore/tree/v0.8.9/examples/external/shader-tutorials/particles.xtm

Implementation

(bind-func distribute_particles
  "randomly initialise the particles_verts to "
  (lambda (np)
    (doloop (i np)
      (pset! particles_verts (+ (* i 4) 0) (random -1. 1.))
      (pset! particles_verts (+ (* i 4) 1) (random -1. 1.))
      (pset! particles_verts (+ (* i 4) 2) (random -1. 1.))
      (pset! particles_verts (+ (* i 4) 3) (random -1. 1.)))))


Back to Index

Similar Entries

  • create_particles_shader    xtlang
  • euclid-distribute-zeros    scheme
  • gl_draw_particles    xtlang
  • move_particles    xtlang
  • particles-frag    scheme
  • particles-frag    scheme
  • particles-vert    scheme
  • particles-vert    scheme
  • set-data-particles    xtlang