Nonlinear optical Galton board