Tiled Map Editor: Make isometric tiles connect seamlessly/remove staircase effect - tile

I am using the TiledMap editor, with a set of Tiles I got from opengameart,
I am using an isometric map, yet I just can't get these tiles to connect without this "stair-stepped" effect.
Any help is appreciated.

The editor "blindly" renders rows of tile-images, These rows are too far apart, leading to this staircase effect. Reduce the map tile height (65 in your screenshot) so that it fits.

Related

Add marker/dot on image at accurate pixel with zoom in/out functionality

I'am using reactJS and want to design a component with following functionality :
Display pixelated image which is able to zoom in and zoom out at pixel level.
When clicked on image , display a marker- which can be a dot or icon at specific position.
When image is zoomIn/zoomOut, marker size and position should not change.
Even after zoomIn/zoomOut when clicked on image, marker should get repositioned at proper pixel on the image.
I am thinking of applying same logic as used in the maps/ leaflet. Like they maintain separate layers for map and markers on the map. If we zoomIn/out maps it won't affect the marker position or size, same functionality I want for the image.
Anyone with the solution or related library will be welcomed !
(For reference, I want this design for marking GCP(Ground Control Points) on the image, which requires very precise marking at pixel level)

Zoom & crop an image and draw an svg-square on top (in angular)

"A stackblitz is worth a thousand words": https://stackblitz.com/edit/angular-zoom-crop-marker
Basically what I'm trying to do is to have a square drawn above a certain position in an image (<img>), and have that dynamically adjust to the image while being zoomed in / out and cropped. The stackblitz link has 3 views, the basic view which is a plain image, a zoomable view (which I got working as well) and a view where the imaged is "zoomed in and cropped" while being zoomable - This is where I need your help.
Should I crop using object-fit in some way? Is it better if I use a canvas to handle this? I've been at this for a whole day I and I feel my css knowledge is too limited to pull this of.
Bonus question: How would I go about to have the zoom-in zoom-out buttons add/remove one image per row using only css flex-box? (ie: not statically adding x pixles in height and width, but rather increase or decrease the size of each image so that another image is removed or added (per row) while always filling up all the available space)
Thank you in advance!
Managed to solve it myself. stackblitz updated with a working solution.

How to handle transitions in container size in OpenLayers 3

When an OpenLayers 3 map is resized, the contents of the map are stretched to fit the new map size. This is typically fixed by calling map.UpdateSize() after the change for the map to adapt.
However, I'm wondering how to achieve a smooth transition for the map contents when animating the width of the map.
Here is a minimal example of the problem.
The map resizes in a very unpleasant way before the update happens.
I figured out that changing the ol.Map renderer to 'dom' fixes the issue, but unfortunately this is not an option for me.

Cocos2d grid design for drawing lines

Hello guys
I have a small problem while designing a iphone game with a grid using cocos2d.
The game needs a 10x10 grid in the middle of the screen (it is not covering the entire screen).
A line is drawn at runtime where the user touches two points in the grid.
Question: would tilemap be ideal for this problem? As i need to verify the co-ordinates do belong to the grid or not when the user touches a point would tilemap be useful?
Question: Is there any better way of solving this in cocos2d. Please help me out.
Thanks
I wouldn't recommend using tilemap for this. Personally I'd do it all with math.
Lets for arguments sake say your grid squares are 10px by 10px.
You now instantly know the positions of the rects for each square.
top right square would be (90, 0, 10, 10), this obviously doesn't include the positioning of your grid, but you can easily add that onto this by adding.. (90+gridPos.x, 0+gridPos.y, 10, 10).
Then you just check your touches intersect the rects of the grids.
Drawing a line is fairly simple, i imagine you'd draw it from the center of the 2 grid points.
So if the line started in the top right grid square it's initial point would start at (90+gridPos.x, 0+gridPos.y, 5, 5), or (90+gridPos.x, 0+gridPos.y, gridSquareHeight/2, gridSquareWidth/2)
Using cocos2d it's pretty easy to also make every square a touchable sprite, that can react when touched however you like, sending a message back to a delegate or even just doing a visual effect.
There are tonnes of possibilities for solving this problem.

How to avoid Alias when rotate the image in gdi+?

I have a problem on roating an Image on a canvas in gdi+, I am using the following code, however I find there are alias on the edge.
myPathMatrix.Rotate(GetDCAngle(), MatrixOrderAppend);
myPathMatrix.Translate(
GetDCX(),
GetDCY(),
MatrixOrderAppend);
canvas->SetTransform(&myPathMatrix);
canvas->Draw(XXX);
I used the following code to remove the alias, but failed.
canvas->SetInterpolationMode(InterpolationMode::InterpolationModeHighQualityBicubic);
canvas->SetSmoothingMode(SmoothingModeAntiAlias);
How can I remove the alias at rotated image's edges.
Many thanks!
It's been a while since I worked with GDI+, but I'd assume there's no effective option to remove antialiasing around the edges when rotating. The reason is basically that pixels are square. To rotate an image an amount other than a multiple of 90 degrees, you need to use some kind of interpolation to estimate pixel colours where there weren't really pixels before.
So if there's nothing in the library to specifically take away antialiasing around the edges, have you thought about drawing hard lines in the background colour along the borders? It should be easier to draw those lines without any antialiasing.

Resources