Here is another one:
I wanted to handle window resizing,
window.addEventListener( 'resize', onWindowResize, false );
function onWindowResize(){
renderer.setSize( window.innerWidth, window.innerHeight );
}
This “mostly” works, except that the particles color is reset to black, and the aspect ratio is not updated, transforming balls in eggs … and I have no idea how to fix this.
Thanks 🙂
You also need to update the camera: