Expose clear and swap to renderer struct and use them.