Be sure to declare the sw renderer first

Otherwise we will have problems caclulating the bounds
with a gl renderer when no gl context is set