void Viewport::setBounds(Recti bounds) { sprite->setBounds(bounds); if (target.isValid()) { target->setSize(bounds.getSize()); } }
Rect::Rect(const Recti &r) : position(r.getPos()), size(r.getSize()) { }