Optimize SDL buffer copying.