Downscaling resampling tutorial

Sprites, textures, sounds, code, and other resources belong here. Share and share-alike!
Forum rules
Before posting your Resource, please make sure you can answer YES to any of the following questions:
  • Is the resource ENTIRELY my own work?
  • If no to the previous one, do I have permission from the original author?
  • If no to the previous one, did I put a reasonable amount of work into the resource myself, such that the changes are noticeably different from the source that I could take credit for them?
If you answered no to all three, maybe you should consider taking your stuff somewhere other than the Resources forum.

Consult the Resource/Request Posting Guidelines for more information.

Please don't put requests here! They have their own forum --> here. Thank you!

Downscaling resampling tutorial

Postby Cage » Fri Feb 17, 2012 4:37 pm

Hello, just a little bit of (maybe) useful info, if you're scaling down textures. For Photoshop, might be translatable to other software.

Here's my texture I've picked up on http://www.texturemate.com/
Image

Liked the colours and details. Let's make a Doom texture out of it! We can use the full texture, it doesn't need croping. 3888x2592 is a bit too much for our needs so let's scale it down.

Image

I've highlighted the resampling droplist. Here are the results:

Image
Nearest neighbor
Whoever scaled down photo textures for use in oldschool stuff like Duke/Doom/whatever, probably tried using this resampling method since.. it's not doing any resampling. While it should work in theory, with things looking nice and pixelly, the end result is just too rough and details start to look like noise.

Image
Bicubic. Oooh, smooth. Too smooth. Almost being blurry :P It's like the opposite of the above result - instead of being noisy it's blurry.

Image
Bicubic sharper. OH GOD PLEASE NO. The result looks like the above bicubic result but with ugly SHARPEN filter aplied. NO.

Image
Bilinear. It's - it's smooth while a bit better at preserving the details than bicubic. I think it's the best solution for scaling down textures to oldschool sizes ;) While you're difference may be subtle for you, non-graphic-nerds, it just feels right in my opinion.

After making it tileable and some tablet and brush tool voodoo you can get something like this:
Image

Cheers and hope this helps in anyway.

GIMP:

ETTiNGRiNDER wrote:Just did a quick poke around with GIMP, which, disregarding "None", has "Linear" "Cubic" and "Sinc". Sinc appeared to have the best effect, but oddly, Linear and Cubic seemed to have reversed effects from what you had with Photoshop (Linear was the blurry one and Cubic was better looking).

Thanks!
Last edited by Cage on Fri Feb 17, 2012 6:23 pm, edited 1 time in total.
User avatar
Cage
A trash bag full of empty coke bottles
 
Joined: 08 Jan 2006
Location: San Escobar
Discord: Cage#9861

Re: Downscaling resampling tutorial

Postby Tormentor667 » Fri Feb 17, 2012 4:50 pm

Awesome :)
User avatar
Tormentor667
needs more detail
 
Joined: 16 Jul 2003
Location: Germany

Re: Downscaling resampling tutorial

Postby ETTiNGRiNDER » Fri Feb 17, 2012 6:04 pm

Cage wrote:For Photoshop, might be translatable to other software.

Just did a quick poke around with GIMP, which, disregarding "None", has "Linear" "Cubic" and "Sinc". Sinc appeared to have the best effect, but oddly, Linear and Cubic seemed to have reversed effects from what you had with Photoshop (Linear was the blurry one and Cubic was better looking).
User avatar
ETTiNGRiNDER
Do not bother me about my old sprites/textures just use them
 
Joined: 30 Jan 2010

Re: Downscaling resampling tutorial

Postby Cage » Fri Feb 17, 2012 6:36 pm

ETTiNGRiNDER wrote:
Cage wrote:For Photoshop, might be translatable to other software.

Just did a quick poke around with GIMP, which, disregarding "None", has "Linear" "Cubic" and "Sinc". Sinc appeared to have the best effect, but oddly, Linear and Cubic seemed to have reversed effects from what you had with Photoshop (Linear was the blurry one and Cubic was better looking).


Since a lot of people here use Gimp (or seems so) I've added that to the first post. Thanks!
User avatar
Cage
A trash bag full of empty coke bottles
 
Joined: 08 Jan 2006
Location: San Escobar
Discord: Cage#9861

Re: Downscaling resampling tutorial

Postby Enjay » Fri Feb 17, 2012 6:49 pm

The options in Paint Shop Pro:

Image

"Smart size", I think, just seems to pick bilinear if the image is 24 bit or greyscale and pixel if it is 256 colours or less. Pixel resize does no filtering/resampling.
User avatar
Enjay
Everyone is a moon, and has a dark side which he never shows to anybody. Twain
 
 
 
Joined: 15 Jul 2003
Location: Scotland

Re: Downscaling resampling tutorial

Postby Gez » Fri Feb 17, 2012 6:54 pm

ETTiNGRiNDER wrote:oddly, Linear and Cubic seemed to have reversed effects from what you had with Photoshop

They're not the same. Linear isn't bilinear; and cubic isn't bicubic, AFAIK.
Gez
 
 
 
Joined: 06 Jul 2007

Re: Downscaling resampling tutorial

Postby Cage » Fri Feb 17, 2012 7:04 pm

Another method of downscaling is to scale your texture x4 of your destination size ((x2, x3, work too) and use a Pixelate -> Mosaic filter or equivalent - it changes your picture into pixels.

Image

Then scale it to desired size with NEAREST/no resampling/pixel resize/whatever

This nets the same results as bilinear in PhotoShop, though.
User avatar
Cage
A trash bag full of empty coke bottles
 
Joined: 08 Jan 2006
Location: San Escobar
Discord: Cage#9861

Re: Downscaling resampling tutorial

Postby printz » Sat Feb 18, 2012 2:56 am

I like all downscaling variants, they make the texture look different enough depending on application.
User avatar
printz
BOW BEFORE ME!
 
Joined: 26 Oct 2006
Location: Bucharest, Romania

Re: Downscaling resampling tutorial

Postby NeuralStunner » Sat Feb 18, 2012 4:56 am

I have something to add!

3x3 tile your texture before you scale it down, then crop the center back to intended final size. This makes sure that any blending will be tilable, and avoid sharp edges at the texture boundaries.
User avatar
NeuralStunner
An Exercise in Self-Indulgence
 
 
 
Joined: 21 Jul 2009
Location: Indiana, USA
Discord: NeuralStunner#1293
Operating System: Windows Vista/7 64-bit


Return to Resources

Who is online

Users browsing this forum: doomcooker and 3 guests