Added texture unit store/restore to keep embedded context in sane state