Original Post
Hello. I created a vector: #define MAXTILES 3 typedef std::vector Tileset; then i tried to load some picture into my vector: Tileset tileset(MAXTILES); int i; char str[32]; for(i = 0; i < MAXTILES; i++) { memset(str, '\0', 32); sprintf(str, "graphics/texture%d.png", i); tileset.push_back(IMG_Load(str)); } And when I'm trying to Blit some of these picture i get a black screen, nothing :something like SDL_BlitSurface(tilset[0/1/2], NULL, screen, &offset); I Tried also SDL_BlitSurface(tilset.at(0/1/2), NULL, screen, &offset); Am i doing something wrong? BTW its my first experience with vectors.