11 refactoring texture manager