Rendering Textures over 256x256?

Started by 9kaywun, June 16, 2012, 10:30:51 AM

Previous topic - Next topic

9kaywun

When I render a sprite such as this one: http://troll.ws/i/hOjXrL.png it comes out deformed on the game screen.. How can I render it to be the same size as the actual image?

Code used to render the sprite.. (works fine with sprites under 256x256)
getBuffer().blit(TextureManager.getInstance().getTexture("chatbox"), 0, 0, (int) x, (int) y, X, Y, FrameBuffer.OPAQUE_BLITTING);
Developing a 3D multiplayer engine using jPCT:
Deleted, will return soon..

EgonOlsen

Depends on what you use for X and Y...

9kaywun

Quote from: EgonOlsen on June 16, 2012, 10:36:01 AM
Depends on what you use for X and Y...

Disregard the naming, X and Y are size variables and are equal to the dimensions of the chatbox sprite.
Developing a 3D multiplayer engine using jPCT:
Deleted, will return soon..

EgonOlsen

Should actually work then...if you scale the sprite to a width and height that are powers of 2. Everything else will be scaled to 256*256...maybe that's your problem!?