Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Plain Object Texture Size

Author
Message
Gunslinger
19
Years of Service
User Offline
Joined: 29th May 2007
Location:
Posted: 10th Mar 2012 12:53
Hello, i've got a problem.
If i texture my plain objects with a image, the "texture" gets stretched / blurred.

Because a plain object of weidth & height 150x150 isn't 150px * 150px texture size.

How can i fix that?

Best regards.

Fallout
23
Years of Service
User Offline
Joined: 1st Sep 2002
Location: Basingstoke, England
Posted: 10th Mar 2012 17:21 Edited at: 10th Mar 2012 17:21
Take a look at the SCALE OBJECT TEXTURE command. You can modify how big the texture is across the object and should be able to adjust it so it's not stretched at all. If the texture is then non aligned properly, look at the SCROLL OBJECT TEXTURE command, which will help you reposition it on the plain.

Pincho Paxton
23
Years of Service
User Offline
Joined: 8th Dec 2002
Location:
Posted: 10th Mar 2012 22:11 Edited at: 10th Mar 2012 22:13
Can't you just fix it in Photoshop? When I use 150x/y on an 150px image it looks identical.

mr Handy
18
Years of Service
User Offline
Joined: 7th Sep 2007
Location: out of TGC
Posted: 15th Mar 2012 15:10
Just keep the aspect ratio of texture and plain. Although, as you are not using paste sprite technique, your sprites always will be resampled and not pixel perfect.
WLGfx
18
Years of Service
User Offline
Joined: 1st Nov 2007
Location: NW United Kingdom
Posted: 16th Mar 2012 14:42
Also some graphics cards will pad out the image when its on the GPU to power of 2. Does on my dodgy laptop. So your 150x150 image is likely to get padded to 256x256.

Mental arithmetic? Me? (That's for computers) I can't subtract a fart from a plate of beans!
Warning! May contain Nuts!

Login to post a reply

Server time is: 2026-07-10 09:47:26
Your offset time is: 2026-07-10 09:47:26