Xna game development - Game background issue

xna

Solution

One way would be to separate your image into smaller tiles and draw the visible ones.

However this technique suffers from a problem when bilinear sampling is used, because the colors bleeds from the one side of the texture to the other. You can probably compensate by disabling texture WRAP sampling or by grabbing a single of pixels from the tiles next to.

For example if you want 256x256 textures, you would only display 255x255 tiles, because one line (right and bottom) is a copy from the tiles next to it.

Hope it makes sense, otherwise I'll have to paint a picture :-)

Problem

Im starting with XNA and i need an advice about the following. I have a .jpg file with my space ship game background with the following size: ``` width: 5000px height: 4800px ``` When i try to load the texture i get the following error: Texture width or height is larger than the device supports What is the most used technique to move the background at the same time that your ship is moving? Thanks a lot. Kind Regards. Josema.

Original source