26 (edited by BeaR 2015-08-16 15:29:11)

Re: Revamp automappers

From my own tests I propose to use broderadd or borderset instead of borderfix as the overall result is better. Borderfix does some nearest-neighbour downsampling with 1px border. Borderadd/set only add borders and don't affect the actual input. The difference between 1px and 2px borders aren't that significant iirc, also depends on the displayed mipmap, which changes with the screen resolution.

0.7 won't need this at all btw.

27

Re: Revamp automappers

Thanks for your reply. Can you explain a little more about these borders, why they're needed and why they need to be 1px or 2px wide?

One little annotation from me:

BeaR wrote:

Borderfix does some nearest-neighbour downsampling with 1px border.

The result of this is:

heinrich5991 wrote:

this tool drops the 17th and 49th column of each tile and duplicates the first and last one instead.

28

Re: Revamp automappers

As we use 1024x1024 tilesets and 64x64 pixels, during the mipmap generation no kind of `bleeding` happens because of the downscaling. The actual issue is the bilinear texture sampling while rendering. To avoid samples from the neighbouring the texture coordinates need an certain offset. Here is an in-depth view about it https://msdn.microsoft.com/en-us/librar … 85%29.aspx .

This offset depends on the chosen mipmap level and the minifcation/magnification, which is hard (impossible?) to calculate without shaders. Teeworlds does approximate it and the border helps to reduce the appromixation errors.

29 (edited by 2015-08-16 21:38:02)

Re: Revamp automappers

BeaR wrote:

0.7 won't need this at all btw.

Good none of this makes any since to me.

BeaR wrote:

As we use 1024x1024 tilesets and 64x64 pixels, during the mipmap generation no kind of `bleeding` happens because of the downscaling.

Do you mean to say that my tileset(the hole image) needs to be 1024x1024? and each tile needs to be 64x64 with or without a 1 or 2 pixel border? Are all these Borderadd/set things a scripts that I can run on my images?  If so where can I get them?

As you can see from my original post all my tile sets are 6x14 tiles or 384x896 px.  is this 1024x1024 a hard requirement made by Teeworlds?  If so why can't Teeworlds accept tilesets that are multiples of 64x64?

say for example I only want to make a one Tree tileset that is 4x4 tiles or 256x256 px.  Why could Teeworlds just see this as a 4x4 object?

In the middle of typing this post I figured out what was wrong with my tileset.  I found out that indeed Teeworlds does have a 1024x1024 hard rule on the tilesets that it will accept.  My problem that I was having is that when I tried to load my tileset teeworlds say a 384x896 image and forced it to be a 1024x1024 tileset.  This gave me a stretched look that I did not understand.

I thought that my tiles were not the right pixel height and width there for it was zoomed in to much. Now I know that teeworlds was stretching my tiles. also I did confirm that the first tile in a tile set must be empty... I have no idea why this is.. actually I do. I think the old way of doing things cartographers would hold space to reveal the available tiles for this layer.  There not being an eraser tool the first tile needs to be empty in order to provide a way to erase tiles.

I am used to a different system and new to the way teeworlds do things.  In my opinion a lot about this system could and should be changed to make cartography a hole lot easter, intuitive and user friendly.  I was planing on making a post on my thoughts for a new map editor mode. 

I will update my tilesets to reflect my new discoveries soon.

Jesus is my Lord and Savior. Praise be unto God for giving us a way to live with him.

Check out my DeviantArt for all my TeeWorlds art and ideas for Teeoworlds