Adding Point Lights

We’re now ready to add some point lights to our scene so we can make our particle fountains glow. We won’t be able to see this too well with a bright backdrop, so the first thing we’ll do is switch over to a night skybox. You can download the night skybox from the website and place it in your project’s /res/drawable-nodpi folder.[63]

To switch to the night skybox, let’s return to ParticlesRenderer and update the assignment to skyboxTexture as follows:

skyboxTexture = TextureHelper.loadCubeMap(context,
new​ ​int​​[]​ { R.drawable.night_left, R.drawable.night_right,
R.drawable.night_bottom, R.drawable.night_top,
R.drawable.night_front, R.drawable.night_back}); ...

Get OpenGL ES 2 for Android now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.