1

How do you introduce randomness within a CAReplicatorLayer layer? For example, randomizing the positions of each particle.

Best, Vance

vance
  • 1,071
  • 11
  • 19

1 Answers1

0

You must setInstanceTransform:(CATransform3D)transform to each replicated layer.

Use that in conjunction with arc4rand() to randomise the positions..

adam
  • 22,404
  • 20
  • 87
  • 119