Here's the deal sparky. Using 0.7.3. I've got a 2d projection matrix with texture2d set to aliasing, (see code below) but I am still getting seams (gaps) between tiles if I position my TileMapAtlas between pixels (on a fraction position, like 0, 0.5). I find that when using MoveBy I'll frequently end up w/ my TileMap on a fractional position. I am contemplating hacks to fix this and am curious if anyone w/ more experience has any suggestions or input. The hacks I am thinking about using are:
1- Change the "setPosition" method of CocosNode to round the position.
-(void) setPosition:(CGPoint) pos
{
position.x = round(pos.x);
position.y = round(pos.y);
}
2- Implement a "setPosition" method on TileMapAtlas that rounds the position
2a- or inherit a new "WholeNumberTileMapAtlas" that will round it's position when being set.
3- Rework all the "MoveBy" type functions to only move by whole pixels (no fractional positions).
Any suggestions on how to best go about this? I'm concerned that the rounding of position may break other things. Any feedback would be much appreciated.
[[Director sharedDirector] set2Dprojection];
[Texture2D setAliasTexParameters];
TileMapAtlas* tilemap1 = [TileMapAtlas tileMapAtlasWithTileFile:@"tiles.png"
mapFile:@"level.tga"
tileWidth:32
tileHeight:32];
[tilemap1 setPosition:ccp(0,0.5)];
[self addChild:tilemap1];
[Texture2D restoreTexParameters];