I'm having trouble with using multiple buffers to use multiple shaders. I understand that I render to buffer1, draw it to buffer2, then continue drawing to buffer2, but I'm having trouble with the implementation. This is what I have so far and all it does is render the second light (at (100, 100)).
void draw( sf::RenderWindow& target )
{
lightShader.setParameter("lightpos", sf::Vector2f( 960.f, 640.f ) );
buffer1.clear( sf::Color::Transparent );
buffer1.draw( buffer1Sprite, &lightShader );
buffer1.display();
lightShader.setParameter("lightpos", sf::Vector2f( 100.f, 100.f ) );
buffer2.clear( sf::Color::Transparent );
buffer2.draw( buffer1Sprite );
buffer2.draw( buffer2Sprite, &lightShader );
buffer2.display();
target.draw( buffer2Sprite );
}